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.

74 lines
1.6 KiB

  1. #ifndef __NT_RSA_H__
  2. #define __NT_RSA_H__
  3. #include "md2.h"
  4. #include "md4.h"
  5. #include "md5.h"
  6. #include "sha.h"
  7. #include "sha2.h"
  8. #include "rc2.h"
  9. #include "rc4.h"
  10. #include "des.h"
  11. #include "modes.h"
  12. /* nt_rsa.h
  13. *
  14. * Stuff local to NameTag, but necessary for the RSA library.
  15. */
  16. #ifdef __cplusplus
  17. extern "C" {
  18. #endif
  19. // This structure keeps state for MD4 hashing.
  20. typedef struct MD4stuff
  21. {
  22. MDstruct MD; // MD4's state
  23. BOOL FinishFlag;
  24. DWORD BufLen;
  25. BYTE Buf[MD4BLOCKSIZE];// staging buffer
  26. } MD4_object;
  27. typedef struct MD2stuff
  28. {
  29. MD2_CTX MD; // MD2's state
  30. BOOL FinishFlag;
  31. } MD2_object;
  32. #define MD2DIGESTLEN 16
  33. typedef struct {
  34. A_SHA_CTX SHACtx;
  35. BOOL FinishFlag;
  36. BYTE HashVal[A_SHA_DIGEST_LEN];
  37. } SHA_object;
  38. typedef struct {
  39. MD5_CTX MD5Ctx;
  40. BOOL FinishFlag;
  41. } MD5_object;
  42. typedef struct {
  43. SHA256_CTX SHA256Ctx;
  44. BOOL FinishFlag;
  45. BYTE HashVal[SHA256_DIGEST_LEN];
  46. } SHA256_object;
  47. typedef struct {
  48. SHA384_CTX SHA384Ctx;
  49. BOOL FinishFlag;
  50. BYTE HashVal[SHA384_DIGEST_LEN];
  51. } SHA384_object;
  52. typedef struct {
  53. SHA512_CTX SHA512Ctx;
  54. BOOL FinishFlag;
  55. BYTE HashVal[SHA512_DIGEST_LEN];
  56. } SHA512_object;
  57. #ifdef __cplusplus
  58. }
  59. #endif
  60. #endif // __NT_RSA_H__