-
Notifications
You must be signed in to change notification settings - Fork 184
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add lookup of account names by SID #228
Add lookup of account names by SID #228
Conversation
Thanks for the change! |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
lgtm, small suggestion
This commit adds a new function LookupNameBySid that wraps LookupAccountSidW and works as an inverse of the already existing LookupSidByName. In addition to offering new functionality, this fixes #202. Signed-off-by: Michael Hofmann <[email protected]>
@ambarve ptal |
} | ||
|
||
name = windows.UTF16ToString(nameBuffer) | ||
return name, nil |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nit: I thought we decided to change this to return windows.UTF16ToString(nameBuffer), nil
?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One minor comment but otherwise LGTM!
This commit adds a new function
LookupNameBySid
that wrapsLookupAccountSidW
and works as an inverse of the already existingLookupSidByName
. In addition to offering new functionality, thisfixes #202.
Signed-off-by: Michael Hofmann [email protected]