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.

247 lines
6.0 KiB

  1. /* Copyright (C) Microsoft Corporation, 1996-1999. All rights reserved. */
  2. /* ASN.1 definitions for Indirect data contents */
  3. #ifndef _WTASN_Module_H_
  4. #define _WTASN_Module_H_
  5. #include "msber.h"
  6. #ifdef __cplusplus
  7. extern "C" {
  8. #endif
  9. typedef ASN1intx_t HUGEINTEGER;
  10. typedef ASN1bitstring_t BITSTRING;
  11. typedef ASN1octetstring_t OCTETSTRING;
  12. typedef ASN1open_t NOCOPYANY;
  13. typedef ASN1charstring_t NUMERICSTRING;
  14. typedef ASN1charstring_t PRINTABLESTRING;
  15. typedef ASN1charstring_t TELETEXSTRING;
  16. typedef ASN1charstring_t T61STRING;
  17. typedef ASN1charstring_t VIDEOTEXSTRING;
  18. typedef ASN1charstring_t IA5STRING;
  19. typedef ASN1charstring_t GRAPHICSTRING;
  20. typedef ASN1charstring_t VISIBLESTRING;
  21. typedef ASN1charstring_t ISO646STRING;
  22. typedef ASN1charstring_t GENERALSTRING;
  23. typedef ASN1char32string_t UNIVERSALSTRING;
  24. typedef ASN1char16string_t BMPSTRING;
  25. typedef ASN1objectidentifier2_t ObjectID;
  26. #define ObjectID_PDU 0
  27. #define SIZE_WTASN_Module_PDU_0 sizeof(ObjectID)
  28. typedef OCTETSTRING SpcUuid;
  29. typedef ASN1bitstring_t SpcPeImageFlags;
  30. #define includeResources 0x80
  31. #define includeDebugInfo 0x40
  32. #define includeImportAddressTable 0x20
  33. typedef ASN1bool_t SpcMinimalCriteria;
  34. #define SpcMinimalCriteria_PDU 1
  35. #define SIZE_WTASN_Module_PDU_1 sizeof(SpcMinimalCriteria)
  36. typedef ASN1utctime_t UtcTime;
  37. #define UtcTime_PDU 2
  38. #define SIZE_WTASN_Module_PDU_2 sizeof(UtcTime)
  39. typedef struct AlgorithmIdentifier {
  40. union {
  41. ASN1uint16_t bit_mask;
  42. ASN1octet_t o[1];
  43. };
  44. ObjectID algorithm;
  45. # define parameters_present 0x80
  46. NOCOPYANY parameters;
  47. } AlgorithmIdentifier;
  48. typedef struct DigestInfo {
  49. AlgorithmIdentifier digestAlgorithm;
  50. OCTETSTRING digest;
  51. } DigestInfo;
  52. typedef struct SpcAttributeTypeAndOptionalValue {
  53. union {
  54. ASN1uint16_t bit_mask;
  55. ASN1octet_t o[1];
  56. };
  57. ObjectID type;
  58. # define value_present 0x80
  59. NOCOPYANY value;
  60. } SpcAttributeTypeAndOptionalValue;
  61. typedef struct SpcString {
  62. ASN1choice_t choice;
  63. union {
  64. # define unicode_chosen 1
  65. BMPSTRING unicode;
  66. # define ascii_chosen 2
  67. IA5STRING ascii;
  68. } u;
  69. } SpcString;
  70. typedef struct SpcSerializedObject {
  71. SpcUuid classId;
  72. OCTETSTRING serializedData;
  73. } SpcSerializedObject;
  74. typedef struct SpcLink {
  75. ASN1choice_t choice;
  76. union {
  77. # define url_chosen 1
  78. IA5STRING url;
  79. # define moniker_chosen 2
  80. SpcSerializedObject moniker;
  81. # define file_chosen 3
  82. SpcString file;
  83. } u;
  84. } SpcLink;
  85. #define SpcLink_PDU 3
  86. #define SIZE_WTASN_Module_PDU_3 sizeof(SpcLink)
  87. typedef struct SpcPeImageData {
  88. union {
  89. ASN1uint16_t bit_mask;
  90. ASN1octet_t o[1];
  91. };
  92. # define flags_present 0x80
  93. SpcPeImageFlags flags;
  94. # define file_present 0x40
  95. SpcLink file;
  96. } SpcPeImageData;
  97. #define SpcPeImageData_PDU 4
  98. #define SIZE_WTASN_Module_PDU_4 sizeof(SpcPeImageData)
  99. typedef struct SpcSigInfo {
  100. ASN1int32_t dwSIPversion;
  101. SpcUuid gSIPguid;
  102. ASN1int32_t dwReserved1;
  103. ASN1int32_t dwReserved2;
  104. ASN1int32_t dwReserved3;
  105. ASN1int32_t dwReserved4;
  106. ASN1int32_t dwReserved5;
  107. } SpcSigInfo;
  108. #define SpcSigInfo_PDU 5
  109. #define SIZE_WTASN_Module_PDU_5 sizeof(SpcSigInfo)
  110. typedef struct SpcImage {
  111. union {
  112. ASN1uint16_t bit_mask;
  113. ASN1octet_t o[1];
  114. };
  115. # define imageLink_present 0x80
  116. SpcLink imageLink;
  117. # define bitmap_present 0x40
  118. OCTETSTRING bitmap;
  119. # define metafile_present 0x20
  120. OCTETSTRING metafile;
  121. # define enhancedMetafile_present 0x10
  122. OCTETSTRING enhancedMetafile;
  123. # define gifFile_present 0x8
  124. OCTETSTRING gifFile;
  125. } SpcImage;
  126. typedef struct SpcFinancialCriteria {
  127. ASN1bool_t financialInfoAvailable;
  128. ASN1bool_t meetsCriteria;
  129. } SpcFinancialCriteria;
  130. #define SpcFinancialCriteria_PDU 6
  131. #define SIZE_WTASN_Module_PDU_6 sizeof(SpcFinancialCriteria)
  132. typedef struct SpcStatementType {
  133. ASN1uint32_t count;
  134. ObjectID *value;
  135. } SpcStatementType;
  136. #define SpcStatementType_PDU 7
  137. #define SIZE_WTASN_Module_PDU_7 sizeof(SpcStatementType)
  138. typedef struct SpcSpOpusInfo {
  139. union {
  140. ASN1uint16_t bit_mask;
  141. ASN1octet_t o[1];
  142. };
  143. # define programName_present 0x80
  144. SpcString programName;
  145. # define moreInfo_present 0x40
  146. SpcLink moreInfo;
  147. # define publisherInfo_present 0x20
  148. SpcLink publisherInfo;
  149. } SpcSpOpusInfo;
  150. #define SpcSpOpusInfo_PDU 8
  151. #define SIZE_WTASN_Module_PDU_8 sizeof(SpcSpOpusInfo)
  152. typedef struct NameValue {
  153. BMPSTRING refname;
  154. ASN1int32_t typeaction;
  155. OCTETSTRING value;
  156. } NameValue;
  157. #define NameValue_PDU 9
  158. #define SIZE_WTASN_Module_PDU_9 sizeof(NameValue)
  159. typedef struct NameValues {
  160. ASN1uint32_t count;
  161. struct NameValue *value;
  162. } NameValues;
  163. #define NameValues_PDU 10
  164. #define SIZE_WTASN_Module_PDU_10 sizeof(NameValues)
  165. typedef struct MemberInfo {
  166. BMPSTRING subguid;
  167. ASN1int32_t certversion;
  168. } MemberInfo;
  169. #define MemberInfo_PDU 11
  170. #define SIZE_WTASN_Module_PDU_11 sizeof(MemberInfo)
  171. typedef struct SpcIndirectDataContent {
  172. SpcAttributeTypeAndOptionalValue data;
  173. DigestInfo messageDigest;
  174. } SpcIndirectDataContent;
  175. #define SpcIndirectDataContent_PDU 12
  176. #define SIZE_WTASN_Module_PDU_12 sizeof(SpcIndirectDataContent)
  177. typedef struct SpcSpAgencyInformation {
  178. union {
  179. ASN1uint16_t bit_mask;
  180. ASN1octet_t o[1];
  181. };
  182. # define policyInformation_present 0x80
  183. SpcLink policyInformation;
  184. # define policyDisplayText_present 0x40
  185. SpcString policyDisplayText;
  186. # define logoImage_present 0x20
  187. SpcImage logoImage;
  188. # define logoLink_present 0x10
  189. SpcLink logoLink;
  190. } SpcSpAgencyInformation;
  191. #define SpcSpAgencyInformation_PDU 13
  192. #define SIZE_WTASN_Module_PDU_13 sizeof(SpcSpAgencyInformation)
  193. extern SpcPeImageFlags SpcPeImageData_flags_default;
  194. extern ASN1module_t WTASN_Module;
  195. extern void ASN1CALL WTASN_Module_Startup(void);
  196. extern void ASN1CALL WTASN_Module_Cleanup(void);
  197. /* Prototypes of element functions for SEQUENCE OF and SET OF constructs */
  198. #ifdef __cplusplus
  199. } /* extern "C" */
  200. #endif
  201. #endif /* _WTASN_Module_H_ */