Hi, is it possible to audit logins by profiler by using domain group?

  • We are designing an audit process based on sql profiler bu the users to be audited are belonged to a win domain group to which people can be added and removed, is there a way to filter by groupname/sid in profiler? Thanks..

  • Not that I'm aware of, but you can use xp_logininfo to list the members of the group.

    John

  • Take a look at extended events. You can capture the login event and then add the nt_username global field. There's also a session_nt_username as well as a username global field. I'm fairly certain one of those is going to give you what you need.

    "The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood"
    - Theodore Roosevelt

    Author of:
    SQL Server Execution Plans
    SQL Server Query Performance Tuning

  • I realized that we can use a like filter based on domain account pattern: 'domain\[a-z][a-z][0-9][0-9][0-9][0-9]%', this seems to work, thanks for the replies..:-)

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

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