
share permissions and enumerating shares
Hi,
security is not implemented in WinNT Provider for NT V4 and the lanmanager
object. With help of the ADSI SDK you may handle permissions on files and
the regsitry.
The only scripatblke way for shares is WMI. Download the SDK, it has a
sample for creating a share and apply permissions.
Hope, this helps.
Best regards,
Manfred Braun
(Private)
Lange Roetterstrasse 7
D68167 Mannheim
Germany
(Remove the anti-spam-underscore to mail me!)
Quote:
> Hi
> I am trying to find out how to enumerate shares on a computer and
> finding out what permission is on the share (not the file and
> directories underneath), but the share.
> Can anyone tell me how to do this. I know you can use net view
> \\computername to enumerate the shares and pipe that into a text file,
> but how about the permissions.
> I also know that you can read the registry key
> [HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\LanmanServer\Share
> s] and get a number that changes when you add different groups to the
> share permissions list but how do I resolve this to account names.
> TIA
> Bindu
> Sent via Deja.com http://www.deja.com/
> Before you buy.