Class SafeBag<T>

Represents the SafeBag structure described in RFC7292

Type Parameters

Hierarchy

Implements

Constructors

Properties

bagAttributes?: Attribute[]
bagId: string
bagValue: T
CLASS_NAME: string = "SafeBag"

Name of the class

Accessors

  • get className(): string
  • Returns string

Methods

  • Converts parsed ASN.1 object into current class

    Parameters

    • schema: any

      ASN.1 schema

    Returns void

  • Converts current object to ASN.1 object and sets correct values

    Returns

    ASN.1 object

    Returns Sequence

  • Parameters

    • encoding: "base64" | "base64url" | "hex" = "hex"

    Returns string

  • Compare values with default values for all class members

    Parameters

    • memberName: string

      String name for a class member

    • memberValue: any

      Value to compare with default value

    Returns boolean

  • Returns default values for all class members

    Returns

    Default value

    Parameters

    • memberName: "bagId"

      String name for a class member

    Returns string

  • Parameters

    • memberName: "bagValue"

    Returns BagType

  • Parameters

    • memberName: "bagAttributes"

    Returns Attribute[]

  • Creates PKI object from the raw data

    Returns

    Initialized and filled current class object

    Type Parameters

    Parameters

    • this: PkiObjectConstructor<T>
    • raw: BufferSource

      ASN.1 encoded raw data

    Returns T

  • Returns value of pre-defined ASN.1 schema for current class

    Returns

    ASN.1 schema object

    Parameters

    • parameters: SchemaParameters<{ bagAttributes?: string; bagId?: string; bagValue?: string }> = {}

      Input parameters for the schema

    Returns any

Generated using TypeDoc