Microsoft KB Archive/324064

From BetaArchive Wiki

Article ID: 324064

Article Last Modified on 11/21/2006



APPLIES TO

  • Microsoft Windows 2000 Server
  • Microsoft Windows 2000 Advanced Server
  • Microsoft Windows 2000 Professional Edition
  • Microsoft Small Business Server 2000 Standard Edition
  • Microsoft Internet Information Services 5.0
  • Microsoft Windows Services for UNIX 3.0 Standard Edition



This article was previously published under Q324064

SUMMARY

You can use the .Htaccess files to set individual properties and configuration settings for a folder. If you do so, you do not have to modify the full configuration file. You can configure some of these settings in Internet Information Services (IIS); however, you must use the main Internet Services Manager snap-in to change other settings. This article describes how to migrate .Htaccess settings to IIS.

back to the top

Limiting Access by IP Address

The .Htaccess file uses the Order, Allow, and Deny directives to limit access by Internet Protocol (IP) address or domain name.

To limit access according to IP address or domain name in IIS:

  1. Right-click the folder, the existing file, or the Web site, and then click Properties.
  2. Click either File Security or Directory Security.
  3. Click Edit in the IP Address and Domain Name restrictions section.

NOTE: In IIS (unlike Apache), an explicit Deny directive always applies, even if an Allow directive would typcially override it.

back to the top

Configuring Authentication Settings

To configure the authentication settings for a folder or a file, you must migrate the user and group information to the Windows 2000-based server.

To configure authentication settings:

  1. Right-click the folder, the existing file, or the Web site, and then click Properties.
  2. Click either File Security or Directory Security.
  3. Click Edit in the Anonymous access and authentication control section.

back to the top

Configuring Folder Settings

You can use the Options directive in Apache Directory directives and .Htaccess files to configure folder-specific settings. To grant the Execution permission for CGI on a folder in IIS, (CGI is equivalent to the ExecCGI option in Apache):

  1. Right-click the folder, and then click Properties.
  2. Click either the Home Directory tab or the Directory tab.
  3. Select the Execute permission for a script in the Execute Permissions section.
  4. To allow specific extensions to be run with specific programs, click Create to create a new program, and then click Configuration to edit the file name extension or program mappings.

To configure the folder so that users can browse the folder contents in IIS, (which is the equivalent to the Indexes option in Apache):

  1. Right-click the folder, and then click Properties.
  2. Click either the Home Directory tab or the Directory tab.
  3. Click to select the Directory Browsing check box.

back to the top

Configuring the Default Folder File

To change the list of default documents or their preference order in the same way that you do with the DirectoryIndex directive in an .Htaccess file:

  1. Right-click the folder, and then click Properties.
  2. Click the Documents tab.
  3. Click Add to add a new default document, or click Remove to delete an existing default file from the folder listing.
  4. Click an existing document, and then use the UP ARROW key and the DOWN ARROW key to change the priority of the item.

back to the top

Redirecting URLs

The .Htaccess file uses the Redirect directive to redirect a file or folder to another URL, for example:

Redirect /old_file.html
http://www.domain.com/new_folder/new_folder.html


You can either use Internet Services Manager to redirect a URL or you can create the Default.asp folder in the folder to which you want to redirect the URL.

To use Internet Services Manager:

  1. Right-click the folder, the existing file, or the Web site, and then click Properties.
  2. Click the Home Directory tab, the Directory tab, or the File tab, click A redirection to a URL, and then type the replacement URL in the Redirect to box.

For a user-defined solution, you can create a file called Default.asp in the folder in which you want to redirect the URL, and then use the Response.Redirect statement to redirect a request for a particular element, for example:

Response.Redirect /old_file.html
http://www.domain.com/new_folder/new_file.html


back to the top

REFERENCES

For additional information about how to redirect files and folders, click the article number below to view the article in the Microsoft Knowledge Base:

324000 HOW TO: Redirect URLs to Alternative Web Sites



For additional information about limiting access to a folder by IP address or configuring authentication settings, click the article number below to view the article in the Microsoft Knowledge Base:

324066 HOW TO: Restrict Site Access by IP Address or Domain Name


324222 HOW TO: Migrate User and Group Information


324068 HOW TO: Set IIS Permissions for Specific Objects



For additional information about securing IIS for migrating from UNIX to Windows, click the article number below to view the article in the Microsoft Knowledge Base:

324216 HOW TO: Secure IIS in a UNIX-to-Windows Migration


back to the top







Keywords: kbhowto kbhowtomaster KB324064