@wildboar/pkcs
Version:
Public Key Cryptography Standard PDUs in TypeScript
130 lines (129 loc) • 3.89 kB
TypeScript
import { ASN1Element as _Element, INTEGER, OCTET_STRING, OPTIONAL } from "asn1-ts";
import * as $ from "asn1-ts/dist/node/functional";
import { RC5_CBC_Parameters_version } from "../PKCS5v2-1/RC5-CBC-Parameters-version.ta";
export { RC5_CBC_Parameters_version, RC5_CBC_Parameters_version_v1_0, v1_0, _decode_RC5_CBC_Parameters_version, _encode_RC5_CBC_Parameters_version, } from "../PKCS5v2-1/RC5-CBC-Parameters-version.ta";
/**
* @summary RC5_CBC_Parameters
* @description
*
* ### ASN.1 Definition:
*
* ```asn1
* RC5-CBC-Parameters ::= SEQUENCE {
* version INTEGER {v1-0(16)} (v1-0),
* rounds INTEGER (8..127),
* blockSizeInBits INTEGER (64 | 128),
* iv OCTET STRING OPTIONAL
* }
* ```
*
* @class
*/
export declare class RC5_CBC_Parameters {
/**
* @summary `version`.
* @public
* @readonly
*/
readonly version: RC5_CBC_Parameters_version;
/**
* @summary `rounds`.
* @public
* @readonly
*/
readonly rounds: INTEGER;
/**
* @summary `blockSizeInBits`.
* @public
* @readonly
*/
readonly blockSizeInBits: INTEGER;
/**
* @summary `iv`.
* @public
* @readonly
*/
readonly iv: OPTIONAL<OCTET_STRING>;
constructor(
/**
* @summary `version`.
* @public
* @readonly
*/
version: RC5_CBC_Parameters_version,
/**
* @summary `rounds`.
* @public
* @readonly
*/
rounds: INTEGER,
/**
* @summary `blockSizeInBits`.
* @public
* @readonly
*/
blockSizeInBits: INTEGER,
/**
* @summary `iv`.
* @public
* @readonly
*/
iv: OPTIONAL<OCTET_STRING>);
/**
* @summary Restructures an object into a RC5_CBC_Parameters
* @description
*
* This takes an `object` and converts it to a `RC5_CBC_Parameters`.
*
* @public
* @static
* @method
* @param {Object} _o An object having all of the keys and values of a `RC5_CBC_Parameters`.
* @returns {RC5_CBC_Parameters}
*/
static _from_object(_o: {
[_K in keyof RC5_CBC_Parameters]: RC5_CBC_Parameters[_K];
}): RC5_CBC_Parameters;
}
/**
* @summary The Leading Root Component Types of RC5_CBC_Parameters
* @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_RC5_CBC_Parameters: $.ComponentSpec[];
/**
* @summary The Trailing Root Component Types of RC5_CBC_Parameters
* @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_RC5_CBC_Parameters: $.ComponentSpec[];
/**
* @summary The Extension Addition Component Types of RC5_CBC_Parameters
* @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_RC5_CBC_Parameters: $.ComponentSpec[];
/**
* @summary Decodes an ASN.1 element into a(n) RC5_CBC_Parameters
* @function
* @param {_Element} el The element being decoded.
* @returns {RC5_CBC_Parameters} The decoded data structure.
*/
export declare function _decode_RC5_CBC_Parameters(el: _Element): RC5_CBC_Parameters;
/**
* @summary Encodes a(n) RC5_CBC_Parameters 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 RC5_CBC_Parameters, encoded as an ASN.1 Element.
*/
export declare function _encode_RC5_CBC_Parameters(value: RC5_CBC_Parameters, elGetter: $.ASN1Encoder<RC5_CBC_Parameters>): _Element;