April 27, 2017
Sometimes you need to get a clear view on which Security Policy is applied to a Users or other AD Object.
There are 2 Tools you can use :
1. Resultant set of Policies Snap-In
So as you can see on this AD User Object there are 3 GPO’s applied.
Which is important to know for Debugging Security Issues.
2. Command line version :
Run gpresult /Scope User /v
January 26, 2014
Ever wondered how you could publish your Active Directory in a SharePoint List. It will show all entries dynamically.
First of all you need to setup a linked server in MS SQL using the ADSL provider
-- CREATE LINKED Server to ADSI
-- sp_addlinkedserver 'ADSI', 'Active Directory Service Interfaces',
-- CREATE VIEW in the ICT DB
USE ICT ;
IF OBJECT_ID ('ADSI_USERS', 'V') IS NOT NULL
DROP VIEW ADSI_USERS ;
CREATE VIEW ADSI_USERS
SELECT * FROM OpenQuery (ADSI, 'select title, displayName, sAMAccountName,
givenName, department, mail, telephoneNumber, sn, physicalDeliveryOfficeName
from ''LDAP://dc=domain,dc=local'' where objectCategory=''user''
AND objectCategory = ''Person'' AND displayName = ''*'' ')
-- Select the USERS to test the connection
Select * from ADSI_USERS
To Drop a Linked server
Sp_DropServer 'ADSI', 'droplogins'
Set the correct security
Set security to BE MADE USING THE CURRENT SECURITY CONTENT !
Giving the correct user and password to connect.
Create an External content type in SharePoint Designer using the ADSI data source.
And make sure that you change the Authentication Mode security of the Default and Client to BCD Identity
See here is the output.
And the beauty is that you can reuse these accounts as lookup Fields in other lists !
This makes sure you are always in sync with your AD.