@bitwarden/sdk-internal 0.2.0-main.87 → 0.2.0-main.88
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/VERSION +1 -1
- package/bitwarden_wasm_internal.d.ts +23 -24
- package/bitwarden_wasm_internal_bg.js +6 -6
- package/bitwarden_wasm_internal_bg.wasm +0 -0
- package/bitwarden_wasm_internal_bg.wasm.d.ts +1 -1
- package/bitwarden_wasm_internal_bg.wasm.js +1 -1
- package/node/bitwarden_wasm_internal.d.ts +23 -24
- package/node/bitwarden_wasm_internal.js +6 -6
- package/node/bitwarden_wasm_internal_bg.wasm +0 -0
- package/node/bitwarden_wasm_internal_bg.wasm.d.ts +1 -1
- package/package.json +1 -1
@@ -115,30 +115,6 @@ export interface VerifyAsymmetricKeysResponse {
|
|
115
115
|
validPrivateKey: boolean;
|
116
116
|
}
|
117
117
|
|
118
|
-
export interface CoreError extends Error {
|
119
|
-
name: "CoreError";
|
120
|
-
variant:
|
121
|
-
| "MissingFieldError"
|
122
|
-
| "VaultLocked"
|
123
|
-
| "NotAuthenticated"
|
124
|
-
| "AccessTokenInvalid"
|
125
|
-
| "InvalidResponse"
|
126
|
-
| "Crypto"
|
127
|
-
| "IdentityFail"
|
128
|
-
| "Reqwest"
|
129
|
-
| "Serde"
|
130
|
-
| "Io"
|
131
|
-
| "InvalidBase64"
|
132
|
-
| "Chrono"
|
133
|
-
| "ResponseContent"
|
134
|
-
| "InvalidStateFileVersion"
|
135
|
-
| "InvalidStateFile"
|
136
|
-
| "Internal"
|
137
|
-
| "EncryptionSettings";
|
138
|
-
}
|
139
|
-
|
140
|
-
export function isCoreError(error: any): error is CoreError;
|
141
|
-
|
142
118
|
export interface EncryptionSettingsError extends Error {
|
143
119
|
name: "EncryptionSettingsError";
|
144
120
|
variant: "Crypto" | "InvalidBase64" | "VaultLocked" | "InvalidPrivateKey" | "MissingPrivateKey";
|
@@ -224,6 +200,29 @@ export type Kdf =
|
|
224
200
|
| { pBKDF2: { iterations: NonZeroU32 } }
|
225
201
|
| { argon2id: { iterations: NonZeroU32; memory: NonZeroU32; parallelism: NonZeroU32 } };
|
226
202
|
|
203
|
+
export interface CryptoError extends Error {
|
204
|
+
name: "CryptoError";
|
205
|
+
variant:
|
206
|
+
| "InvalidKey"
|
207
|
+
| "InvalidMac"
|
208
|
+
| "MacNotProvided"
|
209
|
+
| "KeyDecrypt"
|
210
|
+
| "InvalidKeyLen"
|
211
|
+
| "InvalidUtf8String"
|
212
|
+
| "MissingKey"
|
213
|
+
| "MissingField"
|
214
|
+
| "MissingKeyId"
|
215
|
+
| "ReadOnlyKeyStore"
|
216
|
+
| "InsufficientKdfParameters"
|
217
|
+
| "EncString"
|
218
|
+
| "RsaError"
|
219
|
+
| "FingerprintError"
|
220
|
+
| "ArgonError"
|
221
|
+
| "ZeroNumber";
|
222
|
+
}
|
223
|
+
|
224
|
+
export function isCryptoError(error: any): error is CryptoError;
|
225
|
+
|
227
226
|
export interface SshKey {
|
228
227
|
/**
|
229
228
|
* The private key in OpenSSH format
|
@@ -244,9 +244,9 @@ function addBorrowedObject(obj) {
|
|
244
244
|
* @param {any} error
|
245
245
|
* @returns {boolean}
|
246
246
|
*/
|
247
|
-
module.exports.
|
247
|
+
module.exports.isEncryptionSettingsError = function (error) {
|
248
248
|
try {
|
249
|
-
const ret = wasm.
|
249
|
+
const ret = wasm.isEncryptionSettingsError(addBorrowedObject(error));
|
250
250
|
return ret !== 0;
|
251
251
|
} finally {
|
252
252
|
heap[stack_pointer++] = undefined;
|
@@ -257,9 +257,9 @@ module.exports.isCoreError = function (error) {
|
|
257
257
|
* @param {any} error
|
258
258
|
* @returns {boolean}
|
259
259
|
*/
|
260
|
-
module.exports.
|
260
|
+
module.exports.isCryptoError = function (error) {
|
261
261
|
try {
|
262
|
-
const ret = wasm.
|
262
|
+
const ret = wasm.isCryptoError(addBorrowedObject(error));
|
263
263
|
return ret !== 0;
|
264
264
|
} finally {
|
265
265
|
heap[stack_pointer++] = undefined;
|
@@ -1404,8 +1404,8 @@ module.exports.__wbindgen_cb_drop = function (arg0) {
|
|
1404
1404
|
return ret;
|
1405
1405
|
};
|
1406
1406
|
|
1407
|
-
module.exports.
|
1408
|
-
const ret = makeMutClosure(arg0, arg1,
|
1407
|
+
module.exports.__wbindgen_closure_wrapper2088 = function (arg0, arg1, arg2) {
|
1408
|
+
const ret = makeMutClosure(arg0, arg1, 559, __wbg_adapter_40);
|
1409
1409
|
return addHeapObject(ret);
|
1410
1410
|
};
|
1411
1411
|
|
Binary file
|
@@ -1,8 +1,8 @@
|
|
1
1
|
/* tslint:disable */
|
2
2
|
/* eslint-disable */
|
3
3
|
export const memory: WebAssembly.Memory;
|
4
|
-
export const isCoreError: (a: number) => number;
|
5
4
|
export const isEncryptionSettingsError: (a: number) => number;
|
5
|
+
export const isCryptoError: (a: number) => number;
|
6
6
|
export const isSshKeyExportError: (a: number) => number;
|
7
7
|
export const isSshKeyImportError: (a: number) => number;
|
8
8
|
export const isKeyGenerationError: (a: number) => number;
|