Thread: 403 - Forbidden
View Single Post
  #11  
Old 06-08-2006, 04:56 PM
kinook kinook is online now
Administrator
 
Join Date: 03-06-2001
Location: Colorado
Posts: 6,003
It seems as though your user account doesn't have the necessary rights to access the IIS metabase (via the DirectoryEntry class), which the action needs to access to resolve the project's HTTP path to a local path.

The code that I suspect is failing is approximately:

using System.DirectoryServices;

DirectoryEntry root = new DirectoryEntry("IIS://localhost/W3SVC");
foreach (DirectoryEntry site in root.Children)
{
// ...
}

I do get that error when running the test program off of a network path, but not locally (with an admin user on a plain vanilla Win2K SP4+VS 2003 virtual machine). I'm not exactly sure which permission controls this (anybody out there know?).
Reply With Quote