Skip to content
PKIjsPKIjsPKIjsv4.0.1

AlgorithmIdentifier

Represents the AlgorithmIdentifier structure described in RFC5280

new AlgorithmIdentifier(parameters?): AlgorithmIdentifier

Initializes a new instance of the AlgorithmIdentifier class

AlgorithmIdentifierParameters = {}

Initialization parameters

AlgorithmIdentifier

PkiObject.constructor

algorithmId: string

ObjectIdentifier for algorithm (string representation)

IAlgorithmIdentifier.algorithmId


optional algorithmParams?: any

Any algorithm parameters

IAlgorithmIdentifier.algorithmParams


static CLASS_NAME: string = "AlgorithmIdentifier"

Name of the class

PkiObject.CLASS_NAME

get className(): string

string

PkiObject.className

fromSchema(schema): void

Converts parsed ASN.1 object into current class

any

ASN.1 schema

void

PkiObject.fromSchema


isEqual(algorithmIdentifier): boolean

Checks that two “AlgorithmIdentifiers” are equal

unknown

boolean


toJSON(): AlgorithmIdentifierJson

Converts the class to JSON object

AlgorithmIdentifierJson

JSON object

PkiObject.toJSON


toSchema(): Sequence

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

Sequence

ASN.1 object

PkiObject.toSchema


toString(encoding?): string

"hex" | "base64" | "base64url" = "hex"

string

PkiObject.toString


static blockName(): string

Returns block name

string

Returns string block name

PkiObject.blockName


static compareWithDefault(memberName, memberValue): boolean

Compares values with default values for all class members

string

String name for a class member

any

Value to compare with default value

boolean


static defaultValues(memberName): string

Returns default values for all class members

"algorithmId"

String name for a class member

string

Default value

PkiObject.defaultValues

static defaultValues(memberName): any

Returns default values for all class members

"algorithmParams"

String name for a class member

any

Default value

PkiObject.defaultValues


static fromBER<T>(this, raw): T

Creates PKI object from the raw data

T extends PkiObject

PkiObjectConstructor<T>

BufferSource

ASN.1 encoded raw data

T

Initialized and filled current class object

PkiObject.fromBER


static schema(parameters?): any

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

AlgorithmIdentifierSchema = {}

Input parameters for the schema

any

ASN.1 schema object

PkiObject.schema