Setting IpSecurity for physical directory
Web Server forum
Back To The Forum Home!Search!Private Messaging System

Web Server Talk Web Server Talk > Web Servers reviews > IIS server support > IIS Server Security > Setting IpSecurity for physical directory




  Last Thread   Next Thread Next
  Show Printable Version Email this Page Subscribe to this Thread      Post New Thread    Post A Reply      

    Setting IpSecurity for physical directory  
Sebastien Nadeau


View Ip Address Report This Message To A Moderator Edit/Delete Message


 
10-16-04 02:25 AM

Hi,

Using VBScript I'm able to set IpSecurity for a virtual directory in
IIS6, but not for a physical directory. MSDN explicitly specify that
it is possible to set this property for both virtual and physical
directories. I'm puzzled. Example script:

_BEGIN_
Dim SecObj
Dim MyIPSec
Dim IPList
Set SecObj = GetObject("IIS://LocalHost/W3SVC/1/ROOT/MyDir")
Set MyIPSec = SecObj.IPSecurity
If (TRUE = MyIPSec.GrantByDefault) Then
MyIPSec.GrantByDefault = FALSE
End If
IPList = MyIPSec.IPGrant
ReDim IPList(1)
IPList (0) = "123.123.0.0,255.255.0.0"
MyIPSec.IPGrant = IPList
SecObj.IPSecurity = MyIPSec
SecObj.Setinfo
_END_

This works for a Virtual Dir (and even for ROOT), but when running it
against a Physical Dir, I run into the following error message:

Code 80070003
The system cannot find the path specified.

The physical directory is there, but not in the XML Metabase. I wonder
what I'm doing wrong.

Sébastien Nadeau
Technicien en informatique
Bibliothèque de l'Université Laval






[ Post a follow-up to this message ]



    Sponsored Links  




 





   All times are GMT. The time now is 12:39 PM.      Post New Thread    Post A Reply      
  Last Thread   Next Thread Next


Most Popular forums 

Forum Jump:
Rate This Thread:

Forum Rules:
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is OFF
vB code is ON
Smilies are ON
[IMG] code is OFF
 
Medical and Health forum | Computer Games Reviews | Graphics design forum

Back To The Top
Home | Usercp | Faq | Register