Recipe 8.26. Enabling Web Sharing


Problem

You want to enable web sharing for a folder. This allows users from non-Windows-based PCs to view the contents of a share using the web.

Solution

Using a graphical user interface

  1. Open Windows Explorer.

  2. In the left pane, browse to the folder you want to share.

  3. Right-click folder and select Sharing and Security.

  4. Select the Web Sharing tab.

  5. Select Share this folder.

  6. A dialog box appears with the settings you can configure for the web share. Click OK when you are done.

  7. Click OK to close the dialog box.

Discussion

To use web sharing, you must have IIS installed and running. When you create a web share, you are doing nothing more than creating a virtual directory in IIS.

The security for a web share is a little different from that of a regular share: you have to select the access permissions and application permissions you want to use. Here is a list of access permissions:


Read

Allows web users to read files in the folder


Write

Allows web users to write files in the folder


Script source access

Allows web users to view the source code of scripts in the folder


Directory browsing

Allows web users to browse the folder contents

And here are the application permissions:


None

Does not allow the execution of scripts or programs


Scripts

Allows the execution of scripts, but not programs


Execute

Allows the execution of both scripts and programs

Keep in mind that NTFS and web server permissions also apply to web shares. If the user is accessing the share without authenticating, the permissions will be based on the IUSR account IIS is running under (normally IUSER_<computername>). If the user authenticates, permissions will be based on his or her credentials.

See Also

Recipe 12.5 in Windows Server Cookbook for more on creating virtual directories in IIS



Windows XP Cookbook
Windows XP Cookbook (Cookbooks)
ISBN: 0596007256
EAN: 2147483647
Year: 2006
Pages: 408

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net