cert_v2.asn1 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637
  1. Nebula DEFINITIONS AUTOMATIC TAGS ::= BEGIN
  2. Name ::= UTF8String (SIZE (1..253))
  3. Time ::= INTEGER (0..18446744073709551615) -- Seconds since unix epoch, uint64 maximum
  4. Network ::= OCTET STRING (SIZE (5,17)) -- IP addresses are 4 or 16 bytes + 1 byte for the prefix length
  5. Curve ::= ENUMERATED {
  6. curve25519 (0),
  7. p256 (1)
  8. }
  9. -- The maximum size of a certificate must not exceed 65536 bytes
  10. Certificate ::= SEQUENCE {
  11. details OCTET STRING,
  12. curve Curve DEFAULT curve25519,
  13. publicKey OCTET STRING,
  14. -- signature(details + curve + publicKey) using the appropriate method for curve
  15. signature OCTET STRING
  16. }
  17. Details ::= SEQUENCE {
  18. name Name,
  19. -- At least 1 ipv4 or ipv6 address must be present if isCA is false
  20. networks SEQUENCE OF Network OPTIONAL,
  21. unsafeNetworks SEQUENCE OF Network OPTIONAL,
  22. groups SEQUENCE OF Name OPTIONAL,
  23. isCA BOOLEAN DEFAULT false,
  24. notBefore Time,
  25. notAfter Time,
  26. -- issuer is only required if isCA is false, if isCA is true then it must not be present
  27. issuer OCTET STRING OPTIONAL,
  28. ...
  29. -- New fields can be added below here
  30. }
  31. END