How do I get the domain\usernames of the members of a local group on Windows? Win32::NetAdmin seems to be broken in the version of Perl shipped with TeamSite. On a Perl forum I was told these are binary SIDs but that doesn't seem right because the API should not provide SIDs in one version and usernames in another. I can't figure out how to map SIDs to account names and even if I could this would break with a Perl upgrade, etc.
How are other people getting the users in a local group in Perl? Hopefully I don't have to shell out to net localgroup administrators and parse the results myself...
C:\temp>type users.ipl
use strict;
use Data:

umper;
use Win32::NetAdmin;
my @{users} = ();
if ( Win32::NetAdmin::LocalGroupGetMembers( '', 'administrators', \@{users} ) !=
1 )
{
print 'LocalGroupGetMembers call failed.' . ${/};
}
print Dumper( @{users} );
C:\temp>iwperl users.ipl
$VAR1 = '▲╟ⁿw↑4';
$VAR2 = '▲╟ⁿw↑4';
... and a bunch of beeps
C:\temp>c:\perl\bin\perl users.ipl
$VAR1 = 'admin';
$VAR5 = 'iwsupport';
...