When funds are withdrawn, bridge operators do not check how much was initially deposited by an address and, as long as the withdrawing address deposited in the past, their withdrawals will be granted -no matter how much they deposited.
From documentation:
The bridge operator is in charge of signing withdrawal requests submitted by users. These will be submitted on the L2 component of the bridge, not included here. Our service will validate the payloads submitted by users, checking that the account submitting the withdrawal has first originated a successful deposit in the L1 part of the bridge.
Note that bridge operators do not check amounts of deposits per address. The operators only check that the user deposited at some point in the past. It is not mentioned anywhere in the documentation, nor is it coded anywhere to check amounts of deposits before withdrawing.
Not checking deposit amounts can lead to withdrawals being larger than initial deposits.
src/L1BossBridge.sol
https://github.com/Cyfrin/2023-11-Boss-Bridge/blob/dad104a9f481aace15a550cf3113e81ad6bdf061/src/L1BossBridge.sol#L91
Funds can be drained by a single withdraw function by a user that deposited in the past.
It is recommended that when a user makes a deposit there exists a mapping that will keep track of how much a address deposited total. That address can only withdraw up to that amount of funds.
Manual Audit
Foundry
The contest is live. Earn rewards by submitting a finding.
This is your time to appeal against judgements on your submissions.
Appeals are being carefully reviewed by our judges.