Using this code, you can check the current security context inside your WCF service.
If the user is authenticated and WindowsPrincipal is not null, then you use the Windows security model - you can access all the relevant information:
ServiceSecurityContext current = ServiceSecurityContext.Current; if (!current.IsAnonymous && current.WindowsIdentity != null) { string userName = current.WindowsIdentity.Name; }
source share