Skip to main content

Class: TSTInfo

Represents the TSTInfo structure described in RFC3161

Hierarchy

Implements

Constructors

constructor

new TSTInfo(parameters?): TSTInfo

Initializes a new instance of the TSTInfo class

Parameters

NameTypeDescription
parametersTSTInfoParametersInitialization parameters

Returns

TSTInfo

Overrides

PkiObject.constructor

Properties

accuracy

Optional accuracy: Accuracy

Represents the time deviation around the UTC time contained in GeneralizedTime

Implementation of

ITSTInfo.accuracy


extensions

Optional extensions: Extension[]

Additional information in the future. Extensions is defined in RFC2459

Implementation of

ITSTInfo.extensions


genTime

genTime: Date

Time at which the time-stamp token has been created by the TSA

Implementation of

ITSTInfo.genTime


messageImprint

messageImprint: MessageImprint

The messageImprint MUST have the same value as the similar field in TimeStampReq, provided that the size of the hash value matches the expected size of the hash algorithm identified in hashAlgorithm.

Implementation of

ITSTInfo.messageImprint


nonce

Optional nonce: Integer

Field MUST be present if it was present in the TimeStampReq. In such a case it MUST equal the value provided in the TimeStampReq structure.

Implementation of

ITSTInfo.nonce


ordering

Optional ordering: boolean

If the ordering field is missing, or if the ordering field is present and set to false, then the genTime field only indicates the time at which the time-stamp token has been created by the TSA.In such a case, the ordering of time-stamp tokens issued by the same TSA or different TSAs is only possible when the difference between the genTime of the first time-stamp token and the genTime of the second time-stamp token is greater than the sum of the accuracies of the genTime for each time-stamp token.

If the ordering field is present and set to true, every time-stamp token from the same TSA can always be ordered based on the genTime field, regardless of the genTime accuracy.

Implementation of

ITSTInfo.ordering


policy

policy: string

TSA's policy under which the response was produced.

If a similar field was present in the TimeStampReq, then it MUST have the same value, otherwise an error (unacceptedPolicy) MUST be returned

Implementation of

ITSTInfo.policy


serialNumber

serialNumber: Integer

Integer assigned by the TSA to each TimeStampToken.

It MUST be unique for each TimeStampToken issued by a given TSA.

Implementation of

ITSTInfo.serialNumber


tsa

Optional tsa: GeneralName

tsa field is to give a hint in identifying the name of the TSA. If present, it MUST correspond to one of the subject names included in the certificate that is to be used to verify the token.

Implementation of

ITSTInfo.tsa


version

version: number

Version of the time-stamp token.

Conforming time-stamping servers MUST be able to provide version 1 time-stamp tokens.

Implementation of

ITSTInfo.version


CLASS_NAME

Static CLASS_NAME: string = "TSTInfo"

Name of the class

Overrides

PkiObject.CLASS_NAME

Accessors

className

get className(): string

Returns

string

Inherited from

PkiObject.className

Methods

fromSchema

fromSchema(schema): void

Converts parsed ASN.1 object into current class

Parameters

NameTypeDescription
schemaanyASN.1 schema

Returns

void

Overrides

PkiObject.fromSchema


toJSON

toJSON(): TSTInfoJson

Converts the class to JSON object

Returns

TSTInfoJson

JSON object

Overrides

PkiObject.toJSON


toSchema

toSchema(): Sequence

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

Returns

Sequence

ASN.1 object

Overrides

PkiObject.toSchema


toString

toString(encoding?): string

Parameters

NameTypeDefault value
encoding"base64" | "base64url" | "hex""hex"

Returns

string

Inherited from

PkiObject.toString


verify

verify(params, crypto?): Promise<boolean>

Verify current TST Info value

Parameters

NameTypeDescription
paramsTSTInfoVerifyParamsInput parameters
cryptoICryptoEngineCrypto engine

Returns

Promise<boolean>


blockName

blockName(): string

Returns block name

Returns

string

Returns string block name

Inherited from

PkiObject.blockName


compareWithDefault

compareWithDefault(memberName, memberValue): boolean

Compare values with default values for all class members

Parameters

NameTypeDescription
memberNamestringString name for a class member
memberValueanyValue to compare with default value

Returns

boolean


defaultValues

defaultValues(memberName): number

Returns default values for all class members

Parameters

NameTypeDescription
memberName"version"String name for a class member

Returns

number

Default value

Overrides

PkiObject.defaultValues

defaultValues(memberName): string

Parameters

NameType
memberName"policy"

Returns

string

Overrides

PkiObject.defaultValues

defaultValues(memberName): MessageImprint

Parameters

NameType
memberName"messageImprint"

Returns

MessageImprint

Overrides

PkiObject.defaultValues

defaultValues(memberName): Integer

Parameters

NameType
memberName"serialNumber"

Returns

Integer

Overrides

PkiObject.defaultValues

defaultValues(memberName): Date

Parameters

NameType
memberName"genTime"

Returns

Date

Overrides

PkiObject.defaultValues

defaultValues(memberName): Accuracy

Parameters

NameType
memberName"accuracy"

Returns

Accuracy

Overrides

PkiObject.defaultValues

defaultValues(memberName): boolean

Parameters

NameType
memberName"ordering"

Returns

boolean

Overrides

PkiObject.defaultValues

defaultValues(memberName): Integer

Parameters

NameType
memberName"nonce"

Returns

Integer

Overrides

PkiObject.defaultValues

defaultValues(memberName): GeneralName

Parameters

NameType
memberName"tsa"

Returns

GeneralName

Overrides

PkiObject.defaultValues

defaultValues(memberName): Extension[]

Parameters

NameType
memberName"extensions"

Returns

Extension[]

Overrides

PkiObject.defaultValues


fromBER

fromBER<T>(this, raw): T

Creates PKI object from the raw data

Type parameters

NameType
Textends PkiObject

Parameters

NameTypeDescription
thisPkiObjectConstructor<T>-
rawBufferSourceASN.1 encoded raw data

Returns

T

Initialized and filled current class object

Inherited from

PkiObject.fromBER


schema

schema(parameters?): any

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

Parameters

NameTypeDescription
parametersSchemaParameters<{ accuracy?: AccuracySchema ; extension?: ExtensionSchema ; extensions?: string ; genTime?: string ; messageImprint?: MessageImprintSchema ; nonce?: string ; ordering?: string ; policy?: string ; serialNumber?: string ; tsa?: GeneralNameSchema ; version?: string }>Input parameters for the schema

Returns

any

ASN.1 schema object

Overrides

PkiObject.schema