System.Security.SecurityContext.IsWindowsIdentityFlowSuppressed C# (CSharp) Method

IsWindowsIdentityFlowSuppressed() public static method

public static IsWindowsIdentityFlowSuppressed ( ) : bool
return bool
    public static bool IsWindowsIdentityFlowSuppressed() { throw null; }
    public static void RestoreFlow() { }

Usage Example

Example #1
0
        private static SecurityContext CaptureCore(ExecutionContext.Reader currThreadEC, ref StackCrawlMark stackMark)
        {
            SecurityContext securityContext = new SecurityContext();

            securityContext.isNewCapture = true;
            if (!SecurityContext.IsWindowsIdentityFlowSuppressed())
            {
                WindowsIdentity currentWI = SecurityContext.GetCurrentWI(currThreadEC);
                if (currentWI != null)
                {
                    securityContext._windowsIdentity = new WindowsIdentity(currentWI.AccessToken);
                }
            }
            else
            {
                securityContext._disableFlow = SecurityContextDisableFlow.WI;
            }
            securityContext.CompressedStack = CompressedStack.GetCompressedStack(ref stackMark);
            return(securityContext);
        }