Exemplo n.º 1
0
 public OemString(SafeOemStringPointer oemStringPtr)
 {
     this.Buffer = oemStringPtr;
     if (oemStringPtr == null)
     {
         this.Length        = 0;
         this.MaximumLength = 0;
     }
     else if (oemStringPtr.Length >= ushort.MaxValue)
     {
         throw new ArgumentOutOfRangeException("oemStringPtr");
     }
     else
     {
         // Length of the oem string.
         this.Length        = (ushort)oemStringPtr.Length;
         this.MaximumLength = (ushort)oemStringPtr.Length;
     }
 }
Exemplo n.º 2
0
 public OemString(SafeOemStringPointer oemStringPtr)
 {
     this.Buffer = oemStringPtr;
     if (oemStringPtr == null)
     {
         this.Length = 0;
         this.MaximumLength = 0;
     }
     else if (oemStringPtr.Length >= ushort.MaxValue)
     {
         throw new ArgumentOutOfRangeException("oemStringPtr");
     }
     else
     {
         // Length of the oem string.
         this.Length = (ushort)oemStringPtr.Length;
         this.MaximumLength = (ushort)oemStringPtr.Length;
     }
 }
Exemplo n.º 3
0
 internal static NtStatus RtlCalculateLmOwfPassword(SafeOemStringPointer password, out byte[] hash)
 {
     // Allocate output buffer
     hash = new byte[LMHashNumBytes];
     return(RtlCalculateLmOwfPassword(password, hash));
 }
Exemplo n.º 4
0
 private static extern NtStatus RtlCalculateLmOwfPassword(SafeOemStringPointer password, [MarshalAs(UnmanagedType.LPArray, SizeConst = LMHashNumBytes), In, Out] byte[] hash);
Exemplo n.º 5
0
 internal static NtStatus RtlCalculateLmOwfPassword(SafeOemStringPointer password, out byte[] hash)
 {
     // Allocate output buffer
     hash = new byte[LMHashNumBytes];
     return RtlCalculateLmOwfPassword(password, hash);
 }
Exemplo n.º 6
0
 private static extern NtStatus RtlCalculateLmOwfPassword(SafeOemStringPointer password, [MarshalAs(UnmanagedType.LPArray, SizeConst = LMHashNumBytes), In, Out] byte[] hash);