How to retrieve a Security Group objectSid using ADSI? RRS feed

  • Question

  • Hello,


    I'm trying to use ADSI to retrieve the objectSid for an NT Security Group using C++ but I can't seem to get the proper set of calls down. The IDirectorySearch::ExecuteSearch() combined with GetColumn() isn't working as I'm assuming the objectSid is a Constructed Attribute.


    Can someone please direct me to some sample code that I could use to return the objectSID for something like the "Users" group? I don't want to use anything with "Well Known RIDs" because this is a block of code that needs to work for any/all Global Security Groups listed in the A/D





    • Moved by Rob Pan Wednesday, January 25, 2012 5:32 AM (From:Visual C++ Language)
    Tuesday, January 24, 2012 11:06 PM

All replies

  • Hi,


    According to your description, I will move your thread to the correct forum for better support. Thanks for your understanding.


    Best Regards,



    Rob Pan [MSFT]
    MSDN Community Support | Feedback to us
    Wednesday, January 25, 2012 5:32 AM