SharePoint does not provide support for AD Groups and SharePoint AD Groups through the API.
If you are using AD Groups on your SharePoint you might find limitations with the target users functionality of our web parts.
To minimize this issue we implemented a workaround explained below that in some scenarios allow the use of target users functionality with AD.
- Open a SharePoint Group in your site collection
- Add your AD Group as a member of the SharePoint group
- Edit the Group's Settings
- Set the "Who can view the membership of the group?" option to "Group Members"
- In the Target User fields, use the SharePoint Group
Using this setup, the web part knows that if a user can see the members of this group, he is most likely a part of the group.
Note that Admins and users with permission to see any group's membership will be assumed to be a part of the group even if they're not. As a result, this workaround won't be effective at hiding content from these users.