Source code of Windows XP (NT5)
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.

80 lines
3.0 KiB

  1. /////////////////////////////////////////////////////////////////////////////
  2. // FILE : scp.h //
  3. // DESCRIPTION : Crypto Provider prototypes //
  4. // AUTHOR : //
  5. // HISTORY : //
  6. // Jan 25 1995 larrys Changed from Nametag //
  7. // Apr 9 1995 larrys Removed some APIs //
  8. // Apr 19 1995 larrys Cleanup //
  9. // May 10 1995 larrys added private api calls //
  10. // May 16 1995 larrys updated to spec //
  11. // Aug 30 1995 larrys Changed a parameter to IN OUT //
  12. // Oct 06 1995 larrys Added more APIs //
  13. // OCt 13 1995 larrys Removed CryptGetHashValue //
  14. // Apr 7 2000 dbarlow Moved all the entry point definitions to //
  15. // the cspdk.h header file //
  16. // //
  17. // Copyright (C) 1993 - 2000 Microsoft Corporation All Rights Reserved //
  18. /////////////////////////////////////////////////////////////////////////////
  19. #include <time.h>
  20. #include <wincrypt.h>
  21. #include <policy.h>
  22. #ifdef __cplusplus
  23. extern "C" {
  24. #endif
  25. #ifdef _DEBUG
  26. #include <crtdbg.h>
  27. // #define BreakPoint
  28. #define BreakPoint _CrtDbgBreak();
  29. #define EntryPoint
  30. // #define EntryPoint BreakPoint
  31. #else // _DEBUG
  32. #define BreakPoint
  33. #define EntryPoint
  34. #endif // _DEBUG
  35. // type definition of a NameTag error
  36. typedef unsigned int NTAG_ERROR;
  37. #define NTF_FAILED FALSE
  38. #define NTF_SUCCEED TRUE
  39. #define NTAG_SUCCEEDED(ntag_error) ((ntag_error) == NTF_SUCCEED)
  40. #define NTAG_FAILED(ntag_error) ((ntag_error) == NTF_FAILED)
  41. #define NASCENT 0x00000002
  42. #define NTAG_MAXPADSIZE 8
  43. #define MAXSIGLEN 64
  44. // definitions max length of logon pszUserID parameter
  45. #define MAXUIDLEN 64
  46. // udp type flag
  47. #define KEP_UDP 1
  48. // Flags for NTagGetPubKey
  49. #define SIGPUBKEY 0x1000
  50. #define EXCHPUBKEY 0x2000
  51. //
  52. // NOTE: The following values must match the indicies in the g_AlgTables
  53. // array, defined below.
  54. //
  55. #define POLICY_MS_DEF 0 // Key length table for PROV_MS_DEF
  56. #define POLICY_MS_STRONG 1 // Key length table for PROV_MS_STRONG
  57. #define POLICY_MS_ENHANCED 2 // Key length table for PROV_MS_ENHANCED
  58. #define POLICY_MS_SCHANNEL 3 // Key length table for PROV_MS_SCHANNEL
  59. #define POLICY_MS_SIGONLY 4 // Key length table for undefined
  60. // signature-only CSP.
  61. #define POLICY_MS_RSAAES 5 // Key length table for MS_ENH_RSA_AES_PROV
  62. extern PROV_ENUMALGS_EX *g_AlgTables[];
  63. #ifdef __cplusplus
  64. }
  65. #endif