views:

493

answers:

1

Hi all,

I am looking for a way to set permissions on a virtual directory through command line.
I have a website setup with scripts only permission, but one of the child virtual directories needs to have scripts and executables.

So far, I haven't found a command line option to change the permissions for 6.0 - I saw the chacess command for 5.1 but it is not available in my system...

Is there an equivalent or another function that can do this for me?

Thanks, Christy

A: 

Found it :-)

In case anyone else needs the information - here goes:

use the adsutil.vbs script (usually under inetpub/adminscripts) and type

adsutil.vbs set w3svc/[site id]/AccessExecute "True"

The [site id] is the unique id IIS gives your site. I found another script that gives the site number and name in a nice output:

http://blog.crowe.co.nz/archive/2005/12/08/346.aspx

Hope this helps! Christy

Note: if you are setting a virtual directory - at least the way mine is set up the command is> adsutil.vbs set w3svc/[site id]/root/[virtual directory]/AccessExecute "True"