Repository navigation
v0.5.97
Fixes from QA's independent review (Codex, re-checked by QA against dist/) of 0.5.96.
- Owner recipient pins on bridges. An owner's
recipientslist on abridgeadmission, or on one alternative of it, was never checked by LI.FI (Across, Stargate) or by either direct Stargate V2 lane. Any recipient passed, against the documented contract. LI.FI checks the pin at prepare, approval, reservation and first send. The Stargate token lane checks it at prepare, before the approval and the send, and at the usage hold. The Stargate native lane checks it at prepare and at the usage hold taken right before signing, including a retried hold. A recipient the pin does not list is refused withAPN_ALLOWLIST_REFUSED/allowlist_recipient_not_admitted. The lanes that may only pay the owner (BNB, Monad, Linea native; both Stargate lanes) are still bound by the pin: a pin that does not list the owner refuses them. - ETH to BNB (Across + Fly), a run that dies after saving the destination proof. A resume that found a saved proof always wrote
completed. For a savedrecovered_weth,below_floororprotocol_mismatchproof thatcompletedfailed validation on every resume, and since bridges have no abandon, the operation stayed open. A saved proof now settles through the same outcome as a fresh one, and a new proof is saved in the same transition as its end, so a run can no longer die between them. - Linea, Monad and BNB native destinations, a recipient that also spends in the fill block. The recipient's balance change across the block was required to cover the output, so a same-block spend left the operation unprovable forever (it held its profile and account claims), and on BSC turned a delivered fill into
protocol_mismatch. The call trace is now the proof: its root must be the verified transaction itself (sender, target and calldata, with no error), and the delivery call and every call above it must have succeeded. The BNB composite trace now also checks the root's target, and a root that is not the verified transaction is read again on the next resume instead of ending the operation asprotocol_mismatch. The balance change is kept as corroboration; a negative one is stored asnull. - Stargate V2 token lane (OP Mainnet USDC to Polygon), native debit cap. The cap counted value plus gas only. OP Mainnet also charges an L1 data fee and an operator fee on each transaction. Prepare now reads both upper bounds for each signed transaction at one pinned block (
getL1FeeUpperBound,getOperatorFee), stores them, and counts them in the cap, the staged gas ceiling and the balance check. They are read again before the approval, after it and before the send. A failed read refuses. Once the approval has landed, the bridge's budget is charged the approval's real cost from its receipt; without the receipt's fee fields, it is charged its gas limit times its max fee plus the larger of the prepare and before-approval L1 and operator bounds. Optimism's L1 bound is a practical bound at the read block's L1 prices, not a hard maximum. The consent screen shows the bounds. Operations are now record v6. v5 records stay readable, but their only new signature can be the owner-consented allowance revoke in cleanup:op_stack_fees_unbound_repreparebefore the approval, and cleanup once the approval has landed. A transient RPC error before the send now keeps the operation for the next run instead of sending it to cleanup; a reverted call or estimate is not transient and still goes to cleanup with its own reason. A usage hold that never reached its send marker is released asfailed_before_effecton expiry, on the v5 refusal and when cleanup ends. - Stargate V2 token lane, approval window. With an existing allowance the expiry was not checked again between the preflight and the send marker, so a lock wait could carry the send past
expires_at. It is now checked before the marker, and a late send goes to cleanup with reasonexpired_before_marker. - Local gasless (EIP-7702), delegation revoked after a successful transfer. The settlement proof required the delegation to still be in place at the latest head, so a revocation left a sent transfer at
unknown_finality(gasless_receipt_unresolved). The safe receipt and the consumed nonces prove the transfer, and the delegation no longer has to persist: a revoked delegation completes the operation and showsdelegation_persists: false. Delegation to another contract is still refused. - LI.FI bridge journal capacity. Each transition copies the operation's state, so the 1 MiB journal could fill after about 90 transitions. After that every change was refused, including the terminal one, and the operation stayed open with its claims. Transitions are now classed:
- ordinary transitions stop with 128 KiB still free;
- proofs that close the operation keep 32 KiB and up to 7 slots past 512; a provider hint with no room left is carried to the end instead;
- the destination proof is saved together with the operation's end, as its terminal transition, which is always recorded: without read telemetry if that is what does not fit, and in a journal an earlier release filled to 1 MiB, up to 64 KiB past it.
Downgrading in the middle of an operation is unsupported. 0.5.96 and earlier reject these new records:
- a native fill with a short or
nullbalance change; - a Stargate v6 record;
- a gasless record that completed after its delegation was revoked;
- a LI.FI journal longer than 512 transitions, or a finished one larger than 1 MiB.