Skip to content

chore: CCTPv2 destinationCaller for managed relayer#12664

Merged
mergify[bot] merged 6 commits into
masterfrom
dc-537
May 21, 2026
Merged

chore: CCTPv2 destinationCaller for managed relayer#12664
mergify[bot] merged 6 commits into
masterfrom
dc-537

Conversation

@dckc

@dckc dckc commented May 13, 2026

Copy link
Copy Markdown
Member

closes: AGO-537

Description

Enable CCTP v2 direct EVM-to-EVM USDC transfers with a managed relayer (destinationCaller) to reduce latency from ~18 min to ~60 sec.

  • CCTPv2.apply passes the relayer as destinationCaller to depositForBurn (padded to bytes32); falls back to ZERO_BYTES32 when unset
    • Add optional cctpRelayer address to per-chain contract configs
    • Flow test decodes the GMP memo and asserts the correct relayer address
  • Golden override JSON files for ymax0 and ymax1, validated against chain data
    • ymax-upgrade-run-logs --save-txs <n> dumps recent upgrade transactions for override extraction

Security Considerations

Setting destinationCaller to a managed relayer address makes that relayer required for destination-chain receipt. If the configured address is wrong, unavailable, or loses key control, the mint cannot be completed by another relayer under the normal any-caller flow.

Scaling Considerations

n/a

Testing Considerations

  • Added explicit destinationCaller verification to the CCTPv2 flow test (decodes GMP memo)
  • evm-overrides.test.ts validates shape on computed overrides, compares contract addresses against golden files

Upgrade Considerations

Backwards compatible — cctpRelayer is optional, v1 flows don't set cctpVersion = 2n. Relayer addresses from PAK-354 required before adding to privateArgsOverrides at upgrade time. ymax0 upgrades run via CI; ymax1 via Makefile.

@dckc dckc force-pushed the dc-537 branch 10 times, most recently from 933c6c2 to 534e192 Compare May 14, 2026 23:14
@dckc dckc marked this pull request as ready for review May 14, 2026 23:17
@dckc dckc requested review from LuqiPan, mhofman and usmanmani1122 May 14, 2026 23:22

@mhofman mhofman left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm surprised the design doesn't call for a vstorage difference for CCTP v1 vs v2 transfers. In particular the destinationCaller address is a piece of information that may be operationally relevant (e.g. if / when we need to rotate / update the relayer mechanism).

Comment thread packages/portfolio-contract/src/portfolio.contract.ts Outdated
Comment thread packages/portfolio-contract/src/pos-evm.flows.ts
@mhofman

mhofman commented May 15, 2026

Copy link
Copy Markdown
Member

Restricting destinationCaller prevents unauthorized relayers from front-running the mint.

That sounds like a dubious security claim. Will discuss this offline.

@dckc dckc added the bypass:integration Prevent integration tests from running on PR label May 21, 2026
@dckc dckc requested a review from mhofman May 21, 2026 18:47
@dckc dckc added the automerge:rebase Automatically rebase updates, then merge label May 21, 2026
dckc added 4 commits May 21, 2026 14:03
…VM CCTPv2

Add cctpRelayer test address to Optimism mock. Decode GMP memo in
CCTPv2 flow test and assert depositForBurn receives the correct
destinationCaller.

Also document that real relayer addresses are TBD from PAK-354.
Latest upgrade txs:
  ymax0: 2026-03-25  tx 59A19F0B97B1ACE150CB0C2FCFE188487BC7921A303FAA2F94462E9398BF7A5B
  ymax1: 2026-04-03  tx CB97FABCE49DFD8957CE92641112380C10A91B0641F2C6EB4CFE2C9CCA953928
@mhofman mhofman removed the automerge:rebase Automatically rebase updates, then merge label May 21, 2026

@mhofman mhofman left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, but removing the automerge label to let you address non blocking feedback

Comment thread packages/portfolio-contract/test/portfolio.flows.test.ts
Comment thread packages/portfolio-contract/test/portfolio.flows.test.ts Outdated
Comment thread packages/portfolio-deploy/src/axelar-configs.js
@dckc dckc added the automerge:rebase Automatically rebase updates, then merge label May 21, 2026
@mergify mergify Bot merged commit 20cc70c into master May 21, 2026
104 of 105 checks passed
@mergify mergify Bot deleted the dc-537 branch May 21, 2026 22:34
mergify Bot added a commit that referenced this pull request May 22, 2026
)

refs:
 - #12454 
 - #12415
 - #12664

## Description

re-enable CCTPv2 routes in planner by reverting #12454

### Security / Scaling Considerations

none beyond #12454  (which has "n/a")

There is perhaps an availability impact; resolver responsibility is different as of #12664.

### Documentation Considerations

none beyond #12454

### Testing Considerations

 - restores some tests

### Upgrade Considerations

requires contract is upgraded to include #12664 (done for ymax0; see [ymax-v0.3.2605-beta1 release](https://github.com/Agoric/agoric-sdk/releases/tag/ymax-v0.3.2605-beta1) ).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

automerge:rebase Automatically rebase updates, then merge bypass:integration Prevent integration tests from running on PR

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants