Skip to content

Conversation

@aliXsed
Copy link
Collaborator

@aliXsed aliXsed commented Sep 17, 2025

This pull request introduces important safety and usability improvements to the L1Nodl and L1Bridge contracts. The main updates include enhanced input validation to prevent zero address errors, new helper functions for quoting L2 execution costs, and a minor fix to the withdrawal finalization process.

The suggestions from Resonance Security audit are mostly taken except for the followings:

  • RES-01 “Unbounded ETH Forwarded to Mailbox”: We retain the exact-match ETH forwarding model (no capping/refund) to minimize avoidable failures and align with zkSync BridgeHub’s design, which shifts fee calculation to caller/off-chain code. However, we add helpers to allow integrators pre-compute msg.value without calling Mailbox directly.
  • RES-02 Pausing Contracts Block Deposit Finalization: We consider the current functionality which pauses all major interactions with the bridge as the intended behavior. Many other production bridges do block finalization when the bridge is paused. Since for us "pause" is intended only for emergency situations, we can make this more conservative decision.

Address RES-01 “Unbounded ETH Forwarded to Mailbox” from Resonance’s audit by exposing read-only helpers that return the exact base cost as computed by the zkSync Mailbox. We retain the exact-match ETH forwarding model (no capping/refund) to minimize avoidable failures and align with zkSync BridgeHub’s design, which shifts fee calculation to caller/off-chain code.
The added helpers will let integrators pre-compute msg.value without calling Mailbox directly.
@aliXsed aliXsed merged commit fe5f1ff into main Sep 26, 2025
1 check passed
@aliXsed aliXsed deleted the aliX/address-audit-comments branch September 26, 2025 02:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants