UNPKG

@wildboar/pkcs

Version:
41 lines (40 loc) 1.87 kB
import { ASN1Element as _Element } from "asn1-ts"; import * as $ from "asn1-ts/dist/node/functional"; import { AuthKeyAttributes } from "../PKCS-15/AuthKeyAttributes.ta"; import { CertBasedAuthenticationAttributes } from "../PKCS-15/CertBasedAuthenticationAttributes.ta"; export { AuthKeyAttributes, _decode_AuthKeyAttributes, _encode_AuthKeyAttributes, } from "../PKCS-15/AuthKeyAttributes.ta"; export { CertBasedAuthenticationAttributes, _decode_CertBasedAuthenticationAttributes, _encode_CertBasedAuthenticationAttributes, } from "../PKCS-15/CertBasedAuthenticationAttributes.ta"; /** * @summary ExternalAuthObjectAttributes * @description * * ### ASN.1 Definition: * * ```asn1 * ExternalAuthObjectAttributes ::= CHOICE { * authKeyAttributes AuthKeyAttributes, * certBasedAttributes [0] CertBasedAuthenticationAttributes, * ... -- For future extensions * } * ``` */ export declare type ExternalAuthObjectAttributes = { authKeyAttributes: AuthKeyAttributes; } | { certBasedAttributes: CertBasedAuthenticationAttributes; } | _Element; /** * @summary Decodes an ASN.1 element into a(n) ExternalAuthObjectAttributes * @function * @param {_Element} el The element being decoded. * @returns {ExternalAuthObjectAttributes} The decoded data structure. */ export declare function _decode_ExternalAuthObjectAttributes(el: _Element): ExternalAuthObjectAttributes; /** * @summary Encodes a(n) ExternalAuthObjectAttributes 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 ExternalAuthObjectAttributes, encoded as an ASN.1 Element. */ export declare function _encode_ExternalAuthObjectAttributes(value: ExternalAuthObjectAttributes, elGetter: $.ASN1Encoder<ExternalAuthObjectAttributes>): _Element;