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.

66 lines
1.8 KiB

  1. //+-------------------------------------------------------------------------
  2. //
  3. // Microsoft Windows
  4. //
  5. // Copyright (C) Microsoft Corporation, 1996 - 1999
  6. //
  7. // File: msgasn1.h
  8. //
  9. // Contents: Conversion APIs to/from ASN.1 data structures
  10. //
  11. // Functions: ICM_Asn1ToAttribute
  12. // ICM_Asn1ToAlgorithmIdentifier
  13. // ICM_Asn1FromAlgorithmIdentifier
  14. //
  15. // History: 16-Apr-96 kevinr created
  16. //
  17. //--------------------------------------------------------------------------
  18. #ifndef __MSGASN1_H__
  19. #define __MSGASN1_H__
  20. #ifdef __cplusplus
  21. extern "C" {
  22. #endif
  23. //+-------------------------------------------------------------------------
  24. // Convert an CRYPT_ATTRIBUTE to an ASN1 Attribute
  25. //
  26. // Returns FALSE iff conversion failed.
  27. //--------------------------------------------------------------------------
  28. BOOL
  29. WINAPI
  30. ICM_Asn1ToAttribute(
  31. IN PCRYPT_ATTRIBUTE patr,
  32. OUT Attribute *pAsn1Attr);
  33. //+-------------------------------------------------------------------------
  34. // Convert an CRYPT_ALGORITHM_IDENTIFIER to an ASN1 AlgorithmIdentifier
  35. //
  36. // Returns FALSE iff conversion failed.
  37. //--------------------------------------------------------------------------
  38. BOOL
  39. WINAPI
  40. ICM_Asn1ToAlgorithmIdentifier(
  41. IN PCRYPT_ALGORITHM_IDENTIFIER pai,
  42. OUT AlgorithmIdentifier *pAsn1AlgId);
  43. //+-------------------------------------------------------------------------
  44. // Convert an ASN1 AlgorithmIdentifier to an CRYPT_ALGORITHM_IDENTIFIER
  45. //
  46. // Returns FALSE iff conversion failed.
  47. //--------------------------------------------------------------------------
  48. BOOL
  49. WINAPI
  50. ICM_Asn1FromAlgorithmIdentifier(
  51. IN AlgorithmIdentifier *pAsn1AlgId,
  52. OUT PCRYPT_ALGORITHM_IDENTIFIER pai);
  53. #ifdef __cplusplus
  54. } // Balance extern "C" above
  55. #endif
  56. #endif