Leaked source code of windows server 2003
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

45 lines
1002 B

  1. #ifndef __NT_BLOBS_H__
  2. #define __NT_BLOBS_H__
  3. /* nt_blobs.h
  4. *
  5. * Structure definitions for the NameTag keyblob formats.
  6. *
  7. * Note: the code assumes that all structures begin with the
  8. * STD_PRELUDE macro and end with the STD_POSTLUDE macro.
  9. * This allows the "fill in the blanks" code to work more efficiently.
  10. *
  11. * NTStdHeader is the data that goes before the encrypted portion of
  12. * the key blob.
  13. *
  14. * !!!!!!!!!!!!!!!ALERT!!!!!!!!!!!!!!!!!!!!!!!!!
  15. * Since these structs define a net packet, we always
  16. * assume Intel byte order on these structures!!!!!
  17. *
  18. */
  19. #ifdef __cplusplus
  20. extern "C" {
  21. #endif
  22. #include <sha2.h>
  23. #define CUR_BLOB_VERSION 2
  24. #define NT_HASH_BYTES MAX_HASH_SIZE
  25. typedef struct _SIMPLEBLOB {
  26. ALG_ID aiEncAlg;
  27. } NTSimpleBlob;
  28. typedef struct _STKXB {
  29. DWORD dwRights;
  30. DWORD dwKeyLen;
  31. BYTE abHashData[NT_HASH_BYTES];
  32. } NTKeyXBlob ;
  33. #ifdef __cplusplus
  34. }
  35. #endif
  36. #endif // __NT_BLOBS_H__