@wildboar/pc
Version:
Trusted Computing Group Platform Certificate ASN.1 data structures in TypeScript
216 lines (215 loc) • 7.39 kB
TypeScript
import { OPTIONAL, BOOLEAN, OBJECT_IDENTIFIER, IA5String, ASN1Element as _Element } from "asn1-ts";
import * as $ from "asn1-ts/dist/node/functional";
import { EvaluationAssuranceLevel, _enum_for_EvaluationAssuranceLevel } from "../PlatformCertificateProfile/EvaluationAssuranceLevel.ta";
export { EvaluationAssuranceLevel, _enum_for_EvaluationAssuranceLevel, EvaluationAssuranceLevel_levell, levell, EvaluationAssuranceLevel_level2, level2, EvaluationAssuranceLevel_level3, level3, EvaluationAssuranceLevel_level4, level4, EvaluationAssuranceLevel_level5, level5, EvaluationAssuranceLevel_level6, level6, EvaluationAssuranceLevel_level7, level7, _decode_EvaluationAssuranceLevel, _encode_EvaluationAssuranceLevel } from "../PlatformCertificateProfile/EvaluationAssuranceLevel.ta";
import { StrengthOfFunction, _enum_for_StrengthOfFunction } from "../PlatformCertificateProfile/StrengthOfFunction.ta";
export { StrengthOfFunction, _enum_for_StrengthOfFunction, StrengthOfFunction_basic, basic, StrengthOfFunction_medium, medium, StrengthOfFunction_high, high, _decode_StrengthOfFunction, _encode_StrengthOfFunction } from "../PlatformCertificateProfile/StrengthOfFunction.ta";
import { URIReference } from "../PlatformCertificateProfile/URIReference.ta";
export { URIReference, _decode_URIReference, _encode_URIReference } from "../PlatformCertificateProfile/URIReference.ta";
import { EvaluationStatus } from "./EvaluationStatus.ta";
/**
* @summary CommonCriteriaMeasures
* @description
*
* ### ASN.1 Definition:
*
* ```asn1
* CommonCriteriaMeasures ::= SEQUENCE {
* version IA5String (SIZE (1..strmax)), -- “2.2” or “3.1”; future syntax defined by CC
* assurancelevel EvaluationAssuranceLevel,
* evaluationStatus EvalutionStatus,
* plus BOOLEAN DEFAULT FALSE,
* strengthOfFunction [0] IMPLICIT StrengthOfFunction OPTIONAL,
* profileOid [1] IMPLICIT OBJECT IDENTIFIER OPTIONAL,
* profileUri [2] IMPLICIT URIReference OPTIONAL,
* targetOid [3] IMPLICIT OBJECT IDENTIFIER OPTIONAL,
* targetUri [4] IMPLICIT URIReference OPTIONAL }
* ```
*
* @class
*/
export declare class CommonCriteriaMeasures {
/**
* @summary `version`.
* @public
* @readonly
*/
readonly version: IA5String;
/**
* @summary `assurancelevel`.
* @public
* @readonly
*/
readonly assurancelevel: EvaluationAssuranceLevel;
/**
* @summary `evaluationStatus`.
* @public
* @readonly
*/
readonly evaluationStatus: EvaluationStatus;
/**
* @summary `plus`.
* @public
* @readonly
*/
readonly plus: OPTIONAL<BOOLEAN>;
/**
* @summary `strengthOfFunction`.
* @public
* @readonly
*/
readonly strengthOfFunction: OPTIONAL<StrengthOfFunction>;
/**
* @summary `profileOid`.
* @public
* @readonly
*/
readonly profileOid: OPTIONAL<OBJECT_IDENTIFIER>;
/**
* @summary `profileUri`.
* @public
* @readonly
*/
readonly profileUri: OPTIONAL<URIReference>;
/**
* @summary `targetOid`.
* @public
* @readonly
*/
readonly targetOid: OPTIONAL<OBJECT_IDENTIFIER>;
/**
* @summary `targetUri`.
* @public
* @readonly
*/
readonly targetUri: OPTIONAL<URIReference>;
constructor(
/**
* @summary `version`.
* @public
* @readonly
*/
version: IA5String,
/**
* @summary `assurancelevel`.
* @public
* @readonly
*/
assurancelevel: EvaluationAssuranceLevel,
/**
* @summary `evaluationStatus`.
* @public
* @readonly
*/
evaluationStatus: EvaluationStatus,
/**
* @summary `plus`.
* @public
* @readonly
*/
plus: OPTIONAL<BOOLEAN>,
/**
* @summary `strengthOfFunction`.
* @public
* @readonly
*/
strengthOfFunction: OPTIONAL<StrengthOfFunction>,
/**
* @summary `profileOid`.
* @public
* @readonly
*/
profileOid: OPTIONAL<OBJECT_IDENTIFIER>,
/**
* @summary `profileUri`.
* @public
* @readonly
*/
profileUri: OPTIONAL<URIReference>,
/**
* @summary `targetOid`.
* @public
* @readonly
*/
targetOid: OPTIONAL<OBJECT_IDENTIFIER>,
/**
* @summary `targetUri`.
* @public
* @readonly
*/
targetUri: OPTIONAL<URIReference>);
/**
* @summary Restructures an object into a CommonCriteriaMeasures
* @description
*
* This takes an `object` and converts it to a `CommonCriteriaMeasures`.
*
* @public
* @static
* @method
* @param {Object} _o An object having all of the keys and values of a `CommonCriteriaMeasures`.
* @returns {CommonCriteriaMeasures}
*/
static _from_object(_o: {
[_K in keyof (CommonCriteriaMeasures)]: (CommonCriteriaMeasures)[_K];
}): CommonCriteriaMeasures;
/**
* @summary Getter that returns the default value for `plus`.
* @public
* @static
* @method
*/
static get _default_value_for_plus(): boolean; /**
* @summary The enum used as the type of the component `assurancelevel`
* @public
* @static
*/
static _enum_for_assurancelevel: typeof _enum_for_EvaluationAssuranceLevel; /**
* @summary The enum used as the type of the component `strengthOfFunction`
* @public
* @static
*/
static _enum_for_strengthOfFunction: typeof _enum_for_StrengthOfFunction;
}
/**
* @summary The Leading Root Component Types of CommonCriteriaMeasures
* @description
*
* This is an array of `ComponentSpec`s that define how to decode the leading root component type list of a SET or SEQUENCE.
*
* @constant
*/
export declare const _root_component_type_list_1_spec_for_CommonCriteriaMeasures: $.ComponentSpec[];
/**
* @summary The Trailing Root Component Types of CommonCriteriaMeasures
* @description
*
* This is an array of `ComponentSpec`s that define how to decode the trailing root component type list of a SET or SEQUENCE.
*
* @constant
*/
export declare const _root_component_type_list_2_spec_for_CommonCriteriaMeasures: $.ComponentSpec[];
/**
* @summary The Extension Addition Component Types of CommonCriteriaMeasures
* @description
*
* This is an array of `ComponentSpec`s that define how to decode the extension addition component type list of a SET or SEQUENCE.
*
* @constant
*/
export declare const _extension_additions_list_spec_for_CommonCriteriaMeasures: $.ComponentSpec[];
/**
* @summary Decodes an ASN.1 element into a(n) CommonCriteriaMeasures
* @function
* @param {_Element} el The element being decoded.
* @returns {CommonCriteriaMeasures} The decoded data structure.
*/
export declare function _decode_CommonCriteriaMeasures(el: _Element): CommonCriteriaMeasures;
/**
* @summary Encodes a(n) CommonCriteriaMeasures into an ASN.1 Element.
* @function
* @param {value} el The element being decoded.
* @param elGetter A function that can be used to get new ASN.1 elements.
* @returns {_Element} The CommonCriteriaMeasures, encoded as an ASN.1 Element.
*/
export declare function _encode_CommonCriteriaMeasures(value: CommonCriteriaMeasures, elGetter: $.ASN1Encoder<CommonCriteriaMeasures>): _Element;