[Win32utils-devel] win32-security rough idea
djberg96 at gmail.com
Mon Jul 7 23:51:21 EDT 2008
On Mon, Jul 7, 2008 at 9:05 PM, Heesob Park <phasis at gmail.com> wrote:
> 2008/7/8 Berger, Daniel <Daniel.Berger at qwest.com>:
>> Hi all,
>> How does this look?
>> require 'win32/security'
>> include Win32
>> s = Security::SID.new('djberge')
>> s.length => 28
>> s.account => 'djberge'
>> s.domain => 'mydomain'
>> s.sid => '\001...'
>> s.account_type => 'user'
>> s.to_s => S-1-5-21-55555-444444-88-118888-999999
>> s.valid? => true
>> s == s => true
> It looks good.
>> Here's the implementation so far (more comments at end):
>> I wasn't sure if SID.new should refer to an existing account, or
>> actually create a new SID via InitializeSid() or something. My current
>> idea is to setup a SID.create method for actually creating a new SID.
>> Does that seem reasonable? Or does that seem counterintuitive?
>> Anyway, there you go. Please let me know what you think.
> That seems reasonable. Go ahead please.
Ok, I've committed what I've got so far to CVS. :)
More information about the win32utils-devel