diff --git a/packages/beacon-dapp/src/dapp-client/DAppClient.ts b/packages/beacon-dapp/src/dapp-client/DAppClient.ts index ef6067219..aa37326e8 100644 --- a/packages/beacon-dapp/src/dapp-client/DAppClient.ts +++ b/packages/beacon-dapp/src/dapp-client/DAppClient.ts @@ -1778,6 +1778,14 @@ export class DAppClient extends Client { throw await this.sendInternalError('No active account!') } + if ( + input.operationDetails.some( + (detail: any) => detail.amount && Number(detail.amount) > Number.MAX_SAFE_INTEGER * 1_000_000 + ) + ) { + throw await this.sendInternalError('The amount requested is too large.') + } + const request: OperationRequestInput = { type: BeaconMessageType.OperationRequest, network: activeAccount.network || this.network,