Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@aws-crypto/raw-rsa-keyring-browser

Package Overview
Dependencies
Maintainers
9
Versions
27
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@aws-crypto/raw-rsa-keyring-browser - npm Package Compare versions

Comparing version 3.0.2 to 3.1.0

18

build/main/src/get_import_options.d.ts
import { RsaJsonWebKey, RsaImportableKey, RsaWrappingKeyAlgorithm } from './types';
import { MixedBackendCryptoKey, AwsEsdkJsCryptoKey } from '@aws-crypto/material-management-browser';
export declare function getImportOptions(keyInfo: RsaImportableKey): {
format: string;
format: 'jwk';
wrappingAlgorithm: RsaWrappingKeyAlgorithm;
key: RsaJsonWebKey;
wrappingAlgorithm: Readonly<{
name: "RSA-OAEP" | "RSA-OAEP-256" | "RSA-OAEP-384" | "RSA-OAEP-512";
hash: Readonly<Readonly<{
name: "SHA-256" | "SHA-384" | "SHA-512" | "SHA-1";
}>>;
}>;
} | {
format: "spki" | "pkcs8" | import("./types").Format | "raw";
format: 'raw' | 'pkcs8' | 'spki';
wrappingAlgorithm: RsaWrappingKeyAlgorithm;
key: Uint8Array;
wrappingAlgorithm: Readonly<{
name: "RSA-OAEP" | "RSA-OAEP-256" | "RSA-OAEP-384" | "RSA-OAEP-512";
hash: Readonly<Readonly<{
name: "SHA-256" | "SHA-384" | "SHA-512" | "SHA-1";
}>>;
}>;
};

