Saving work.. working on implementing EncryptMessage. The buffer types and allocation that get passed to the call is really crazy in the sample.

This commit is contained in:
antiduh
2014-06-23 02:34:36 +00:00
parent 3142cfff7b
commit 1be2b9c7ef
2 changed files with 18 additions and 0 deletions

View File

@@ -49,5 +49,9 @@ namespace NSspi
this.disposed = true;
}
public byte[] Encrypt( byte[] input )
{
}
}
}

View File

@@ -148,5 +148,19 @@ namespace NSspi.Contexts
SetLastError = true
)]
public static extern SecurityStatus DeleteSecurityContext( ref long contextHandle );
[DllImport(
"Secur32.dll",
EntryPoint = "EncryptMessag",
CallingConvention = CallingConvention.Winapi,
CharSet = CharSet.Unicode,
SetLastError = true
)]
public static extern SecurityStatus EncryptMessage(
ref long contextHandle,
int qualityOfProtection,
IntPtr bufferDescriptor,
int sequenceNumber
);
}
}