コード例 #1
0
 internal static SecurityStatusPal CompleteAuthToken(
     ref SafeDeleteContext securityContext,
     SecurityBuffer[] inSecurityBufferArray)
 {
     Interop.SECURITY_STATUS winStatus = (Interop.SECURITY_STATUS)SSPIWrapper.CompleteAuthToken(
         GlobalSSPI.SSPIAuth,
         ref securityContext,
         inSecurityBufferArray);
     return(SecurityStatusAdapterPal.GetSecurityStatusPalFromInterop(winStatus));
 }
コード例 #2
0
        internal static SecurityStatusPal CompleteAuthToken(
            ref SafeDeleteContext securityContext,
            byte[] incomingBlob)
        {
            var inSecurityBuffer = new SecurityBuffer(incomingBlob, SecurityBufferType.SECBUFFER_TOKEN);

            Interop.SECURITY_STATUS winStatus = (Interop.SECURITY_STATUS)SSPIWrapper.CompleteAuthToken(
                GlobalSSPI.SSPIAuth,
                ref securityContext,
                in inSecurityBuffer);
            return(SecurityStatusAdapterPal.GetSecurityStatusPalFromInterop(winStatus));
        }
コード例 #3
0
        internal static SecurityStatusPal CompleteAuthToken(
            ref SafeDeleteContext?securityContext,
            byte[]?incomingBlob)
        {
            // There is only one SafeDeleteContext type on Windows which is SafeDeleteSslContext so this cast is safe.
            SafeDeleteSslContext?sslContext = (SafeDeleteSslContext?)securityContext;
            var inSecurityBuffer            = new SecurityBuffer(incomingBlob, SecurityBufferType.SECBUFFER_TOKEN);

            Interop.SECURITY_STATUS winStatus = (Interop.SECURITY_STATUS)SSPIWrapper.CompleteAuthToken(
                GlobalSSPI.SSPIAuth,
                ref sslContext,
                in inSecurityBuffer);
            securityContext = sslContext;
            return(SecurityStatusAdapterPal.GetSecurityStatusPalFromInterop(winStatus));
        }