@@ -22,0 +12,0 @@ export declare function getWrappingAlgorithm(publicKey?: AwsEsdkJsCryptoKey, privateKey?: AwsEsdkJsCryptoKey | MixedBackendCryptoKey): Readonly<{

@@ -89,8 +89,8 @@ "use strict";

/* Precondition: Need at least 1 algorithm to verify. */
material_management_browser_1.needs(wrappingAlgorithm, 'Can not verify an empty set of algorithms.');
(0, material_management_browser_1.needs)(wrappingAlgorithm, 'Can not verify an empty set of algorithms.');
const { name, hash } = wrappingAlgorithm;
/* Precondition: The wrappingAlgorithm name must be a supported value. */
material_management_browser_1.needs(types_1.JsonWebKeyRsaAlg[name], 'Algorithm name is not supported.');
(0, material_management_browser_1.needs)(types_1.JsonWebKeyRsaAlg[name], 'Algorithm name is not supported.');
/* Precondition: The hash name must be a supported value. */
material_management_browser_1.needs(hash && types_1.RsaHash[hash.name], 'Hash name is not supported.');
(0, material_management_browser_1.needs)(hash && types_1.RsaHash[hash.name], 'Hash name is not supported.');
/* Check for early return (Postcondition): Only 1 wrappingAlgorithm is clearly valid. */

@@ -100,3 +100,3 @@ if (!rest.length)

/* Precondition: All keys must have the same wrappingAlgorithm. */
material_management_browser_1.needs(rest.every(equalWrappingAlgorithm), 'Not all RSA keys have the same wrappingAlgorithm.');
(0, material_management_browser_1.needs)(rest.every(equalWrappingAlgorithm), 'Not all RSA keys have the same wrappingAlgorithm.');
return wrappingAlgorithm;

@@ -114,3 +114,3 @@ function equalWrappingAlgorithm(algorithm) {

return [];
if (material_management_browser_1.isCryptoKey(key))
if ((0, material_management_browser_1.isCryptoKey)(key))
return [key];

@@ -120,6 +120,6 @@ const { nonZeroByteCryptoKey, zeroByteCryptoKey } = key;

/* Postcondition: Not all keys are CryptoKeys. */
material_management_browser_1.needs(keys.every(material_management_browser_1.isCryptoKey), 'Not all keys are CryptoKeys.');
(0, material_management_browser_1.needs)(keys.every(material_management_browser_1.isCryptoKey), 'Not all keys are CryptoKeys.');
return keys;
}
exports.flattenMixedCryptoKey = flattenMixedCryptoKey;
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZ2V0X2ltcG9ydF9vcHRpb25zLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vc3JjL2dldF9pbXBvcnRfb3B0aW9ucy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiO0FBQUEsb0VBQW9FO0FBQ3BFLHNDQUFzQzs7O0FBRXRDLG1DQVFnQjtBQUNoQix5RkFLZ0Q7QUFHaEQsTUFBTSx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25CLElBQUksSUFBQSx5Q0FBVyxFQUFDLEdBQUcsQ0FBQztRQUFFLE9BQU8sQ0FBQyxHQUFHLENBQUMsQ0FBQTtJQUNsQyxNQUFNLEVBQUUsb0JBQW9CLEVBQUUsaUJBQWlCLEVBQUUsR0FBRyxHQUFHLENBQUE7SUFDdkQsTUFBTSxJQUFJLEdBQUcsQ0FBQyxvQkFBb0IsRUFBRSxpQkFBaUIsQ0FBQyxDQUFBO0lBQ3RELGlEQUFpRDtJQUNqRCxJQUFBLG1DQUFLLEVBQUMsSUFBSSxDQUFDLEtBQUssQ0FBQyx5Q0FBVyxDQUFDLEVBQUUsOEJBQThCLENBQUMsQ0FBQTtJQUM5RCxPQUFPLElBQUksQ0FBQTtBQUNiLENBQUM7QUFYRCxzREFXQyJ9

@@ -11,2 +11,3 @@ "use strict";

const get_import_options_1 = require("./get_import_options");
// noinspection TypeScriptValidateTypes
class RawRsaKeyringWebCrypto extends material_management_browser_1.KeyringWebCrypto {

@@ -17,6 +18,6 @@ constructor(input) {

/* Precondition: RsaKeyringWebCrypto needs either a public or a private key to operate. */
material_management_browser_1.needs(publicKey || privateKey, 'No Key provided.');
(0, material_management_browser_1.needs)(publicKey || privateKey, 'No Key provided.');
/* Precondition: RsaKeyringWebCrypto needs identifying information for encrypt and decrypt. */
material_management_browser_1.needs(keyName && keyNamespace, 'Identifying information must be defined.');
const wrappingAlgorithm = get_import_options_1.getWrappingAlgorithm(publicKey, privateKey);
(0, material_management_browser_1.needs)(keyName && keyNamespace, 'Identifying information must be defined.');
const wrappingAlgorithm = (0, get_import_options_1.getWrappingAlgorithm)(publicKey, privateKey);
const _wrapKey = async (material) => {

@@ -29,3 +30,3 @@ /* Precondition: I must have a publicKey to wrap. */

// browser implementation of wrapKey
const subtle = web_crypto_backend_1.getNonZeroByteBackend(await web_crypto_backend_1.getWebCryptoBackend());
const subtle = (0, web_crypto_backend_1.getNonZeroByteBackend)(await (0, web_crypto_backend_1.getWebCryptoBackend)());
/* Can not use importCryptoKey as `wrapKey` requires extractable = true

@@ -39,3 +40,3 @@ * In web crypto `wrapKey` is a composition of `export` and `encrypt` and

const keyUsages = ['wrapKey']; // limit the use of this key (*not* decrypt, encrypt, deriveKey)
const jwk = material_management_browser_1.bytes2JWK(material_management_browser_1.unwrapDataKey(material.getUnencryptedDataKey()));
const jwk = (0, material_management_browser_1.bytes2JWK)((0, material_management_browser_1.unwrapDataKey)(material.getUnencryptedDataKey()));
const cryptoKey = await subtle.importKey(importFormat, jwk, encryption, extractable, keyUsages);

@@ -55,3 +56,3 @@ const wrapFormat = 'raw';

*/
const privateKeys = get_import_options_1.flattenMixedCryptoKey(privateKey);
const privateKeys = (0, get_import_options_1.flattenMixedCryptoKey)(privateKey);
const _unwrapKey = async (material, edk) => {

@@ -61,3 +62,3 @@ /* Precondition: I must have a privateKey to unwrap. */

throw new Error('No privateKey configured, decrypt not supported.');
const backend = await web_crypto_backend_1.getWebCryptoBackend();
const backend = await (0, web_crypto_backend_1.getWebCryptoBackend)();
const { suite } = material;

@@ -72,3 +73,3 @@ const trace = {

const algorithm = suite.kdf ? suite.kdf : suite.encryption;
const keyUsages = [material_management_browser_1.keyUsageForMaterial(material)];
const keyUsages = [(0, material_management_browser_1.keyUsageForMaterial)(material)];
const importArgs = [

@@ -87,3 +88,3 @@ format,

*/
if (web_crypto_backend_1.isFullSupportWebCryptoBackend(backend)) {
if ((0, web_crypto_backend_1.isFullSupportWebCryptoBackend)(backend)) {
const cryptoKey = await backend.subtle.unwrapKey(...importArgs);

@@ -105,6 +106,6 @@ return material.setCryptoKey(cryptoKey, trace);

};
material_management_browser_1.readOnlyProperty(this, 'keyName', keyName);
material_management_browser_1.readOnlyProperty(this, 'keyNamespace', keyNamespace);
material_management_browser_1.readOnlyProperty(this, '_wrapKey', _wrapKey);
material_management_browser_1.readOnlyProperty(this, '_unwrapKey', _unwrapKey);
(0, material_management_browser_1.readOnlyProperty)(this, 'keyName', keyName);
(0, material_management_browser_1.readOnlyProperty)(this, 'keyNamespace', keyNamespace);
(0, material_management_browser_1.readOnlyProperty)(this, '_wrapKey', _wrapKey);
(0, material_management_browser_1.readOnlyProperty)(this, '_unwrapKey', _unwrapKey);
}

@@ -115,6 +116,6 @@ _filter({ providerId, providerInfo }) {

}
_rawOnEncrypt = raw_keyring_1._onEncrypt(random_source_browser_1.randomValuesOnly);
_rawOnEncrypt = (0, raw_keyring_1._onEncrypt)(random_source_browser_1.randomValuesOnly);
_onEncrypt = async (material) => {
const _material = await this._rawOnEncrypt(material);
return material_management_browser_1.importForWebCryptoEncryptionMaterial(_material);
return (0, material_management_browser_1.importForWebCryptoEncryptionMaterial)(_material);
};

@@ -125,21 +126,19 @@ /* onDecrypt does not need to import the CryptoKey, because this is handled in the unwrap operation.

*/
_onDecrypt = raw_keyring_1._onDecrypt();
_onDecrypt = (0, raw_keyring_1._onDecrypt)();
static async importPublicKey(publicKey) {
const { wrappingAlgorithm, format, key } = get_import_options_1.getImportOptions(publicKey);
const backend = await web_crypto_backend_1.getWebCryptoBackend();
const subtle = web_crypto_backend_1.getNonZeroByteBackend(backend);
return subtle.importKey(format, key, wrappingAlgorithm, false, ['wrapKey']);
const op = (0, get_import_options_1.getImportOptions)(publicKey);
const backend = await (0, web_crypto_backend_1.getWebCryptoBackend)();
const subtle = (0, web_crypto_backend_1.getNonZeroByteBackend)(backend);
return ImportKeyTypeOverload(op, subtle, ['wrapKey']);
}
static async importPrivateKey(privateKey) {
const { wrappingAlgorithm, format, key } = get_import_options_1.getImportOptions(privateKey);
const backend = await web_crypto_backend_1.getWebCryptoBackend();
if (web_crypto_backend_1.isFullSupportWebCryptoBackend(backend)) {
return backend.subtle.importKey(format, key, wrappingAlgorithm, false, [
'unwrapKey',
]);
const op = (0, get_import_options_1.getImportOptions)(privateKey);
const backend = await (0, web_crypto_backend_1.getWebCryptoBackend)();
if ((0, web_crypto_backend_1.isFullSupportWebCryptoBackend)(backend)) {
return ImportKeyTypeOverload(op, backend.subtle, ['unwrapKey']);
}
else {
return Promise.all([
backend.nonZeroByteSubtle.importKey(format, key, wrappingAlgorithm, false, ['unwrapKey']),
backend.zeroByteSubtle.importKey(format, key, wrappingAlgorithm, false, ['unwrapKey']),
ImportKeyTypeOverload(op, backend.nonZeroByteSubtle, ['unwrapKey']),
ImportKeyTypeOverload(op, backend.zeroByteSubtle, ['unwrapKey']),
]).then(([nonZeroByteCryptoKey, zeroByteCryptoKey]) => ({

@@ -153,3 +152,30 @@ nonZeroByteCryptoKey,

exports.RawRsaKeyringWebCrypto = RawRsaKeyringWebCrypto;
material_management_browser_1.immutableClass(RawRsaKeyringWebCrypto);
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmF3X3JzYV9rZXlyaW5nX3dlYl9jcnlwdG8uanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8uLi9zcmMvcmF3X3JzYV9rZXlyaW5nX3dlYl9jcnlwdG8udHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IjtBQUFBLG9FQUFvRTtBQUNwRSxzQ0FBc0M7OztBQUV0Qyx5RkFpQmdEO0FBRWhELHVFQUl1QztBQUN2Qyx5REFLZ0M7QUFDaEMsNkVBQW9FO0FBRXBFLDZEQUk2QjtBQUU3QixNQUFhLHNCQUF1QixTQUFRLDhDQUFnQjtJQU0xRCxZQUFZLEtBQWtDO1FBQzVDLEtBQUssRUFBRSxDQUFBO1FBRVAsTUFBTSxFQUFFLFNBQVMsRUFBRSxVQUFVLEVBQUUsT0FBTyxFQUFFLFlBQVksRUFBRSxHQUFHLEtBQUssQ0FBQTtRQUM5RCwwRkFBMEY7UUFDMUYsbUNBQUssQ0FBQyxTQUFTLElBQUksVUFBVSxFQUFFLGtCQUFrQixDQUFDLENBQUE7UUFDbEQsOEZBQThGO1FBQzlGLG1DQUFLLENBQUMsT0FBTyxJQUFJLFlBQVksRUFBRSwwQ0FBMEMsQ0FBQyxDQUFBO1FBRTFFLE1BQU0saUJBQW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O2dCQUNELE9BQU8sQ0FBQyxjQUFjLENBQUMsU0FBUyxDQUM5QixNQUFNLEVBQ04sR0FBRyxFQUNILGlCQUFpQixFQUNqQixLQUFLLEVBQ0wsQ0FBQyxXQUFXLENBQUMsQ0FDZDthQUNGLENBQUMsQ0FBQyxJQUFJLENBQUMsQ0FBQyxDQUFDLG9CQUFvQixFQUFFLGlCQUFpQixDQUFDLEVBQUUsRUFBRSxDQUFDLENBQUM7Z0JBQ3RELG9CQUFvQjtnQkFDcEIsaUJBQWlCO2FBQ2xCLENBQUMsQ0FBQyxDQUFBO1NBQ0o7SUFDSCxDQUFDO0NBQ0Y7QUE3TEQsd0RBNkxDO0FBQ0QsNENBQWMsQ0FBQyxzQkFBc0IsQ0FBQyxDQUFBIn0=
(0, material_management_browser_1.immutableClass)(RawRsaKeyringWebCrypto);
// TS2769 Note:
// TS2769 is "No overload matches this call".
// Above and below, TS is incorrect.
// `importKey` has two overrides,
// They are abbreviated below:
// ```
// importKey(format: "jwk", keyData: JsonWebKey, algorithm: AlgorithmIdentifier | ... , extractable: boolean, keyUsages: KeyUsage[]): Promise<CryptoKey>;
// importKey(format: "raw" | "pkcs8" | "spki", keyData: BufferSource, algorithm: AlgorithmIdentifier | ..., extractable: boolean, keyUsages: KeyUsage[]): Promise<CryptoKey>;
// ```
// The method getImportOptions explicitly
// returns format & key that match
// these overrides.
// However, TS is unable to recognize this easily.
// The following ugly function does the disambiguation.
// There are 2 problems that TS is having.
// First when format key and wrappingAlgorithm are independent,
// TS does not _remember_ the relationship between format and key.
// The second issue is related,
// when trying to select the proper overload,
// it is collapsing the definition of format.
// Thus discriminating the union by `format`
// helps TS understand all the arguments.
async function ImportKeyTypeOverload(op, subtle, keyUsages) {
return op.format == 'jwk'
? subtle.importKey(op.format, op.key, op.wrappingAlgorithm, false, keyUsages)
: subtle.importKey(op.format, op.key, op.wrappingAlgorithm, false, keyUsages);
}
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJma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WlDO0FBQ2pDLDhCQUE4QjtBQUM5QixNQUFNO0FBQ04seUpBQXlKO0FBQ3pKLDhLQUE4SztBQUM5SyxNQUFNO0FBQ04seUNBQXlDO0FBQ3pDLGtDQUFrQztBQUNsQyxtQkFBbUI7QUFDbkIsa0RBQWtEO0FBQ2xELHVEQUF1RDtBQUN2RCwwQ0FBMEM7QUFDMUMsK0RBQStEO0FBQy9ELGtFQUFrRTtBQUNsRSwrQkFBK0I7QUFDL0IsNkNBQTZDO0FBQzdDLDZDQUE2QztBQUM3Qyw0Q0FBNEM7QUFDNUMseUNBQXlDO0FBQ3pDLEtBQUssVUFBVSxxQkFBcUIsQ0FDbEMsRUFBdUMsRUFDdkMsTUFBb0IsRUFDcEIsU0FBcUI7SUFFckIsT0FBTyxFQUFFLENBQUMsTUFBTSxJQUFJLEtBQUs7UUFDdkIsQ0FBQyxDQUFDLE1BQU0sQ0FBQyxTQUFTLENBQ2QsRUFBRSxDQUFDLE1BQU0sRUFDVCxFQUFFLENBQUMsR0FBRyxFQUNOLEVBQUUsQ0FBQyxpQkFBaUIsRUFDcEIsS0FBSyxFQUNMLFNBQVMsQ0FDVjtRQUNILENBQUMsQ0FBQyxNQUFNLENBQUMsU0FBUyxDQUNkLEVBQUUsQ0FBQyxNQUFNLEVBQ1QsRUFBRSxDQUFDLEdBQUcsRUFDTixFQUFFLENBQUMsaUJBQWlCLEVBQ3BCLEtBQUssRUFDTCxTQUFTLENBQ1YsQ0FBQTtBQUNQLENBQUMifQ==
import { RsaJsonWebKey, RsaImportableKey, RsaWrappingKeyAlgorithm } from './types';
import { MixedBackendCryptoKey, AwsEsdkJsCryptoKey } from '@aws-crypto/material-management-browser';
export declare function getImportOptions(keyInfo: RsaImportableKey): {
format: string;
format: 'jwk';
wrappingAlgorithm: RsaWrappingKeyAlgorithm;
key: RsaJsonWebKey;
wrappingAlgorithm: Readonly<{
name: "RSA-OAEP" | "RSA-OAEP-256" | "RSA-OAEP-384" | "RSA-OAEP-512";
hash: Readonly<Readonly<{
name: "SHA-256" | "SHA-384" | "SHA-512" | "SHA-1";
}>>;
}>;
} | {
format: "spki" | "pkcs8" | import("./types").Format | "raw";
format: 'raw' | 'pkcs8' | 'spki';
wrappingAlgorithm: RsaWrappingKeyAlgorithm;
key: Uint8Array;
wrappingAlgorithm: Readonly<{
name: "RSA-OAEP" | "RSA-OAEP-256" | "RSA-OAEP-384" | "RSA-OAEP-512";
hash: Readonly<Readonly<{
name: "SHA-256" | "SHA-384" | "SHA-512" | "SHA-1";
}>>;
}>;
};

@@ -22,0 +12,0 @@ export declare function getWrappingAlgorithm(publicKey?: AwsEsdkJsCryptoKey, privateKey?: AwsEsdkJsCryptoKey | MixedBackendCryptoKey): Readonly<{

@@ -113,2 +113,2 @@ // Copyright Amazon.com Inc. or its affiliates. All Rights Reserved.

}
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZ2V0X2ltcG9ydF9vcHRpb25zLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vc3JjL2dldF9pbXBvcnRfb3B0aW9ucy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxvRUFBb0U7QUFDcEUsc0NBQXNDO0FBRXRDLE9BQU8sRUFDTCxVQUFVLEVBQ1YsZ0JBQWdCLEVBQ2hCLE9BQU8sR0FLUixNQUFNLFNBQVMsQ0FBQTtBQUNoQixPQUFPLEVBRUwsS0FBSyxFQUNMLFdBQVcsR0FFWixNQUFNLHlDQUF5QyxDQUFBO0FBR2hELE1BQU0sY0FBYyxHQUE0QjtJQUM5QyxJQUFJLEVBQUUsVUFBVTtJQUNoQixJQUFJLEVBQUUsRUFBRSxJQUFJLEVBQUUsT0FBTyxFQUFFO0NBQ3hCLENBQUE7QUFDRCxNQUFNLENBQUMsTUFBTSxDQUFDLGNBQWMsQ0FBQyxDQUFBO0FBQzdCLE1BQU0sQ0FBQyxNQUFNLENBQUMsY0FBYy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0FBQyxJQUFJLENBQUMsS0FBSyxDQUFDLFdBQVcsQ0FBQyxFQUFFLDhCQUE4QixDQUFDLENBQUE7SUFDOUQsT0FBTyxJQUFJLENBQUE7QUFDYixDQUFDIn0=

@@ -8,2 +8,3 @@ // Copyright Amazon.com Inc. or its affiliates. All Rights Reserved.

import { getImportOptions, getWrappingAlgorithm, flattenMixedCryptoKey, } from './get_import_options';
// noinspection TypeScriptValidateTypes
export class RawRsaKeyringWebCrypto extends KeyringWebCrypto {

@@ -115,19 +116,17 @@ constructor(input) {

static async importPublicKey(publicKey) {
const { wrappingAlgorithm, format, key } = getImportOptions(publicKey);
const op = getImportOptions(publicKey);
const backend = await getWebCryptoBackend();
const subtle = getNonZeroByteBackend(backend);
return subtle.importKey(format, key, wrappingAlgorithm, false, ['wrapKey']);
return ImportKeyTypeOverload(op, subtle, ['wrapKey']);
}
static async importPrivateKey(privateKey) {
const { wrappingAlgorithm, format, key } = getImportOptions(privateKey);
const op = getImportOptions(privateKey);
const backend = await getWebCryptoBackend();
if (isFullSupportWebCryptoBackend(backend)) {
return backend.subtle.importKey(format, key, wrappingAlgorithm, false, [
'unwrapKey',
]);
return ImportKeyTypeOverload(op, backend.subtle, ['unwrapKey']);
}
else {
return Promise.all([
backend.nonZeroByteSubtle.importKey(format, key, wrappingAlgorithm, false, ['unwrapKey']),
backend.zeroByteSubtle.importKey(format, key, wrappingAlgorithm, false, ['unwrapKey']),
ImportKeyTypeOverload(op, backend.nonZeroByteSubtle, ['unwrapKey']),
ImportKeyTypeOverload(op, backend.zeroByteSubtle, ['unwrapKey']),
]).then(([nonZeroByteCryptoKey, zeroByteCryptoKey]) => ({

@@ -141,2 +140,29 @@ nonZeroByteCryptoKey,

immutableClass(RawRsaKeyringWebCrypto);
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmF3X3JzYV9rZXlyaW5nX3dlYl9jcnlwdG8uanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcy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0FBQyxTQUFTLENBQzlCLE1BQU0sRUFDTixHQUFHLEVBQ0gsaUJBQWlCLEVBQ2pCLEtBQUssRUFDTCxDQUFDLFdBQVcsQ0FBQyxDQUNkO2FBQ0YsQ0FBQyxDQUFDLElBQUksQ0FBQyxDQUFDLENBQUMsb0JBQW9CLEVBQUUsaUJBQWlCLENBQUMsRUFBRSxFQUFFLENBQUMsQ0FBQztnQkFDdEQsb0JBQW9CO2dCQUNwQixpQkFBaUI7YUFDbEIsQ0FBQyxDQUFDLENBQUE7U0FDSjtJQUNILENBQUM7Q0FDRjtBQUNELGNBQWMsQ0FBQyxzQkFBc0IsQ0FBQyxDQUFBIn0=
// TS2769 Note:
// TS2769 is "No overload matches this call".
// Above and below, TS is incorrect.
// `importKey` has two overrides,
// They are abbreviated below:
// ```
// importKey(format: "jwk", keyData: JsonWebKey, algorithm: AlgorithmIdentifier | ... , extractable: boolean, keyUsages: KeyUsage[]): Promise<CryptoKey>;
// importKey(format: "raw" | "pkcs8" | "spki", keyData: BufferSource, algorithm: AlgorithmIdentifier | ..., extractable: boolean, keyUsages: KeyUsage[]): Promise<CryptoKey>;
// ```
// The method getImportOptions explicitly
// returns format & key that match
// these overrides.
// However, TS is unable to recognize this easily.
// The following ugly function does the disambiguation.
// There are 2 problems that TS is having.
// First when format key and wrappingAlgorithm are independent,
// TS does not _remember_ the relationship between format and key.
// The second issue is related,
// when trying to select the proper overload,
// it is collapsing the definition of format.
// Thus discriminating the union by `format`
// helps TS understand all the arguments.
async function ImportKeyTypeOverload(op, subtle, keyUsages) {
return op.format == 'jwk'
? subtle.importKey(op.format, op.key, op.wrappingAlgorithm, false, keyUsages)
: subtle.importKey(op.format, op.key, op.wrappingAlgorithm, false, keyUsages);
}
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoicmF3X3JzYV9rZXlyaW5nX3dlYl9jcnlwdG8uanMiLCJzb3VyY2VSb290IjoiIiwic291cmNlcyI6WyIuLi8uLi8u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UFDLENBQUE7U0FDSjtJQUNILENBQUM7Q0FDRjtBQUNELGNBQWMsQ0FBQyxzQkFBc0IsQ0FBQyxDQUFBO0FBRXRDLGVBQWU7QUFDZiw2Q0FBNkM7QUFDN0Msb0NBQW9DO0FBQ3BDLGlDQUFpQztBQUNqQyw4QkFBOEI7QUFDOUIsTUFBTTtBQUNOLHlKQUF5SjtBQUN6Siw4S0FBOEs7QUFDOUssTUFBTTtBQUNOLHlDQUF5QztBQUN6QyxrQ0FBa0M7QUFDbEMsbUJBQW1CO0FBQ25CLGtEQUFrRDtBQUNsRCx1REFBdUQ7QUFDdkQsMENBQTBDO0FBQzFDLCtEQUErRDtBQUMvRCxrRUFBa0U7QUFDbEUsK0JBQStCO0FBQy9CLDZDQUE2QztBQUM3Qyw2Q0FBNkM7QUFDN0MsNENBQTRDO0FBQzVDLHlDQUF5QztBQUN6QyxLQUFLLFVBQVUscUJBQXFCLENBQ2xDLEVBQXVDLEVBQ3ZDLE1BQW9CLEVBQ3BCLFNBQXFCO0lBRXJCLE9BQU8sRUFBRSxDQUFDLE1BQU0sSUFBSSxLQUFLO1FBQ3ZCLENBQUMsQ0FBQyxNQUFNLENBQUMsU0FBUyxDQUNkLEVBQUUsQ0FBQyxNQUFNLEVBQ1QsRUFBRSxDQUFDLEdBQUcsRUFDTixFQUFFLENBQUMsaUJBQWlCLEVBQ3BCLEtBQUssRUFDTCxTQUFTLENBQ1Y7UUFDSCxDQUFDLENBQUMsTUFBTSxDQUFDLFNBQVMsQ0FDZCxFQUFFLENBQUMsTUFBTSxFQUNULEVBQUUsQ0FBQyxHQUFHLEVBQ04sRUFBRSxDQUFDLGlCQUFpQixFQUNwQixLQUFLLEVBQ0wsU0FBUyxDQUNWLENBQUE7QUFDUCxDQUFDIn0=
{
"name": "@aws-crypto/raw-rsa-keyring-browser",
"version": "3.0.2",
"version": "3.1.0",
"scripts": {

@@ -21,6 +21,6 @@ "prepublishOnly": "npm run build",

"dependencies": {
"@aws-crypto/material-management-browser": "^3.0.2",
"@aws-crypto/material-management-browser": "^3.1.0",
"@aws-crypto/random-source-browser": "1.0.0",
"@aws-crypto/raw-keyring": "^3.0.0",
"@aws-crypto/web-crypto-backend": "^3.0.2",
"@aws-crypto/raw-keyring": "^3.1.0",
"@aws-crypto/web-crypto-backend": "^3.1.0",
"@aws-sdk/util-base64-browser": "3.1.0",

@@ -36,3 +36,3 @@ "tslib": "^2.2.0"

],
"gitHead": "80db4edcce0853a303e0200551bf658cac18f9c6"
"gitHead": "1bc8957ce9378767d3fca65ae5310c130384e075"
}

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc