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.

100 lines
3.7 KiB

  1. ----------------------------------------------------------------------------
  2. -- X509.ASN
  3. --
  4. -- ASN.1 definitions for NetScape KeyGen tag
  5. ----------------------------------------------------------------------------
  6. --<ROOT KEYGEN>--
  7. --<COPYRIGHT "Copyright (C) Microsoft Corporation, 1996 - 1996">--
  8. --<OBJECTID LONG>--
  9. --<OBJECTID 16>--
  10. --<NOPDU>--
  11. --<NOVALUE>--
  12. --<LENGTHSIZE LONG>--
  13. --<SUPPRESS C0391W>-- -- C0391W: Duplicate PDU tag
  14. --<SUPPRESS A0427W>-- -- A0427W: Mixed 1990 and 1994 ASN.1 syntax
  15. --<SUPPRESS A0433W>-- -- A0433W: 'ANY' is invalid 1994 ASN.1 syntax
  16. --<UNBOUNDED SEQUENCE OF, SET OF>--
  17. --<UNBOUNDED BIT STRING, OCTET STRING>--
  18. KEYGEN
  19. DEFINITIONS EXPLICIT TAGS ::=
  20. BEGIN
  21. HUGEINTEGER ::= INTEGER --<HUGE>-- -- tag 0x02
  22. BITSTRING ::= BIT STRING --<UNBOUNDED>-- -- tag 0x03
  23. OCTETSTRING ::= OCTET STRING --<UNBOUNDED>-- -- tag 0x04
  24. NUMERICSTRING ::= NumericString --<UNBOUNDED>-- -- tag 0x12 (18)
  25. PRINTABLESTRING ::= PrintableString --<UNBOUNDED>-- -- tag 0x13 (19)
  26. TELETEXSTRING ::= TeletexString --<UNBOUNDED>-- -- tag 0x14 (20)
  27. T61STRING ::= T61String --<UNBOUNDED>-- -- tag 0x14 (20)
  28. VIDEOTEXSTRING ::= VideotexString --<UNBOUNDED>-- -- tag 0x15 (21)
  29. IA5STRING ::= IA5String --<UNBOUNDED>-- -- tag 0x16 (22)
  30. GRAPHICSTRING ::= GraphicString --<UNBOUNDED>-- -- tag 0x19 (25)
  31. VISIBLESTRING ::= VisibleString --<UNBOUNDED>-- -- tag 0x1A (26)
  32. ISO646STRING ::= ISO646String --<UNBOUNDED>-- -- tag 0x1A (26)
  33. GENERALSTRING ::= GeneralString --<UNBOUNDED>-- -- tag 0x1B (27)
  34. UNIVERSALSTRING ::= UniversalString --<UNBOUNDED>-- -- tag 0x1C (28)
  35. BMPSTRING ::= BMPString --<UNBOUNDED>-- -- tag 0x1E (30)
  36. --------------------------------------------
  37. -- Algorithm Identifier
  38. --------------------------------------------
  39. AlgorithmIdentifier ::= SEQUENCE {
  40. algorithm OBJECT IDENTIFIER,
  41. parameters ANY --<ENCODABLE>-- OPTIONAL
  42. }
  43. --------------------------------------------
  44. -- Digest Info
  45. --------------------------------------------
  46. DigestInfo ::= SEQUENCE {
  47. digestAlgorithm AlgorithmIdentifier,
  48. digest OCTETSTRING
  49. }
  50. --------------------------------------------
  51. -- From PKCS #1: ASN.1 representation for public key
  52. --------------------------------------------
  53. RSAPublicKey ::= SEQUENCE {
  54. modulus HUGEINTEGER, -- n
  55. publicExponent INTEGER -- e
  56. } --<PDU>--
  57. --------------------------------------------
  58. -- Subject Public Key Info
  59. --------------------------------------------
  60. SubjectPublicKeyInfo ::= SEQUENCE {
  61. algorithm AlgorithmIdentifier,
  62. subjectPublicKey BITSTRING
  63. } --<PDU>--
  64. --------------------------------------------
  65. -- Signed Content: Cert, CRL or Cert Request
  66. --------------------------------------------
  67. SignedContent ::= SEQUENCE {
  68. toBeSigned ANY --<ENCODABLE>--,
  69. algorithm AlgorithmIdentifier,
  70. signature BITSTRING
  71. } --<PDU>--
  72. --------------------------------------------
  73. -- NetScape hack : keygen tag
  74. --------------------------------------------
  75. PublicKeyAndChallenge ::= SEQUENCE {
  76. spki SubjectPublicKeyInfo,
  77. challenge IA5STRING
  78. }
  79. SignedPublicKeyAndChallenge ::= SEQUENCE {
  80. publicKeyAndChallenge PublicKeyAndChallenge,
  81. signatureAlgorithm AlgorithmIdentifier,
  82. signature BIT STRING
  83. } --<PDU>--
  84. END