ok, maybe i am missing something here, but according to the docs ResolveSid SHOULD return a text representation of the SID. i am getting nothing back, not even 0. the variable isn't even initializing.
-----Original Message----- From: John Deretich [mailto:[EMAIL PROTECTED] Sent: Friday, March 28, 2003 7:36 AM To: Raymond Forbes Cc: Perl-Win32-Admin-Request (E-mail) Subject: RE: Win32::Perms Raymond, try using $result2 = Win32::Perms::ResolveSid ("W2KASVM1\\administrator") with $result3 = Win32::Perms::ResolveAccount ("W2KASVM1\\administrator"); your missing some parameters in both function calls, for ResolveSid( $Account [, $BinarySid ] ) $Account = "W2KASVM1\\administrator"; initialize $Binarysid and the sid will be created for you, then use ResolveAccount( $Sid ) which will give you what your looking for which I think is the account name. I found this info on http://www.roth.net/perl/perms/#ResolveSid. or use Win32; if (Win32::LookupAccountName( $Machines, $Account, $Domain, $Sid, $Type ) ) { if (Win32::LookupAccountSID( $Machines,$Sid, $Account, $Domain, $Type ) ) { print "$Machines $Account $Domain $Type \n"; John -----Original Message----- From: Raymond Forbes [mailto:[EMAIL PROTECTED] Sent: Friday, March 28, 2003 12:52 AM To: [EMAIL PROTECTED] Subject: RE: Win32::Perms let's try that again... - --------------------------------------------------------- i am at my wits end on this one. first, pertinent info... c:\dev\ioactive>perl -v This is perl, v5.6.1 built for MSWin32-x86-multi-thread (with 1 registered patch, see perl -V for more detail) Copyright 1987-2001, Larry Wall Binary build 635 provided by ActiveState Corp. http://www.ActiveState.com Built 15:34:21 Feb 4 2003 Win32-Perms [0.2002.06.05] The Win32::Perms extension for Win32 X86. ok, now to the problem. for some reason i cannot get this to work in any reasonable way. i am not sure if i am doing something wrong, or ifit is a misconfiguration but i thought i would run it by everybody here. here are some examples of things that don't work.... use Win32::Perms; $dir = 'c:/inetpub'; $perm = new Win32::Perms ($dir); $result = $perm -> CheckSD(); print $result; ( $result is always 0 here) $result2 = Win32::Perms::ResolveSid ("W2KASVM1\\administrator"); print "the sid is:$result2\n"; this returns nothing in $result2. not sure if it is a NULL or UNDEF or what. the part that is so frustrating is it's impossible to see what is actually going wrong. since i can't get the Win32 error messages to bubble to the top, i don't even know where to begin. _______________________________________________ Perl-Win32-Admin mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs _______________________________________________ Perl-Win32-Admin mailing list [EMAIL PROTECTED] To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
