Solitary tag

pyasn1.type.tag.tagClassUniversal = 0

Identifier for ASN.1 class UNIVERSAL

pyasn1.type.tag.tagClassApplication = 64

Identifier for ASN.1 class APPLICATION

pyasn1.type.tag.tagClassContext = 128

Identifier for ASN.1 class context-specific

pyasn1.type.tag.tagClassPrivate = 192

Identifier for ASN.1 class private

pyasn1.type.tag.tagFormatSimple = 0

Identifier for “simple” ASN.1 structure (e.g. scalar)

pyasn1.type.tag.tagFormatConstructed = 32

Identifier for “constructed” ASN.1 structure (e.g. may have inner components)

class pyasn1.type.tag.Tag(tagClass, tagFormat, tagId)

Create ASN.1 tag

Represents ASN.1 tag that can be attached to a ASN.1 type to make types distinguishable from each other.

Tag objects are immutable and duck-type Python tuple objects holding three integer components of a tag.

Parameters
  • tagClass (int) – Tag class value

  • tagFormat (int) – Tag format value

  • tagId (int) – Tag ID value

Note

The Tag objects are normally used by the TagSet, objects to model a collection of ASN.1 tags.

property tagClass

ASN.1 tag class

Returns

int – Tag class

property tagFormat

ASN.1 tag format

Returns

int – Tag format

property tagId

ASN.1 tag ID

Returns

int – Tag ID