PowerShell Team

On an internal mailing list someone asked how to get the SID for the current context using PowerShell.  Chris Bellée correctly responded:



I used this to create a script:  Get-Me.ps1

# Get-Me.ps1



PS> .\get-me.ps1

AuthenticationType : NTLM
ImpersonationLevel : None
IsAuthenticated    : False
IsGuest            : False
IsSystem           : False
IsAnonymous        : False
Name               : JPSLAP14\Guest
Owner              : S-1-5-21-2812635655-1585162248-3907382133-501
User               : S-1-5-21-2812635655-1585162248-3907382133-501
Groups             : {S-1-5-21-2812635655-1585162248-3907382133-513, S-1-1-0, S
                     -1-5-32-546, S-1-5-32-545…}
Token              : 1128


Simple – Useful – PowerShell 🙂


Jeffrey Snover [MSFT]
Windows Management Partner Architect
Visit the Windows PowerShell Team blog at:
Visit the Windows PowerShell ScriptCenter at:


Discussion is closed.

Feedback usabilla icon