tenzro-wallet 0.1.0
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/LICENSE +201 -0
- package/README.md +128 -0
- package/dist/balance/aggregator.d.ts +16 -0
- package/dist/balance/aggregator.d.ts.map +1 -0
- package/dist/balance/aggregator.js +73 -0
- package/dist/balance/aggregator.js.map +1 -0
- package/dist/balance/index.d.ts +3 -0
- package/dist/balance/index.d.ts.map +1 -0
- package/dist/balance/index.js +2 -0
- package/dist/balance/index.js.map +1 -0
- package/dist/consent/index.d.ts +3 -0
- package/dist/consent/index.d.ts.map +1 -0
- package/dist/consent/index.js +2 -0
- package/dist/consent/index.js.map +1 -0
- package/dist/consent/policy.d.ts +27 -0
- package/dist/consent/policy.d.ts.map +1 -0
- package/dist/consent/policy.js +121 -0
- package/dist/consent/policy.js.map +1 -0
- package/dist/crypto/eip1559.d.ts +53 -0
- package/dist/crypto/eip1559.d.ts.map +1 -0
- package/dist/crypto/eip1559.js +79 -0
- package/dist/crypto/eip1559.js.map +1 -0
- package/dist/crypto/keccak256.d.ts +20 -0
- package/dist/crypto/keccak256.d.ts.map +1 -0
- package/dist/crypto/keccak256.js +167 -0
- package/dist/crypto/keccak256.js.map +1 -0
- package/dist/crypto/rlp.d.ts +30 -0
- package/dist/crypto/rlp.d.ts.map +1 -0
- package/dist/crypto/rlp.js +165 -0
- package/dist/crypto/rlp.js.map +1 -0
- package/dist/crypto/sha256.d.ts +14 -0
- package/dist/crypto/sha256.d.ts.map +1 -0
- package/dist/crypto/sha256.js +33 -0
- package/dist/crypto/sha256.js.map +1 -0
- package/dist/crypto/solana.d.ts +86 -0
- package/dist/crypto/solana.d.ts.map +1 -0
- package/dist/crypto/solana.js +218 -0
- package/dist/crypto/solana.js.map +1 -0
- package/dist/custody/frost/backend.d.ts +59 -0
- package/dist/custody/frost/backend.d.ts.map +1 -0
- package/dist/custody/frost/backend.js +83 -0
- package/dist/custody/frost/backend.js.map +1 -0
- package/dist/custody/frost/coordinator.d.ts +148 -0
- package/dist/custody/frost/coordinator.d.ts.map +1 -0
- package/dist/custody/frost/coordinator.js +58 -0
- package/dist/custody/frost/coordinator.js.map +1 -0
- package/dist/custody/frost/ed25519-driver.d.ts +30 -0
- package/dist/custody/frost/ed25519-driver.d.ts.map +1 -0
- package/dist/custody/frost/ed25519-driver.js +76 -0
- package/dist/custody/frost/ed25519-driver.js.map +1 -0
- package/dist/custody/frost/http-adapter.d.ts +77 -0
- package/dist/custody/frost/http-adapter.d.ts.map +1 -0
- package/dist/custody/frost/http-adapter.js +168 -0
- package/dist/custody/frost/http-adapter.js.map +1 -0
- package/dist/custody/frost/hybrid-driver.d.ts +37 -0
- package/dist/custody/frost/hybrid-driver.d.ts.map +1 -0
- package/dist/custody/frost/hybrid-driver.js +60 -0
- package/dist/custody/frost/hybrid-driver.js.map +1 -0
- package/dist/custody/frost/index.d.ts +12 -0
- package/dist/custody/frost/index.d.ts.map +1 -0
- package/dist/custody/frost/index.js +6 -0
- package/dist/custody/frost/index.js.map +1 -0
- package/dist/custody/frost/secp256k1-driver.d.ts +26 -0
- package/dist/custody/frost/secp256k1-driver.d.ts.map +1 -0
- package/dist/custody/frost/secp256k1-driver.js +78 -0
- package/dist/custody/frost/secp256k1-driver.js.map +1 -0
- package/dist/custody/index.d.ts +9 -0
- package/dist/custody/index.d.ts.map +1 -0
- package/dist/custody/index.js +11 -0
- package/dist/custody/index.js.map +1 -0
- package/dist/custody/internal-mpc.d.ts +14 -0
- package/dist/custody/internal-mpc.d.ts.map +1 -0
- package/dist/custody/internal-mpc.js +40 -0
- package/dist/custody/internal-mpc.js.map +1 -0
- package/dist/custody/mldsa/coordinator.d.ts +63 -0
- package/dist/custody/mldsa/coordinator.d.ts.map +1 -0
- package/dist/custody/mldsa/coordinator.js +44 -0
- package/dist/custody/mldsa/coordinator.js.map +1 -0
- package/dist/custody/mldsa/driver.d.ts +23 -0
- package/dist/custody/mldsa/driver.d.ts.map +1 -0
- package/dist/custody/mldsa/driver.js +43 -0
- package/dist/custody/mldsa/driver.js.map +1 -0
- package/dist/custody/mldsa/http-adapter.d.ts +59 -0
- package/dist/custody/mldsa/http-adapter.d.ts.map +1 -0
- package/dist/custody/mldsa/http-adapter.js +103 -0
- package/dist/custody/mldsa/http-adapter.js.map +1 -0
- package/dist/custody/mldsa/index.d.ts +7 -0
- package/dist/custody/mldsa/index.d.ts.map +1 -0
- package/dist/custody/mldsa/index.js +4 -0
- package/dist/custody/mldsa/index.js.map +1 -0
- package/dist/custody/pairing/http-adapter.d.ts +40 -0
- package/dist/custody/pairing/http-adapter.d.ts.map +1 -0
- package/dist/custody/pairing/http-adapter.js +113 -0
- package/dist/custody/pairing/http-adapter.js.map +1 -0
- package/dist/custody/pairing/index.d.ts +10 -0
- package/dist/custody/pairing/index.d.ts.map +1 -0
- package/dist/custody/pairing/index.js +8 -0
- package/dist/custody/pairing/index.js.map +1 -0
- package/dist/custody/pairing/port.d.ts +121 -0
- package/dist/custody/pairing/port.d.ts.map +1 -0
- package/dist/custody/pairing/port.js +40 -0
- package/dist/custody/pairing/port.js.map +1 -0
- package/dist/custody/passkey-share/http-adapter.d.ts +77 -0
- package/dist/custody/passkey-share/http-adapter.d.ts.map +1 -0
- package/dist/custody/passkey-share/http-adapter.js +125 -0
- package/dist/custody/passkey-share/http-adapter.js.map +1 -0
- package/dist/custody/passkey-share/index.d.ts +7 -0
- package/dist/custody/passkey-share/index.d.ts.map +1 -0
- package/dist/custody/passkey-share/index.js +4 -0
- package/dist/custody/passkey-share/index.js.map +1 -0
- package/dist/custody/passkey-share/unwrapper.d.ts +174 -0
- package/dist/custody/passkey-share/unwrapper.d.ts.map +1 -0
- package/dist/custody/passkey-share/unwrapper.js +132 -0
- package/dist/custody/passkey-share/unwrapper.js.map +1 -0
- package/dist/custody/passkey-share/webauthn-adapter.d.ts +112 -0
- package/dist/custody/passkey-share/webauthn-adapter.d.ts.map +1 -0
- package/dist/custody/passkey-share/webauthn-adapter.js +150 -0
- package/dist/custody/passkey-share/webauthn-adapter.js.map +1 -0
- package/dist/custody/surface-key-id.d.ts +15 -0
- package/dist/custody/surface-key-id.d.ts.map +1 -0
- package/dist/custody/surface-key-id.js +25 -0
- package/dist/custody/surface-key-id.js.map +1 -0
- package/dist/dapp/eip6963.d.ts +64 -0
- package/dist/dapp/eip6963.d.ts.map +1 -0
- package/dist/dapp/eip6963.js +55 -0
- package/dist/dapp/eip6963.js.map +1 -0
- package/dist/dapp/index.d.ts +21 -0
- package/dist/dapp/index.d.ts.map +1 -0
- package/dist/dapp/index.js +24 -0
- package/dist/dapp/index.js.map +1 -0
- package/dist/identity/delegate-set.d.ts +57 -0
- package/dist/identity/delegate-set.d.ts.map +1 -0
- package/dist/identity/delegate-set.js +85 -0
- package/dist/identity/delegate-set.js.map +1 -0
- package/dist/identity/did.d.ts +17 -0
- package/dist/identity/did.d.ts.map +1 -0
- package/dist/identity/did.js +60 -0
- package/dist/identity/did.js.map +1 -0
- package/dist/identity/index.d.ts +14 -0
- package/dist/identity/index.d.ts.map +1 -0
- package/dist/identity/index.js +8 -0
- package/dist/identity/index.js.map +1 -0
- package/dist/identity/provision.d.ts +13 -0
- package/dist/identity/provision.d.ts.map +1 -0
- package/dist/identity/provision.js +151 -0
- package/dist/identity/provision.js.map +1 -0
- package/dist/identity/provisioning-http-adapter.d.ts +81 -0
- package/dist/identity/provisioning-http-adapter.d.ts.map +1 -0
- package/dist/identity/provisioning-http-adapter.js +114 -0
- package/dist/identity/provisioning-http-adapter.js.map +1 -0
- package/dist/identity/recovery-http-adapter.d.ts +83 -0
- package/dist/identity/recovery-http-adapter.d.ts.map +1 -0
- package/dist/identity/recovery-http-adapter.js +139 -0
- package/dist/identity/recovery-http-adapter.js.map +1 -0
- package/dist/identity/wallet-new.d.ts +132 -0
- package/dist/identity/wallet-new.d.ts.map +1 -0
- package/dist/identity/wallet-new.js +94 -0
- package/dist/identity/wallet-new.js.map +1 -0
- package/dist/identity/wallet-recover.d.ts +116 -0
- package/dist/identity/wallet-recover.d.ts.map +1 -0
- package/dist/identity/wallet-recover.js +95 -0
- package/dist/identity/wallet-recover.js.map +1 -0
- package/dist/index.d.ts +12 -0
- package/dist/index.d.ts.map +1 -0
- package/dist/index.js +11 -0
- package/dist/index.js.map +1 -0
- package/dist/kernel.d.ts +119 -0
- package/dist/kernel.d.ts.map +1 -0
- package/dist/kernel.js +144 -0
- package/dist/kernel.js.map +1 -0
- package/dist/ports/adapters/tenzro-identity-adapter.d.ts +44 -0
- package/dist/ports/adapters/tenzro-identity-adapter.d.ts.map +1 -0
- package/dist/ports/adapters/tenzro-identity-adapter.js +60 -0
- package/dist/ports/adapters/tenzro-identity-adapter.js.map +1 -0
- package/dist/ports/adapters/tenzro-sdk-adapter.d.ts +86 -0
- package/dist/ports/adapters/tenzro-sdk-adapter.d.ts.map +1 -0
- package/dist/ports/adapters/tenzro-sdk-adapter.js +100 -0
- package/dist/ports/adapters/tenzro-sdk-adapter.js.map +1 -0
- package/dist/ports/agent/acp.d.ts +66 -0
- package/dist/ports/agent/acp.d.ts.map +1 -0
- package/dist/ports/agent/acp.js +27 -0
- package/dist/ports/agent/acp.js.map +1 -0
- package/dist/ports/agent/adapters/acp-adapter.d.ts +67 -0
- package/dist/ports/agent/adapters/acp-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/acp-adapter.js +70 -0
- package/dist/ports/agent/adapters/acp-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/agent-bond-adapter.d.ts +31 -0
- package/dist/ports/agent/adapters/agent-bond-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/agent-bond-adapter.js +82 -0
- package/dist/ports/agent/adapters/agent-bond-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/agent-payment-adapter.d.ts +66 -0
- package/dist/ports/agent/adapters/agent-payment-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/agent-payment-adapter.js +75 -0
- package/dist/ports/agent/adapters/agent-payment-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/ap2-adapter.d.ts +28 -0
- package/dist/ports/agent/adapters/ap2-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/ap2-adapter.js +97 -0
- package/dist/ports/agent/adapters/ap2-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/auth-approval-adapter.d.ts +26 -0
- package/dist/ports/agent/adapters/auth-approval-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/auth-approval-adapter.js +37 -0
- package/dist/ports/agent/adapters/auth-approval-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/erc7802-adapter.d.ts +30 -0
- package/dist/ports/agent/adapters/erc7802-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/erc7802-adapter.js +60 -0
- package/dist/ports/agent/adapters/erc7802-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/erc8004-adapter.d.ts +54 -0
- package/dist/ports/agent/adapters/erc8004-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/erc8004-adapter.js +53 -0
- package/dist/ports/agent/adapters/erc8004-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/escrow-adapter.d.ts +33 -0
- package/dist/ports/agent/adapters/escrow-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/escrow-adapter.js +109 -0
- package/dist/ports/agent/adapters/escrow-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/fee-estimator-adapter.d.ts +31 -0
- package/dist/ports/agent/adapters/fee-estimator-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/fee-estimator-adapter.js +103 -0
- package/dist/ports/agent/adapters/fee-estimator-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/htlc-escrow-adapter.d.ts +68 -0
- package/dist/ports/agent/adapters/htlc-escrow-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/htlc-escrow-adapter.js +131 -0
- package/dist/ports/agent/adapters/htlc-escrow-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/insurance-adapter.d.ts +32 -0
- package/dist/ports/agent/adapters/insurance-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/insurance-adapter.js +103 -0
- package/dist/ports/agent/adapters/insurance-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/lifecycle-adapter.d.ts +26 -0
- package/dist/ports/agent/adapters/lifecycle-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/lifecycle-adapter.js +136 -0
- package/dist/ports/agent/adapters/lifecycle-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/nanopayment-adapter.d.ts +62 -0
- package/dist/ports/agent/adapters/nanopayment-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/nanopayment-adapter.js +76 -0
- package/dist/ports/agent/adapters/nanopayment-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/payment-rails-adapter.d.ts +67 -0
- package/dist/ports/agent/adapters/payment-rails-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/payment-rails-adapter.js +108 -0
- package/dist/ports/agent/adapters/payment-rails-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/principal-chain-adapter.d.ts +23 -0
- package/dist/ports/agent/adapters/principal-chain-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/principal-chain-adapter.js +156 -0
- package/dist/ports/agent/adapters/principal-chain-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/session-key-adapter.d.ts +45 -0
- package/dist/ports/agent/adapters/session-key-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/session-key-adapter.js +80 -0
- package/dist/ports/agent/adapters/session-key-adapter.js.map +1 -0
- package/dist/ports/agent/adapters/tee-attestation-adapter.d.ts +32 -0
- package/dist/ports/agent/adapters/tee-attestation-adapter.d.ts.map +1 -0
- package/dist/ports/agent/adapters/tee-attestation-adapter.js +38 -0
- package/dist/ports/agent/adapters/tee-attestation-adapter.js.map +1 -0
- package/dist/ports/agent/agent-bond.d.ts +80 -0
- package/dist/ports/agent/agent-bond.d.ts.map +1 -0
- package/dist/ports/agent/agent-bond.js +23 -0
- package/dist/ports/agent/agent-bond.js.map +1 -0
- package/dist/ports/agent/agent-payment.d.ts +72 -0
- package/dist/ports/agent/agent-payment.d.ts.map +1 -0
- package/dist/ports/agent/agent-payment.js +17 -0
- package/dist/ports/agent/agent-payment.js.map +1 -0
- package/dist/ports/agent/ap2.d.ts +104 -0
- package/dist/ports/agent/ap2.d.ts.map +1 -0
- package/dist/ports/agent/ap2.js +22 -0
- package/dist/ports/agent/ap2.js.map +1 -0
- package/dist/ports/agent/auth-approval.d.ts +40 -0
- package/dist/ports/agent/auth-approval.d.ts.map +1 -0
- package/dist/ports/agent/auth-approval.js +23 -0
- package/dist/ports/agent/auth-approval.js.map +1 -0
- package/dist/ports/agent/erc7802.d.ts +94 -0
- package/dist/ports/agent/erc7802.d.ts.map +1 -0
- package/dist/ports/agent/erc7802.js +30 -0
- package/dist/ports/agent/erc7802.js.map +1 -0
- package/dist/ports/agent/erc8004.d.ts +57 -0
- package/dist/ports/agent/erc8004.d.ts.map +1 -0
- package/dist/ports/agent/erc8004.js +20 -0
- package/dist/ports/agent/erc8004.js.map +1 -0
- package/dist/ports/agent/escrow.d.ts +74 -0
- package/dist/ports/agent/escrow.d.ts.map +1 -0
- package/dist/ports/agent/escrow.js +18 -0
- package/dist/ports/agent/escrow.js.map +1 -0
- package/dist/ports/agent/fee-estimator.d.ts +71 -0
- package/dist/ports/agent/fee-estimator.d.ts.map +1 -0
- package/dist/ports/agent/fee-estimator.js +21 -0
- package/dist/ports/agent/fee-estimator.js.map +1 -0
- package/dist/ports/agent/htlc-escrow.d.ts +94 -0
- package/dist/ports/agent/htlc-escrow.d.ts.map +1 -0
- package/dist/ports/agent/htlc-escrow.js +25 -0
- package/dist/ports/agent/htlc-escrow.js.map +1 -0
- package/dist/ports/agent/index.d.ts +58 -0
- package/dist/ports/agent/index.d.ts.map +1 -0
- package/dist/ports/agent/index.js +24 -0
- package/dist/ports/agent/index.js.map +1 -0
- package/dist/ports/agent/insurance.d.ts +65 -0
- package/dist/ports/agent/insurance.d.ts.map +1 -0
- package/dist/ports/agent/insurance.js +18 -0
- package/dist/ports/agent/insurance.js.map +1 -0
- package/dist/ports/agent/lifecycle.d.ts +69 -0
- package/dist/ports/agent/lifecycle.d.ts.map +1 -0
- package/dist/ports/agent/lifecycle.js +17 -0
- package/dist/ports/agent/lifecycle.js.map +1 -0
- package/dist/ports/agent/nanopayment.d.ts +72 -0
- package/dist/ports/agent/nanopayment.d.ts.map +1 -0
- package/dist/ports/agent/nanopayment.js +16 -0
- package/dist/ports/agent/nanopayment.js.map +1 -0
- package/dist/ports/agent/payment-rails.d.ts +140 -0
- package/dist/ports/agent/payment-rails.d.ts.map +1 -0
- package/dist/ports/agent/payment-rails.js +25 -0
- package/dist/ports/agent/payment-rails.js.map +1 -0
- package/dist/ports/agent/principal-chain.d.ts +95 -0
- package/dist/ports/agent/principal-chain.d.ts.map +1 -0
- package/dist/ports/agent/principal-chain.js +16 -0
- package/dist/ports/agent/principal-chain.js.map +1 -0
- package/dist/ports/agent/session-key.d.ts +94 -0
- package/dist/ports/agent/session-key.d.ts.map +1 -0
- package/dist/ports/agent/session-key.js +31 -0
- package/dist/ports/agent/session-key.js.map +1 -0
- package/dist/ports/agent/tee-attestation.d.ts +51 -0
- package/dist/ports/agent/tee-attestation.d.ts.map +1 -0
- package/dist/ports/agent/tee-attestation.js +28 -0
- package/dist/ports/agent/tee-attestation.js.map +1 -0
- package/dist/ports/bridge/adapters/bridge-adapter-base.d.ts +47 -0
- package/dist/ports/bridge/adapters/bridge-adapter-base.d.ts.map +1 -0
- package/dist/ports/bridge/adapters/bridge-adapter-base.js +144 -0
- package/dist/ports/bridge/adapters/bridge-adapter-base.js.map +1 -0
- package/dist/ports/bridge/adapters/canton-bridge-adapter.d.ts +30 -0
- package/dist/ports/bridge/adapters/canton-bridge-adapter.d.ts.map +1 -0
- package/dist/ports/bridge/adapters/canton-bridge-adapter.js +31 -0
- package/dist/ports/bridge/adapters/canton-bridge-adapter.js.map +1 -0
- package/dist/ports/bridge/adapters/ccip-adapter.d.ts +30 -0
- package/dist/ports/bridge/adapters/ccip-adapter.d.ts.map +1 -0
- package/dist/ports/bridge/adapters/ccip-adapter.js +31 -0
- package/dist/ports/bridge/adapters/ccip-adapter.js.map +1 -0
- package/dist/ports/bridge/adapters/debridge-adapter.d.ts +27 -0
- package/dist/ports/bridge/adapters/debridge-adapter.d.ts.map +1 -0
- package/dist/ports/bridge/adapters/debridge-adapter.js +28 -0
- package/dist/ports/bridge/adapters/debridge-adapter.js.map +1 -0
- package/dist/ports/bridge/adapters/layerzero-adapter.d.ts +30 -0
- package/dist/ports/bridge/adapters/layerzero-adapter.d.ts.map +1 -0
- package/dist/ports/bridge/adapters/layerzero-adapter.js +31 -0
- package/dist/ports/bridge/adapters/layerzero-adapter.js.map +1 -0
- package/dist/ports/bridge/adapters/lifi-adapter.d.ts +48 -0
- package/dist/ports/bridge/adapters/lifi-adapter.d.ts.map +1 -0
- package/dist/ports/bridge/adapters/lifi-adapter.js +49 -0
- package/dist/ports/bridge/adapters/lifi-adapter.js.map +1 -0
- package/dist/ports/bridge/adapters/wormhole-adapter.d.ts +26 -0
- package/dist/ports/bridge/adapters/wormhole-adapter.d.ts.map +1 -0
- package/dist/ports/bridge/adapters/wormhole-adapter.js +27 -0
- package/dist/ports/bridge/adapters/wormhole-adapter.js.map +1 -0
- package/dist/ports/bridge/bridge.d.ts +123 -0
- package/dist/ports/bridge/bridge.d.ts.map +1 -0
- package/dist/ports/bridge/bridge.js +20 -0
- package/dist/ports/bridge/bridge.js.map +1 -0
- package/dist/ports/bridge/index.d.ts +13 -0
- package/dist/ports/bridge/index.d.ts.map +1 -0
- package/dist/ports/bridge/index.js +11 -0
- package/dist/ports/bridge/index.js.map +1 -0
- package/dist/ports/canton/adapters/ledger-api-adapter.d.ts +52 -0
- package/dist/ports/canton/adapters/ledger-api-adapter.d.ts.map +1 -0
- package/dist/ports/canton/adapters/ledger-api-adapter.js +232 -0
- package/dist/ports/canton/adapters/ledger-api-adapter.js.map +1 -0
- package/dist/ports/canton/canton-identity.d.ts +60 -0
- package/dist/ports/canton/canton-identity.d.ts.map +1 -0
- package/dist/ports/canton/canton-identity.js +28 -0
- package/dist/ports/canton/canton-identity.js.map +1 -0
- package/dist/ports/canton/canton-validator.d.ts +182 -0
- package/dist/ports/canton/canton-validator.d.ts.map +1 -0
- package/dist/ports/canton/canton-validator.js +39 -0
- package/dist/ports/canton/canton-validator.js.map +1 -0
- package/dist/ports/canton/fingerprint.d.ts +24 -0
- package/dist/ports/canton/fingerprint.d.ts.map +1 -0
- package/dist/ports/canton/fingerprint.js +31 -0
- package/dist/ports/canton/fingerprint.js.map +1 -0
- package/dist/ports/canton/hash.d.ts +37 -0
- package/dist/ports/canton/hash.d.ts.map +1 -0
- package/dist/ports/canton/hash.js +68 -0
- package/dist/ports/canton/hash.js.map +1 -0
- package/dist/ports/canton/http.d.ts +64 -0
- package/dist/ports/canton/http.d.ts.map +1 -0
- package/dist/ports/canton/http.js +177 -0
- package/dist/ports/canton/http.js.map +1 -0
- package/dist/ports/cross-vm.d.ts +79 -0
- package/dist/ports/cross-vm.d.ts.map +1 -0
- package/dist/ports/cross-vm.js +81 -0
- package/dist/ports/cross-vm.js.map +1 -0
- package/dist/ports/index.d.ts +18 -0
- package/dist/ports/index.d.ts.map +1 -0
- package/dist/ports/index.js +11 -0
- package/dist/ports/index.js.map +1 -0
- package/dist/ports/tenzro-identity.d.ts +29 -0
- package/dist/ports/tenzro-identity.d.ts.map +1 -0
- package/dist/ports/tenzro-identity.js +19 -0
- package/dist/ports/tenzro-identity.js.map +1 -0
- package/dist/ports/tenzro-rpc.d.ts +79 -0
- package/dist/ports/tenzro-rpc.d.ts.map +1 -0
- package/dist/ports/tenzro-rpc.js +21 -0
- package/dist/ports/tenzro-rpc.js.map +1 -0
- package/dist/router/index.d.ts +3 -0
- package/dist/router/index.d.ts.map +1 -0
- package/dist/router/index.js +2 -0
- package/dist/router/index.js.map +1 -0
- package/dist/router/route.d.ts +17 -0
- package/dist/router/route.d.ts.map +1 -0
- package/dist/router/route.js +78 -0
- package/dist/router/route.js.map +1 -0
- package/dist/settlement/nanopayment-flow.d.ts +48 -0
- package/dist/settlement/nanopayment-flow.d.ts.map +1 -0
- package/dist/settlement/nanopayment-flow.js +111 -0
- package/dist/settlement/nanopayment-flow.js.map +1 -0
- package/dist/surfaces/canton-external.d.ts +43 -0
- package/dist/surfaces/canton-external.d.ts.map +1 -0
- package/dist/surfaces/canton-external.js +252 -0
- package/dist/surfaces/canton-external.js.map +1 -0
- package/dist/surfaces/canton-internal.d.ts +34 -0
- package/dist/surfaces/canton-internal.d.ts.map +1 -0
- package/dist/surfaces/canton-internal.js +163 -0
- package/dist/surfaces/canton-internal.js.map +1 -0
- package/dist/surfaces/canton-onboarding.d.ts +64 -0
- package/dist/surfaces/canton-onboarding.d.ts.map +1 -0
- package/dist/surfaces/canton-onboarding.js +113 -0
- package/dist/surfaces/canton-onboarding.js.map +1 -0
- package/dist/surfaces/evm-on-tenzro.d.ts +29 -0
- package/dist/surfaces/evm-on-tenzro.d.ts.map +1 -0
- package/dist/surfaces/evm-on-tenzro.js +226 -0
- package/dist/surfaces/evm-on-tenzro.js.map +1 -0
- package/dist/surfaces/index.d.ts +13 -0
- package/dist/surfaces/index.d.ts.map +1 -0
- package/dist/surfaces/index.js +7 -0
- package/dist/surfaces/index.js.map +1 -0
- package/dist/surfaces/svm-on-tenzro.d.ts +24 -0
- package/dist/surfaces/svm-on-tenzro.d.ts.map +1 -0
- package/dist/surfaces/svm-on-tenzro.js +238 -0
- package/dist/surfaces/svm-on-tenzro.js.map +1 -0
- package/dist/surfaces/tenzro-native.d.ts +45 -0
- package/dist/surfaces/tenzro-native.d.ts.map +1 -0
- package/dist/surfaces/tenzro-native.js +299 -0
- package/dist/surfaces/tenzro-native.js.map +1 -0
- package/dist/surfaces/util.d.ts +18 -0
- package/dist/surfaces/util.d.ts.map +1 -0
- package/dist/surfaces/util.js +36 -0
- package/dist/surfaces/util.js.map +1 -0
- package/dist/types/asset.d.ts +43 -0
- package/dist/types/asset.d.ts.map +1 -0
- package/dist/types/asset.js +13 -0
- package/dist/types/asset.js.map +1 -0
- package/dist/types/consent.d.ts +46 -0
- package/dist/types/consent.d.ts.map +1 -0
- package/dist/types/consent.js +18 -0
- package/dist/types/consent.js.map +1 -0
- package/dist/types/identity.d.ts +115 -0
- package/dist/types/identity.d.ts.map +1 -0
- package/dist/types/identity.js +12 -0
- package/dist/types/identity.js.map +1 -0
- package/dist/types/index.d.ts +10 -0
- package/dist/types/index.d.ts.map +1 -0
- package/dist/types/index.js +3 -0
- package/dist/types/index.js.map +1 -0
- package/dist/types/intent.d.ts +132 -0
- package/dist/types/intent.d.ts.map +1 -0
- package/dist/types/intent.js +8 -0
- package/dist/types/intent.js.map +1 -0
- package/dist/types/signing-driver.d.ts +48 -0
- package/dist/types/signing-driver.d.ts.map +1 -0
- package/dist/types/signing-driver.js +9 -0
- package/dist/types/signing-driver.js.map +1 -0
- package/dist/types/surface-module.d.ts +38 -0
- package/dist/types/surface-module.d.ts.map +1 -0
- package/dist/types/surface-module.js +19 -0
- package/dist/types/surface-module.js.map +1 -0
- package/dist/types/surface.d.ts +17 -0
- package/dist/types/surface.d.ts.map +1 -0
- package/dist/types/surface.js +28 -0
- package/dist/types/surface.js.map +1 -0
- package/package.json +84 -0
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Surface-internal helpers. Not exported from the package root.
|
|
3
|
+
*/
|
|
4
|
+
let counter = 0;
|
|
5
|
+
export function makeHandle(surface, _intent, hash) {
|
|
6
|
+
counter += 1;
|
|
7
|
+
return {
|
|
8
|
+
id: `${surface}-${Date.now().toString(36)}-${counter.toString(36)}`,
|
|
9
|
+
surface,
|
|
10
|
+
submittedAt: Date.now(),
|
|
11
|
+
...(hash !== undefined ? { hash } : {}),
|
|
12
|
+
};
|
|
13
|
+
}
|
|
14
|
+
/**
|
|
15
|
+
* M1 placeholder confirmation walk: created → pending → confirmed → finalized.
|
|
16
|
+
*
|
|
17
|
+
* Used by every surface that doesn't yet have a real port wired. As of M2,
|
|
18
|
+
* `tenzro-native` replaces this with `watchViaPort` against a real RPC; the
|
|
19
|
+
* remaining consumers (evm-on-tenzro, svm-on-tenzro, canton-internal,
|
|
20
|
+
* canton-external) keep using this until their respective milestones land.
|
|
21
|
+
*
|
|
22
|
+
* Delete this when no surface imports it any more.
|
|
23
|
+
*/
|
|
24
|
+
export async function* mockStatusWalk(handle) {
|
|
25
|
+
yield { handle, phase: 'created' };
|
|
26
|
+
await sleep(10);
|
|
27
|
+
yield { handle, phase: 'pending' };
|
|
28
|
+
await sleep(10);
|
|
29
|
+
yield { handle, phase: 'confirmed', blockHeight: 1, hash: `0x${handle.id}` };
|
|
30
|
+
await sleep(10);
|
|
31
|
+
yield { handle, phase: 'finalized', blockHeight: 1, hash: `0x${handle.id}` };
|
|
32
|
+
}
|
|
33
|
+
function sleep(ms) {
|
|
34
|
+
return new Promise((r) => setTimeout(r, ms));
|
|
35
|
+
}
|
|
36
|
+
//# sourceMappingURL=util.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"util.js","sourceRoot":"","sources":["../../src/surfaces/util.ts"],"names":[],"mappings":"AAAA;;GAEG;AAKH,IAAI,OAAO,GAAG,CAAC,CAAC;AAEhB,MAAM,UAAU,UAAU,CAAC,OAAoB,EAAE,OAAe,EAAE,IAAa;IAC7E,OAAO,IAAI,CAAC,CAAC;IACb,OAAO;QACL,EAAE,EAAE,GAAG,OAAO,IAAI,IAAI,CAAC,GAAG,EAAE,CAAC,QAAQ,CAAC,EAAE,CAAC,IAAI,OAAO,CAAC,QAAQ,CAAC,EAAE,CAAC,EAAE;QACnE,OAAO;QACP,WAAW,EAAE,IAAI,CAAC,GAAG,EAAE;QACvB,GAAG,CAAC,IAAI,KAAK,SAAS,CAAC,CAAC,CAAC,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC;KACxC,CAAC;AACJ,CAAC;AAED;;;;;;;;;GASG;AACH,MAAM,CAAC,KAAK,SAAS,CAAC,CAAC,cAAc,CAAC,MAAgB;IACpD,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC;IACnC,MAAM,KAAK,CAAC,EAAE,CAAC,CAAC;IAChB,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC;IACnC,MAAM,KAAK,CAAC,EAAE,CAAC,CAAC;IAChB,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,WAAW,EAAE,WAAW,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,MAAM,CAAC,EAAE,EAAE,EAAE,CAAC;IAC7E,MAAM,KAAK,CAAC,EAAE,CAAC,CAAC;IAChB,MAAM,EAAE,MAAM,EAAE,KAAK,EAAE,WAAW,EAAE,WAAW,EAAE,CAAC,EAAE,IAAI,EAAE,KAAK,MAAM,CAAC,EAAE,EAAE,EAAE,CAAC;AAC/E,CAAC;AAED,SAAS,KAAK,CAAC,EAAU;IACvB,OAAO,IAAI,OAAO,CAAC,CAAC,CAAC,EAAE,EAAE,CAAC,UAAU,CAAC,CAAC,EAAE,EAAE,CAAC,CAAC,CAAC;AAC/C,CAAC"}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Asset model. Balances are always stored in canonical native units (bigint);
|
|
3
|
+
* decimal conversion happens at the UI edge.
|
|
4
|
+
*
|
|
5
|
+
* `scope` distinguishes:
|
|
6
|
+
* - "tenzro-native" — the canonical TNZO balance (one ledger, three views)
|
|
7
|
+
* - "tenzro-asset" — any other asset registered on Tenzro (USDC on Tempo, etc.)
|
|
8
|
+
* - "external-evm" — assets on an external EVM chain (Ethereum, Base, ...)
|
|
9
|
+
* - "external-svm" — assets on Solana mainnet
|
|
10
|
+
* - "canton-mainnet" — CIP-56 holdings on Canton Network MainNet
|
|
11
|
+
*/
|
|
12
|
+
import type { SurfaceName } from './surface.js';
|
|
13
|
+
export type AssetScope = 'tenzro-native' | 'tenzro-asset' | 'external-evm' | 'external-svm' | 'canton-mainnet';
|
|
14
|
+
/**
|
|
15
|
+
* Canonical asset identifier. For multi-surface assets (TNZO), the same AssetId
|
|
16
|
+
* appears under multiple SurfaceName entries in the unified balance.
|
|
17
|
+
*/
|
|
18
|
+
export interface AssetId {
|
|
19
|
+
readonly scope: AssetScope;
|
|
20
|
+
/** Symbol as displayed: TNZO, USDC, CC, etc. */
|
|
21
|
+
readonly symbol: string;
|
|
22
|
+
/** Chain-specific identifier (contract addr, mint addr, package+template, etc.). */
|
|
23
|
+
readonly nativeId?: string;
|
|
24
|
+
/** Decimal count for canonical-unit storage. */
|
|
25
|
+
readonly decimals: number;
|
|
26
|
+
}
|
|
27
|
+
export interface AssetView {
|
|
28
|
+
readonly asset: AssetId;
|
|
29
|
+
readonly surface: SurfaceName;
|
|
30
|
+
readonly balance: bigint;
|
|
31
|
+
}
|
|
32
|
+
/**
|
|
33
|
+
* The unified balance card the UI renders. One entry per asset, with all
|
|
34
|
+
* surface-views collapsed and any precision warnings attached.
|
|
35
|
+
*/
|
|
36
|
+
export interface UnifiedBalance {
|
|
37
|
+
readonly asset: AssetId;
|
|
38
|
+
/** Sum across all surfaces, in canonical units of `asset.decimals`. */
|
|
39
|
+
readonly total: bigint;
|
|
40
|
+
readonly views: readonly AssetView[];
|
|
41
|
+
readonly warnings: readonly string[];
|
|
42
|
+
}
|
|
43
|
+
//# sourceMappingURL=asset.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"asset.d.ts","sourceRoot":"","sources":["../../src/types/asset.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAEhD,MAAM,MAAM,UAAU,GAClB,eAAe,GACf,cAAc,GACd,cAAc,GACd,cAAc,GACd,gBAAgB,CAAC;AAErB;;;GAGG;AACH,MAAM,WAAW,OAAO;IACtB,QAAQ,CAAC,KAAK,EAAE,UAAU,CAAC;IAC3B,gDAAgD;IAChD,QAAQ,CAAC,MAAM,EAAE,MAAM,CAAC;IACxB,oFAAoF;IACpF,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAC3B,gDAAgD;IAChD,QAAQ,CAAC,QAAQ,EAAE,MAAM,CAAC;CAC3B;AAED,MAAM,WAAW,SAAS;IACxB,QAAQ,CAAC,KAAK,EAAE,OAAO,CAAC;IACxB,QAAQ,CAAC,OAAO,EAAE,WAAW,CAAC;IAC9B,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B;AAED;;;GAGG;AACH,MAAM,WAAW,cAAc;IAC7B,QAAQ,CAAC,KAAK,EAAE,OAAO,CAAC;IACxB,uEAAuE;IACvE,QAAQ,CAAC,KAAK,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,KAAK,EAAE,SAAS,SAAS,EAAE,CAAC;IACrC,QAAQ,CAAC,QAAQ,EAAE,SAAS,MAAM,EAAE,CAAC;CACtC"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Asset model. Balances are always stored in canonical native units (bigint);
|
|
3
|
+
* decimal conversion happens at the UI edge.
|
|
4
|
+
*
|
|
5
|
+
* `scope` distinguishes:
|
|
6
|
+
* - "tenzro-native" — the canonical TNZO balance (one ledger, three views)
|
|
7
|
+
* - "tenzro-asset" — any other asset registered on Tenzro (USDC on Tempo, etc.)
|
|
8
|
+
* - "external-evm" — assets on an external EVM chain (Ethereum, Base, ...)
|
|
9
|
+
* - "external-svm" — assets on Solana mainnet
|
|
10
|
+
* - "canton-mainnet" — CIP-56 holdings on Canton Network MainNet
|
|
11
|
+
*/
|
|
12
|
+
export {};
|
|
13
|
+
//# sourceMappingURL=asset.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"asset.js","sourceRoot":"","sources":["../../src/types/asset.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG"}
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Consent and policy types. The kernel always enforces
|
|
3
|
+
* `effectiveLimit = sessionPolicy ∩ delegationScope` at sign time.
|
|
4
|
+
*/
|
|
5
|
+
import type { AssetId } from './asset.js';
|
|
6
|
+
/**
|
|
7
|
+
* KYC verification tier. Mirrors `tenzro_identity::KycTier` exactly:
|
|
8
|
+
* Unverified (0), Basic (1), Enhanced (2), Full (3). When set on a
|
|
9
|
+
* policy, the signing identity must hold a credential at this tier or
|
|
10
|
+
* higher for the policy to satisfy.
|
|
11
|
+
*/
|
|
12
|
+
export type KycTier = 'Unverified' | 'Basic' | 'Enhanced' | 'Full';
|
|
13
|
+
export interface SpendingPolicy {
|
|
14
|
+
readonly maxPerTx?: bigint;
|
|
15
|
+
readonly maxPerDay?: bigint;
|
|
16
|
+
readonly assetWhitelist?: readonly AssetId[];
|
|
17
|
+
/** Allowed contract addresses, for EVM/SVM. */
|
|
18
|
+
readonly contractWhitelist?: readonly string[];
|
|
19
|
+
/** Operations the session may invoke. */
|
|
20
|
+
readonly operationWhitelist?: readonly string[];
|
|
21
|
+
readonly expiresAt?: number;
|
|
22
|
+
/**
|
|
23
|
+
* Minimum KYC tier the *signing identity* must hold for this policy to
|
|
24
|
+
* be satisfied. The kernel reads the identity's tier from the
|
|
25
|
+
* `tenzro-identity` port and compares numerically: signer tier ≥
|
|
26
|
+
* required tier. Undefined = no KYC requirement.
|
|
27
|
+
*/
|
|
28
|
+
readonly minKycTier?: KycTier;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Compares two KYC tiers numerically. Returns positive when `a > b`,
|
|
32
|
+
* negative when `a < b`, zero when equal.
|
|
33
|
+
*/
|
|
34
|
+
export declare function compareKycTier(a: KycTier, b: KycTier): number;
|
|
35
|
+
/**
|
|
36
|
+
* A user-confirmed consent envelope passed to `surface.sign(prepared, consent)`.
|
|
37
|
+
* The kernel's `sign()` facade attaches this; surface modules don't construct it.
|
|
38
|
+
*/
|
|
39
|
+
export interface Consent {
|
|
40
|
+
/** Set when the user is signing under an active session key. */
|
|
41
|
+
readonly sessionId?: string;
|
|
42
|
+
readonly approvedAt: number;
|
|
43
|
+
/** Optional human-typed confirmation phrase for high-value sends. */
|
|
44
|
+
readonly confirmationPhrase?: string;
|
|
45
|
+
}
|
|
46
|
+
//# sourceMappingURL=consent.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"consent.d.ts","sourceRoot":"","sources":["../../src/types/consent.ts"],"names":[],"mappings":"AAAA;;;GAGG;AAEH,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,YAAY,CAAC;AAE1C;;;;;GAKG;AACH,MAAM,MAAM,OAAO,GAAG,YAAY,GAAG,OAAO,GAAG,UAAU,GAAG,MAAM,CAAC;AAEnE,MAAM,WAAW,cAAc;IAC7B,QAAQ,CAAC,QAAQ,CAAC,EAAE,MAAM,CAAC;IAC3B,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,cAAc,CAAC,EAAE,SAAS,OAAO,EAAE,CAAC;IAC7C,+CAA+C;IAC/C,QAAQ,CAAC,iBAAiB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAC/C,yCAAyC;IACzC,QAAQ,CAAC,kBAAkB,CAAC,EAAE,SAAS,MAAM,EAAE,CAAC;IAChD,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;IAC5B;;;;;OAKG;IACH,QAAQ,CAAC,UAAU,CAAC,EAAE,OAAO,CAAC;CAC/B;AASD;;;GAGG;AACH,wBAAgB,cAAc,CAAC,CAAC,EAAE,OAAO,EAAE,CAAC,EAAE,OAAO,GAAG,MAAM,CAE7D;AAED;;;GAGG;AACH,MAAM,WAAW,OAAO;IACtB,gEAAgE;IAChE,QAAQ,CAAC,SAAS,CAAC,EAAE,MAAM,CAAC;IAC5B,QAAQ,CAAC,UAAU,EAAE,MAAM,CAAC;IAC5B,qEAAqE;IACrE,QAAQ,CAAC,kBAAkB,CAAC,EAAE,MAAM,CAAC;CACtC"}
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Consent and policy types. The kernel always enforces
|
|
3
|
+
* `effectiveLimit = sessionPolicy ∩ delegationScope` at sign time.
|
|
4
|
+
*/
|
|
5
|
+
const KYC_TIER_ORDER = {
|
|
6
|
+
Unverified: 0,
|
|
7
|
+
Basic: 1,
|
|
8
|
+
Enhanced: 2,
|
|
9
|
+
Full: 3,
|
|
10
|
+
};
|
|
11
|
+
/**
|
|
12
|
+
* Compares two KYC tiers numerically. Returns positive when `a > b`,
|
|
13
|
+
* negative when `a < b`, zero when equal.
|
|
14
|
+
*/
|
|
15
|
+
export function compareKycTier(a, b) {
|
|
16
|
+
return KYC_TIER_ORDER[a] - KYC_TIER_ORDER[b];
|
|
17
|
+
}
|
|
18
|
+
//# sourceMappingURL=consent.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"consent.js","sourceRoot":"","sources":["../../src/types/consent.ts"],"names":[],"mappings":"AAAA;;;GAGG;AA8BH,MAAM,cAAc,GAA4B;IAC9C,UAAU,EAAE,CAAC;IACb,KAAK,EAAE,CAAC;IACR,QAAQ,EAAE,CAAC;IACX,IAAI,EAAE,CAAC;CACR,CAAC;AAEF;;;GAGG;AACH,MAAM,UAAU,cAAc,CAAC,CAAU,EAAE,CAAU;IACnD,OAAO,cAAc,CAAC,CAAC,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,CAAC;AAC/C,CAAC"}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* TDIP identity types — the root of all wallet identity.
|
|
3
|
+
*
|
|
4
|
+
* A user has exactly one root DID. Each surface (native, evm, svm, canton-internal,
|
|
5
|
+
* canton-external) projects a derived key from the same MPC quorum.
|
|
6
|
+
*
|
|
7
|
+
* Spec refs:
|
|
8
|
+
* - https://tenzro.com/docs/identity (TDIP)
|
|
9
|
+
* - W3C DID 1.0 (DID Document compatibility)
|
|
10
|
+
*/
|
|
11
|
+
export type DidMethod = 'tenzro';
|
|
12
|
+
export type TdipKind = 'human' | 'controlled-machine' | 'autonomous-machine';
|
|
13
|
+
/**
|
|
14
|
+
* A `did:tenzro:human:{uuid}` or `did:tenzro:machine:{controller?}:{uuid}`.
|
|
15
|
+
* Stored as a normalized string; parsed via `parseTdipDid`.
|
|
16
|
+
*/
|
|
17
|
+
export type TdipDid = string & {
|
|
18
|
+
readonly __brand: 'TdipDid';
|
|
19
|
+
};
|
|
20
|
+
export interface TdipDidParts {
|
|
21
|
+
readonly method: DidMethod;
|
|
22
|
+
readonly kind: TdipKind;
|
|
23
|
+
/** Controller DID, only present when kind === 'controlled-machine'. */
|
|
24
|
+
readonly controller?: TdipDid;
|
|
25
|
+
readonly uuid: string;
|
|
26
|
+
/**
|
|
27
|
+
* Set when the identity was registered as a SeedAgent — protocol-owned
|
|
28
|
+
* bootstrap counterparty funded from the genesis treasury earmark. Drives
|
|
29
|
+
* counterparty filters (`deny_other_seed_agents`) and lets activity
|
|
30
|
+
* metrics exclude protocol-bootstrap traffic.
|
|
31
|
+
*
|
|
32
|
+
* Source of truth is `IdentityData::Machine.is_seed_agent` on the ledger;
|
|
33
|
+
* surfaced here for client-side gating without an extra RPC.
|
|
34
|
+
*/
|
|
35
|
+
readonly isSeedAgent?: boolean;
|
|
36
|
+
}
|
|
37
|
+
/**
|
|
38
|
+
* Canton signing schemes accepted on `PartyToKeyMapping`. Mirrors the
|
|
39
|
+
* `CantonSigningScheme` in `ports/canton/canton-validator.ts`; redeclared
|
|
40
|
+
* here to avoid a port→type reverse import. See DESIGN.md §4.5.5.
|
|
41
|
+
*/
|
|
42
|
+
export type CantonKeyScheme = 'ed25519' | 'ec-dsa-p256';
|
|
43
|
+
/**
|
|
44
|
+
* Canton party shape on a `SurfaceKey`. Both canton-internal and
|
|
45
|
+
* canton-external use this — they differ only in `synchronizerId` and
|
|
46
|
+
* which validator hosts the party. See DESIGN.md §4.5.4.
|
|
47
|
+
*
|
|
48
|
+
* Two-key model:
|
|
49
|
+
* - `namespaceKey` roots the identity (cold/recovery key, fingerprint =
|
|
50
|
+
* the `::xxxx` part of the party id, used for topology changes).
|
|
51
|
+
* - `signingKeys` are the warm/online keys (per-tx). The party id is
|
|
52
|
+
* immutable; signing keys can be rotated via topology updates.
|
|
53
|
+
* - `threshold` is the M-of-N over `signingKeys`. M-of-N requires
|
|
54
|
+
* `threshold <= signingKeys.length`.
|
|
55
|
+
*/
|
|
56
|
+
export interface CantonPartyKey {
|
|
57
|
+
/** `<hint>::<32-byte-fingerprint-hex>` */
|
|
58
|
+
readonly partyId: string;
|
|
59
|
+
/** Synchronizer the party is hosted on. `global-domain::<fp>` for MainNet
|
|
60
|
+
* external, Tenzro-operated synchronizer id for internal. */
|
|
61
|
+
readonly synchronizerId: string;
|
|
62
|
+
/** Participant id hosting the party. */
|
|
63
|
+
readonly hostingParticipantId: string;
|
|
64
|
+
readonly namespaceKey: {
|
|
65
|
+
readonly scheme: 'ed25519';
|
|
66
|
+
readonly publicKey: Uint8Array;
|
|
67
|
+
/** Canton fingerprint string: `1220` + lowercase-hex SHA-256 of `publicKey`.
|
|
68
|
+
* Matches the `::xxxx` portion of the party id when this is the namespace
|
|
69
|
+
* key. Computed at provision time so the signing path stays sync. */
|
|
70
|
+
readonly fingerprint: string;
|
|
71
|
+
};
|
|
72
|
+
readonly signingKeys: ReadonlyArray<{
|
|
73
|
+
readonly scheme: CantonKeyScheme;
|
|
74
|
+
readonly publicKey: Uint8Array;
|
|
75
|
+
/** Canton fingerprint string: `1220` + lowercase-hex SHA-256 of `publicKey`.
|
|
76
|
+
* Used as `signedBy` on the wire so the validator can look the key up
|
|
77
|
+
* in `PartyToKeyMapping` without us carrying the pubkey. */
|
|
78
|
+
readonly fingerprint: string;
|
|
79
|
+
}>;
|
|
80
|
+
/** M of `signingKeys.length`. */
|
|
81
|
+
readonly threshold: number;
|
|
82
|
+
}
|
|
83
|
+
/**
|
|
84
|
+
* The set of cryptographic personas the wallet derives from one TDIP root.
|
|
85
|
+
* Each entry's `kind` matches the surface that consumes it.
|
|
86
|
+
*/
|
|
87
|
+
export type SurfaceKey = {
|
|
88
|
+
readonly surface: 'tenzro-native';
|
|
89
|
+
readonly scheme: 'ed25519';
|
|
90
|
+
readonly publicKey: Uint8Array;
|
|
91
|
+
/** Base58-encoded Tenzro address (per `Address` in tenzro-sdk types). */
|
|
92
|
+
readonly address: string;
|
|
93
|
+
} | {
|
|
94
|
+
readonly surface: 'evm-on-tenzro';
|
|
95
|
+
readonly scheme: 'secp256k1';
|
|
96
|
+
readonly address: `0x${string}`;
|
|
97
|
+
} | {
|
|
98
|
+
readonly surface: 'svm-on-tenzro';
|
|
99
|
+
readonly scheme: 'ed25519';
|
|
100
|
+
readonly publicKey: Uint8Array;
|
|
101
|
+
/** Base58-encoded SVM public-key/address. */
|
|
102
|
+
readonly address: string;
|
|
103
|
+
} | ({
|
|
104
|
+
readonly surface: 'canton-internal';
|
|
105
|
+
} & CantonPartyKey) | ({
|
|
106
|
+
readonly surface: 'canton-external';
|
|
107
|
+
} & CantonPartyKey);
|
|
108
|
+
export interface TdipIdentity {
|
|
109
|
+
readonly did: TdipDid;
|
|
110
|
+
readonly parts: TdipDidParts;
|
|
111
|
+
/** Surface keys derived from the MPC quorum. Indexed by surface name. */
|
|
112
|
+
readonly keys: ReadonlyMap<SurfaceKey['surface'], SurfaceKey>;
|
|
113
|
+
readonly createdAt: number;
|
|
114
|
+
}
|
|
115
|
+
//# sourceMappingURL=identity.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"identity.d.ts","sourceRoot":"","sources":["../../src/types/identity.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAEH,MAAM,MAAM,SAAS,GAAG,QAAQ,CAAC;AAEjC,MAAM,MAAM,QAAQ,GAAG,OAAO,GAAG,oBAAoB,GAAG,oBAAoB,CAAC;AAE7E;;;GAGG;AACH,MAAM,MAAM,OAAO,GAAG,MAAM,GAAG;IAAE,QAAQ,CAAC,OAAO,EAAE,SAAS,CAAA;CAAE,CAAC;AAE/D,MAAM,WAAW,YAAY;IAC3B,QAAQ,CAAC,MAAM,EAAE,SAAS,CAAC;IAC3B,QAAQ,CAAC,IAAI,EAAE,QAAQ,CAAC;IACxB,uEAAuE;IACvE,QAAQ,CAAC,UAAU,CAAC,EAAE,OAAO,CAAC;IAC9B,QAAQ,CAAC,IAAI,EAAE,MAAM,CAAC;IACtB;;;;;;;;OAQG;IACH,QAAQ,CAAC,WAAW,CAAC,EAAE,OAAO,CAAC;CAChC;AAED;;;;GAIG;AACH,MAAM,MAAM,eAAe,GAAG,SAAS,GAAG,aAAa,CAAC;AAExD;;;;;;;;;;;;GAYG;AACH,MAAM,WAAW,cAAc;IAC7B,0CAA0C;IAC1C,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;IACzB;kEAC8D;IAC9D,QAAQ,CAAC,cAAc,EAAE,MAAM,CAAC;IAChC,wCAAwC;IACxC,QAAQ,CAAC,oBAAoB,EAAE,MAAM,CAAC;IACtC,QAAQ,CAAC,YAAY,EAAE;QACrB,QAAQ,CAAC,MAAM,EAAE,SAAS,CAAC;QAC3B,QAAQ,CAAC,SAAS,EAAE,UAAU,CAAC;QAC/B;;8EAEsE;QACtE,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;KAC9B,CAAC;IACF,QAAQ,CAAC,WAAW,EAAE,aAAa,CAAC;QAClC,QAAQ,CAAC,MAAM,EAAE,eAAe,CAAC;QACjC,QAAQ,CAAC,SAAS,EAAE,UAAU,CAAC;QAC/B;;qEAE6D;QAC7D,QAAQ,CAAC,WAAW,EAAE,MAAM,CAAC;KAC9B,CAAC,CAAC;IACH,iCAAiC;IACjC,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;CAC5B;AAED;;;GAGG;AACH,MAAM,MAAM,UAAU,GAClB;IACE,QAAQ,CAAC,OAAO,EAAE,eAAe,CAAC;IAClC,QAAQ,CAAC,MAAM,EAAE,SAAS,CAAC;IAC3B,QAAQ,CAAC,SAAS,EAAE,UAAU,CAAC;IAC/B,yEAAyE;IACzE,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B,GACD;IACE,QAAQ,CAAC,OAAO,EAAE,eAAe,CAAC;IAClC,QAAQ,CAAC,MAAM,EAAE,WAAW,CAAC;IAC7B,QAAQ,CAAC,OAAO,EAAE,KAAK,MAAM,EAAE,CAAC;CACjC,GACD;IACE,QAAQ,CAAC,OAAO,EAAE,eAAe,CAAC;IAClC,QAAQ,CAAC,MAAM,EAAE,SAAS,CAAC;IAC3B,QAAQ,CAAC,SAAS,EAAE,UAAU,CAAC;IAC/B,6CAA6C;IAC7C,QAAQ,CAAC,OAAO,EAAE,MAAM,CAAC;CAC1B,GACD,CAAC;IAAE,QAAQ,CAAC,OAAO,EAAE,iBAAiB,CAAA;CAAE,GAAG,cAAc,CAAC,GAC1D,CAAC;IAAE,QAAQ,CAAC,OAAO,EAAE,iBAAiB,CAAA;CAAE,GAAG,cAAc,CAAC,CAAC;AAE/D,MAAM,WAAW,YAAY;IAC3B,QAAQ,CAAC,GAAG,EAAE,OAAO,CAAC;IACtB,QAAQ,CAAC,KAAK,EAAE,YAAY,CAAC;IAC7B,yEAAyE;IACzE,QAAQ,CAAC,IAAI,EAAE,WAAW,CAAC,UAAU,CAAC,SAAS,CAAC,EAAE,UAAU,CAAC,CAAC;IAC9D,QAAQ,CAAC,SAAS,EAAE,MAAM,CAAC;CAC5B"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* TDIP identity types — the root of all wallet identity.
|
|
3
|
+
*
|
|
4
|
+
* A user has exactly one root DID. Each surface (native, evm, svm, canton-internal,
|
|
5
|
+
* canton-external) projects a derived key from the same MPC quorum.
|
|
6
|
+
*
|
|
7
|
+
* Spec refs:
|
|
8
|
+
* - https://tenzro.com/docs/identity (TDIP)
|
|
9
|
+
* - W3C DID 1.0 (DID Document compatibility)
|
|
10
|
+
*/
|
|
11
|
+
export {};
|
|
12
|
+
//# sourceMappingURL=identity.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"identity.js","sourceRoot":"","sources":["../../src/types/identity.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
export type { AssetId, AssetScope, AssetView, UnifiedBalance, } from './asset.js';
|
|
2
|
+
export type { Consent, SpendingPolicy } from './consent.js';
|
|
3
|
+
export type { DidMethod, SurfaceKey, TdipDid, TdipDidParts, TdipIdentity, TdipKind, } from './identity.js';
|
|
4
|
+
export type { FeeBreakdown, Intent, MemoSpec, PreparedTx, Recipient, Reversibility, Route, SendIntent, SignedTx, TxHandle, TxStatus, TxStatusPhase, } from './intent.js';
|
|
5
|
+
export { MEMO_SPEC_NONE } from './intent.js';
|
|
6
|
+
export type { SigningDriver, SigningRequest, SigningResult, SigningScheme, } from './signing-driver.js';
|
|
7
|
+
export { SURFACE_IS_ON_TENZRO, SURFACE_NATIVE_DECIMALS, } from './surface.js';
|
|
8
|
+
export type { SurfaceName } from './surface.js';
|
|
9
|
+
export type { SurfaceModule } from './surface-module.js';
|
|
10
|
+
//# sourceMappingURL=index.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAAA,YAAY,EACV,OAAO,EACP,UAAU,EACV,SAAS,EACT,cAAc,GACf,MAAM,YAAY,CAAC;AAEpB,YAAY,EAAE,OAAO,EAAE,cAAc,EAAE,MAAM,cAAc,CAAC;AAE5D,YAAY,EACV,SAAS,EACT,UAAU,EACV,OAAO,EACP,YAAY,EACZ,YAAY,EACZ,QAAQ,GACT,MAAM,eAAe,CAAC;AAEvB,YAAY,EACV,YAAY,EACZ,MAAM,EACN,QAAQ,EACR,UAAU,EACV,SAAS,EACT,aAAa,EACb,KAAK,EACL,UAAU,EACV,QAAQ,EACR,QAAQ,EACR,QAAQ,EACR,aAAa,GACd,MAAM,aAAa,CAAC;AACrB,OAAO,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAE7C,YAAY,EACV,aAAa,EACb,cAAc,EACd,aAAa,EACb,aAAa,GACd,MAAM,qBAAqB,CAAC;AAE7B,OAAO,EACL,oBAAoB,EACpB,uBAAuB,GACxB,MAAM,cAAc,CAAC;AACtB,YAAY,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAEhD,YAAY,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAgCA,OAAO,EAAE,cAAc,EAAE,MAAM,aAAa,CAAC;AAS7C,OAAO,EACL,oBAAoB,EACpB,uBAAuB,GACxB,MAAM,cAAc,CAAC"}
|
|
@@ -0,0 +1,132 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Intent / Preview / Signed / Handle / Status — the four-step lifecycle every
|
|
3
|
+
* surface module implements. The kernel never inspects the inside of a
|
|
4
|
+
* `PreparedTx` or `SignedTx`; it just plumbs them through the surface.
|
|
5
|
+
*/
|
|
6
|
+
import type { AssetId } from './asset.js';
|
|
7
|
+
import type { TdipDid } from './identity.js';
|
|
8
|
+
import type { SurfaceName } from './surface.js';
|
|
9
|
+
/** Recipient address. The shape depends on the destination surface. */
|
|
10
|
+
export type Recipient = {
|
|
11
|
+
readonly kind: 'tdip';
|
|
12
|
+
readonly did: TdipDid;
|
|
13
|
+
} | {
|
|
14
|
+
readonly kind: 'evm';
|
|
15
|
+
readonly address: `0x${string}`;
|
|
16
|
+
} | {
|
|
17
|
+
readonly kind: 'svm';
|
|
18
|
+
readonly publicKey: string;
|
|
19
|
+
} | {
|
|
20
|
+
readonly kind: 'canton';
|
|
21
|
+
readonly partyId: string;
|
|
22
|
+
};
|
|
23
|
+
/**
|
|
24
|
+
* What the user wants to happen, expressed before the kernel has chosen a route.
|
|
25
|
+
*/
|
|
26
|
+
export interface SendIntent {
|
|
27
|
+
readonly kind: 'send';
|
|
28
|
+
readonly from: TdipDid;
|
|
29
|
+
readonly to: Recipient;
|
|
30
|
+
readonly asset: AssetId;
|
|
31
|
+
readonly amount: bigint;
|
|
32
|
+
/**
|
|
33
|
+
* Memo / destination tag / payment id — generalised across surfaces. Canton
|
|
34
|
+
* uses it as the transfer description; Stellar/XRPL (via bridge) use it as
|
|
35
|
+
* a destination tag; some exchanges require it to credit the recipient.
|
|
36
|
+
* `surface.memoSpec(intent)` (when implemented) tells the UI what shape and
|
|
37
|
+
* whether it's required.
|
|
38
|
+
*/
|
|
39
|
+
readonly memo?: string;
|
|
40
|
+
/**
|
|
41
|
+
* Force a specific source surface. If omitted, the router chooses based on
|
|
42
|
+
* asset scope and recipient kind.
|
|
43
|
+
*/
|
|
44
|
+
readonly fromSurface?: SurfaceName;
|
|
45
|
+
}
|
|
46
|
+
export type Intent = SendIntent;
|
|
47
|
+
/** How the kernel proposes to execute an intent. */
|
|
48
|
+
export type Route = {
|
|
49
|
+
readonly kind: 'native';
|
|
50
|
+
readonly surface: SurfaceName;
|
|
51
|
+
} | {
|
|
52
|
+
readonly kind: 'cross-vm-pointer';
|
|
53
|
+
readonly fromSurface: SurfaceName;
|
|
54
|
+
readonly toSurface: SurfaceName;
|
|
55
|
+
/** Cross-VM Bridge precompile address on EVM-on-Tenzro. */
|
|
56
|
+
readonly precompile: '0x1003';
|
|
57
|
+
} | {
|
|
58
|
+
readonly kind: 'bridge';
|
|
59
|
+
readonly fromSurface: SurfaceName;
|
|
60
|
+
readonly toSurface: SurfaceName;
|
|
61
|
+
readonly adapter: 'lifi' | 'layerzero' | 'ccip' | 'debridge' | 'canton-adapter';
|
|
62
|
+
};
|
|
63
|
+
/** Reversibility hint shown to the user. */
|
|
64
|
+
export type Reversibility = 'final-on-submit' | 'reversible-until-confirmed' | 'irreversible';
|
|
65
|
+
export interface FeeBreakdown {
|
|
66
|
+
readonly asset: AssetId;
|
|
67
|
+
readonly amount: bigint;
|
|
68
|
+
readonly label: string;
|
|
69
|
+
}
|
|
70
|
+
/**
|
|
71
|
+
* Result of `surface.prepare(intent)`. Opaque transaction body lives in `body`;
|
|
72
|
+
* everything else is for UI rendering and consent.
|
|
73
|
+
*/
|
|
74
|
+
export interface PreparedTx {
|
|
75
|
+
readonly route: Route;
|
|
76
|
+
readonly intent: Intent;
|
|
77
|
+
readonly fees: readonly FeeBreakdown[];
|
|
78
|
+
readonly etaMs: number;
|
|
79
|
+
readonly reversibility: Reversibility;
|
|
80
|
+
readonly warnings: readonly string[];
|
|
81
|
+
/** Surface-specific transaction body — opaque to the kernel. */
|
|
82
|
+
readonly body: unknown;
|
|
83
|
+
}
|
|
84
|
+
/** Result of `surface.sign(prepared, consent)`. */
|
|
85
|
+
export interface SignedTx {
|
|
86
|
+
readonly prepared: PreparedTx;
|
|
87
|
+
readonly signatures: readonly Uint8Array[];
|
|
88
|
+
readonly body: unknown;
|
|
89
|
+
}
|
|
90
|
+
/** Returned by `surface.submit(signed)` — used to track the tx after submission. */
|
|
91
|
+
export interface TxHandle {
|
|
92
|
+
readonly id: string;
|
|
93
|
+
readonly surface: SurfaceName;
|
|
94
|
+
readonly submittedAt: number;
|
|
95
|
+
/** On-chain transaction hash. Optional only because the M1 mock surfaces
|
|
96
|
+
* produced handles before they had real chain hashes; real surfaces
|
|
97
|
+
* always populate it. */
|
|
98
|
+
readonly hash?: string;
|
|
99
|
+
}
|
|
100
|
+
export type TxStatusPhase = 'created' | 'pending' | 'confirmed' | 'finalized' | 'failed' | 'dropped';
|
|
101
|
+
export interface TxStatus {
|
|
102
|
+
readonly handle: TxHandle;
|
|
103
|
+
readonly phase: TxStatusPhase;
|
|
104
|
+
readonly blockHeight?: number;
|
|
105
|
+
readonly hash?: string;
|
|
106
|
+
readonly error?: string;
|
|
107
|
+
}
|
|
108
|
+
/**
|
|
109
|
+
* Surface-declared memo requirement. Returned by `SurfaceModule.memoSpec`
|
|
110
|
+
* (optional method); the kernel forwards this to the UI so consent flows
|
|
111
|
+
* can show the right input. `kind` is the dialect:
|
|
112
|
+
*
|
|
113
|
+
* - `text` — free-form string (Canton transfer description, generic memo)
|
|
114
|
+
* - `numeric` — uint string (Stellar `MEMO_ID`, XRPL destination tag)
|
|
115
|
+
* - `hash` — 32-byte hex (Stellar `MEMO_HASH`)
|
|
116
|
+
*
|
|
117
|
+
* `required` is true when the destination *will fail to credit* without the
|
|
118
|
+
* memo. The kernel doesn't enforce the requirement itself — that's the
|
|
119
|
+
* surface's job at `prepare` time — but the UI uses the flag to mark the
|
|
120
|
+
* field as "required" rather than "optional".
|
|
121
|
+
*/
|
|
122
|
+
export interface MemoSpec {
|
|
123
|
+
readonly kind: 'text' | 'numeric' | 'hash';
|
|
124
|
+
readonly required: boolean;
|
|
125
|
+
/** Optional max length / byte limit (e.g. Canton: 256 chars). */
|
|
126
|
+
readonly maxLength?: number;
|
|
127
|
+
/** UI-only, e.g. "Destination tag" / "Transfer description". */
|
|
128
|
+
readonly label?: string;
|
|
129
|
+
}
|
|
130
|
+
/** No-memo sentinel — surfaces that don't accept a memo return this. */
|
|
131
|
+
export declare const MEMO_SPEC_NONE: MemoSpec;
|
|
132
|
+
//# sourceMappingURL=intent.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"intent.d.ts","sourceRoot":"","sources":["../../src/types/intent.ts"],"names":[],"mappings":"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"}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Intent / Preview / Signed / Handle / Status — the four-step lifecycle every
|
|
3
|
+
* surface module implements. The kernel never inspects the inside of a
|
|
4
|
+
* `PreparedTx` or `SignedTx`; it just plumbs them through the surface.
|
|
5
|
+
*/
|
|
6
|
+
/** No-memo sentinel — surfaces that don't accept a memo return this. */
|
|
7
|
+
export const MEMO_SPEC_NONE = { kind: 'text', required: false, maxLength: 0 };
|
|
8
|
+
//# sourceMappingURL=intent.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"intent.js","sourceRoot":"","sources":["../../src/types/intent.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AA4IH,wEAAwE;AACxE,MAAM,CAAC,MAAM,cAAc,GAAa,EAAE,IAAI,EAAE,MAAM,EAAE,QAAQ,EAAE,KAAK,EAAE,SAAS,EAAE,CAAC,EAAE,CAAC"}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Signing driver abstraction. Maps to the same shape Splice Wallet Kernel uses
|
|
3
|
+
* (core-signing-internal, core-signing-fireblocks, core-signing-blockdaemon,
|
|
4
|
+
* core-signing-participant) plus a Tenzro-native MPC driver.
|
|
5
|
+
*
|
|
6
|
+
* Surface modules call these; they never see raw key material.
|
|
7
|
+
*/
|
|
8
|
+
import type { SurfaceKey, TdipDid } from './identity.js';
|
|
9
|
+
/**
|
|
10
|
+
* - `ed25519` — single Ed25519 signature (Tenzro native non-hybrid surfaces,
|
|
11
|
+
* SVM, Canton).
|
|
12
|
+
* - `secp256k1` — single ECDSA signature (EVM).
|
|
13
|
+
* - `ed25519+ml-dsa-65` — hybrid pair (Tenzro native). Per DESIGN.md §4.3.4
|
|
14
|
+
* and §11, M5 threshold-signs the Ed25519 leg across the passkey-quorum
|
|
15
|
+
* (FROST-Ed25519) but the ML-DSA-65 leg is supplied by the node TEE
|
|
16
|
+
* alone, since threshold ML-DSA has no audited WASM-shippable
|
|
17
|
+
* implementation as of 2026-04. Device-side `SigningDriver`s therefore
|
|
18
|
+
* return a *single* Ed25519 signature for this scheme; the ML-DSA leg
|
|
19
|
+
* is appended server-side and the node submits the hybrid pair. This
|
|
20
|
+
* means the TEE is in every Tenzro-native signature until threshold
|
|
21
|
+
* ML-DSA exists. Track NIST IR 8214B and FROST-PQ for when that flips
|
|
22
|
+
* to a 2-element `signatures` array assembled locally.
|
|
23
|
+
*/
|
|
24
|
+
export type SigningScheme = 'ed25519' | 'secp256k1' | 'ed25519+ml-dsa-65';
|
|
25
|
+
export interface SigningRequest {
|
|
26
|
+
readonly did: TdipDid;
|
|
27
|
+
readonly surfaceKey: SurfaceKey;
|
|
28
|
+
readonly scheme: SigningScheme;
|
|
29
|
+
/** Canonical preimage bytes — surface module is responsible for canonicalization. */
|
|
30
|
+
readonly preimage: Uint8Array;
|
|
31
|
+
/** Optional context tag for the signing driver's audit log. */
|
|
32
|
+
readonly purpose?: string;
|
|
33
|
+
}
|
|
34
|
+
export interface SigningResult {
|
|
35
|
+
/** One signature per scheme component. Hybrid signing returns two entries. */
|
|
36
|
+
readonly signatures: readonly Uint8Array[];
|
|
37
|
+
}
|
|
38
|
+
export interface SigningDriver {
|
|
39
|
+
readonly id: 'internal-mpc' | 'tenzro-tee' | 'fireblocks' | 'blockdaemon' | 'canton-participant'
|
|
40
|
+
/** Threshold Ed25519 device driver — FROST round-coordinated (M5). */
|
|
41
|
+
| 'frost-ed25519'
|
|
42
|
+
/** Threshold secp256k1 device driver — FROST round-coordinated (M5). */
|
|
43
|
+
| 'frost-secp256k1'
|
|
44
|
+
/** Hybrid driver — FROST-Ed25519 leg + node-TEE ML-DSA-65 leg (M5). */
|
|
45
|
+
| 'hybrid-ed25519-mldsa';
|
|
46
|
+
sign(req: SigningRequest): Promise<SigningResult>;
|
|
47
|
+
}
|
|
48
|
+
//# sourceMappingURL=signing-driver.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"signing-driver.d.ts","sourceRoot":"","sources":["../../src/types/signing-driver.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,KAAK,EAAE,UAAU,EAAE,OAAO,EAAE,MAAM,eAAe,CAAC;AAEzD;;;;;;;;;;;;;;GAcG;AACH,MAAM,MAAM,aAAa,GAAG,SAAS,GAAG,WAAW,GAAG,mBAAmB,CAAC;AAE1E,MAAM,WAAW,cAAc;IAC7B,QAAQ,CAAC,GAAG,EAAE,OAAO,CAAC;IACtB,QAAQ,CAAC,UAAU,EAAE,UAAU,CAAC;IAChC,QAAQ,CAAC,MAAM,EAAE,aAAa,CAAC;IAC/B,qFAAqF;IACrF,QAAQ,CAAC,QAAQ,EAAE,UAAU,CAAC;IAC9B,+DAA+D;IAC/D,QAAQ,CAAC,OAAO,CAAC,EAAE,MAAM,CAAC;CAC3B;AAED,MAAM,WAAW,aAAa;IAC5B,8EAA8E;IAC9E,QAAQ,CAAC,UAAU,EAAE,SAAS,UAAU,EAAE,CAAC;CAC5C;AAED,MAAM,WAAW,aAAa;IAC5B,QAAQ,CAAC,EAAE,EACP,cAAc,GACd,YAAY,GACZ,YAAY,GACZ,aAAa,GACb,oBAAoB;IACtB,sEAAsE;OACpE,eAAe;IACjB,wEAAwE;OACtE,iBAAiB;IACnB,uEAAuE;OACrE,sBAAsB,CAAC;IAC3B,IAAI,CAAC,GAAG,EAAE,cAAc,GAAG,OAAO,CAAC,aAAa,CAAC,CAAC;CACnD"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Signing driver abstraction. Maps to the same shape Splice Wallet Kernel uses
|
|
3
|
+
* (core-signing-internal, core-signing-fireblocks, core-signing-blockdaemon,
|
|
4
|
+
* core-signing-participant) plus a Tenzro-native MPC driver.
|
|
5
|
+
*
|
|
6
|
+
* Surface modules call these; they never see raw key material.
|
|
7
|
+
*/
|
|
8
|
+
export {};
|
|
9
|
+
//# sourceMappingURL=signing-driver.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"signing-driver.js","sourceRoot":"","sources":["../../src/types/signing-driver.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG"}
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The Surface interface — every surface module implements exactly this.
|
|
3
|
+
*
|
|
4
|
+
* `prepare` is read-mostly: it can hit RPCs to estimate fees, check nonces, and
|
|
5
|
+
* validate the recipient. It must never request user signing.
|
|
6
|
+
*
|
|
7
|
+
* `sign` is where the MPC quorum runs. Surface modules call into the
|
|
8
|
+
* `SigningDriver` (passed at kernel construction) rather than holding key
|
|
9
|
+
* material directly.
|
|
10
|
+
*
|
|
11
|
+
* `submit` is fire-and-forget; `watch` is the long-poll for finality.
|
|
12
|
+
*
|
|
13
|
+
* `preparePointer` is optional and lives on on-Tenzro surfaces only. Kernel
|
|
14
|
+
* dispatches to it when route is `cross-vm-pointer` (precompile 0x1003 / SVM
|
|
15
|
+
* cross-VM instruction / native syscall). Surfaces that can't be a pointer-op
|
|
16
|
+
* source (canton-external) omit it; canton-internal lands its impl in M4.
|
|
17
|
+
*/
|
|
18
|
+
import type { CrossVmPointerOp } from '../ports/cross-vm.js';
|
|
19
|
+
import type { Consent } from './consent.js';
|
|
20
|
+
import type { Intent, MemoSpec, PreparedTx, SignedTx, TxHandle, TxStatus } from './intent.js';
|
|
21
|
+
import type { SurfaceName } from './surface.js';
|
|
22
|
+
export interface SurfaceModule {
|
|
23
|
+
readonly name: SurfaceName;
|
|
24
|
+
prepare(intent: Intent): Promise<PreparedTx>;
|
|
25
|
+
preparePointer?(intent: Intent, op: CrossVmPointerOp): Promise<PreparedTx>;
|
|
26
|
+
sign(prepared: PreparedTx, consent: Consent): Promise<SignedTx>;
|
|
27
|
+
submit(signed: SignedTx): Promise<TxHandle>;
|
|
28
|
+
watch(handle: TxHandle): AsyncIterable<TxStatus>;
|
|
29
|
+
/**
|
|
30
|
+
* Tell the UI what memo / destination-tag shape this surface accepts for
|
|
31
|
+
* a given intent. Optional — surfaces that never need a memo can omit it
|
|
32
|
+
* (kernel treats absence as `MEMO_SPEC_NONE`). Recipients differ even
|
|
33
|
+
* within a surface (an exchange Canton party may require memos while a
|
|
34
|
+
* personal party may not), so the spec is per-intent, not per-surface.
|
|
35
|
+
*/
|
|
36
|
+
memoSpec?(intent: Intent): MemoSpec;
|
|
37
|
+
}
|
|
38
|
+
//# sourceMappingURL=surface-module.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"surface-module.d.ts","sourceRoot":"","sources":["../../src/types/surface-module.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAEH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,sBAAsB,CAAC;AAC7D,OAAO,KAAK,EAAE,OAAO,EAAE,MAAM,cAAc,CAAC;AAC5C,OAAO,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,UAAU,EAAE,QAAQ,EAAE,QAAQ,EAAE,QAAQ,EAAE,MAAM,aAAa,CAAC;AAC9F,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,cAAc,CAAC;AAEhD,MAAM,WAAW,aAAa;IAC5B,QAAQ,CAAC,IAAI,EAAE,WAAW,CAAC;IAC3B,OAAO,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;IAC7C,cAAc,CAAC,CAAC,MAAM,EAAE,MAAM,EAAE,EAAE,EAAE,gBAAgB,GAAG,OAAO,CAAC,UAAU,CAAC,CAAC;IAC3E,IAAI,CAAC,QAAQ,EAAE,UAAU,EAAE,OAAO,EAAE,OAAO,GAAG,OAAO,CAAC,QAAQ,CAAC,CAAC;IAChE,MAAM,CAAC,MAAM,EAAE,QAAQ,GAAG,OAAO,CAAC,QAAQ,CAAC,CAAC;IAC5C,KAAK,CAAC,MAAM,EAAE,QAAQ,GAAG,aAAa,CAAC,QAAQ,CAAC,CAAC;IACjD;;;;;;OAMG;IACH,QAAQ,CAAC,CAAC,MAAM,EAAE,MAAM,GAAG,QAAQ,CAAC;CACrC"}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* The Surface interface — every surface module implements exactly this.
|
|
3
|
+
*
|
|
4
|
+
* `prepare` is read-mostly: it can hit RPCs to estimate fees, check nonces, and
|
|
5
|
+
* validate the recipient. It must never request user signing.
|
|
6
|
+
*
|
|
7
|
+
* `sign` is where the MPC quorum runs. Surface modules call into the
|
|
8
|
+
* `SigningDriver` (passed at kernel construction) rather than holding key
|
|
9
|
+
* material directly.
|
|
10
|
+
*
|
|
11
|
+
* `submit` is fire-and-forget; `watch` is the long-poll for finality.
|
|
12
|
+
*
|
|
13
|
+
* `preparePointer` is optional and lives on on-Tenzro surfaces only. Kernel
|
|
14
|
+
* dispatches to it when route is `cross-vm-pointer` (precompile 0x1003 / SVM
|
|
15
|
+
* cross-VM instruction / native syscall). Surfaces that can't be a pointer-op
|
|
16
|
+
* source (canton-external) omit it; canton-internal lands its impl in M4.
|
|
17
|
+
*/
|
|
18
|
+
export {};
|
|
19
|
+
//# sourceMappingURL=surface-module.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"surface-module.js","sourceRoot":"","sources":["../../src/types/surface-module.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG"}
|