Using sql to search inside an AD group

  • I am having issues with a LAN admin putting their username in a SQL AD group to gain access to SQL.

    Is there a way to use a SQL query to scan the inside of an AD group to see the members?

    I have been looking and haven't found a way yet. Any help would be greatly appreciated

    This way I can monitor the group from SQL.

    Thanks

  • Just replace Domain\SecurityGroup in the query below with the actual domain and security group you want to know about.

    EXEC xp_logininfo 'Domain\SecurityGroup','members'

  • Perfect! Works like a charm. Now I can track the members of my group.

    Thanks

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply