Skip to content
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

Merged
merged 1 commit into from Jul 6, 2022

Conversation

mversiotech
Copy link
Contributor

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 michael.hofmann@bitgestalt.com

@mversiotech mversiotech requested a review from a team as a code owner December 3, 2021 09:24
sd.go Outdated Show resolved Hide resolved
sd.go Outdated Show resolved Hide resolved
sd.go Outdated Show resolved Hide resolved
@dcantah
Copy link
Contributor

dcantah commented Feb 5, 2022

Thanks for the change!

@dcantah dcantah self-assigned this Feb 5, 2022
Copy link
Contributor

@dcantah dcantah left a 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 microsoft#202.

Signed-off-by: Michael Hofmann <michael.hofmann@bitgestalt.com>
@dcantah
Copy link
Contributor

dcantah commented Mar 8, 2022

@ambarve ptal

}

name = windows.UTF16ToString(nameBuffer)
return name, nil
Copy link
Contributor

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?

Copy link
Contributor

@ambarve ambarve left a 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!

@dcantah dcantah merged commit 4ed8d49 into microsoft:master Jul 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Test case fails because of localized account names
3 participants