Verification System using SIDs and Batch

luke127

The Ghost
Messages
868
Location
Australia
hey guys, quick programming problem I'm having an issue with solving. I'd like to use my user SID as an access verification system for certain sections of my batch script, how would I go about this? I've thought about using an IF statement, which is the obvious solution, but entering the SID is a long and tedious process considering the length and complexity of said ID. Is there a way to read from a file in batch?

Cheers,
Luke
 
Please be aware that this may be run in a domain environment, not just a home environment, and that I do not have administrative privileges in the domain environment. So I don't think wmic would work in the non-admin environment.

Cheers,
Luke

PS: I'm learning C# too :D Looking forward to stuffing around with it once I understand it better. (Most of the extremely basic stuff I learnt from Powershell and Batch, (such as variable assignments and what operators do, but syntax is drastically different lol)

(Thank god I started doing IF statements with parentheses indentation in my recent batch coding, it's helped a ton with C# hehe)
 
Last edited:
Back
Top Bottom