• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1#
2# This file is part of pyasn1-modules software.
3#
4# Created by Russ Housley with assistance from asn1ate v.0.6.0.
5#
6# Copyright (c) 2019, Vigil Security, LLC
7# License: http://snmplabs.com/pyasn1/license.html
8#
9# Internet X.509 Public Key Infrastructure Permanent Identifier
10#
11# ASN.1 source from:
12# https://www.rfc-editor.org/rfc/rfc4043.txt
13#
14
15from pyasn1.type import char
16from pyasn1.type import namedtype
17from pyasn1.type import univ
18
19from pyasn1_modules import rfc5280
20
21
22id_pkix = univ.ObjectIdentifier((1, 3, 6, 1, 5, 5, 7, ))
23
24id_on = id_pkix + (8, )
25
26id_on_permanentIdentifier = id_on + (3, )
27
28
29class PermanentIdentifier(univ.Sequence):
30    componentType = namedtype.NamedTypes(
31        namedtype.OptionalNamedType('identifierValue', char.UTF8String()),
32        namedtype.OptionalNamedType('assigner', univ.ObjectIdentifier())
33    )
34
35
36# Map of Other Name OIDs to Other Name is added to the
37# ones that are in rfc5280.py
38
39_anotherNameMapUpdate = {
40    id_on_permanentIdentifier: PermanentIdentifier(),
41}
42
43rfc5280.anotherNameMap.update(_anotherNameMapUpdate)
44