asn1js
Classes
- Any
- BaseBlock
- BaseStringBlock
- BitString
- BmpString
- Boolean
- CharacterString
- Choice
- Constructed
- DATE
- DateTime
- Duration
- EndOfContent
- Enumerated
- GeneralString
- GeneralizedTime
- GraphicString
- IA5String
- Integer
- Null
- NumericString
- ObjectIdentifier
- OctetString
- Primitive
- PrintableString
- RawData
- RelativeObjectIdentifier
- Repeated
- Sequence
- Set
- TIME
- TeletexString
- TimeOfDay
- UTCTime
- UniversalString
- Utf8String
- ValueBlock
- VideotexString
- ViewWriter
- VisibleString
Interfaces
- BaseBlockJson
- BaseBlockParams
- BaseStringBlockParams
- BitStringParams
- BooleanParams
- CompareSchemaFail
- CompareSchemaSuccess
- ConstructedParams
- FromBerResult
- GeneralizedTimeJson
- HexBlockJson
- IAny
- IBaseBlock
- IBerConvertible
- IChoice
- IDateConvertible
- IDerConvertible
- IGeneralizedTime
- IHexBlock
- IRawData
- IRepeated
- IStringConvertible
- IUTCTime
- IntegerParams
- ObjectIdentifierJson
- ObjectIdentifierParams
- OctetStringParams
- PrimitiveParams
- RelativeObjectIdentifierJson
- RelativeObjectIdentifierParams
- UTCTimeJson
- UTCTimeParams
- Utf8StringParams
- ValueBlockConstructor
Type Aliases
AnyParams
Ƭ AnyParams: Partial
<IAny
>
AsnSchemaType
Ƭ AsnSchemaType: AsnType
| Any
| Choice
| Repeated
AsnType
Ƭ AsnType: BaseBlock
| EndOfContent
| Boolean
| Integer
| BitString
| OctetString
| Null
| ObjectIdentifier
| Enumerated
| Utf8String
| RelativeObjectIdentifier
| TIME
| Sequence
| Set
| NumericString
| PrintableString
| TeletexString
| VideotexString
| IA5String
| UTCTime
| GeneralizedTime
| GraphicString
| VisibleString
| GeneralString
| UniversalString
| CharacterString
| BmpString
| DATE
| TimeOfDay
| DateTime
| Duration
| Constructed
| Primitive
BaseStringBlockJson
Ƭ BaseStringBlockJson: LocalStringValueBlockJson
BitStringJson
Ƭ BitStringJson: BaseBlockJson
<LocalBitStringValueBlockJson
>
BmpStringJson
Ƭ BmpStringJson: LocalBmpStringValueBlockJson
BmpStringParams
Ƭ BmpStringParams: LocalBmpStringValueBlockParams
BooleanJson
Ƭ BooleanJson: BaseBlockJson
<LocalBooleanValueBlockJson
>
CharacterStringJson
Ƭ CharacterStringJson: LocalSimpleStringBlockJson
CharacterStringParams
Ƭ CharacterStringParams: LocalSimpleStringBlockParams
ChoiceParams
Ƭ ChoiceParams: Partial
<IChoice
>
CompareSchemaResult
Ƭ CompareSchemaResult: CompareSchemaSuccess
| CompareSchemaFail
ConstructedJson
Ƭ ConstructedJson: BaseBlockJson
<LocalConstructedValueBlockJson
>
DATEJson
Ƭ DATEJson: Utf8StringJson
DATEParams
Ƭ DATEParams: Utf8StringParams
DateStringEncoding
Ƭ DateStringEncoding: StringEncoding
| "iso"
DateTimeJson
Ƭ DateTimeJson: Utf8StringJson
DateTimeParams
Ƭ DateTimeParams: Utf8StringParams
DurationJson
Ƭ DurationJson: Utf8StringJson
DurationParams
Ƭ DurationParams: Utf8StringParams
EndOfContentJson
Ƭ EndOfContentJson: BaseBlockJson
EndOfContentParams
Ƭ EndOfContentParams: BaseBlockParams
EnumeratedJson
Ƭ EnumeratedJson: IntegerJson
EnumeratedParams
Ƭ EnumeratedParams: IntegerParams
GeneralStringJson
Ƭ GeneralStringJson: LocalSimpleStringBlockJson
GeneralStringParams
Ƭ GeneralStringParams: LocalSimpleStringBlockParams
GeneralizedTimeParams
Ƭ GeneralizedTimeParams: UTCTimeParams
GraphicStringJson
Ƭ GraphicStringJson: LocalSimpleStringBlockJson
GraphicStringParams
Ƭ GraphicStringParams: LocalSimpleStringBlockParams
HexBlockParams
Ƭ HexBlockParams: Partial
<IHexBlock
>
IA5StringJson
Ƭ IA5StringJson: LocalSimpleStringBlockJson
IA5StringParams
Ƭ IA5StringParams: LocalSimpleStringBlockParams
IValueBlock
Ƭ IValueBlock: internals.ILocalBaseBlock
IntegerJson
Ƭ IntegerJson: BaseBlockJson
<LocalIntegerValueBlockJson
>
NullJson
Ƭ NullJson: BaseBlockJson
<ValueBlockJson
>
NullParams
Ƭ NullParams: BaseBlockParams
NumericStringJson
Ƭ NumericStringJson: LocalSimpleStringBlockJson
NumericStringParams
Ƭ NumericStringParams: LocalSimpleStringBlockParams
OctetStringJson
Ƭ OctetStringJson: BaseBlockJson
<LocalOctetStringValueBlockJson
>
PrimitiveJson
Ƭ PrimitiveJson: BaseBlockJson
<LocalPrimitiveValueBlockJson
>
PrintableStringJson
Ƭ PrintableStringJson: LocalSimpleStringBlockJson
PrintableStringParams
Ƭ PrintableStringParams: LocalSimpleStringBlockParams
RawDataParams
Ƭ RawDataParams: Partial
<IRawData
>
RepeatedParams
Ƭ RepeatedParams: Partial
<IRepeated
>
SequenceJson
Ƭ SequenceJson: ConstructedJson
SequenceParams
Ƭ SequenceParams: ConstructedParams
SetJson
Ƭ SetJson: ConstructedJson
SetParams
Ƭ SetParams: ConstructedParams
StringEncoding
Ƭ StringEncoding: "ascii"
| "hex"
TIMEJson
Ƭ TIMEJson: Utf8StringJson
TIMEParams
Ƭ TIMEParams: Utf8StringParams
TeletexStringJson
Ƭ TeletexStringJson: LocalSimpleStringBlockJson
TeletexStringParams
Ƭ TeletexStringParams: LocalSimpleStringBlockParams
TimeOfDayJson
Ƭ TimeOfDayJson: Utf8StringJson
TimeOfDayParams
Ƭ TimeOfDayParams: Utf8StringParams
UniversalStringJson
Ƭ UniversalStringJson: LocalUniversalStringValueBlockJson
UniversalStringParams
Ƭ UniversalStringParams: LocalUniversalStringValueBlockParams
Utf8StringJson
Ƭ Utf8StringJson: BaseBlockJson
<LocalUtf8StringValueBlockJson
>
ValueBlockJson
Ƭ ValueBlockJson: internals.LocalBaseBlockJson
ValueBlockParams
Ƭ ValueBlockParams: internals.LocalBaseBlockParams
VideotexStringJson
Ƭ VideotexStringJson: LocalSimpleStringBlockJson
VideotexStringParams
Ƭ VideotexStringParams: LocalSimpleStringBlockParams
VisibleStringJson
Ƭ VisibleStringJson: LocalSimpleStringBlockJson
VisibleStringParams
Ƭ VisibleStringParams: LocalSimpleStringBlockParams
Functions
HexBlock
▸ HexBlock<T
>(BaseClass
): (...args
: any
[]) => Some
<T
> & T
Class used as a base block for all remaining ASN.1 classes
Type parameters
Name | Type |
---|---|
T | extends LocalBaseBlockConstructor <LocalBaseBlock > |
Parameters
Name | Type |
---|---|
BaseClass | T |
Returns
(...args
: any
[]) => Some
<T
> & T
compareSchema
▸ compareSchema(root
, inputData
, inputSchema
): CompareSchemaResult
Compare of two ASN.1 object trees
Parameters
Name | Type | Description |
---|---|---|
root | AsnType | Root of input ASN.1 object tree |
inputData | AsnType | Input ASN.1 object tree |
inputSchema | AsnSchemaType | Input ASN.1 schema to compare with |
Returns
Returns result of comparison
fromBER
▸ fromBER(inputBuffer
): FromBerResult
Major function for decoding ASN.1 BER array into internal library structures
Parameters
Name | Type | Description |
---|---|---|
inputBuffer | BufferSource | ASN.1 BER encoded array of bytes |
Returns
verifySchema
▸ verifySchema(inputBuffer
, inputSchema
): CompareSchemaResult
ASN.1 schema verification for ArrayBuffer data
Parameters
Name | Type | Description |
---|---|---|
inputBuffer | BufferSource | Input BER-encoded ASN.1 data |
inputSchema | AsnSchemaType | Input ASN.1 schema to verify against to |