@pooflabs/web 0.0.71 → 0.0.72
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/dist/{index-DFBVGK4A.js → index-CJuG7364.js} +2 -2
- package/dist/{index-DFBVGK4A.js.map → index-CJuG7364.js.map} +1 -1
- package/dist/{index-BpxspB4P.js → index-CMTlhmPS.js} +5 -4
- package/dist/{index-BpxspB4P.js.map → index-CMTlhmPS.js.map} +1 -1
- package/dist/{index-BEFBhDYr.esm.js → index-Crc3B1ZK.esm.js} +2 -2
- package/dist/{index-BEFBhDYr.esm.js.map → index-Crc3B1ZK.esm.js.map} +1 -1
- package/dist/{index-CIsuR4Ki.esm.js → index-u0Q8zhkj.esm.js} +5 -5
- package/dist/{index-CIsuR4Ki.esm.js.map → index-u0Q8zhkj.esm.js.map} +1 -1
- package/dist/index.browser-BOJRGZWX.js +1167 -0
- package/dist/index.browser-BOJRGZWX.js.map +1 -0
- package/dist/index.browser-C6e2ssNC.esm.js +4867 -0
- package/dist/index.browser-C6e2ssNC.esm.js.map +1 -0
- package/dist/index.browser-CPRwXOyN.js +311 -0
- package/dist/index.browser-CPRwXOyN.js.map +1 -0
- package/dist/index.browser-DZjyUgtx.esm.js +1164 -0
- package/dist/index.browser-DZjyUgtx.esm.js.map +1 -0
- package/dist/index.browser-DjDHEvuF.esm.js +308 -0
- package/dist/index.browser-DjDHEvuF.esm.js.map +1 -0
- package/dist/index.browser-jwxjZVpT.js +4877 -0
- package/dist/index.browser-jwxjZVpT.js.map +1 -0
- package/dist/index.esm.js +1 -1
- package/dist/index.js +1 -1
- package/package.json +4 -15
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.browser-BOJRGZWX.js","sources":["../node_modules/@solana/wallet-standard-util/lib/esm/signIn.js","../node_modules/@solana-mobile/mobile-wallet-adapter-protocol/node_modules/@solana/codecs-core/dist/index.browser.mjs","../node_modules/@solana-mobile/mobile-wallet-adapter-protocol/node_modules/@solana/codecs-strings/dist/index.browser.mjs","../node_modules/@solana-mobile/mobile-wallet-adapter-protocol/lib/esm/index.browser.js"],"sourcesContent":["import { verifyMessageSignature } from './signMessage.js';\nimport { arraysEqual } from './util.js';\n/**\n * TODO: docs\n */\nexport function verifySignIn(input, output) {\n const { signedMessage, signature, account: { publicKey }, } = output;\n const message = deriveSignInMessage(input, output);\n return (!!message && verifyMessageSignature({ message, signedMessage, signature, publicKey: publicKey }));\n}\n/**\n * TODO: docs\n */\nexport function deriveSignInMessage(input, output) {\n const text = deriveSignInMessageText(input, output);\n if (!text)\n return null;\n return new TextEncoder().encode(text);\n}\n/**\n * TODO: docs\n */\nexport function deriveSignInMessageText(input, output) {\n const parsed = parseSignInMessage(output.signedMessage);\n if (!parsed)\n return null;\n if (input.domain && input.domain !== parsed.domain)\n return null;\n if (input.address && input.address !== parsed.address)\n return null;\n if (input.statement !== parsed.statement)\n return null;\n if (input.uri !== parsed.uri)\n return null;\n if (input.version !== parsed.version)\n return null;\n if (input.chainId !== parsed.chainId)\n return null;\n if (input.nonce !== parsed.nonce)\n return null;\n if (input.issuedAt !== parsed.issuedAt)\n return null;\n if (input.expirationTime !== parsed.expirationTime)\n return null;\n if (input.notBefore !== parsed.notBefore)\n return null;\n if (input.requestId !== parsed.requestId)\n return null;\n if (input.resources) {\n if (!parsed.resources)\n return null;\n if (!arraysEqual(input.resources, parsed.resources))\n return null;\n }\n else if (parsed.resources)\n return null;\n return createSignInMessageText(parsed);\n}\n/**\n * TODO: docs\n */\nexport function parseSignInMessage(message) {\n const text = new TextDecoder().decode(message);\n return parseSignInMessageText(text);\n}\n// TODO: implement https://github.com/solana-labs/solana/blob/master/docs/src/proposals/off-chain-message-signing.md\nconst DOMAIN = '(?<domain>[^\\\\n]+?) wants you to sign in with your Solana account:\\\\n';\nconst ADDRESS = '(?<address>[^\\\\n]+)(?:\\\\n|$)';\nconst STATEMENT = '(?:\\\\n(?<statement>[\\\\S\\\\s]*?)(?:\\\\n|$))??';\nconst URI = '(?:\\\\nURI: (?<uri>[^\\\\n]+))?';\nconst VERSION = '(?:\\\\nVersion: (?<version>[^\\\\n]+))?';\nconst CHAIN_ID = '(?:\\\\nChain ID: (?<chainId>[^\\\\n]+))?';\nconst NONCE = '(?:\\\\nNonce: (?<nonce>[^\\\\n]+))?';\nconst ISSUED_AT = '(?:\\\\nIssued At: (?<issuedAt>[^\\\\n]+))?';\nconst EXPIRATION_TIME = '(?:\\\\nExpiration Time: (?<expirationTime>[^\\\\n]+))?';\nconst NOT_BEFORE = '(?:\\\\nNot Before: (?<notBefore>[^\\\\n]+))?';\nconst REQUEST_ID = '(?:\\\\nRequest ID: (?<requestId>[^\\\\n]+))?';\nconst RESOURCES = '(?:\\\\nResources:(?<resources>(?:\\\\n- [^\\\\n]+)*))?';\nconst FIELDS = `${URI}${VERSION}${CHAIN_ID}${NONCE}${ISSUED_AT}${EXPIRATION_TIME}${NOT_BEFORE}${REQUEST_ID}${RESOURCES}`;\nconst MESSAGE = new RegExp(`^${DOMAIN}${ADDRESS}${STATEMENT}${FIELDS}\\\\n*$`);\n/**\n * TODO: docs\n */\nexport function parseSignInMessageText(text) {\n const match = MESSAGE.exec(text);\n if (!match)\n return null;\n const groups = match.groups;\n if (!groups)\n return null;\n return {\n domain: groups.domain,\n address: groups.address,\n statement: groups.statement,\n uri: groups.uri,\n version: groups.version,\n nonce: groups.nonce,\n chainId: groups.chainId,\n issuedAt: groups.issuedAt,\n expirationTime: groups.expirationTime,\n notBefore: groups.notBefore,\n requestId: groups.requestId,\n resources: groups.resources?.split('\\n- ').slice(1),\n };\n}\n/**\n * TODO: docs\n */\nexport function createSignInMessage(input) {\n const text = createSignInMessageText(input);\n return new TextEncoder().encode(text);\n}\n/**\n * TODO: docs\n */\nexport function createSignInMessageText(input) {\n // ${domain} wants you to sign in with your Solana account:\n // ${address}\n //\n // ${statement}\n //\n // URI: ${uri}\n // Version: ${version}\n // Chain ID: ${chain}\n // Nonce: ${nonce}\n // Issued At: ${issued-at}\n // Expiration Time: ${expiration-time}\n // Not Before: ${not-before}\n // Request ID: ${request-id}\n // Resources:\n // - ${resources[0]}\n // - ${resources[1]}\n // ...\n // - ${resources[n]}\n let message = `${input.domain} wants you to sign in with your Solana account:\\n`;\n message += `${input.address}`;\n if (input.statement) {\n message += `\\n\\n${input.statement}`;\n }\n const fields = [];\n if (input.uri) {\n fields.push(`URI: ${input.uri}`);\n }\n if (input.version) {\n fields.push(`Version: ${input.version}`);\n }\n if (input.chainId) {\n fields.push(`Chain ID: ${input.chainId}`);\n }\n if (input.nonce) {\n fields.push(`Nonce: ${input.nonce}`);\n }\n if (input.issuedAt) {\n fields.push(`Issued At: ${input.issuedAt}`);\n }\n if (input.expirationTime) {\n fields.push(`Expiration Time: ${input.expirationTime}`);\n }\n if (input.notBefore) {\n fields.push(`Not Before: ${input.notBefore}`);\n }\n if (input.requestId) {\n fields.push(`Request ID: ${input.requestId}`);\n }\n if (input.resources) {\n fields.push(`Resources:`);\n for (const resource of input.resources) {\n fields.push(`- ${resource}`);\n }\n }\n if (fields.length) {\n message += `\\n\\n${fields.join('\\n')}`;\n }\n return message;\n}\n//# sourceMappingURL=signIn.js.map","import { SolanaError, SOLANA_ERROR__CODECS__EXPECTED_FIXED_LENGTH, SOLANA_ERROR__CODECS__EXPECTED_VARIABLE_LENGTH, SOLANA_ERROR__CODECS__ENCODER_DECODER_SIZE_COMPATIBILITY_MISMATCH, SOLANA_ERROR__CODECS__ENCODER_DECODER_FIXED_SIZE_MISMATCH, SOLANA_ERROR__CODECS__ENCODER_DECODER_MAX_SIZE_MISMATCH, SOLANA_ERROR__CODECS__CANNOT_DECODE_EMPTY_BYTE_ARRAY, SOLANA_ERROR__CODECS__INVALID_BYTE_LENGTH, SOLANA_ERROR__CODECS__OFFSET_OUT_OF_RANGE, SOLANA_ERROR__CODECS__EXPECTED_DECODER_TO_CONSUME_ENTIRE_BYTE_ARRAY, SOLANA_ERROR__CODECS__EXPECTED_POSITIVE_BYTE_LENGTH, SOLANA_ERROR__CODECS__SENTINEL_MISSING_IN_DECODED_BYTES, SOLANA_ERROR__CODECS__ENCODED_BYTES_MUST_NOT_INCLUDE_SENTINEL } from '@solana/errors';\n\n// src/add-codec-sentinel.ts\n\n// src/bytes.ts\nvar mergeBytes = (byteArrays) => {\n const nonEmptyByteArrays = byteArrays.filter((arr) => arr.length);\n if (nonEmptyByteArrays.length === 0) {\n return byteArrays.length ? byteArrays[0] : new Uint8Array();\n }\n if (nonEmptyByteArrays.length === 1) {\n return nonEmptyByteArrays[0];\n }\n const totalLength = nonEmptyByteArrays.reduce((total, arr) => total + arr.length, 0);\n const result = new Uint8Array(totalLength);\n let offset = 0;\n nonEmptyByteArrays.forEach((arr) => {\n result.set(arr, offset);\n offset += arr.length;\n });\n return result;\n};\nfunction padBytes(bytes, length) {\n if (bytes.length >= length) return bytes;\n const paddedBytes = new Uint8Array(length).fill(0);\n paddedBytes.set(bytes);\n return paddedBytes;\n}\nvar fixBytes = (bytes, length) => padBytes(bytes.length <= length ? bytes : bytes.slice(0, length), length);\nfunction containsBytes(data, bytes, offset) {\n const slice = offset === 0 && data.length === bytes.length ? data : data.slice(offset, offset + bytes.length);\n if (slice.length !== bytes.length) return false;\n return bytes.every((b, i) => b === slice[i]);\n}\nfunction getEncodedSize(value, encoder) {\n return \"fixedSize\" in encoder ? encoder.fixedSize : encoder.getSizeFromValue(value);\n}\nfunction createEncoder(encoder) {\n return Object.freeze({\n ...encoder,\n encode: (value) => {\n const bytes = new Uint8Array(getEncodedSize(value, encoder));\n encoder.write(value, bytes, 0);\n return bytes;\n }\n });\n}\nfunction createDecoder(decoder) {\n return Object.freeze({\n ...decoder,\n decode: (bytes, offset = 0) => decoder.read(bytes, offset)[0]\n });\n}\nfunction createCodec(codec) {\n return Object.freeze({\n ...codec,\n decode: (bytes, offset = 0) => codec.read(bytes, offset)[0],\n encode: (value) => {\n const bytes = new Uint8Array(getEncodedSize(value, codec));\n codec.write(value, bytes, 0);\n return bytes;\n }\n });\n}\nfunction isFixedSize(codec) {\n return \"fixedSize\" in codec && typeof codec.fixedSize === \"number\";\n}\nfunction assertIsFixedSize(codec) {\n if (!isFixedSize(codec)) {\n throw new SolanaError(SOLANA_ERROR__CODECS__EXPECTED_FIXED_LENGTH);\n }\n}\nfunction isVariableSize(codec) {\n return !isFixedSize(codec);\n}\nfunction assertIsVariableSize(codec) {\n if (!isVariableSize(codec)) {\n throw new SolanaError(SOLANA_ERROR__CODECS__EXPECTED_VARIABLE_LENGTH);\n }\n}\nfunction combineCodec(encoder, decoder) {\n if (isFixedSize(encoder) !== isFixedSize(decoder)) {\n throw new SolanaError(SOLANA_ERROR__CODECS__ENCODER_DECODER_SIZE_COMPATIBILITY_MISMATCH);\n }\n if (isFixedSize(encoder) && isFixedSize(decoder) && encoder.fixedSize !== decoder.fixedSize) {\n throw new SolanaError(SOLANA_ERROR__CODECS__ENCODER_DECODER_FIXED_SIZE_MISMATCH, {\n decoderFixedSize: decoder.fixedSize,\n encoderFixedSize: encoder.fixedSize\n });\n }\n if (!isFixedSize(encoder) && !isFixedSize(decoder) && encoder.maxSize !== decoder.maxSize) {\n throw new SolanaError(SOLANA_ERROR__CODECS__ENCODER_DECODER_MAX_SIZE_MISMATCH, {\n decoderMaxSize: decoder.maxSize,\n encoderMaxSize: encoder.maxSize\n });\n }\n return {\n ...decoder,\n ...encoder,\n decode: decoder.decode,\n encode: encoder.encode,\n read: decoder.read,\n write: encoder.write\n };\n}\n\n// src/add-codec-sentinel.ts\nfunction addEncoderSentinel(encoder, sentinel) {\n const write = (value, bytes, offset) => {\n const encoderBytes = encoder.encode(value);\n if (findSentinelIndex(encoderBytes, sentinel) >= 0) {\n throw new SolanaError(SOLANA_ERROR__CODECS__ENCODED_BYTES_MUST_NOT_INCLUDE_SENTINEL, {\n encodedBytes: encoderBytes,\n hexEncodedBytes: hexBytes(encoderBytes),\n hexSentinel: hexBytes(sentinel),\n sentinel\n });\n }\n bytes.set(encoderBytes, offset);\n offset += encoderBytes.length;\n bytes.set(sentinel, offset);\n offset += sentinel.length;\n return offset;\n };\n if (isFixedSize(encoder)) {\n return createEncoder({ ...encoder, fixedSize: encoder.fixedSize + sentinel.length, write });\n }\n return createEncoder({\n ...encoder,\n ...encoder.maxSize != null ? { maxSize: encoder.maxSize + sentinel.length } : {},\n getSizeFromValue: (value) => encoder.getSizeFromValue(value) + sentinel.length,\n write\n });\n}\nfunction addDecoderSentinel(decoder, sentinel) {\n const read = (bytes, offset) => {\n const candidateBytes = offset === 0 ? bytes : bytes.slice(offset);\n const sentinelIndex = findSentinelIndex(candidateBytes, sentinel);\n if (sentinelIndex === -1) {\n throw new SolanaError(SOLANA_ERROR__CODECS__SENTINEL_MISSING_IN_DECODED_BYTES, {\n decodedBytes: candidateBytes,\n hexDecodedBytes: hexBytes(candidateBytes),\n hexSentinel: hexBytes(sentinel),\n sentinel\n });\n }\n const preSentinelBytes = candidateBytes.slice(0, sentinelIndex);\n return [decoder.decode(preSentinelBytes), offset + preSentinelBytes.length + sentinel.length];\n };\n if (isFixedSize(decoder)) {\n return createDecoder({ ...decoder, fixedSize: decoder.fixedSize + sentinel.length, read });\n }\n return createDecoder({\n ...decoder,\n ...decoder.maxSize != null ? { maxSize: decoder.maxSize + sentinel.length } : {},\n read\n });\n}\nfunction addCodecSentinel(codec, sentinel) {\n return combineCodec(addEncoderSentinel(codec, sentinel), addDecoderSentinel(codec, sentinel));\n}\nfunction findSentinelIndex(bytes, sentinel) {\n return bytes.findIndex((byte, index, arr) => {\n if (sentinel.length === 1) return byte === sentinel[0];\n return containsBytes(arr, sentinel, index);\n });\n}\nfunction hexBytes(bytes) {\n return bytes.reduce((str, byte) => str + byte.toString(16).padStart(2, \"0\"), \"\");\n}\nfunction assertByteArrayIsNotEmptyForCodec(codecDescription, bytes, offset = 0) {\n if (bytes.length - offset <= 0) {\n throw new SolanaError(SOLANA_ERROR__CODECS__CANNOT_DECODE_EMPTY_BYTE_ARRAY, {\n codecDescription\n });\n }\n}\nfunction assertByteArrayHasEnoughBytesForCodec(codecDescription, expected, bytes, offset = 0) {\n const bytesLength = bytes.length - offset;\n if (bytesLength < expected) {\n throw new SolanaError(SOLANA_ERROR__CODECS__INVALID_BYTE_LENGTH, {\n bytesLength,\n codecDescription,\n expected\n });\n }\n}\nfunction assertByteArrayOffsetIsNotOutOfRange(codecDescription, offset, bytesLength) {\n if (offset < 0 || offset > bytesLength) {\n throw new SolanaError(SOLANA_ERROR__CODECS__OFFSET_OUT_OF_RANGE, {\n bytesLength,\n codecDescription,\n offset\n });\n }\n}\n\n// src/add-codec-size-prefix.ts\nfunction addEncoderSizePrefix(encoder, prefix) {\n const write = (value, bytes, offset) => {\n const encoderBytes = encoder.encode(value);\n offset = prefix.write(encoderBytes.length, bytes, offset);\n bytes.set(encoderBytes, offset);\n return offset + encoderBytes.length;\n };\n if (isFixedSize(prefix) && isFixedSize(encoder)) {\n return createEncoder({ ...encoder, fixedSize: prefix.fixedSize + encoder.fixedSize, write });\n }\n const prefixMaxSize = isFixedSize(prefix) ? prefix.fixedSize : prefix.maxSize ?? null;\n const encoderMaxSize = isFixedSize(encoder) ? encoder.fixedSize : encoder.maxSize ?? null;\n const maxSize = prefixMaxSize !== null && encoderMaxSize !== null ? prefixMaxSize + encoderMaxSize : null;\n return createEncoder({\n ...encoder,\n ...maxSize !== null ? { maxSize } : {},\n getSizeFromValue: (value) => {\n const encoderSize = getEncodedSize(value, encoder);\n return getEncodedSize(encoderSize, prefix) + encoderSize;\n },\n write\n });\n}\nfunction addDecoderSizePrefix(decoder, prefix) {\n const read = (bytes, offset) => {\n const [bigintSize, decoderOffset] = prefix.read(bytes, offset);\n const size = Number(bigintSize);\n offset = decoderOffset;\n if (offset > 0 || bytes.length > size) {\n bytes = bytes.slice(offset, offset + size);\n }\n assertByteArrayHasEnoughBytesForCodec(\"addDecoderSizePrefix\", size, bytes);\n return [decoder.decode(bytes), offset + size];\n };\n if (isFixedSize(prefix) && isFixedSize(decoder)) {\n return createDecoder({ ...decoder, fixedSize: prefix.fixedSize + decoder.fixedSize, read });\n }\n const prefixMaxSize = isFixedSize(prefix) ? prefix.fixedSize : prefix.maxSize ?? null;\n const decoderMaxSize = isFixedSize(decoder) ? decoder.fixedSize : decoder.maxSize ?? null;\n const maxSize = prefixMaxSize !== null && decoderMaxSize !== null ? prefixMaxSize + decoderMaxSize : null;\n return createDecoder({ ...decoder, ...maxSize !== null ? { maxSize } : {}, read });\n}\nfunction addCodecSizePrefix(codec, prefix) {\n return combineCodec(addEncoderSizePrefix(codec, prefix), addDecoderSizePrefix(codec, prefix));\n}\nfunction createDecoderThatConsumesEntireByteArray(decoder) {\n return createDecoder({\n ...decoder,\n read(bytes, offset) {\n const [value, newOffset] = decoder.read(bytes, offset);\n if (bytes.length > newOffset) {\n throw new SolanaError(SOLANA_ERROR__CODECS__EXPECTED_DECODER_TO_CONSUME_ENTIRE_BYTE_ARRAY, {\n expectedLength: newOffset,\n numExcessBytes: bytes.length - newOffset\n });\n }\n return [value, newOffset];\n }\n });\n}\n\n// src/fix-codec-size.ts\nfunction fixEncoderSize(encoder, fixedBytes) {\n return createEncoder({\n fixedSize: fixedBytes,\n write: (value, bytes, offset) => {\n const variableByteArray = encoder.encode(value);\n const fixedByteArray = variableByteArray.length > fixedBytes ? variableByteArray.slice(0, fixedBytes) : variableByteArray;\n bytes.set(fixedByteArray, offset);\n return offset + fixedBytes;\n }\n });\n}\nfunction fixDecoderSize(decoder, fixedBytes) {\n return createDecoder({\n fixedSize: fixedBytes,\n read: (bytes, offset) => {\n assertByteArrayHasEnoughBytesForCodec(\"fixCodecSize\", fixedBytes, bytes, offset);\n if (offset > 0 || bytes.length > fixedBytes) {\n bytes = bytes.slice(offset, offset + fixedBytes);\n }\n if (isFixedSize(decoder)) {\n bytes = fixBytes(bytes, decoder.fixedSize);\n }\n const [value] = decoder.read(bytes, 0);\n return [value, offset + fixedBytes];\n }\n });\n}\nfunction fixCodecSize(codec, fixedBytes) {\n return combineCodec(fixEncoderSize(codec, fixedBytes), fixDecoderSize(codec, fixedBytes));\n}\n\n// src/offset-codec.ts\nfunction offsetEncoder(encoder, config) {\n return createEncoder({\n ...encoder,\n write: (value, bytes, preOffset) => {\n const wrapBytes = (offset) => modulo(offset, bytes.length);\n const newPreOffset = config.preOffset ? config.preOffset({ bytes, preOffset, wrapBytes }) : preOffset;\n assertByteArrayOffsetIsNotOutOfRange(\"offsetEncoder\", newPreOffset, bytes.length);\n const postOffset = encoder.write(value, bytes, newPreOffset);\n const newPostOffset = config.postOffset ? config.postOffset({ bytes, newPreOffset, postOffset, preOffset, wrapBytes }) : postOffset;\n assertByteArrayOffsetIsNotOutOfRange(\"offsetEncoder\", newPostOffset, bytes.length);\n return newPostOffset;\n }\n });\n}\nfunction offsetDecoder(decoder, config) {\n return createDecoder({\n ...decoder,\n read: (bytes, preOffset) => {\n const wrapBytes = (offset) => modulo(offset, bytes.length);\n const newPreOffset = config.preOffset ? config.preOffset({ bytes, preOffset, wrapBytes }) : preOffset;\n assertByteArrayOffsetIsNotOutOfRange(\"offsetDecoder\", newPreOffset, bytes.length);\n const [value, postOffset] = decoder.read(bytes, newPreOffset);\n const newPostOffset = config.postOffset ? config.postOffset({ bytes, newPreOffset, postOffset, preOffset, wrapBytes }) : postOffset;\n assertByteArrayOffsetIsNotOutOfRange(\"offsetDecoder\", newPostOffset, bytes.length);\n return [value, newPostOffset];\n }\n });\n}\nfunction offsetCodec(codec, config) {\n return combineCodec(offsetEncoder(codec, config), offsetDecoder(codec, config));\n}\nfunction modulo(dividend, divisor) {\n if (divisor === 0) return 0;\n return (dividend % divisor + divisor) % divisor;\n}\nfunction resizeEncoder(encoder, resize) {\n if (isFixedSize(encoder)) {\n const fixedSize = resize(encoder.fixedSize);\n if (fixedSize < 0) {\n throw new SolanaError(SOLANA_ERROR__CODECS__EXPECTED_POSITIVE_BYTE_LENGTH, {\n bytesLength: fixedSize,\n codecDescription: \"resizeEncoder\"\n });\n }\n return createEncoder({ ...encoder, fixedSize });\n }\n return createEncoder({\n ...encoder,\n getSizeFromValue: (value) => {\n const newSize = resize(encoder.getSizeFromValue(value));\n if (newSize < 0) {\n throw new SolanaError(SOLANA_ERROR__CODECS__EXPECTED_POSITIVE_BYTE_LENGTH, {\n bytesLength: newSize,\n codecDescription: \"resizeEncoder\"\n });\n }\n return newSize;\n }\n });\n}\nfunction resizeDecoder(decoder, resize) {\n if (isFixedSize(decoder)) {\n const fixedSize = resize(decoder.fixedSize);\n if (fixedSize < 0) {\n throw new SolanaError(SOLANA_ERROR__CODECS__EXPECTED_POSITIVE_BYTE_LENGTH, {\n bytesLength: fixedSize,\n codecDescription: \"resizeDecoder\"\n });\n }\n return createDecoder({ ...decoder, fixedSize });\n }\n return decoder;\n}\nfunction resizeCodec(codec, resize) {\n return combineCodec(resizeEncoder(codec, resize), resizeDecoder(codec, resize));\n}\n\n// src/pad-codec.ts\nfunction padLeftEncoder(encoder, offset) {\n return offsetEncoder(\n resizeEncoder(encoder, (size) => size + offset),\n { preOffset: ({ preOffset }) => preOffset + offset }\n );\n}\nfunction padRightEncoder(encoder, offset) {\n return offsetEncoder(\n resizeEncoder(encoder, (size) => size + offset),\n { postOffset: ({ postOffset }) => postOffset + offset }\n );\n}\nfunction padLeftDecoder(decoder, offset) {\n return offsetDecoder(\n resizeDecoder(decoder, (size) => size + offset),\n { preOffset: ({ preOffset }) => preOffset + offset }\n );\n}\nfunction padRightDecoder(decoder, offset) {\n return offsetDecoder(\n resizeDecoder(decoder, (size) => size + offset),\n { postOffset: ({ postOffset }) => postOffset + offset }\n );\n}\nfunction padLeftCodec(codec, offset) {\n return combineCodec(padLeftEncoder(codec, offset), padLeftDecoder(codec, offset));\n}\nfunction padRightCodec(codec, offset) {\n return combineCodec(padRightEncoder(codec, offset), padRightDecoder(codec, offset));\n}\n\n// src/reverse-codec.ts\nfunction copySourceToTargetInReverse(source, target_WILL_MUTATE, sourceOffset, sourceLength, targetOffset = 0) {\n while (sourceOffset < --sourceLength) {\n const leftValue = source[sourceOffset];\n target_WILL_MUTATE[sourceOffset + targetOffset] = source[sourceLength];\n target_WILL_MUTATE[sourceLength + targetOffset] = leftValue;\n sourceOffset++;\n }\n if (sourceOffset === sourceLength) {\n target_WILL_MUTATE[sourceOffset + targetOffset] = source[sourceOffset];\n }\n}\nfunction reverseEncoder(encoder) {\n assertIsFixedSize(encoder);\n return createEncoder({\n ...encoder,\n write: (value, bytes, offset) => {\n const newOffset = encoder.write(value, bytes, offset);\n copySourceToTargetInReverse(\n bytes,\n bytes,\n offset,\n offset + encoder.fixedSize\n );\n return newOffset;\n }\n });\n}\nfunction reverseDecoder(decoder) {\n assertIsFixedSize(decoder);\n return createDecoder({\n ...decoder,\n read: (bytes, offset) => {\n const reversedBytes = bytes.slice();\n copySourceToTargetInReverse(\n bytes,\n reversedBytes,\n offset,\n offset + decoder.fixedSize\n );\n return decoder.read(reversedBytes, offset);\n }\n });\n}\nfunction reverseCodec(codec) {\n return combineCodec(reverseEncoder(codec), reverseDecoder(codec));\n}\n\n// src/transform-codec.ts\nfunction transformEncoder(encoder, unmap) {\n return createEncoder({\n ...isVariableSize(encoder) ? { ...encoder, getSizeFromValue: (value) => encoder.getSizeFromValue(unmap(value)) } : encoder,\n write: (value, bytes, offset) => encoder.write(unmap(value), bytes, offset)\n });\n}\nfunction transformDecoder(decoder, map) {\n return createDecoder({\n ...decoder,\n read: (bytes, offset) => {\n const [value, newOffset] = decoder.read(bytes, offset);\n return [map(value, bytes, offset), newOffset];\n }\n });\n}\nfunction transformCodec(codec, unmap, map) {\n return createCodec({\n ...transformEncoder(codec, unmap),\n read: map ? transformDecoder(codec, map).read : codec.read\n });\n}\n\nexport { addCodecSentinel, addCodecSizePrefix, addDecoderSentinel, addDecoderSizePrefix, addEncoderSentinel, addEncoderSizePrefix, assertByteArrayHasEnoughBytesForCodec, assertByteArrayIsNotEmptyForCodec, assertByteArrayOffsetIsNotOutOfRange, assertIsFixedSize, assertIsVariableSize, combineCodec, containsBytes, createCodec, createDecoder, createDecoderThatConsumesEntireByteArray, createEncoder, fixBytes, fixCodecSize, fixDecoderSize, fixEncoderSize, getEncodedSize, isFixedSize, isVariableSize, mergeBytes, offsetCodec, offsetDecoder, offsetEncoder, padBytes, padLeftCodec, padLeftDecoder, padLeftEncoder, padRightCodec, padRightDecoder, padRightEncoder, resizeCodec, resizeDecoder, resizeEncoder, reverseCodec, reverseDecoder, reverseEncoder, transformCodec, transformDecoder, transformEncoder };\n//# sourceMappingURL=index.browser.mjs.map\n//# sourceMappingURL=index.browser.mjs.map","import { SolanaError, SOLANA_ERROR__CODECS__INVALID_STRING_FOR_BASE } from '@solana/errors';\nimport { combineCodec, createDecoder, createEncoder } from '@solana/codecs-core';\n\n// src/assertions.ts\nfunction assertValidBaseString(alphabet4, testValue, givenValue = testValue) {\n if (!testValue.match(new RegExp(`^[${alphabet4}]*$`))) {\n throw new SolanaError(SOLANA_ERROR__CODECS__INVALID_STRING_FOR_BASE, {\n alphabet: alphabet4,\n base: alphabet4.length,\n value: givenValue\n });\n }\n}\nvar getBaseXEncoder = (alphabet4) => {\n return createEncoder({\n getSizeFromValue: (value) => {\n const [leadingZeroes, tailChars] = partitionLeadingZeroes(value, alphabet4[0]);\n if (!tailChars) return value.length;\n const base10Number = getBigIntFromBaseX(tailChars, alphabet4);\n return leadingZeroes.length + Math.ceil(base10Number.toString(16).length / 2);\n },\n write(value, bytes, offset) {\n assertValidBaseString(alphabet4, value);\n if (value === \"\") return offset;\n const [leadingZeroes, tailChars] = partitionLeadingZeroes(value, alphabet4[0]);\n if (!tailChars) {\n bytes.set(new Uint8Array(leadingZeroes.length).fill(0), offset);\n return offset + leadingZeroes.length;\n }\n let base10Number = getBigIntFromBaseX(tailChars, alphabet4);\n const tailBytes = [];\n while (base10Number > 0n) {\n tailBytes.unshift(Number(base10Number % 256n));\n base10Number /= 256n;\n }\n const bytesToAdd = [...Array(leadingZeroes.length).fill(0), ...tailBytes];\n bytes.set(bytesToAdd, offset);\n return offset + bytesToAdd.length;\n }\n });\n};\nvar getBaseXDecoder = (alphabet4) => {\n return createDecoder({\n read(rawBytes, offset) {\n const bytes = offset === 0 ? rawBytes : rawBytes.slice(offset);\n if (bytes.length === 0) return [\"\", 0];\n let trailIndex = bytes.findIndex((n) => n !== 0);\n trailIndex = trailIndex === -1 ? bytes.length : trailIndex;\n const leadingZeroes = alphabet4[0].repeat(trailIndex);\n if (trailIndex === bytes.length) return [leadingZeroes, rawBytes.length];\n const base10Number = bytes.slice(trailIndex).reduce((sum, byte) => sum * 256n + BigInt(byte), 0n);\n const tailChars = getBaseXFromBigInt(base10Number, alphabet4);\n return [leadingZeroes + tailChars, rawBytes.length];\n }\n });\n};\nvar getBaseXCodec = (alphabet4) => combineCodec(getBaseXEncoder(alphabet4), getBaseXDecoder(alphabet4));\nfunction partitionLeadingZeroes(value, zeroCharacter) {\n const [leadingZeros, tailChars] = value.split(new RegExp(`((?!${zeroCharacter}).*)`));\n return [leadingZeros, tailChars];\n}\nfunction getBigIntFromBaseX(value, alphabet4) {\n const base = BigInt(alphabet4.length);\n let sum = 0n;\n for (const char of value) {\n sum *= base;\n sum += BigInt(alphabet4.indexOf(char));\n }\n return sum;\n}\nfunction getBaseXFromBigInt(value, alphabet4) {\n const base = BigInt(alphabet4.length);\n const tailChars = [];\n while (value > 0n) {\n tailChars.unshift(alphabet4[Number(value % base)]);\n value /= base;\n }\n return tailChars.join(\"\");\n}\n\n// src/base10.ts\nvar alphabet = \"0123456789\";\nvar getBase10Encoder = () => getBaseXEncoder(alphabet);\nvar getBase10Decoder = () => getBaseXDecoder(alphabet);\nvar getBase10Codec = () => getBaseXCodec(alphabet);\nvar INVALID_STRING_ERROR_BASE_CONFIG = {\n alphabet: \"0123456789abcdef\",\n base: 16\n};\nfunction charCodeToBase16(char) {\n if (char >= 48 /* ZERO */ && char <= 57 /* NINE */) return char - 48 /* ZERO */;\n if (char >= 65 /* A_UP */ && char <= 70 /* F_UP */) return char - (65 /* A_UP */ - 10);\n if (char >= 97 /* A_LO */ && char <= 102 /* F_LO */) return char - (97 /* A_LO */ - 10);\n}\nvar getBase16Encoder = () => createEncoder({\n getSizeFromValue: (value) => Math.ceil(value.length / 2),\n write(value, bytes, offset) {\n const len = value.length;\n const al = len / 2;\n if (len === 1) {\n const c = value.charCodeAt(0);\n const n = charCodeToBase16(c);\n if (n === void 0) {\n throw new SolanaError(SOLANA_ERROR__CODECS__INVALID_STRING_FOR_BASE, {\n ...INVALID_STRING_ERROR_BASE_CONFIG,\n value\n });\n }\n bytes.set([n], offset);\n return 1 + offset;\n }\n const hexBytes = new Uint8Array(al);\n for (let i = 0, j = 0; i < al; i++) {\n const c1 = value.charCodeAt(j++);\n const c2 = value.charCodeAt(j++);\n const n1 = charCodeToBase16(c1);\n const n2 = charCodeToBase16(c2);\n if (n1 === void 0 || n2 === void 0 && !Number.isNaN(c2)) {\n throw new SolanaError(SOLANA_ERROR__CODECS__INVALID_STRING_FOR_BASE, {\n ...INVALID_STRING_ERROR_BASE_CONFIG,\n value\n });\n }\n hexBytes[i] = !Number.isNaN(c2) ? n1 << 4 | (n2 ?? 0) : n1;\n }\n bytes.set(hexBytes, offset);\n return hexBytes.length + offset;\n }\n});\nvar getBase16Decoder = () => createDecoder({\n read(bytes, offset) {\n const value = bytes.slice(offset).reduce((str, byte) => str + byte.toString(16).padStart(2, \"0\"), \"\");\n return [value, bytes.length];\n }\n});\nvar getBase16Codec = () => combineCodec(getBase16Encoder(), getBase16Decoder());\n\n// src/base58.ts\nvar alphabet2 = \"123456789ABCDEFGHJKLMNPQRSTUVWXYZabcdefghijkmnopqrstuvwxyz\";\nvar getBase58Encoder = () => getBaseXEncoder(alphabet2);\nvar getBase58Decoder = () => getBaseXDecoder(alphabet2);\nvar getBase58Codec = () => getBaseXCodec(alphabet2);\nvar getBaseXResliceEncoder = (alphabet4, bits) => createEncoder({\n getSizeFromValue: (value) => Math.floor(value.length * bits / 8),\n write(value, bytes, offset) {\n assertValidBaseString(alphabet4, value);\n if (value === \"\") return offset;\n const charIndices = [...value].map((c) => alphabet4.indexOf(c));\n const reslicedBytes = reslice(charIndices, bits, 8, false);\n bytes.set(reslicedBytes, offset);\n return reslicedBytes.length + offset;\n }\n});\nvar getBaseXResliceDecoder = (alphabet4, bits) => createDecoder({\n read(rawBytes, offset = 0) {\n const bytes = offset === 0 ? rawBytes : rawBytes.slice(offset);\n if (bytes.length === 0) return [\"\", rawBytes.length];\n const charIndices = reslice([...bytes], 8, bits, true);\n return [charIndices.map((i) => alphabet4[i]).join(\"\"), rawBytes.length];\n }\n});\nvar getBaseXResliceCodec = (alphabet4, bits) => combineCodec(getBaseXResliceEncoder(alphabet4, bits), getBaseXResliceDecoder(alphabet4, bits));\nfunction reslice(input, inputBits, outputBits, useRemainder) {\n const output = [];\n let accumulator = 0;\n let bitsInAccumulator = 0;\n const mask = (1 << outputBits) - 1;\n for (const value of input) {\n accumulator = accumulator << inputBits | value;\n bitsInAccumulator += inputBits;\n while (bitsInAccumulator >= outputBits) {\n bitsInAccumulator -= outputBits;\n output.push(accumulator >> bitsInAccumulator & mask);\n }\n }\n if (useRemainder && bitsInAccumulator > 0) {\n output.push(accumulator << outputBits - bitsInAccumulator & mask);\n }\n return output;\n}\n\n// src/base64.ts\nvar alphabet3 = \"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/\";\nvar getBase64Encoder = () => {\n {\n return createEncoder({\n getSizeFromValue: (value) => {\n try {\n return atob(value).length;\n } catch {\n throw new SolanaError(SOLANA_ERROR__CODECS__INVALID_STRING_FOR_BASE, {\n alphabet: alphabet3,\n base: 64,\n value\n });\n }\n },\n write(value, bytes, offset) {\n try {\n const bytesToAdd = atob(value).split(\"\").map((c) => c.charCodeAt(0));\n bytes.set(bytesToAdd, offset);\n return bytesToAdd.length + offset;\n } catch {\n throw new SolanaError(SOLANA_ERROR__CODECS__INVALID_STRING_FOR_BASE, {\n alphabet: alphabet3,\n base: 64,\n value\n });\n }\n }\n });\n }\n};\nvar getBase64Decoder = () => {\n {\n return createDecoder({\n read(bytes, offset = 0) {\n const slice = bytes.slice(offset);\n const value = btoa(String.fromCharCode(...slice));\n return [value, bytes.length];\n }\n });\n }\n};\nvar getBase64Codec = () => combineCodec(getBase64Encoder(), getBase64Decoder());\n\n// src/null-characters.ts\nvar removeNullCharacters = (value) => (\n // eslint-disable-next-line no-control-regex\n value.replace(/\\u0000/g, \"\")\n);\nvar padNullCharacters = (value, chars) => value.padEnd(chars, \"\\0\");\n\n// ../text-encoding-impl/dist/index.browser.mjs\nvar e = globalThis.TextDecoder;\nvar o = globalThis.TextEncoder;\n\n// src/utf8.ts\nvar getUtf8Encoder = () => {\n let textEncoder;\n return createEncoder({\n getSizeFromValue: (value) => (textEncoder ||= new o()).encode(value).length,\n write: (value, bytes, offset) => {\n const bytesToAdd = (textEncoder ||= new o()).encode(value);\n bytes.set(bytesToAdd, offset);\n return offset + bytesToAdd.length;\n }\n });\n};\nvar getUtf8Decoder = () => {\n let textDecoder;\n return createDecoder({\n read(bytes, offset) {\n const value = (textDecoder ||= new e()).decode(bytes.slice(offset));\n return [removeNullCharacters(value), bytes.length];\n }\n });\n};\nvar getUtf8Codec = () => combineCodec(getUtf8Encoder(), getUtf8Decoder());\n\nexport { assertValidBaseString, getBase10Codec, getBase10Decoder, getBase10Encoder, getBase16Codec, getBase16Decoder, getBase16Encoder, getBase58Codec, getBase58Decoder, getBase58Encoder, getBase64Codec, getBase64Decoder, getBase64Encoder, getBaseXCodec, getBaseXDecoder, getBaseXEncoder, getBaseXResliceCodec, getBaseXResliceDecoder, getBaseXResliceEncoder, getUtf8Codec, getUtf8Decoder, getUtf8Encoder, padNullCharacters, removeNullCharacters };\n//# sourceMappingURL=index.browser.mjs.map\n//# sourceMappingURL=index.browser.mjs.map","import { createSignInMessageText } from '@solana/wallet-standard-util';\nimport { getBase58Decoder } from '@solana/codecs-strings';\n\n// Typescript `enums` thwart tree-shaking. See https://bargsten.org/jsts/enums/\nconst SolanaMobileWalletAdapterErrorCode = {\n ERROR_ASSOCIATION_PORT_OUT_OF_RANGE: 'ERROR_ASSOCIATION_PORT_OUT_OF_RANGE',\n ERROR_REFLECTOR_ID_OUT_OF_RANGE: 'ERROR_REFLECTOR_ID_OUT_OF_RANGE',\n ERROR_FORBIDDEN_WALLET_BASE_URL: 'ERROR_FORBIDDEN_WALLET_BASE_URL',\n ERROR_SECURE_CONTEXT_REQUIRED: 'ERROR_SECURE_CONTEXT_REQUIRED',\n ERROR_SESSION_CLOSED: 'ERROR_SESSION_CLOSED',\n ERROR_SESSION_TIMEOUT: 'ERROR_SESSION_TIMEOUT',\n ERROR_WALLET_NOT_FOUND: 'ERROR_WALLET_NOT_FOUND',\n ERROR_INVALID_PROTOCOL_VERSION: 'ERROR_INVALID_PROTOCOL_VERSION',\n ERROR_BROWSER_NOT_SUPPORTED: 'ERROR_BROWSER_NOT_SUPPORTED',\n};\nclass SolanaMobileWalletAdapterError extends Error {\n constructor(...args) {\n const [code, message, data] = args;\n super(message);\n this.code = code;\n this.data = data;\n this.name = 'SolanaMobileWalletAdapterError';\n }\n}\n// Typescript `enums` thwart tree-shaking. See https://bargsten.org/jsts/enums/\nconst SolanaMobileWalletAdapterProtocolErrorCode = {\n // Keep these in sync with `mobilewalletadapter/common/ProtocolContract.java`.\n ERROR_AUTHORIZATION_FAILED: -1,\n ERROR_INVALID_PAYLOADS: -2,\n ERROR_NOT_SIGNED: -3,\n ERROR_NOT_SUBMITTED: -4,\n ERROR_TOO_MANY_PAYLOADS: -5,\n ERROR_ATTEST_ORIGIN_ANDROID: -100,\n};\nclass SolanaMobileWalletAdapterProtocolError extends Error {\n constructor(...args) {\n const [jsonRpcMessageId, code, message, data] = args;\n super(message);\n this.code = code;\n this.data = data;\n this.jsonRpcMessageId = jsonRpcMessageId;\n this.name = 'SolanaMobileWalletAdapterProtocolError';\n }\n}\n\n/******************************************************************************\r\nCopyright (c) Microsoft Corporation.\r\n\r\nPermission to use, copy, modify, and/or distribute this software for any\r\npurpose with or without fee is hereby granted.\r\n\r\nTHE SOFTWARE IS PROVIDED \"AS IS\" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH\r\nREGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY\r\nAND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,\r\nINDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM\r\nLOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR\r\nOTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR\r\nPERFORMANCE OF THIS SOFTWARE.\r\n***************************************************************************** */\r\n\r\nfunction __awaiter(thisArg, _arguments, P, generator) {\r\n function adopt(value) { return value instanceof P ? value : new P(function (resolve) { resolve(value); }); }\r\n return new (P || (P = Promise))(function (resolve, reject) {\r\n function fulfilled(value) { try { step(generator.next(value)); } catch (e) { reject(e); } }\r\n function rejected(value) { try { step(generator[\"throw\"](value)); } catch (e) { reject(e); } }\r\n function step(result) { result.done ? resolve(result.value) : adopt(result.value).then(fulfilled, rejected); }\r\n step((generator = generator.apply(thisArg, _arguments || [])).next());\r\n });\r\n}\n\nfunction encode(input) {\n return window.btoa(input);\n}\nfunction fromUint8Array$1(byteArray, urlsafe) {\n const base64 = window.btoa(String.fromCharCode.call(null, ...byteArray));\n if (urlsafe) {\n return base64\n .replace(/\\+/g, '-')\n .replace(/\\//g, '_')\n .replace(/=+$/, '');\n }\n else\n return base64;\n}\nfunction toUint8Array(base64EncodedByteArray) {\n return new Uint8Array(window\n .atob(base64EncodedByteArray)\n .split('')\n .map((c) => c.charCodeAt(0)));\n}\n\nfunction createHelloReq(ecdhPublicKey, associationKeypairPrivateKey) {\n return __awaiter(this, void 0, void 0, function* () {\n const publicKeyBuffer = yield crypto.subtle.exportKey('raw', ecdhPublicKey);\n const signatureBuffer = yield crypto.subtle.sign({ hash: 'SHA-256', name: 'ECDSA' }, associationKeypairPrivateKey, publicKeyBuffer);\n const response = new Uint8Array(publicKeyBuffer.byteLength + signatureBuffer.byteLength);\n response.set(new Uint8Array(publicKeyBuffer), 0);\n response.set(new Uint8Array(signatureBuffer), publicKeyBuffer.byteLength);\n return response;\n });\n}\n\nfunction createSIWSMessage(payload) {\n return createSignInMessageText(payload);\n}\nfunction createSIWSMessageBase64Url(payload) {\n return encode(createSIWSMessage(payload))\n .replace(/\\+/g, '-')\n .replace(/\\//g, '_')\n .replace(/=+$/, ''); // convert to base64url encoding;\n}\n\n// optional features\nconst SolanaSignTransactions = 'solana:signTransactions';\nconst SolanaCloneAuthorization = 'solana:cloneAuthorization';\nconst SolanaSignInWithSolana = 'solana:signInWithSolana';\n\nfunction fromUint8Array(byteArray) {\n return getBase58Decoder().decode(byteArray);\n}\nfunction base64ToBase58(base64EncodedString) {\n return fromUint8Array(toUint8Array(base64EncodedString));\n}\n\n/**\n * Creates a {@link MobileWallet} proxy that handles backwards compatibility and API to RPC conversion.\n *\n * @param protocolVersion the protocol version in use for this session/request\n * @param protocolRequestHandler callback function that handles sending the RPC request to the wallet endpoint.\n * @returns a {@link MobileWallet} proxy\n */\nfunction createMobileWalletProxy(protocolVersion, protocolRequestHandler) {\n return new Proxy({}, {\n get(target, p) {\n // Wrapping a Proxy in a promise results in the Proxy being asked for a 'then' property so must \n // return null if 'then' is called on this proxy to let the 'resolve()' call know this is not a promise.\n // see: https://stackoverflow.com/a/53890904\n //@ts-ignore\n if (p === 'then') {\n return null;\n }\n if (target[p] == null) {\n target[p] = function (inputParams) {\n return __awaiter(this, void 0, void 0, function* () {\n const { method, params } = handleMobileWalletRequest(p, inputParams, protocolVersion);\n const result = yield protocolRequestHandler(method, params);\n // if the request tried to sign in but the wallet did not return a sign in result, fallback on message signing\n if (method === 'authorize' && params.sign_in_payload && !result.sign_in_result) {\n result['sign_in_result'] = yield signInFallback(params.sign_in_payload, result, protocolRequestHandler);\n }\n return handleMobileWalletResponse(p, result, protocolVersion);\n });\n };\n }\n return target[p];\n },\n defineProperty() {\n return false;\n },\n deleteProperty() {\n return false;\n },\n });\n}\n/**\n * Handles all {@link MobileWallet} API requests and determines the correct MWA RPC method and params to call.\n * This handles backwards compatibility, based on the provided @protocolVersion.\n *\n * @param methodName the name of {@link MobileWallet} method that was called\n * @param methodParams the parameters that were passed to the method\n * @param protocolVersion the protocol version in use for this session/request\n * @returns the RPC request method and params that should be sent to the wallet endpoint\n */\nfunction handleMobileWalletRequest(methodName, methodParams, protocolVersion) {\n let params = methodParams;\n let method = methodName\n .toString()\n .replace(/[A-Z]/g, (letter) => `_${letter.toLowerCase()}`)\n .toLowerCase();\n switch (methodName) {\n case 'authorize': {\n let { chain } = params;\n if (protocolVersion === 'legacy') {\n switch (chain) {\n case 'solana:testnet': {\n chain = 'testnet';\n break;\n }\n case 'solana:devnet': {\n chain = 'devnet';\n break;\n }\n case 'solana:mainnet': {\n chain = 'mainnet-beta';\n break;\n }\n default: {\n chain = params.cluster;\n }\n }\n params.cluster = chain;\n }\n else {\n switch (chain) {\n case 'testnet':\n case 'devnet': {\n chain = `solana:${chain}`;\n break;\n }\n case 'mainnet-beta': {\n chain = 'solana:mainnet';\n break;\n }\n }\n params.chain = chain;\n }\n }\n case 'reauthorize': {\n const { auth_token, identity } = params;\n if (auth_token) {\n switch (protocolVersion) {\n case 'legacy': {\n method = 'reauthorize';\n params = { auth_token: auth_token, identity: identity };\n break;\n }\n default: {\n method = 'authorize';\n break;\n }\n }\n }\n break;\n }\n }\n return { method, params };\n}\n/**\n * Handles all {@link MobileWallet} API responses and modifies the response for backwards compatibility, if needed\n *\n * @param method the {@link MobileWallet} method that was called\n * @param response the original response that was returned by the method call\n * @param protocolVersion the protocol version in use for this session/request\n * @returns the possibly modified response\n */\nfunction handleMobileWalletResponse(method, response, protocolVersion) {\n switch (method) {\n case 'getCapabilities': {\n const capabilities = response;\n switch (protocolVersion) {\n case 'legacy': {\n const features = [SolanaSignTransactions];\n if (capabilities.supports_clone_authorization === true) {\n features.push(SolanaCloneAuthorization);\n }\n return Object.assign(Object.assign({}, capabilities), { features: features });\n }\n case 'v1': {\n return Object.assign(Object.assign({}, capabilities), { supports_sign_and_send_transactions: true, supports_clone_authorization: capabilities.features.includes(SolanaCloneAuthorization) });\n }\n }\n }\n }\n return response;\n}\nfunction signInFallback(signInPayload, authorizationResult, protocolRequestHandler) {\n var _a;\n return __awaiter(this, void 0, void 0, function* () {\n const domain = (_a = signInPayload.domain) !== null && _a !== void 0 ? _a : window.location.host;\n const address = authorizationResult.accounts[0].address;\n const siwsMessage = createSIWSMessageBase64Url(Object.assign(Object.assign({}, signInPayload), { domain, address: base64ToBase58(address) }));\n const signMessageResult = yield protocolRequestHandler('sign_messages', {\n addresses: [address],\n payloads: [siwsMessage]\n });\n const signedPayload = toUint8Array(signMessageResult.signed_payloads[0]);\n const signedMessage = fromUint8Array$1(signedPayload.slice(0, signedPayload.length - 64));\n const signature = fromUint8Array$1(signedPayload.slice(signedPayload.length - 64));\n const signInResult = {\n address: address,\n // Workaround: some wallets have been observed to only reply with the message signature.\n // This is non-compliant with the spec, but in the interest of maximizing compatibility,\n // detect this case and reuse the original message.\n signed_message: signedMessage.length == 0 ? siwsMessage : signedMessage,\n signature\n };\n return signInResult;\n });\n}\n\nconst SEQUENCE_NUMBER_BYTES = 4;\nfunction createSequenceNumberVector(sequenceNumber) {\n if (sequenceNumber >= 4294967296) {\n throw new Error('Outbound sequence number overflow. The maximum sequence number is 32-bytes.');\n }\n const byteArray = new ArrayBuffer(SEQUENCE_NUMBER_BYTES);\n const view = new DataView(byteArray);\n view.setUint32(0, sequenceNumber, /* littleEndian */ false);\n return new Uint8Array(byteArray);\n}\n\nconst INITIALIZATION_VECTOR_BYTES = 12;\nconst ENCODED_PUBLIC_KEY_LENGTH_BYTES = 65;\nfunction encryptMessage(plaintext, sequenceNumber, sharedSecret) {\n return __awaiter(this, void 0, void 0, function* () {\n const sequenceNumberVector = createSequenceNumberVector(sequenceNumber);\n const initializationVector = new Uint8Array(INITIALIZATION_VECTOR_BYTES);\n crypto.getRandomValues(initializationVector);\n const ciphertext = yield crypto.subtle.encrypt(getAlgorithmParams(sequenceNumberVector, initializationVector), sharedSecret, new TextEncoder().encode(plaintext));\n const response = new Uint8Array(sequenceNumberVector.byteLength + initializationVector.byteLength + ciphertext.byteLength);\n response.set(new Uint8Array(sequenceNumberVector), 0);\n response.set(new Uint8Array(initializationVector), sequenceNumberVector.byteLength);\n response.set(new Uint8Array(ciphertext), sequenceNumberVector.byteLength + initializationVector.byteLength);\n return response;\n });\n}\nfunction decryptMessage(message, sharedSecret) {\n return __awaiter(this, void 0, void 0, function* () {\n const sequenceNumberVector = message.slice(0, SEQUENCE_NUMBER_BYTES);\n const initializationVector = message.slice(SEQUENCE_NUMBER_BYTES, SEQUENCE_NUMBER_BYTES + INITIALIZATION_VECTOR_BYTES);\n const ciphertext = message.slice(SEQUENCE_NUMBER_BYTES + INITIALIZATION_VECTOR_BYTES);\n const plaintextBuffer = yield crypto.subtle.decrypt(getAlgorithmParams(sequenceNumberVector, initializationVector), sharedSecret, ciphertext);\n const plaintext = getUtf8Decoder().decode(plaintextBuffer);\n return plaintext;\n });\n}\nfunction getAlgorithmParams(sequenceNumber, initializationVector) {\n return {\n additionalData: sequenceNumber,\n iv: initializationVector,\n name: 'AES-GCM',\n tagLength: 128, // 16 byte tag => 128 bits\n };\n}\nlet _utf8Decoder;\nfunction getUtf8Decoder() {\n if (_utf8Decoder === undefined) {\n _utf8Decoder = new TextDecoder('utf-8');\n }\n return _utf8Decoder;\n}\n\nfunction generateAssociationKeypair() {\n return __awaiter(this, void 0, void 0, function* () {\n return yield crypto.subtle.generateKey({\n name: 'ECDSA',\n namedCurve: 'P-256',\n }, false /* extractable */, ['sign'] /* keyUsages */);\n });\n}\n\nfunction generateECDHKeypair() {\n return __awaiter(this, void 0, void 0, function* () {\n return yield crypto.subtle.generateKey({\n name: 'ECDH',\n namedCurve: 'P-256',\n }, false /* extractable */, ['deriveKey', 'deriveBits'] /* keyUsages */);\n });\n}\n\n// https://stackoverflow.com/a/9458996/802047\nfunction arrayBufferToBase64String(buffer) {\n let binary = '';\n const bytes = new Uint8Array(buffer);\n const len = bytes.byteLength;\n for (let ii = 0; ii < len; ii++) {\n binary += String.fromCharCode(bytes[ii]);\n }\n return window.btoa(binary);\n}\n\nfunction getRandomAssociationPort() {\n return assertAssociationPort(49152 + Math.floor(Math.random() * (65535 - 49152 + 1)));\n}\nfunction assertAssociationPort(port) {\n if (port < 49152 || port > 65535) {\n throw new SolanaMobileWalletAdapterError(SolanaMobileWalletAdapterErrorCode.ERROR_ASSOCIATION_PORT_OUT_OF_RANGE, `Association port number must be between 49152 and 65535. ${port} given.`, { port });\n }\n return port;\n}\n\nfunction getStringWithURLUnsafeCharactersReplaced(unsafeBase64EncodedString) {\n return unsafeBase64EncodedString.replace(/[/+=]/g, (m) => ({\n '/': '_',\n '+': '-',\n '=': '.',\n }[m]));\n}\n\nconst INTENT_NAME = 'solana-wallet';\nfunction getPathParts(pathString) {\n return (pathString\n // Strip leading and trailing slashes\n .replace(/(^\\/+|\\/+$)/g, '')\n // Return an array of directories\n .split('/'));\n}\nfunction getIntentURL(methodPathname, intentUrlBase) {\n let baseUrl = null;\n if (intentUrlBase) {\n try {\n baseUrl = new URL(intentUrlBase);\n }\n catch (_a) { } // eslint-disable-line no-empty\n if ((baseUrl === null || baseUrl === void 0 ? void 0 : baseUrl.protocol) !== 'https:') {\n throw new SolanaMobileWalletAdapterError(SolanaMobileWalletAdapterErrorCode.ERROR_FORBIDDEN_WALLET_BASE_URL, 'Base URLs supplied by wallets must be valid `https` URLs');\n }\n }\n baseUrl || (baseUrl = new URL(`${INTENT_NAME}:/`));\n const pathname = methodPathname.startsWith('/')\n ? // Method is an absolute path. Replace it wholesale.\n methodPathname\n : // Method is a relative path. Merge it with the existing one.\n [...getPathParts(baseUrl.pathname), ...getPathParts(methodPathname)].join('/');\n return new URL(pathname, baseUrl);\n}\nfunction getAssociateAndroidIntentURL(associationPublicKey, putativePort, associationURLBase, protocolVersions = ['v1']) {\n return __awaiter(this, void 0, void 0, function* () {\n const associationPort = assertAssociationPort(putativePort);\n const exportedKey = yield crypto.subtle.exportKey('raw', associationPublicKey);\n const encodedKey = arrayBufferToBase64String(exportedKey);\n const url = getIntentURL('v1/associate/local', associationURLBase);\n url.searchParams.set('association', getStringWithURLUnsafeCharactersReplaced(encodedKey));\n url.searchParams.set('port', `${associationPort}`);\n protocolVersions.forEach((version) => {\n url.searchParams.set('v', version);\n });\n return url;\n });\n}\nfunction getRemoteAssociateAndroidIntentURL(associationPublicKey, hostAuthority, reflectorId, associationURLBase, protocolVersions = ['v1']) {\n return __awaiter(this, void 0, void 0, function* () {\n const exportedKey = yield crypto.subtle.exportKey('raw', associationPublicKey);\n const encodedKey = arrayBufferToBase64String(exportedKey);\n const url = getIntentURL('v1/associate/remote', associationURLBase);\n url.searchParams.set('association', getStringWithURLUnsafeCharactersReplaced(encodedKey));\n url.searchParams.set('reflector', `${hostAuthority}`);\n url.searchParams.set('id', `${fromUint8Array$1(reflectorId, true)}`);\n protocolVersions.forEach((version) => {\n url.searchParams.set('v', version);\n });\n return url;\n });\n}\n\nfunction encryptJsonRpcMessage(jsonRpcMessage, sharedSecret) {\n return __awaiter(this, void 0, void 0, function* () {\n const plaintext = JSON.stringify(jsonRpcMessage);\n const sequenceNumber = jsonRpcMessage.id;\n return encryptMessage(plaintext, sequenceNumber, sharedSecret);\n });\n}\nfunction decryptJsonRpcMessage(message, sharedSecret) {\n return __awaiter(this, void 0, void 0, function* () {\n const plaintext = yield decryptMessage(message, sharedSecret);\n const jsonRpcMessage = JSON.parse(plaintext);\n if (Object.hasOwnProperty.call(jsonRpcMessage, 'error')) {\n throw new SolanaMobileWalletAdapterProtocolError(jsonRpcMessage.id, jsonRpcMessage.error.code, jsonRpcMessage.error.message);\n }\n return jsonRpcMessage;\n });\n}\n\nfunction parseHelloRsp(payloadBuffer, // The X9.62-encoded wallet endpoint ephemeral ECDH public keypoint.\nassociationPublicKey, ecdhPrivateKey) {\n return __awaiter(this, void 0, void 0, function* () {\n const [associationPublicKeyBuffer, walletPublicKey] = yield Promise.all([\n crypto.subtle.exportKey('raw', associationPublicKey),\n crypto.subtle.importKey('raw', payloadBuffer.slice(0, ENCODED_PUBLIC_KEY_LENGTH_BYTES), { name: 'ECDH', namedCurve: 'P-256' }, false /* extractable */, [] /* keyUsages */),\n ]);\n const sharedSecret = yield crypto.subtle.deriveBits({ name: 'ECDH', public: walletPublicKey }, ecdhPrivateKey, 256);\n const ecdhSecretKey = yield crypto.subtle.importKey('raw', sharedSecret, 'HKDF', false /* extractable */, ['deriveKey'] /* keyUsages */);\n const aesKeyMaterialVal = yield crypto.subtle.deriveKey({\n name: 'HKDF',\n hash: 'SHA-256',\n salt: new Uint8Array(associationPublicKeyBuffer),\n info: new Uint8Array(),\n }, ecdhSecretKey, { name: 'AES-GCM', length: 128 }, false /* extractable */, ['encrypt', 'decrypt']);\n return aesKeyMaterialVal;\n });\n}\n\nfunction parseSessionProps(message, sharedSecret) {\n return __awaiter(this, void 0, void 0, function* () {\n const plaintext = yield decryptMessage(message, sharedSecret);\n const jsonProperties = JSON.parse(plaintext);\n let protocolVersion = 'legacy';\n if (Object.hasOwnProperty.call(jsonProperties, 'v')) {\n switch (jsonProperties.v) {\n case 1:\n case '1':\n case 'v1':\n protocolVersion = 'v1';\n break;\n case 'legacy':\n protocolVersion = 'legacy';\n break;\n default:\n throw new SolanaMobileWalletAdapterError(SolanaMobileWalletAdapterErrorCode.ERROR_INVALID_PROTOCOL_VERSION, `Unknown/unsupported protocol version: ${jsonProperties.v}`);\n }\n }\n return ({\n protocol_version: protocolVersion\n });\n });\n}\n\n// Typescript `enums` thwart tree-shaking. See https://bargsten.org/jsts/enums/\nconst Browser = {\n Firefox: 0,\n Other: 1,\n};\nfunction assertUnreachable(x) {\n return x;\n}\nfunction getBrowser() {\n return navigator.userAgent.indexOf('Firefox/') !== -1 ? Browser.Firefox : Browser.Other;\n}\nfunction getDetectionPromise() {\n // Chrome and others silently fail if a custom protocol is not supported.\n // For these, we wait to see if the browser is navigated away from in\n // a reasonable amount of time (ie. the native wallet opened).\n return new Promise((resolve, reject) => {\n function cleanup() {\n clearTimeout(timeoutId);\n window.removeEventListener('blur', handleBlur);\n }\n function handleBlur() {\n cleanup();\n resolve();\n }\n window.addEventListener('blur', handleBlur);\n const timeoutId = setTimeout(() => {\n cleanup();\n reject();\n }, 3000);\n });\n}\nlet _frame = null;\nfunction launchUrlThroughHiddenFrame(url) {\n if (_frame == null) {\n _frame = document.createElement('iframe');\n _frame.style.display = 'none';\n document.body.appendChild(_frame);\n }\n // eslint-disable-next-line @typescript-eslint/no-non-null-assertion\n _frame.contentWindow.location.href = url.toString();\n}\nfunction launchAssociation(associationUrl) {\n return __awaiter(this, void 0, void 0, function* () {\n if (associationUrl.protocol === 'https:') {\n // The association URL is an Android 'App Link' or iOS 'Universal Link'.\n // These are regular web URLs that are designed to launch an app if it\n // is installed or load the actual target webpage if not.\n window.location.assign(associationUrl);\n }\n else {\n // The association URL has a custom protocol (eg. `solana-wallet:`)\n try {\n const browser = getBrowser();\n switch (browser) {\n case Browser.Firefox:\n // If a custom protocol is not supported in Firefox, it throws.\n launchUrlThroughHiddenFrame(associationUrl);\n // If we reached this line, it's supported.\n break;\n case Browser.Other: {\n const detectionPromise = getDetectionPromise();\n window.location.assign(associationUrl);\n yield detectionPromise;\n break;\n }\n default:\n assertUnreachable(browser);\n }\n }\n catch (e) {\n throw new SolanaMobileWalletAdapterError(SolanaMobileWalletAdapterErrorCode.ERROR_WALLET_NOT_FOUND, 'Found no installed wallet that supports the mobile wallet protocol.');\n }\n }\n });\n}\nfunction startSession(associationPublicKey, associationURLBase) {\n return __awaiter(this, void 0, void 0, function* () {\n const randomAssociationPort = getRandomAssociationPort();\n const associationUrl = yield getAssociateAndroidIntentURL(associationPublicKey, randomAssociationPort, associationURLBase);\n yield launchAssociation(associationUrl);\n return randomAssociationPort;\n });\n}\n\nconst WEBSOCKET_CONNECTION_CONFIG = {\n /**\n * 300 milliseconds is a generally accepted threshold for what someone\n * would consider an acceptable response time for a user interface\n * after having performed a low-attention tapping task. We set the initial\n * interval at which we wait for the wallet to set up the websocket at\n * half this, as per the Nyquist frequency, with a progressive backoff\n * sequence from there. The total wait time is 30s, which allows for the\n * user to be presented with a disambiguation dialog, select a wallet, and\n * for the wallet app to subsequently start.\n */\n retryDelayScheduleMs: [150, 150, 200, 500, 500, 750, 750, 1000],\n timeoutMs: 30000,\n};\nconst WEBSOCKET_PROTOCOL_BINARY = 'com.solana.mobilewalletadapter.v1';\nconst WEBSOCKET_PROTOCOL_BASE64 = 'com.solana.mobilewalletadapter.v1.base64';\nfunction assertSecureContext() {\n if (typeof window === 'undefined' || window.isSecureContext !== true) {\n throw new SolanaMobileWalletAdapterError(SolanaMobileWalletAdapterErrorCode.ERROR_SECURE_CONTEXT_REQUIRED, 'The mobile wallet adapter protocol must be used in a secure context (`https`).');\n }\n}\nfunction assertSecureEndpointSpecificURI(walletUriBase) {\n let url;\n try {\n url = new URL(walletUriBase);\n }\n catch (_a) {\n throw new SolanaMobileWalletAdapterError(SolanaMobileWalletAdapterErrorCode.ERROR_FORBIDDEN_WALLET_BASE_URL, 'Invalid base URL supplied by wallet');\n }\n if (url.protocol !== 'https:') {\n throw new SolanaMobileWalletAdapterError(SolanaMobileWalletAdapterErrorCode.ERROR_FORBIDDEN_WALLET_BASE_URL, 'Base URLs supplied by wallets must be valid `https` URLs');\n }\n}\nfunction getSequenceNumberFromByteArray(byteArray) {\n const view = new DataView(byteArray);\n return view.getUint32(0, /* littleEndian */ false);\n}\nfunction decodeVarLong(byteArray) {\n var bytes = new Uint8Array(byteArray), l = byteArray.byteLength, limit = 10, value = 0, offset = 0, b;\n do {\n if (offset >= l || offset > limit)\n throw new RangeError('Failed to decode varint');\n b = bytes[offset++];\n value |= (b & 0x7F) << (7 * offset);\n } while (b >= 0x80);\n return { value, offset };\n}\nfunction getReflectorIdFromByteArray(byteArray) {\n let { value: length, offset } = decodeVarLong(byteArray);\n return new Uint8Array(byteArray.slice(offset, offset + length));\n}\nfunction transact(callback, config) {\n return __awaiter(this, void 0, void 0, function* () {\n assertSecureContext();\n const associationKeypair = yield generateAssociationKeypair();\n const sessionPort = yield startSession(associationKeypair.publicKey, config === null || config === void 0 ? void 0 : config.baseUri);\n const websocketURL = `ws://localhost:${sessionPort}/solana-wallet`;\n let connectionStartTime;\n const getNextRetryDelayMs = (() => {\n const schedule = [...WEBSOCKET_CONNECTION_CONFIG.retryDelayScheduleMs];\n return () => (schedule.length > 1 ? schedule.shift() : schedule[0]);\n })();\n let nextJsonRpcMessageId = 1;\n let lastKnownInboundSequenceNumber = 0;\n let state = { __type: 'disconnected' };\n return new Promise((resolve, reject) => {\n let socket;\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const jsonRpcResponsePromises = {};\n const handleOpen = () => __awaiter(this, void 0, void 0, function* () {\n if (state.__type !== 'connecting') {\n console.warn('Expected adapter state to be `connecting` at the moment the websocket opens. ' +\n `Got \\`${state.__type}\\`.`);\n return;\n }\n socket.removeEventListener('open', handleOpen);\n // previous versions of this library and walletlib incorrectly implemented the MWA session \n // establishment protocol for local connections. The dapp is supposed to wait for the \n // APP_PING message before sending the HELLO_REQ. Instead, the dapp was sending the HELLO_REQ \n // immediately upon connection to the websocket server regardless of wether or not an \n // APP_PING was sent by the wallet/websocket server. We must continue to support this behavior \n // in case the user is using a wallet that has not updated their walletlib implementation. \n const { associationKeypair } = state;\n const ecdhKeypair = yield generateECDHKeypair();\n socket.send(yield createHelloReq(ecdhKeypair.publicKey, associationKeypair.privateKey));\n state = {\n __type: 'hello_req_sent',\n associationPublicKey: associationKeypair.publicKey,\n ecdhPrivateKey: ecdhKeypair.privateKey,\n };\n });\n const handleClose = (evt) => {\n if (evt.wasClean) {\n state = { __type: 'disconnected' };\n }\n else {\n reject(new SolanaMobileWalletAdapterError(SolanaMobileWalletAdapterErrorCode.ERROR_SESSION_CLOSED, `The wallet session dropped unexpectedly (${evt.code}: ${evt.reason}).`, { closeEvent: evt }));\n }\n disposeSocket();\n };\n const handleError = (_evt) => __awaiter(this, void 0, void 0, function* () {\n disposeSocket();\n if (Date.now() - connectionStartTime >= WEBSOCKET_CONNECTION_CONFIG.timeoutMs) {\n reject(new SolanaMobileWalletAdapterError(SolanaMobileWalletAdapterErrorCode.ERROR_SESSION_TIMEOUT, `Failed to connect to the wallet websocket at ${websocketURL}.`));\n }\n else {\n yield new Promise((resolve) => {\n const retryDelayMs = getNextRetryDelayMs();\n retryWaitTimeoutId = window.setTimeout(resolve, retryDelayMs);\n });\n attemptSocketConnection();\n }\n });\n const handleMessage = (evt) => __awaiter(this, void 0, void 0, function* () {\n const responseBuffer = yield evt.data.arrayBuffer();\n switch (state.__type) {\n case 'connecting':\n if (responseBuffer.byteLength !== 0) {\n throw new Error('Encountered unexpected message while connecting');\n }\n const ecdhKeypair = yield generateECDHKeypair();\n socket.send(yield createHelloReq(ecdhKeypair.publicKey, associationKeypair.privateKey));\n state = {\n __type: 'hello_req_sent',\n associationPublicKey: associationKeypair.publicKey,\n ecdhPrivateKey: ecdhKeypair.privateKey,\n };\n break;\n case 'connected':\n try {\n const sequenceNumberVector = responseBuffer.slice(0, SEQUENCE_NUMBER_BYTES);\n const sequenceNumber = getSequenceNumberFromByteArray(sequenceNumberVector);\n if (sequenceNumber !== (lastKnownInboundSequenceNumber + 1)) {\n throw new Error('Encrypted message has invalid sequence number');\n }\n lastKnownInboundSequenceNumber = sequenceNumber;\n const jsonRpcMessage = yield decryptJsonRpcMessage(responseBuffer, state.sharedSecret);\n const responsePromise = jsonRpcResponsePromises[jsonRpcMessage.id];\n delete jsonRpcResponsePromises[jsonRpcMessage.id];\n responsePromise.resolve(jsonRpcMessage.result);\n }\n catch (e) {\n if (e instanceof SolanaMobileWalletAdapterProtocolError) {\n const responsePromise = jsonRpcResponsePromises[e.jsonRpcMessageId];\n delete jsonRpcResponsePromises[e.jsonRpcMessageId];\n responsePromise.reject(e);\n }\n else {\n throw e;\n }\n }\n break;\n case 'hello_req_sent': {\n // if we receive an APP_PING message (empty message), resend the HELLO_REQ (see above)\n if (responseBuffer.byteLength === 0) {\n const ecdhKeypair = yield generateECDHKeypair();\n socket.send(yield createHelloReq(ecdhKeypair.publicKey, associationKeypair.privateKey));\n state = {\n __type: 'hello_req_sent',\n associationPublicKey: associationKeypair.publicKey,\n ecdhPrivateKey: ecdhKeypair.privateKey,\n };\n break;\n }\n const sharedSecret = yield parseHelloRsp(responseBuffer, state.associationPublicKey, state.ecdhPrivateKey);\n const sessionPropertiesBuffer = responseBuffer.slice(ENCODED_PUBLIC_KEY_LENGTH_BYTES);\n const sessionProperties = sessionPropertiesBuffer.byteLength !== 0\n ? yield (() => __awaiter(this, void 0, void 0, function* () {\n const sequenceNumberVector = sessionPropertiesBuffer.slice(0, SEQUENCE_NUMBER_BYTES);\n const sequenceNumber = getSequenceNumberFromByteArray(sequenceNumberVector);\n if (sequenceNumber !== (lastKnownInboundSequenceNumber + 1)) {\n throw new Error('Encrypted message has invalid sequence number');\n }\n lastKnownInboundSequenceNumber = sequenceNumber;\n return parseSessionProps(sessionPropertiesBuffer, sharedSecret);\n }))() : { protocol_version: 'legacy' };\n state = { __type: 'connected', sharedSecret, sessionProperties };\n const wallet = createMobileWalletProxy(sessionProperties.protocol_version, (method, params) => __awaiter(this, void 0, void 0, function* () {\n const id = nextJsonRpcMessageId++;\n socket.send(yield encryptJsonRpcMessage({\n id,\n jsonrpc: '2.0',\n method,\n params: params !== null && params !== void 0 ? params : {},\n }, sharedSecret));\n return new Promise((resolve, reject) => {\n jsonRpcResponsePromises[id] = {\n resolve(result) {\n switch (method) {\n case 'authorize':\n case 'reauthorize': {\n const { wallet_uri_base } = result;\n if (wallet_uri_base != null) {\n try {\n assertSecureEndpointSpecificURI(wallet_uri_base);\n }\n catch (e) {\n reject(e);\n return;\n }\n }\n break;\n }\n }\n resolve(result);\n },\n reject,\n };\n });\n }));\n try {\n resolve(yield callback(wallet));\n }\n catch (e) {\n reject(e);\n }\n finally {\n disposeSocket();\n socket.close();\n }\n break;\n }\n }\n });\n let disposeSocket;\n let retryWaitTimeoutId;\n const attemptSocketConnection = () => {\n if (disposeSocket) {\n disposeSocket();\n }\n state = { __type: 'connecting', associationKeypair };\n if (connectionStartTime === undefined) {\n connectionStartTime = Date.now();\n }\n socket = new WebSocket(websocketURL, [WEBSOCKET_PROTOCOL_BINARY]);\n socket.addEventListener('open', handleOpen);\n socket.addEventListener('close', handleClose);\n socket.addEventListener('error', handleError);\n socket.addEventListener('message', handleMessage);\n disposeSocket = () => {\n window.clearTimeout(retryWaitTimeoutId);\n socket.removeEventListener('open', handleOpen);\n socket.removeEventListener('close', handleClose);\n socket.removeEventListener('error', handleError);\n socket.removeEventListener('message', handleMessage);\n };\n };\n attemptSocketConnection();\n });\n });\n}\nfunction startRemoteScenario(config) {\n return __awaiter(this, void 0, void 0, function* () {\n assertSecureContext();\n const associationKeypair = yield generateAssociationKeypair();\n const websocketURL = `wss://${config === null || config === void 0 ? void 0 : config.remoteHostAuthority}/reflect`;\n let connectionStartTime;\n const getNextRetryDelayMs = (() => {\n const schedule = [...WEBSOCKET_CONNECTION_CONFIG.retryDelayScheduleMs];\n return () => (schedule.length > 1 ? schedule.shift() : schedule[0]);\n })();\n let nextJsonRpcMessageId = 1;\n let lastKnownInboundSequenceNumber = 0;\n let encoding;\n let state = { __type: 'disconnected' };\n let socket;\n let disposeSocket;\n let decodeBytes = (evt) => __awaiter(this, void 0, void 0, function* () {\n if (encoding == 'base64') { // base64 encoding\n const message = yield evt.data;\n return toUint8Array(message).buffer;\n }\n else {\n return yield evt.data.arrayBuffer();\n }\n });\n // Reflector Connection Phase\n // here we connect to the reflector and wait for the REFLECTOR_ID message \n // so we build the association URL and return that back to the caller\n const associationUrl = yield new Promise((resolve, reject) => {\n const handleOpen = () => __awaiter(this, void 0, void 0, function* () {\n if (state.__type !== 'connecting') {\n console.warn('Expected adapter state to be `connecting` at the moment the websocket opens. ' +\n `Got \\`${state.__type}\\`.`);\n return;\n }\n if (socket.protocol.includes(WEBSOCKET_PROTOCOL_BASE64)) {\n encoding = 'base64';\n }\n else {\n encoding = 'binary';\n }\n socket.removeEventListener('open', handleOpen);\n });\n const handleClose = (evt) => {\n if (evt.wasClean) {\n state = { __type: 'disconnected' };\n }\n else {\n reject(new SolanaMobileWalletAdapterError(SolanaMobileWalletAdapterErrorCode.ERROR_SESSION_CLOSED, `The wallet session dropped unexpectedly (${evt.code}: ${evt.reason}).`, { closeEvent: evt }));\n }\n disposeSocket();\n };\n const handleError = (_evt) => __awaiter(this, void 0, void 0, function* () {\n disposeSocket();\n if (Date.now() - connectionStartTime >= WEBSOCKET_CONNECTION_CONFIG.timeoutMs) {\n reject(new SolanaMobileWalletAdapterError(SolanaMobileWalletAdapterErrorCode.ERROR_SESSION_TIMEOUT, `Failed to connect to the wallet websocket at ${websocketURL}.`));\n }\n else {\n yield new Promise((resolve) => {\n const retryDelayMs = getNextRetryDelayMs();\n retryWaitTimeoutId = window.setTimeout(resolve, retryDelayMs);\n });\n attemptSocketConnection();\n }\n });\n const handleReflectorIdMessage = (evt) => __awaiter(this, void 0, void 0, function* () {\n const responseBuffer = yield decodeBytes(evt);\n if (state.__type === 'connecting') {\n if (responseBuffer.byteLength == 0) {\n throw new Error('Encountered unexpected message while connecting');\n }\n const reflectorId = getReflectorIdFromByteArray(responseBuffer);\n state = {\n __type: 'reflector_id_received',\n reflectorId: reflectorId\n };\n const associationUrl = yield getRemoteAssociateAndroidIntentURL(associationKeypair.publicKey, config.remoteHostAuthority, reflectorId, config === null || config === void 0 ? void 0 : config.baseUri);\n socket.removeEventListener('message', handleReflectorIdMessage);\n resolve(associationUrl);\n }\n });\n let retryWaitTimeoutId;\n const attemptSocketConnection = () => {\n if (disposeSocket) {\n disposeSocket();\n }\n state = { __type: 'connecting', associationKeypair };\n if (connectionStartTime === undefined) {\n connectionStartTime = Date.now();\n }\n socket = new WebSocket(websocketURL, [WEBSOCKET_PROTOCOL_BINARY, WEBSOCKET_PROTOCOL_BASE64]);\n socket.addEventListener('open', handleOpen);\n socket.addEventListener('close', handleClose);\n socket.addEventListener('error', handleError);\n socket.addEventListener('message', handleReflectorIdMessage);\n disposeSocket = () => {\n window.clearTimeout(retryWaitTimeoutId);\n socket.removeEventListener('open', handleOpen);\n socket.removeEventListener('close', handleClose);\n socket.removeEventListener('error', handleError);\n socket.removeEventListener('message', handleReflectorIdMessage);\n };\n };\n attemptSocketConnection();\n });\n // Wallet Connection Phase\n // here we return the association URL (containing the reflector ID) to the caller + \n // a promise that will resolve the MobileWallet object once the wallet connects.\n let sessionEstablished = false;\n let handleClose;\n return { associationUrl, close: () => {\n socket.close();\n handleClose();\n }, wallet: new Promise((resolve, reject) => {\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const jsonRpcResponsePromises = {};\n const handleMessage = (evt) => __awaiter(this, void 0, void 0, function* () {\n const responseBuffer = yield decodeBytes(evt);\n switch (state.__type) {\n case 'reflector_id_received':\n if (responseBuffer.byteLength !== 0) {\n throw new Error('Encountered unexpected message while awaiting reflection');\n }\n const ecdhKeypair = yield generateECDHKeypair();\n const binaryMsg = yield createHelloReq(ecdhKeypair.publicKey, associationKeypair.privateKey);\n if (encoding == 'base64') {\n socket.send(fromUint8Array$1(binaryMsg));\n }\n else {\n socket.send(binaryMsg);\n }\n state = {\n __type: 'hello_req_sent',\n associationPublicKey: associationKeypair.publicKey,\n ecdhPrivateKey: ecdhKeypair.privateKey,\n };\n break;\n case 'connected':\n try {\n const sequenceNumberVector = responseBuffer.slice(0, SEQUENCE_NUMBER_BYTES);\n const sequenceNumber = getSequenceNumberFromByteArray(sequenceNumberVector);\n if (sequenceNumber !== (lastKnownInboundSequenceNumber + 1)) {\n throw new Error('Encrypted message has invalid sequence number');\n }\n lastKnownInboundSequenceNumber = sequenceNumber;\n const jsonRpcMessage = yield decryptJsonRpcMessage(responseBuffer, state.sharedSecret);\n const responsePromise = jsonRpcResponsePromises[jsonRpcMessage.id];\n delete jsonRpcResponsePromises[jsonRpcMessage.id];\n responsePromise.resolve(jsonRpcMessage.result);\n }\n catch (e) {\n if (e instanceof SolanaMobileWalletAdapterProtocolError) {\n const responsePromise = jsonRpcResponsePromises[e.jsonRpcMessageId];\n delete jsonRpcResponsePromises[e.jsonRpcMessageId];\n responsePromise.reject(e);\n }\n else {\n throw e;\n }\n }\n break;\n case 'hello_req_sent': {\n const sharedSecret = yield parseHelloRsp(responseBuffer, state.associationPublicKey, state.ecdhPrivateKey);\n const sessionPropertiesBuffer = responseBuffer.slice(ENCODED_PUBLIC_KEY_LENGTH_BYTES);\n const sessionProperties = sessionPropertiesBuffer.byteLength !== 0\n ? yield (() => __awaiter(this, void 0, void 0, function* () {\n const sequenceNumberVector = sessionPropertiesBuffer.slice(0, SEQUENCE_NUMBER_BYTES);\n const sequenceNumber = getSequenceNumberFromByteArray(sequenceNumberVector);\n if (sequenceNumber !== (lastKnownInboundSequenceNumber + 1)) {\n throw new Error('Encrypted message has invalid sequence number');\n }\n lastKnownInboundSequenceNumber = sequenceNumber;\n return parseSessionProps(sessionPropertiesBuffer, sharedSecret);\n }))() : { protocol_version: 'legacy' };\n state = { __type: 'connected', sharedSecret, sessionProperties };\n const wallet = createMobileWalletProxy(sessionProperties.protocol_version, (method, params) => __awaiter(this, void 0, void 0, function* () {\n const id = nextJsonRpcMessageId++;\n const binaryMsg = yield encryptJsonRpcMessage({\n id,\n jsonrpc: '2.0',\n method,\n params: params !== null && params !== void 0 ? params : {},\n }, sharedSecret);\n if (encoding == 'base64') {\n socket.send(fromUint8Array$1(binaryMsg));\n }\n else {\n socket.send(binaryMsg);\n }\n return new Promise((resolve, reject) => {\n jsonRpcResponsePromises[id] = {\n resolve(result) {\n switch (method) {\n case 'authorize':\n case 'reauthorize': {\n const { wallet_uri_base } = result;\n if (wallet_uri_base != null) {\n try {\n assertSecureEndpointSpecificURI(wallet_uri_base);\n }\n catch (e) {\n reject(e);\n return;\n }\n }\n break;\n }\n }\n resolve(result);\n },\n reject,\n };\n });\n }));\n sessionEstablished = true;\n try {\n resolve(wallet);\n }\n catch (e) {\n reject(e);\n }\n break;\n }\n }\n });\n socket.addEventListener('message', handleMessage);\n handleClose = () => {\n socket.removeEventListener('message', handleMessage);\n disposeSocket();\n if (!sessionEstablished) {\n reject(new SolanaMobileWalletAdapterError(SolanaMobileWalletAdapterErrorCode.ERROR_SESSION_CLOSED, `The wallet session was closed before connection.`, { closeEvent: new CloseEvent('socket was closed before connection') }));\n }\n };\n }) };\n });\n}\n\nexport { SolanaCloneAuthorization, SolanaMobileWalletAdapterError, SolanaMobileWalletAdapterErrorCode, SolanaMobileWalletAdapterProtocolError, SolanaMobileWalletAdapterProtocolErrorCode, SolanaSignInWithSolana, SolanaSignTransactions, startRemoteScenario, transact };\n"],"names":[],"mappings":";;AAgHA;AACA;AACA;AACO,SAAS,uBAAuB,CAAC,KAAK,EAAE;AAC/C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,IAAI,IAAI,OAAO,GAAG,CAAC,EAAE,KAAK,CAAC,MAAM,CAAC,iDAAiD,CAAC;AACpF,IAAI,OAAO,IAAI,CAAC,EAAE,KAAK,CAAC,OAAO,CAAC,CAAC;AACjC,IAAI,IAAI,KAAK,CAAC,SAAS,EAAE;AACzB,QAAQ,OAAO,IAAI,CAAC,IAAI,EAAE,KAAK,CAAC,SAAS,CAAC,CAAC;AAC3C,IAAI;AACJ,IAAI,MAAM,MAAM,GAAG,EAAE;AACrB,IAAI,IAAI,KAAK,CAAC,GAAG,EAAE;AACnB,QAAQ,MAAM,CAAC,IAAI,CAAC,CAAC,KAAK,EAAE,KAAK,CAAC,GAAG,CAAC,CAAC,CAAC;AACxC,IAAI;AACJ,IAAI,IAAI,KAAK,CAAC,OAAO,EAAE;AACvB,QAA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