I needed to add new MIME types to Plesk running IIS 6 in order to allow download of Microsoft Office 2007 & 2010 files saved with the new office extensions (.docx, .xlsx, and .pptx). IIS 6 restricts the files it will serve by default, which is a good thing in my opinion, requiring administrators to explicitly configure support for additional MIME types.

Adding new extensions and their respective MIME types is pretty straightforward in IIS as you can verify from Microsoft here:

  1. Open IIS
  2. Right click “Web Sites” and select “Properties” to modify the global behavior (to modify a specific website right click the website instead)
  3. Select “HTTP Headers”
  4. Select “Mime Types”
  5. Enter the extension you wish to add and the appropriate mime type
  6. Repeat as needed for each extension
  7. Click “OK” to save your work and close all the dialogs

The tricky part is knowing the correct MIME type to use for each file extension. I had to search the Internet to find a list of MIME types I could trust and use. I chose to trust Microsoft and used the Office 2007 MIME type information here. Here are the MIME types I used:

  1. Microsoft Word (.docx): application/vnd.openxmlformats-officedocument.wordprocessingml.document
  2. Microsoft Excel (.xlsx): application/vnd.openxmlformats-officedocument.spreadsheetml.sheet
  3. Microsoft PowerPoint (.pptx): application/vnd.openxmlformats-officedocument.presentationml.presentation

Don’t forget to restart IIS or at least the World Wide Web Publishing service.

Parts of this post are taken from: https://www.helicontech.com/isapi_rewrite/doc/security.htm – these worked to resolve issues I was having with Plesk with custom sites but not with WordPress sites, which also required the plugin listed below.

Automatic installation of ISAPI_Rewrite on a clean default Windows system does not require any permission tweaking. But installing of some other products like Plesk, IIS Lock Down Tool, etc. may tighten server security and prevent ISAPI_Rewrite from correct operation. Here is a list of premissions required by ISAPI_Rewrite.

On Windows 2000, Windows XP and Windows 2003 in IIS5 compatibility mode filter runs in the inetinfo.exe process under the System account. Thus System account should be given at least Read and List Folder Content access to the folder locating ISAPI_Rewrite installation files. We also recommend giving System account general Modify permissions on this folder. That will allow creation of log files containing parse and other errors. The same permissions should be given to any web site folder containing .htaccess files or ISAPI_Rewrite will be unable to load and monitor it.

Pay special attention to any Deny permission settings on ISAPI_Rewrite installation directory because in Windows OS Deny permissions override any Allow premissions records.

On Windows 2003 in native IIS mode (WPI mode) and Windows Server 2008 both the filter and the proxy run in the w3wp.exe worker process corresponding to an application pool hosting particular web application. Each application pool could be configured to use its own identity. This could turn permissions configuration into a tricky task. However in a correct IIS configuration each used identity should be a member of IIS_WPG group. So, IIS_WPG group could be used instead of System account to assign required permissions as noted above.

On Windows Vista permissions configuration is almost the same as Windows 2003 configuration except that there is no IIS_WPG group there. So, all WPI accounts (usually NETWORK SERVICE is the only such account) should be given required permissions.

Additionally for proxy function to work you will need to enable at least “Scripts only” execution permission in the properties of web site or web application which will be running proxy.

There’s a handy plugin for WordPress + ISAPI_rewrite at https://wordpress.org/extend/plugins/isapi-rewriter

Generate a key on your local machine

ssh-keygen -t dsa

or

ssh-keygen -t rsa -b 4096

hit enter at the prompts and specifying a strong password

Copy the key to a remote machine

cat .ssh/id_dsa.pub | ssh username@hostname 'cat >> .ssh/authorized_keys'

or

cat .ssh/id_rsa.pub | ssh username@hostname 'cat >> .ssh/authorized_keys'

This should work whether you’re using Cygwin on Windows, Mac OS X, or some flavor of Linux

Need a place I can always get to this handy little string so that anytime I’m on someone else’s computer I can quickly add God Mode to the desktop. Just create a new directory on the desktop and name it as follows:

GodMode.{ED7BA470-8E54-465E-825C-99712043E01C}