@metamask-previews/passkey-controller 2.1.0-preview-eade524 → 2.1.0-preview-355b70c
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/CHANGELOG.md +0 -21
- package/README.md +20 -85
- package/dist/PasskeyController-method-action-types.cjs.map +1 -1
- package/dist/PasskeyController-method-action-types.d.cts +7 -85
- package/dist/PasskeyController-method-action-types.d.cts.map +1 -1
- package/dist/PasskeyController-method-action-types.d.mts +7 -85
- package/dist/PasskeyController-method-action-types.d.mts.map +1 -1
- package/dist/PasskeyController-method-action-types.mjs.map +1 -1
- package/dist/PasskeyController.cjs +164 -326
- package/dist/PasskeyController.cjs.map +1 -1
- package/dist/PasskeyController.d.cts +50 -88
- package/dist/PasskeyController.d.cts.map +1 -1
- package/dist/PasskeyController.d.mts +50 -88
- package/dist/PasskeyController.d.mts.map +1 -1
- package/dist/PasskeyController.mjs +164 -326
- package/dist/PasskeyController.mjs.map +1 -1
- package/dist/constants.cjs +0 -3
- package/dist/constants.cjs.map +1 -1
- package/dist/constants.d.cts +1 -4
- package/dist/constants.d.cts.map +1 -1
- package/dist/constants.d.mts +1 -4
- package/dist/constants.d.mts.map +1 -1
- package/dist/constants.mjs +0 -3
- package/dist/constants.mjs.map +1 -1
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +3 -2
- package/dist/index.d.cts.map +1 -1
- package/dist/index.d.mts +3 -2
- package/dist/index.d.mts.map +1 -1
- package/dist/index.mjs.map +1 -1
- package/dist/types.cjs +0 -1
- package/dist/types.cjs.map +1 -1
- package/dist/types.d.cts +0 -38
- package/dist/types.d.cts.map +1 -1
- package/dist/types.d.mts +0 -38
- package/dist/types.d.mts.map +1 -1
- package/dist/types.mjs +1 -1
- package/dist/types.mjs.map +1 -1
- package/package.json +2 -4
package/dist/types.mjs.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"types.mjs","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"types.mjs","sourceRoot":"","sources":["../src/types.ts"],"names":[],"mappings":"","sourcesContent":["export type Base64String = string;\n\nexport type Base64URLString = string;\n\nexport type AuthenticatorTransportFuture =\n | 'ble'\n | 'cable'\n | 'hybrid'\n | 'internal'\n | 'nfc'\n | 'smart-card'\n | 'usb';\n\n/**\n * WebAuthn credential metadata used to identify the passkey and verify\n * subsequent assertions.\n */\nexport type PasskeyCredentialInfo = {\n /** WebAuthn credential ID (base64url). */\n id: Base64URLString;\n /** COSE-encoded credential public key (base64url) used to verify assertions. */\n publicKey: Base64URLString;\n /** Authenticator signature counter for replay/clone detection. */\n counter: number;\n /** Authenticator transports hint for `allowCredentials`. */\n transports?: AuthenticatorTransportFuture[];\n /** Authenticator AAGUID captured from attested credential data at registration. */\n aaguid: string;\n};\n\n/**\n * Vault key wrapped under the passkey-derived AES-256-GCM key.\n */\nexport type EncryptedVaultKey = {\n /** Base64-encoded AES-256-GCM ciphertext of the vault key. */\n ciphertext: Base64String;\n /** Base64-encoded AES-GCM IV used during encryption. */\n iv: Base64String;\n};\n\n/**\n * Parameters needed to reproduce the AES-256 wrapping key at unlock time.\n *\n * Encoded as a discriminated union so PRF-only fields (e.g. `prfSalt`) can\n * only exist on the PRF branch, removing the \"optional but actually\n * required\" footgun.\n */\nexport type PasskeyKeyDerivation =\n | {\n method: 'prf';\n /**\n * PRF salt sent in `get()` extension options to reproduce the same PRF\n * output that was generated at registration.\n */\n prfSalt: Base64URLString;\n }\n | { method: 'userHandle' };\n\n/** Discriminator value for {@link PasskeyKeyDerivation}. */\nexport type PasskeyDerivationMethod = PasskeyKeyDerivation['method'];\n\nexport type PasskeyRecord = {\n /** WebAuthn credential metadata used for assertion verification & re-discovery. */\n credential: PasskeyCredentialInfo;\n /** Vault key wrapped under the passkey-derived key. */\n encryptedVaultKey: EncryptedVaultKey;\n /** How the wrapping key is reconstructed at unlock time. */\n keyDerivation: PasskeyKeyDerivation;\n};\n\n/**\n * In-memory state for one **in-flight** WebAuthn **registration** ceremony\n * (from `create()` options until `protectVaultKeyWithPasskey` completes). This is\n * not a user login session; it is keyed by challenge and distinct from the full\n * spec ceremony (which includes the authenticator round-trip).\n */\nexport type PasskeyRegistrationCeremony = {\n userHandle: Base64URLString;\n prfSalt?: Base64URLString;\n challenge: Base64URLString;\n /** When this ceremony was started (ms since epoch); used for TTL pruning. */\n createdAt: number;\n};\n\n/**\n * In-memory state for one **in-flight** WebAuthn **authentication** ceremony\n * (`get()` options until the assertion is verified). Not a user login session.\n */\nexport type PasskeyAuthenticationCeremony = {\n challenge: Base64URLString;\n /** When this ceremony was started (ms since epoch); used for TTL pruning. */\n createdAt: number;\n};\n\n/**\n * PRF extension types not covered by DOM typings.\n */\nexport type PrfEvalExtension = {\n eval: {\n first: Base64URLString;\n };\n};\n\nexport type PrfClientExtensionResults = {\n prf?: {\n enabled?: boolean;\n results?: { first?: Base64URLString };\n };\n};\n"]}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@metamask-previews/passkey-controller",
|
|
3
|
-
"version": "2.1.0-preview-
|
|
3
|
+
"version": "2.1.0-preview-355b70c",
|
|
4
4
|
"description": "Controller and utilities for passkey-based wallet unlock",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"Ethereum",
|
|
@@ -58,13 +58,11 @@
|
|
|
58
58
|
"dependencies": {
|
|
59
59
|
"@levischuck/tiny-cbor": "^0.3.3",
|
|
60
60
|
"@metamask/base-controller": "^9.1.0",
|
|
61
|
-
"@metamask/keyring-controller": "^27.1.0",
|
|
62
61
|
"@metamask/messenger": "^2.0.0",
|
|
63
62
|
"@metamask/utils": "^11.11.0",
|
|
64
63
|
"@noble/ciphers": "^1.3.0",
|
|
65
64
|
"@noble/curves": "^1.9.2",
|
|
66
|
-
"@noble/hashes": "^1.8.0"
|
|
67
|
-
"async-mutex": "^0.5.0"
|
|
65
|
+
"@noble/hashes": "^1.8.0"
|
|
68
66
|
},
|
|
69
67
|
"devDependencies": {
|
|
70
68
|
"@metamask/auto-changelog": "^6.1.0",
|