@bounded-sh/client 0.0.44 → 0.0.50
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/README.md +21 -0
- package/dist/auth/crossmint-signer-bridge.d.ts +1 -1
- package/dist/auth/index.d.ts +1 -1
- package/dist/auth/providers/email-auth-provider.d.ts +1 -2
- package/dist/auth/providers/guest-auth-provider.d.ts +8 -1
- package/dist/auth/providers/guest-keystore.d.ts +2 -0
- package/dist/auth/providers/injected-wallet-provider.d.ts +1 -1
- package/dist/auth/providers/offchain-auth-provider.d.ts +3 -3
- package/dist/auth/providers/phantom-wallet-provider.d.ts +1 -1
- package/dist/auth/providers/privy-expo-provider.d.ts +1 -1
- package/dist/auth/providers/privy-wallet-provider.d.ts +1 -1
- package/dist/auth/providers/sol/sol-utils.d.ts +1 -1
- package/dist/auth/providers/transaction-utils.d.ts +1 -1
- package/dist/builds/apps.d.ts +32 -0
- package/dist/builds/client.d.ts +74 -0
- package/dist/builds/index.d.ts +20 -0
- package/dist/builds/types.d.ts +121 -0
- package/dist/builds/watch.d.ts +20 -0
- package/dist/email-auth-provider-B7czfBEU.mjs +99 -0
- package/dist/email-auth-provider-B7czfBEU.mjs.map +1 -0
- package/dist/email-auth-provider-CmYs6Dcm.js +102 -0
- package/dist/email-auth-provider-CmYs6Dcm.js.map +1 -0
- package/dist/email-auth-provider-DIZAETBC.mjs +99 -0
- package/dist/email-auth-provider-DIZAETBC.mjs.map +1 -0
- package/dist/email-auth-provider-Dj66AuH0.js +102 -0
- package/dist/email-auth-provider-Dj66AuH0.js.map +1 -0
- package/dist/global.d.ts +3 -1
- package/dist/guest-auth-provider-B5sgg-q5.js +277 -0
- package/dist/guest-auth-provider-B5sgg-q5.js.map +1 -0
- package/dist/guest-auth-provider-BR0_YL8z.mjs +275 -0
- package/dist/guest-auth-provider-BR0_YL8z.mjs.map +1 -0
- package/dist/guest-auth-provider-CCpNvX3j.mjs +275 -0
- package/dist/guest-auth-provider-CCpNvX3j.mjs.map +1 -0
- package/dist/guest-auth-provider-CxsLCznO.js +277 -0
- package/dist/guest-auth-provider-CxsLCznO.js.map +1 -0
- package/dist/hooks/useBuildRun.d.ts +13 -0
- package/dist/index-BYy1tSkr.mjs +6123 -0
- package/dist/index-BYy1tSkr.mjs.map +1 -0
- package/dist/index-m42Be5Oj.js +6190 -0
- package/dist/index-m42Be5Oj.js.map +1 -0
- package/dist/index.d.ts +5 -0
- package/dist/index.js +91 -6378
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +2 -6283
- package/dist/index.mjs.map +1 -1
- package/dist/index.native-B-ldAbu2.mjs +5972 -0
- package/dist/index.native-B-ldAbu2.mjs.map +1 -0
- package/dist/index.native-BfoLJCZg.js +6035 -0
- package/dist/index.native-BfoLJCZg.js.map +1 -0
- package/dist/index.native.d.ts +5 -0
- package/dist/index.native.js +87 -6308
- package/dist/index.native.js.map +1 -1
- package/dist/index.native.mjs +2 -6217
- package/dist/index.native.mjs.map +1 -1
- package/dist/injected-evm-wallet-provider-BLQzWiBP.js +343 -0
- package/dist/injected-evm-wallet-provider-BLQzWiBP.js.map +1 -0
- package/dist/injected-evm-wallet-provider-BXj1YFaZ.js +409 -0
- package/dist/injected-evm-wallet-provider-BXj1YFaZ.js.map +1 -0
- package/dist/injected-evm-wallet-provider-sBCSkksr.mjs +340 -0
- package/dist/injected-evm-wallet-provider-sBCSkksr.mjs.map +1 -0
- package/dist/injected-evm-wallet-provider-ubsHX217.mjs +406 -0
- package/dist/injected-evm-wallet-provider-ubsHX217.mjs.map +1 -0
- package/dist/injected-wallet-provider-BfzoheDy.mjs +260 -0
- package/dist/injected-wallet-provider-BfzoheDy.mjs.map +1 -0
- package/dist/injected-wallet-provider-Cml9TkyV.js +263 -0
- package/dist/injected-wallet-provider-Cml9TkyV.js.map +1 -0
- package/dist/injected-wallet-provider-DG87X6AQ.mjs +279 -0
- package/dist/injected-wallet-provider-DG87X6AQ.mjs.map +1 -0
- package/dist/injected-wallet-provider-PYcvLO2Z.js +282 -0
- package/dist/injected-wallet-provider-PYcvLO2Z.js.map +1 -0
- package/package.json +10 -5
|
@@ -0,0 +1,343 @@
|
|
|
1
|
+
'use strict';
|
|
2
|
+
|
|
3
|
+
var core = require('@bounded-sh/core');
|
|
4
|
+
var index = require('./index-m42Be5Oj.js');
|
|
5
|
+
require('react');
|
|
6
|
+
|
|
7
|
+
const STORED_AUTH_METHOD_KEY = 'bounded_last_auth_method';
|
|
8
|
+
// Must equal the authMethod the registry (auth/index.ts) sets as currentAuthMethod,
|
|
9
|
+
// so clearIncompatibleSession() keeps (not wipes) this session on the next init().
|
|
10
|
+
const INJECTED_EVM_AUTH_METHOD = 'evm-wallet';
|
|
11
|
+
// The /session issuer's discriminator for the SIWE (EIP-4361 secp256k1) exchange.
|
|
12
|
+
const SIWE_SESSION_METHOD = 'siwe';
|
|
13
|
+
const NO_WALLET_ERR = 'No injected EVM wallet found. Install a wallet like MetaMask (metamask.io) or Rabby and try again, ' +
|
|
14
|
+
'or pass config.evmWalletConfig.getProvider to point at your wallet.';
|
|
15
|
+
const NO_SOL_TX_ERR = 'EVM wallet login signs+submits transactions in one step (eth_sendTransaction) and has no Solana ' +
|
|
16
|
+
'transaction surface. Use an onchain WRITE (setMany) — the worker returns a pre-built EVM tx that ' +
|
|
17
|
+
'runTransaction submits — instead of signTransaction/signAndSubmitTransaction.';
|
|
18
|
+
// Bounded polling for the tx receipt: ~60s at 2s cadence (L2 blocks are seconds).
|
|
19
|
+
const RECEIPT_POLL_ATTEMPTS = 30;
|
|
20
|
+
const RECEIPT_POLL_INTERVAL_MS = 2000;
|
|
21
|
+
function normalizeConfig(config) {
|
|
22
|
+
var _a;
|
|
23
|
+
if (config.chainId !== undefined && (!Number.isSafeInteger(config.chainId) || config.chainId <= 0)) {
|
|
24
|
+
throw new Error('EVM wallet chainId must be a positive safe integer');
|
|
25
|
+
}
|
|
26
|
+
let runtimeAddress;
|
|
27
|
+
if (config.runtimeAddress !== undefined) {
|
|
28
|
+
runtimeAddress = (_a = core.normalizeEvmAddress(config.runtimeAddress)) !== null && _a !== void 0 ? _a : undefined;
|
|
29
|
+
if (!runtimeAddress)
|
|
30
|
+
throw new Error('EVM wallet runtimeAddress is invalid');
|
|
31
|
+
if (config.chainId === undefined)
|
|
32
|
+
throw new Error('EVM wallet runtimeAddress requires an explicit chainId');
|
|
33
|
+
}
|
|
34
|
+
let runtimeAddresses;
|
|
35
|
+
if (config.runtimeAddresses !== undefined) {
|
|
36
|
+
runtimeAddresses = {};
|
|
37
|
+
for (const [rawChainId, rawAddress] of Object.entries(config.runtimeAddresses)) {
|
|
38
|
+
const chainId = Number(rawChainId);
|
|
39
|
+
const address = core.normalizeEvmAddress(rawAddress);
|
|
40
|
+
if (!Number.isSafeInteger(chainId) || chainId <= 0 || String(chainId) !== rawChainId || !address) {
|
|
41
|
+
throw new Error(`Invalid EVM runtime allowlist entry for chain ${rawChainId}`);
|
|
42
|
+
}
|
|
43
|
+
runtimeAddresses[rawChainId] = address;
|
|
44
|
+
}
|
|
45
|
+
}
|
|
46
|
+
return Object.assign(Object.assign({}, config), { runtimeAddress, runtimeAddresses });
|
|
47
|
+
}
|
|
48
|
+
class InjectedEvmWalletProvider {
|
|
49
|
+
constructor(config = {}) {
|
|
50
|
+
this.authenticatedAddress = null;
|
|
51
|
+
if (typeof window === 'undefined') {
|
|
52
|
+
throw new Error('InjectedEvmWalletProvider can only be instantiated in a browser environment');
|
|
53
|
+
}
|
|
54
|
+
const normalized = normalizeConfig(config);
|
|
55
|
+
// Singleton so the SDK reuses one instance (mirrors the other providers).
|
|
56
|
+
if (InjectedEvmWalletProvider.instance) {
|
|
57
|
+
InjectedEvmWalletProvider.instance.config = normalized;
|
|
58
|
+
InjectedEvmWalletProvider.instance.authenticatedAddress = null;
|
|
59
|
+
return InjectedEvmWalletProvider.instance;
|
|
60
|
+
}
|
|
61
|
+
this.config = normalized;
|
|
62
|
+
InjectedEvmWalletProvider.instance = this;
|
|
63
|
+
}
|
|
64
|
+
// @user.address (the Solana wallet) is null for an EVM-wallet login. User.address
|
|
65
|
+
// is typed `string` for legacy reasons — email logins cast the same null the same
|
|
66
|
+
// way (email-auth-provider.ts) — so the null is cast here in one place.
|
|
67
|
+
evmUser(address) {
|
|
68
|
+
return { id: address, address: null, evmAddress: address, provider: this };
|
|
69
|
+
}
|
|
70
|
+
resolveProvider() {
|
|
71
|
+
var _a;
|
|
72
|
+
const provider = (_a = (this.config.getProvider ? this.config.getProvider() : null)) !== null && _a !== void 0 ? _a : index.defaultInjectedEvmProvider();
|
|
73
|
+
if (!provider)
|
|
74
|
+
throw new Error(NO_WALLET_ERR);
|
|
75
|
+
return provider;
|
|
76
|
+
}
|
|
77
|
+
/** Connect the injected wallet and return its canonical lowercase EVM address. */
|
|
78
|
+
async connectAddress(provider) {
|
|
79
|
+
const accounts = await provider.request({ method: 'eth_requestAccounts' });
|
|
80
|
+
const raw = Array.isArray(accounts) ? accounts[0] : undefined;
|
|
81
|
+
const address = core.normalizeEvmAddress(raw);
|
|
82
|
+
if (!address)
|
|
83
|
+
throw new Error('Wallet did not return a valid EVM address on connect');
|
|
84
|
+
return address;
|
|
85
|
+
}
|
|
86
|
+
/** Current chain id the wallet is connected to (EIP-155 number), or null. */
|
|
87
|
+
async currentChainId(provider) {
|
|
88
|
+
try {
|
|
89
|
+
const hex = await provider.request({ method: 'eth_chainId' });
|
|
90
|
+
if (typeof hex !== 'string' || !/^0x[0-9a-fA-F]+$/.test(hex))
|
|
91
|
+
return null;
|
|
92
|
+
const n = Number(BigInt(hex));
|
|
93
|
+
return Number.isSafeInteger(n) && n > 0 ? n : null;
|
|
94
|
+
}
|
|
95
|
+
catch (_a) {
|
|
96
|
+
return null;
|
|
97
|
+
}
|
|
98
|
+
}
|
|
99
|
+
async login() {
|
|
100
|
+
var _a;
|
|
101
|
+
index.setAuthLoading(true);
|
|
102
|
+
try {
|
|
103
|
+
const provider = this.resolveProvider();
|
|
104
|
+
const address = await this.connectAddress(provider);
|
|
105
|
+
// Reuse a still-valid session for THIS wallet.
|
|
106
|
+
const existing = await core.getActiveSessionManager().getSession();
|
|
107
|
+
if (existing && existing.address === address) {
|
|
108
|
+
const user = this.evmUser(address);
|
|
109
|
+
this.authenticatedAddress = address;
|
|
110
|
+
index.setCurrentUser(user);
|
|
111
|
+
this.markAuthMethod();
|
|
112
|
+
return user;
|
|
113
|
+
}
|
|
114
|
+
// SIWE: nonce -> canonical EIP-4361 prompt -> the wallet personal_sign's it.
|
|
115
|
+
const nonce = await core.genAuthNonce();
|
|
116
|
+
const appId = (await core.getConfig()).appId;
|
|
117
|
+
const chainId = (_a = this.config.chainId) !== null && _a !== void 0 ? _a : await this.currentChainId(provider);
|
|
118
|
+
if (chainId === null)
|
|
119
|
+
throw new Error('Could not verify the EVM wallet chain for SIWE login');
|
|
120
|
+
const message = core.genSiweMessage(address, nonce, appId, this.resolveDomain(), this.resolveUri(), { chainId });
|
|
121
|
+
// personal_sign(message, address) -> 0x r‖s‖v hex (the shape the
|
|
122
|
+
// bounded-auth verifier's recoverSiweSigner consumes). The raw UTF-8
|
|
123
|
+
// message is signed under the EIP-191 envelope the verifier hashes.
|
|
124
|
+
const signature = await provider.request({
|
|
125
|
+
method: 'personal_sign',
|
|
126
|
+
params: [message, address],
|
|
127
|
+
});
|
|
128
|
+
const result = await core.createSessionWithSignature(address, message, signature, SIWE_SESSION_METHOD);
|
|
129
|
+
await core.getActiveSessionManager().storeSession(address, result.accessToken, result.idToken, result.refreshToken);
|
|
130
|
+
this.markAuthMethod();
|
|
131
|
+
const user = this.evmUser(address);
|
|
132
|
+
this.authenticatedAddress = address;
|
|
133
|
+
index.setCurrentUser(user);
|
|
134
|
+
return user;
|
|
135
|
+
}
|
|
136
|
+
finally {
|
|
137
|
+
index.setAuthLoading(false);
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
resolveDomain() {
|
|
141
|
+
const actual = window.location.host.toLowerCase();
|
|
142
|
+
if (this.config.domain && this.config.domain.toLowerCase() !== actual) {
|
|
143
|
+
throw new Error('SIWE domain override must match the current browser origin');
|
|
144
|
+
}
|
|
145
|
+
return actual;
|
|
146
|
+
}
|
|
147
|
+
resolveUri() {
|
|
148
|
+
const actual = window.location.origin.toLowerCase();
|
|
149
|
+
if (this.config.uri) {
|
|
150
|
+
let configured;
|
|
151
|
+
try {
|
|
152
|
+
configured = new URL(this.config.uri).origin.toLowerCase();
|
|
153
|
+
}
|
|
154
|
+
catch (_a) {
|
|
155
|
+
throw new Error('SIWE URI override must be an absolute URL');
|
|
156
|
+
}
|
|
157
|
+
if (configured !== actual)
|
|
158
|
+
throw new Error('SIWE URI override must match the current browser origin');
|
|
159
|
+
}
|
|
160
|
+
return actual;
|
|
161
|
+
}
|
|
162
|
+
markAuthMethod() {
|
|
163
|
+
try {
|
|
164
|
+
index.getPlatform().storage.setItem(STORED_AUTH_METHOD_KEY, INJECTED_EVM_AUTH_METHOD);
|
|
165
|
+
}
|
|
166
|
+
catch ( /* no storage */_a) { /* no storage */ }
|
|
167
|
+
}
|
|
168
|
+
async restoreSession() {
|
|
169
|
+
const session = await core.getActiveSessionManager().getSession();
|
|
170
|
+
if (!session)
|
|
171
|
+
return null;
|
|
172
|
+
// An EVM-wallet session stores the EVM address as its address; @user.address
|
|
173
|
+
// (the Solana wallet) is null for this login.
|
|
174
|
+
const address = core.normalizeEvmAddress(session.address);
|
|
175
|
+
if (!address) {
|
|
176
|
+
core.getActiveSessionManager().clearSession();
|
|
177
|
+
return null;
|
|
178
|
+
}
|
|
179
|
+
this.authenticatedAddress = address;
|
|
180
|
+
const user = this.evmUser(address);
|
|
181
|
+
index.setCurrentUser(user);
|
|
182
|
+
return user;
|
|
183
|
+
}
|
|
184
|
+
async logout() {
|
|
185
|
+
// EIP-1193 has no standard disconnect; clearing the Bounded session is the
|
|
186
|
+
// logout. (wallet_revokePermissions is non-standard/opt-in — skip it.)
|
|
187
|
+
core.getActiveSessionManager().clearSession();
|
|
188
|
+
this.authenticatedAddress = null;
|
|
189
|
+
index.setCurrentUser(null);
|
|
190
|
+
}
|
|
191
|
+
// --- Signing surface -------------------------------------------------------
|
|
192
|
+
/** App-facing message signing: EIP-191 personal_sign, returns 0x r‖s‖v hex. */
|
|
193
|
+
async signMessage(message) {
|
|
194
|
+
const provider = this.resolveProvider();
|
|
195
|
+
const address = await this.connectAddress(provider);
|
|
196
|
+
if (!this.authenticatedAddress || address !== this.authenticatedAddress) {
|
|
197
|
+
throw new Error('The connected EVM wallet account changed after login. Sign in again before signing.');
|
|
198
|
+
}
|
|
199
|
+
return provider.request({ method: 'personal_sign', params: [message, address] });
|
|
200
|
+
}
|
|
201
|
+
// Solana-typed methods are structurally unsupported on an EVM wallet — the
|
|
202
|
+
// EVM onchain write goes through runTransaction (eth_sendTransaction).
|
|
203
|
+
async signTransaction(_transaction) {
|
|
204
|
+
throw new Error(NO_SOL_TX_ERR);
|
|
205
|
+
}
|
|
206
|
+
async signAndSubmitTransaction(_transaction, _feePayer) {
|
|
207
|
+
throw new Error(NO_SOL_TX_ERR);
|
|
208
|
+
}
|
|
209
|
+
/**
|
|
210
|
+
* Onchain write path: submit the worker's PRE-BUILT EIP-1559 tx via
|
|
211
|
+
* eth_sendTransaction (the injected wallet signs + submits in one step), then
|
|
212
|
+
* poll for the receipt. The EVM branch of operations.ts's 202 dispatch calls
|
|
213
|
+
* this with the pre-built payload in the EVM slot and the Solana slot undefined.
|
|
214
|
+
*/
|
|
215
|
+
async runTransaction(evmTransactionData, solTransactionData, options) {
|
|
216
|
+
var _a, _b, _c;
|
|
217
|
+
const evmTx = evmTransactionData;
|
|
218
|
+
if (evmTx && solTransactionData) {
|
|
219
|
+
throw new Error('A transaction cannot target EVM and Solana at the same time.');
|
|
220
|
+
}
|
|
221
|
+
if (!evmTx || !core.normalizeEvmAddress(evmTx.to) || typeof evmTx.data !== 'string' || !/^0x(?:[0-9a-fA-F]{2})+$/.test(evmTx.data)) {
|
|
222
|
+
throw new Error('EVM transaction data (pre-built { to, data, chainId }) is required for an EVM onchain write');
|
|
223
|
+
}
|
|
224
|
+
// Exact decode, rather than a four-byte prefix check: permits the
|
|
225
|
+
// ordinary and attested document-write entrypoints while rejecting
|
|
226
|
+
// malformed/trailing calldata before the wallet sees a signing prompt.
|
|
227
|
+
core.assertCanonicalBoundedRuntimeWriteCalldata(evmTx.data);
|
|
228
|
+
if (!Number.isSafeInteger(evmTx.chainId) || evmTx.chainId <= 0) {
|
|
229
|
+
throw new Error('EVM transaction chainId is required and must be a positive safe integer');
|
|
230
|
+
}
|
|
231
|
+
const chainId = evmTx.chainId;
|
|
232
|
+
const trustedRuntime = (_b = (_a = this.config.runtimeAddresses) === null || _a === void 0 ? void 0 : _a[String(chainId)]) !== null && _b !== void 0 ? _b : (this.config.chainId === chainId ? this.config.runtimeAddress : undefined);
|
|
233
|
+
if (!trustedRuntime)
|
|
234
|
+
throw new Error(`No trusted BoundedRuntime address configured for EVM chain ${chainId}`);
|
|
235
|
+
if (core.normalizeEvmAddress(evmTx.to) !== trustedRuntime) {
|
|
236
|
+
throw new Error('EVM transaction target is not the configured BoundedRuntime');
|
|
237
|
+
}
|
|
238
|
+
if (evmTx.nonce !== undefined) {
|
|
239
|
+
throw new Error('Server-supplied EVM nonces are not accepted');
|
|
240
|
+
}
|
|
241
|
+
try {
|
|
242
|
+
if (BigInt((_c = evmTx.value) !== null && _c !== void 0 ? _c : '0') !== BigInt(0)) {
|
|
243
|
+
throw new Error('BoundedRuntime.setDocuments cannot transfer native value');
|
|
244
|
+
}
|
|
245
|
+
}
|
|
246
|
+
catch (error) {
|
|
247
|
+
if (error instanceof Error && error.message.includes('cannot transfer'))
|
|
248
|
+
throw error;
|
|
249
|
+
throw new Error('Invalid EVM transaction value');
|
|
250
|
+
}
|
|
251
|
+
if ((options === null || options === void 0 ? void 0 : options.shouldSubmitTx) === false) {
|
|
252
|
+
// Injected EVM wallets sign+submit atomically; eth_signTransaction is not
|
|
253
|
+
// broadly supported (MetaMask removed it), so we cannot return a signed-
|
|
254
|
+
// but-unsubmitted tx here. Fail clearly instead of silently submitting.
|
|
255
|
+
throw new Error('shouldSubmitTx:false is unsupported for injected EVM wallets (they sign and submit atomically).');
|
|
256
|
+
}
|
|
257
|
+
const provider = this.resolveProvider();
|
|
258
|
+
const from = await this.connectAddress(provider);
|
|
259
|
+
if (!this.authenticatedAddress || from !== this.authenticatedAddress) {
|
|
260
|
+
throw new Error('The connected EVM wallet account changed after login. Sign in again before submitting this write.');
|
|
261
|
+
}
|
|
262
|
+
// Chain-switch guard: the pre-built tx names the chain it MUST execute on.
|
|
263
|
+
if (typeof evmTx.chainId === 'number') {
|
|
264
|
+
const current = await this.currentChainId(provider);
|
|
265
|
+
if (current === null)
|
|
266
|
+
throw new Error('Could not verify the EVM wallet chain; refusing to submit the transaction.');
|
|
267
|
+
if (current !== evmTx.chainId) {
|
|
268
|
+
const targetHex = '0x' + evmTx.chainId.toString(16);
|
|
269
|
+
try {
|
|
270
|
+
await provider.request({
|
|
271
|
+
method: 'wallet_switchEthereumChain',
|
|
272
|
+
params: [{ chainId: targetHex }],
|
|
273
|
+
});
|
|
274
|
+
}
|
|
275
|
+
catch (err) {
|
|
276
|
+
throw new Error(`EVM wallet is on chain ${current} but this write targets chain ${evmTx.chainId}, ` +
|
|
277
|
+
`and the chain switch was rejected or failed${(err === null || err === void 0 ? void 0 : err.message) ? `: ${err.message}` : ''}. ` +
|
|
278
|
+
`Switch your wallet to chain ${evmTx.chainId} and retry.`);
|
|
279
|
+
}
|
|
280
|
+
const switched = await this.currentChainId(provider);
|
|
281
|
+
if (switched !== evmTx.chainId) {
|
|
282
|
+
throw new Error(`EVM wallet did not switch to required chain ${evmTx.chainId}; refusing to submit.`);
|
|
283
|
+
}
|
|
284
|
+
}
|
|
285
|
+
}
|
|
286
|
+
const txParams = { from, to: core.normalizeEvmAddress(evmTx.to), data: evmTx.data.toLowerCase() };
|
|
287
|
+
txParams.value = '0x0';
|
|
288
|
+
// Gas, fee and nonce hints come from the server and are not part of the
|
|
289
|
+
// governed action. Deliberately omit them: the wallet estimates locally,
|
|
290
|
+
// preventing a compromised response from forcing an abusive fee/nonce.
|
|
291
|
+
const txHash = await provider.request({
|
|
292
|
+
method: 'eth_sendTransaction',
|
|
293
|
+
params: [txParams],
|
|
294
|
+
});
|
|
295
|
+
if (typeof txHash !== 'string' || !/^0x[0-9a-fA-F]{64}$/.test(txHash)) {
|
|
296
|
+
throw new Error('EVM wallet returned an invalid transaction hash');
|
|
297
|
+
}
|
|
298
|
+
const receipt = await this.waitForReceipt(provider, txHash);
|
|
299
|
+
if (!receipt || typeof receipt.status !== 'string' || !/^0x[0-9a-fA-F]+$/.test(receipt.status)) {
|
|
300
|
+
throw new Error(`EVM transaction ${txHash} returned an invalid receipt status`);
|
|
301
|
+
}
|
|
302
|
+
if (BigInt(receipt.status) !== BigInt(1)) {
|
|
303
|
+
throw new Error(`EVM transaction ${txHash} reverted on-chain`);
|
|
304
|
+
}
|
|
305
|
+
if (typeof receipt.blockNumber !== 'string' || !/^0x[0-9a-fA-F]+$/.test(receipt.blockNumber)) {
|
|
306
|
+
throw new Error(`EVM transaction ${txHash} returned an invalid block number`);
|
|
307
|
+
}
|
|
308
|
+
const blockNumber = BigInt(receipt.blockNumber);
|
|
309
|
+
if (blockNumber > BigInt(Number.MAX_SAFE_INTEGER))
|
|
310
|
+
throw new Error('EVM receipt block number exceeds the SDK safe-integer range');
|
|
311
|
+
if (typeof receipt.gasUsed !== 'string' || !/^0x[0-9a-fA-F]+$/.test(receipt.gasUsed)) {
|
|
312
|
+
throw new Error(`EVM transaction ${txHash} returned invalid gas usage`);
|
|
313
|
+
}
|
|
314
|
+
return {
|
|
315
|
+
transactionSignature: txHash,
|
|
316
|
+
blockNumber: Number(blockNumber),
|
|
317
|
+
gasUsed: BigInt(receipt.gasUsed).toString(),
|
|
318
|
+
data: receipt,
|
|
319
|
+
};
|
|
320
|
+
}
|
|
321
|
+
/** Poll eth_getTransactionReceipt until it lands (bounded retries) or throw. */
|
|
322
|
+
async waitForReceipt(provider, txHash) {
|
|
323
|
+
for (let attempt = 0; attempt < RECEIPT_POLL_ATTEMPTS; attempt++) {
|
|
324
|
+
const receipt = await provider.request({
|
|
325
|
+
method: 'eth_getTransactionReceipt',
|
|
326
|
+
params: [txHash],
|
|
327
|
+
});
|
|
328
|
+
if (receipt)
|
|
329
|
+
return receipt;
|
|
330
|
+
await new Promise((r) => setTimeout(r, RECEIPT_POLL_INTERVAL_MS));
|
|
331
|
+
}
|
|
332
|
+
throw new Error(`EVM transaction ${txHash} was submitted but no receipt confirmed within ` +
|
|
333
|
+
`${(RECEIPT_POLL_ATTEMPTS * RECEIPT_POLL_INTERVAL_MS) / 1000}s. It may still land; check the explorer.`);
|
|
334
|
+
}
|
|
335
|
+
async getNativeMethods() {
|
|
336
|
+
return this.resolveProvider();
|
|
337
|
+
}
|
|
338
|
+
}
|
|
339
|
+
InjectedEvmWalletProvider.instance = null;
|
|
340
|
+
|
|
341
|
+
exports.defaultInjectedEvmProvider = index.defaultInjectedEvmProvider;
|
|
342
|
+
exports.InjectedEvmWalletProvider = InjectedEvmWalletProvider;
|
|
343
|
+
//# sourceMappingURL=injected-evm-wallet-provider-BLQzWiBP.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"injected-evm-wallet-provider-BLQzWiBP.js","sources":["../.rollup-tmp/auth/providers/injected-evm-wallet-provider.js"],"sourcesContent":["import { getActiveSessionManager as SessionManager, createSessionWithSignature, genAuthNonce, genSiweMessage, getConfig, normalizeEvmAddress, assertCanonicalBoundedRuntimeWriteCalldata, } from '@bounded-sh/core';\nimport { setCurrentUser, setAuthLoading } from '../../global';\nimport { getPlatform } from '../../platform';\nimport { defaultInjectedEvmProvider, } from './injected-evm-wallet-types';\n// Re-export the type surface + discovery helper for callers who import the\n// provider module directly.\nexport { defaultInjectedEvmProvider };\nconst STORED_AUTH_METHOD_KEY = 'bounded_last_auth_method';\n// Must equal the authMethod the registry (auth/index.ts) sets as currentAuthMethod,\n// so clearIncompatibleSession() keeps (not wipes) this session on the next init().\nconst INJECTED_EVM_AUTH_METHOD = 'evm-wallet';\n// The /session issuer's discriminator for the SIWE (EIP-4361 secp256k1) exchange.\nconst SIWE_SESSION_METHOD = 'siwe';\nconst NO_WALLET_ERR = 'No injected EVM wallet found. Install a wallet like MetaMask (metamask.io) or Rabby and try again, ' +\n 'or pass config.evmWalletConfig.getProvider to point at your wallet.';\nconst NO_SOL_TX_ERR = 'EVM wallet login signs+submits transactions in one step (eth_sendTransaction) and has no Solana ' +\n 'transaction surface. Use an onchain WRITE (setMany) — the worker returns a pre-built EVM tx that ' +\n 'runTransaction submits — instead of signTransaction/signAndSubmitTransaction.';\n// Bounded polling for the tx receipt: ~60s at 2s cadence (L2 blocks are seconds).\nconst RECEIPT_POLL_ATTEMPTS = 30;\nconst RECEIPT_POLL_INTERVAL_MS = 2000;\nfunction normalizeConfig(config) {\n var _a;\n if (config.chainId !== undefined && (!Number.isSafeInteger(config.chainId) || config.chainId <= 0)) {\n throw new Error('EVM wallet chainId must be a positive safe integer');\n }\n let runtimeAddress;\n if (config.runtimeAddress !== undefined) {\n runtimeAddress = (_a = normalizeEvmAddress(config.runtimeAddress)) !== null && _a !== void 0 ? _a : undefined;\n if (!runtimeAddress)\n throw new Error('EVM wallet runtimeAddress is invalid');\n if (config.chainId === undefined)\n throw new Error('EVM wallet runtimeAddress requires an explicit chainId');\n }\n let runtimeAddresses;\n if (config.runtimeAddresses !== undefined) {\n runtimeAddresses = {};\n for (const [rawChainId, rawAddress] of Object.entries(config.runtimeAddresses)) {\n const chainId = Number(rawChainId);\n const address = normalizeEvmAddress(rawAddress);\n if (!Number.isSafeInteger(chainId) || chainId <= 0 || String(chainId) !== rawChainId || !address) {\n throw new Error(`Invalid EVM runtime allowlist entry for chain ${rawChainId}`);\n }\n runtimeAddresses[rawChainId] = address;\n }\n }\n return Object.assign(Object.assign({}, config), { runtimeAddress, runtimeAddresses });\n}\nexport class InjectedEvmWalletProvider {\n constructor(config = {}) {\n this.authenticatedAddress = null;\n if (typeof window === 'undefined') {\n throw new Error('InjectedEvmWalletProvider can only be instantiated in a browser environment');\n }\n const normalized = normalizeConfig(config);\n // Singleton so the SDK reuses one instance (mirrors the other providers).\n if (InjectedEvmWalletProvider.instance) {\n InjectedEvmWalletProvider.instance.config = normalized;\n InjectedEvmWalletProvider.instance.authenticatedAddress = null;\n return InjectedEvmWalletProvider.instance;\n }\n this.config = normalized;\n InjectedEvmWalletProvider.instance = this;\n }\n // @user.address (the Solana wallet) is null for an EVM-wallet login. User.address\n // is typed `string` for legacy reasons — email logins cast the same null the same\n // way (email-auth-provider.ts) — so the null is cast here in one place.\n evmUser(address) {\n return { id: address, address: null, evmAddress: address, provider: this };\n }\n resolveProvider() {\n var _a;\n const provider = (_a = (this.config.getProvider ? this.config.getProvider() : null)) !== null && _a !== void 0 ? _a : defaultInjectedEvmProvider();\n if (!provider)\n throw new Error(NO_WALLET_ERR);\n return provider;\n }\n /** Connect the injected wallet and return its canonical lowercase EVM address. */\n async connectAddress(provider) {\n const accounts = await provider.request({ method: 'eth_requestAccounts' });\n const raw = Array.isArray(accounts) ? accounts[0] : undefined;\n const address = normalizeEvmAddress(raw);\n if (!address)\n throw new Error('Wallet did not return a valid EVM address on connect');\n return address;\n }\n /** Current chain id the wallet is connected to (EIP-155 number), or null. */\n async currentChainId(provider) {\n try {\n const hex = await provider.request({ method: 'eth_chainId' });\n if (typeof hex !== 'string' || !/^0x[0-9a-fA-F]+$/.test(hex))\n return null;\n const n = Number(BigInt(hex));\n return Number.isSafeInteger(n) && n > 0 ? n : null;\n }\n catch (_a) {\n return null;\n }\n }\n async login() {\n var _a;\n setAuthLoading(true);\n try {\n const provider = this.resolveProvider();\n const address = await this.connectAddress(provider);\n // Reuse a still-valid session for THIS wallet.\n const existing = await SessionManager().getSession();\n if (existing && existing.address === address) {\n const user = this.evmUser(address);\n this.authenticatedAddress = address;\n setCurrentUser(user);\n this.markAuthMethod();\n return user;\n }\n // SIWE: nonce -> canonical EIP-4361 prompt -> the wallet personal_sign's it.\n const nonce = await genAuthNonce();\n const appId = (await getConfig()).appId;\n const chainId = (_a = this.config.chainId) !== null && _a !== void 0 ? _a : await this.currentChainId(provider);\n if (chainId === null)\n throw new Error('Could not verify the EVM wallet chain for SIWE login');\n const message = genSiweMessage(address, nonce, appId, this.resolveDomain(), this.resolveUri(), { chainId });\n // personal_sign(message, address) -> 0x r‖s‖v hex (the shape the\n // bounded-auth verifier's recoverSiweSigner consumes). The raw UTF-8\n // message is signed under the EIP-191 envelope the verifier hashes.\n const signature = await provider.request({\n method: 'personal_sign',\n params: [message, address],\n });\n const result = await createSessionWithSignature(address, message, signature, SIWE_SESSION_METHOD);\n await SessionManager().storeSession(address, result.accessToken, result.idToken, result.refreshToken);\n this.markAuthMethod();\n const user = this.evmUser(address);\n this.authenticatedAddress = address;\n setCurrentUser(user);\n return user;\n }\n finally {\n setAuthLoading(false);\n }\n }\n resolveDomain() {\n const actual = window.location.host.toLowerCase();\n if (this.config.domain && this.config.domain.toLowerCase() !== actual) {\n throw new Error('SIWE domain override must match the current browser origin');\n }\n return actual;\n }\n resolveUri() {\n const actual = window.location.origin.toLowerCase();\n if (this.config.uri) {\n let configured;\n try {\n configured = new URL(this.config.uri).origin.toLowerCase();\n }\n catch (_a) {\n throw new Error('SIWE URI override must be an absolute URL');\n }\n if (configured !== actual)\n throw new Error('SIWE URI override must match the current browser origin');\n }\n return actual;\n }\n markAuthMethod() {\n try {\n getPlatform().storage.setItem(STORED_AUTH_METHOD_KEY, INJECTED_EVM_AUTH_METHOD);\n }\n catch ( /* no storage */_a) { /* no storage */ }\n }\n async restoreSession() {\n const session = await SessionManager().getSession();\n if (!session)\n return null;\n // An EVM-wallet session stores the EVM address as its address; @user.address\n // (the Solana wallet) is null for this login.\n const address = normalizeEvmAddress(session.address);\n if (!address) {\n SessionManager().clearSession();\n return null;\n }\n this.authenticatedAddress = address;\n const user = this.evmUser(address);\n setCurrentUser(user);\n return user;\n }\n async logout() {\n // EIP-1193 has no standard disconnect; clearing the Bounded session is the\n // logout. (wallet_revokePermissions is non-standard/opt-in — skip it.)\n SessionManager().clearSession();\n this.authenticatedAddress = null;\n setCurrentUser(null);\n }\n // --- Signing surface -------------------------------------------------------\n /** App-facing message signing: EIP-191 personal_sign, returns 0x r‖s‖v hex. */\n async signMessage(message) {\n const provider = this.resolveProvider();\n const address = await this.connectAddress(provider);\n if (!this.authenticatedAddress || address !== this.authenticatedAddress) {\n throw new Error('The connected EVM wallet account changed after login. Sign in again before signing.');\n }\n return provider.request({ method: 'personal_sign', params: [message, address] });\n }\n // Solana-typed methods are structurally unsupported on an EVM wallet — the\n // EVM onchain write goes through runTransaction (eth_sendTransaction).\n async signTransaction(_transaction) {\n throw new Error(NO_SOL_TX_ERR);\n }\n async signAndSubmitTransaction(_transaction, _feePayer) {\n throw new Error(NO_SOL_TX_ERR);\n }\n /**\n * Onchain write path: submit the worker's PRE-BUILT EIP-1559 tx via\n * eth_sendTransaction (the injected wallet signs + submits in one step), then\n * poll for the receipt. The EVM branch of operations.ts's 202 dispatch calls\n * this with the pre-built payload in the EVM slot and the Solana slot undefined.\n */\n async runTransaction(evmTransactionData, solTransactionData, options) {\n var _a, _b, _c;\n const evmTx = evmTransactionData;\n if (evmTx && solTransactionData) {\n throw new Error('A transaction cannot target EVM and Solana at the same time.');\n }\n if (!evmTx || !normalizeEvmAddress(evmTx.to) || typeof evmTx.data !== 'string' || !/^0x(?:[0-9a-fA-F]{2})+$/.test(evmTx.data)) {\n throw new Error('EVM transaction data (pre-built { to, data, chainId }) is required for an EVM onchain write');\n }\n // Exact decode, rather than a four-byte prefix check: permits the\n // ordinary and attested document-write entrypoints while rejecting\n // malformed/trailing calldata before the wallet sees a signing prompt.\n assertCanonicalBoundedRuntimeWriteCalldata(evmTx.data);\n if (!Number.isSafeInteger(evmTx.chainId) || evmTx.chainId <= 0) {\n throw new Error('EVM transaction chainId is required and must be a positive safe integer');\n }\n const chainId = evmTx.chainId;\n const trustedRuntime = (_b = (_a = this.config.runtimeAddresses) === null || _a === void 0 ? void 0 : _a[String(chainId)]) !== null && _b !== void 0 ? _b : (this.config.chainId === chainId ? this.config.runtimeAddress : undefined);\n if (!trustedRuntime)\n throw new Error(`No trusted BoundedRuntime address configured for EVM chain ${chainId}`);\n if (normalizeEvmAddress(evmTx.to) !== trustedRuntime) {\n throw new Error('EVM transaction target is not the configured BoundedRuntime');\n }\n if (evmTx.nonce !== undefined) {\n throw new Error('Server-supplied EVM nonces are not accepted');\n }\n try {\n if (BigInt((_c = evmTx.value) !== null && _c !== void 0 ? _c : '0') !== BigInt(0)) {\n throw new Error('BoundedRuntime.setDocuments cannot transfer native value');\n }\n }\n catch (error) {\n if (error instanceof Error && error.message.includes('cannot transfer'))\n throw error;\n throw new Error('Invalid EVM transaction value');\n }\n if ((options === null || options === void 0 ? void 0 : options.shouldSubmitTx) === false) {\n // Injected EVM wallets sign+submit atomically; eth_signTransaction is not\n // broadly supported (MetaMask removed it), so we cannot return a signed-\n // but-unsubmitted tx here. Fail clearly instead of silently submitting.\n throw new Error('shouldSubmitTx:false is unsupported for injected EVM wallets (they sign and submit atomically).');\n }\n const provider = this.resolveProvider();\n const from = await this.connectAddress(provider);\n if (!this.authenticatedAddress || from !== this.authenticatedAddress) {\n throw new Error('The connected EVM wallet account changed after login. Sign in again before submitting this write.');\n }\n // Chain-switch guard: the pre-built tx names the chain it MUST execute on.\n if (typeof evmTx.chainId === 'number') {\n const current = await this.currentChainId(provider);\n if (current === null)\n throw new Error('Could not verify the EVM wallet chain; refusing to submit the transaction.');\n if (current !== evmTx.chainId) {\n const targetHex = '0x' + evmTx.chainId.toString(16);\n try {\n await provider.request({\n method: 'wallet_switchEthereumChain',\n params: [{ chainId: targetHex }],\n });\n }\n catch (err) {\n throw new Error(`EVM wallet is on chain ${current} but this write targets chain ${evmTx.chainId}, ` +\n `and the chain switch was rejected or failed${(err === null || err === void 0 ? void 0 : err.message) ? `: ${err.message}` : ''}. ` +\n `Switch your wallet to chain ${evmTx.chainId} and retry.`);\n }\n const switched = await this.currentChainId(provider);\n if (switched !== evmTx.chainId) {\n throw new Error(`EVM wallet did not switch to required chain ${evmTx.chainId}; refusing to submit.`);\n }\n }\n }\n const txParams = { from, to: normalizeEvmAddress(evmTx.to), data: evmTx.data.toLowerCase() };\n txParams.value = '0x0';\n // Gas, fee and nonce hints come from the server and are not part of the\n // governed action. Deliberately omit them: the wallet estimates locally,\n // preventing a compromised response from forcing an abusive fee/nonce.\n const txHash = await provider.request({\n method: 'eth_sendTransaction',\n params: [txParams],\n });\n if (typeof txHash !== 'string' || !/^0x[0-9a-fA-F]{64}$/.test(txHash)) {\n throw new Error('EVM wallet returned an invalid transaction hash');\n }\n const receipt = await this.waitForReceipt(provider, txHash);\n if (!receipt || typeof receipt.status !== 'string' || !/^0x[0-9a-fA-F]+$/.test(receipt.status)) {\n throw new Error(`EVM transaction ${txHash} returned an invalid receipt status`);\n }\n if (BigInt(receipt.status) !== BigInt(1)) {\n throw new Error(`EVM transaction ${txHash} reverted on-chain`);\n }\n if (typeof receipt.blockNumber !== 'string' || !/^0x[0-9a-fA-F]+$/.test(receipt.blockNumber)) {\n throw new Error(`EVM transaction ${txHash} returned an invalid block number`);\n }\n const blockNumber = BigInt(receipt.blockNumber);\n if (blockNumber > BigInt(Number.MAX_SAFE_INTEGER))\n throw new Error('EVM receipt block number exceeds the SDK safe-integer range');\n if (typeof receipt.gasUsed !== 'string' || !/^0x[0-9a-fA-F]+$/.test(receipt.gasUsed)) {\n throw new Error(`EVM transaction ${txHash} returned invalid gas usage`);\n }\n return {\n transactionSignature: txHash,\n blockNumber: Number(blockNumber),\n gasUsed: BigInt(receipt.gasUsed).toString(),\n data: receipt,\n };\n }\n /** Poll eth_getTransactionReceipt until it lands (bounded retries) or throw. */\n async waitForReceipt(provider, txHash) {\n for (let attempt = 0; attempt < RECEIPT_POLL_ATTEMPTS; attempt++) {\n const receipt = await provider.request({\n method: 'eth_getTransactionReceipt',\n params: [txHash],\n });\n if (receipt)\n return receipt;\n await new Promise((r) => setTimeout(r, RECEIPT_POLL_INTERVAL_MS));\n }\n throw new Error(`EVM transaction ${txHash} was submitted but no receipt confirmed within ` +\n `${(RECEIPT_POLL_ATTEMPTS * RECEIPT_POLL_INTERVAL_MS) / 1000}s. It may still land; check the explorer.`);\n }\n async getNativeMethods() {\n return this.resolveProvider();\n }\n}\nInjectedEvmWalletProvider.instance = null;\n"],"names":["normalizeEvmAddress","defaultInjectedEvmProvider","setAuthLoading","SessionManager","setCurrentUser","genAuthNonce","getConfig","genSiweMessage","createSessionWithSignature","getPlatform","assertCanonicalBoundedRuntimeWriteCalldata"],"mappings":";;;;;;AAOA,MAAM,sBAAsB,GAAG,0BAA0B;AACzD;AACA;AACA,MAAM,wBAAwB,GAAG,YAAY;AAC7C;AACA,MAAM,mBAAmB,GAAG,MAAM;AAClC,MAAM,aAAa,GAAG,qGAAqG;AAC3H,IAAI,qEAAqE;AACzE,MAAM,aAAa,GAAG,kGAAkG;AACxH,IAAI,mGAAmG;AACvG,IAAI,+EAA+E;AACnF;AACA,MAAM,qBAAqB,GAAG,EAAE;AAChC,MAAM,wBAAwB,GAAG,IAAI;AACrC,SAAS,eAAe,CAAC,MAAM,EAAE;AACjC,IAAI,IAAI,EAAE;AACV,IAAI,IAAI,MAAM,CAAC,OAAO,KAAK,SAAS,KAAK,CAAC,MAAM,CAAC,aAAa,CAAC,MAAM,CAAC,OAAO,CAAC,IAAI,MAAM,CAAC,OAAO,IAAI,CAAC,CAAC,EAAE;AACxG,QAAQ,MAAM,IAAI,KAAK,CAAC,oDAAoD,CAAC;AAC7E,IAAI;AACJ,IAAI,IAAI,cAAc;AACtB,IAAI,IAAI,MAAM,CAAC,cAAc,KAAK,SAAS,EAAE;AAC7C,QAAQ,cAAc,GAAG,CAAC,EAAE,GAAGA,wBAAmB,CAAC,MAAM,CAAC,cAAc,CAAC,MAAM,IAAI,IAAI,EAAE,KAAK,MAAM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