[SMRT] TokenPoolFactory 1.5.1 on 0G and Plume stores address(160) as the hooks of a 2.0 burn-mint pool

Aperta
#23,896 1 commento 0 reazioni 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 1 giorno

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
4/5
Tempo stimato
3-5 giorni
Idoneità per principianti
43/100
Tipo di issue
Bug
Chiarezza
Specificata chiaramente
Stato di attività
Attiva
Stack tecnologico
solidity
Ambito
release

Direzione di ricerca

Start with the linked write-up and the TokenPoolFactory 2.0.0 reference, then compare the stated 1.5.1 and 2.0.0 burn-mint deployment arguments and selectors. Check the CCIP mainnet directory entries for 0G and Plume; done means the deployed factory matches 2.0.0 and can deploy a usable BurnMintTokenPool 2.0.0 with the intended hooks value.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

Description

On 0G and on Plume, deploying BurnMintTokenPool 2.0.0 through the TokenPoolFactory that is actually on the chain succeeds, and the resulting pool cannot move tokens.

Both factories are TokenPoolFactory 1.5.1. On the burn-mint path that version appends an empty address[] allowlist. For this argument list the third constructor word is the offset of that empty array, 0xa0. BurnMintTokenPool 2.0.0 reads the third word as the hooks address, so the pool stores address(160).

The constructor rejects a zero token, a zero router, and a zero RMN proxy. It does not reject a nonzero hooks address, so the deploy goes through. There is no code at address(160). The pool calls that address on lock, burn, release, and mint, and the call reverts. Nothing is stolen and no extra supply is minted. The pool just cannot be used.

The full write-up is here: https://hackmd.io/@u2135/chainlink-0g-factory-deployment-gap

Basic Information

Read on 3 October 2026 from the CCIP mainnet directory and from typeAndVersion() / getOnRamp(5009297550715157269) on each chain. 5009297550715157269 is the Ethereum mainnet selector. Both routers report Router 1.2.0. This is the on-ramp version, not a claim that every contract on the lane is 2.0.0.

Chain Chain id TokenPoolFactory 1.5.1 On-ramp toward Ethereum
0G 16661 0x094Ffe96db4e8bC05CF3D4bD4aCc4B7E770ba7d8 OnRamp 2.0.0 0xE274394930b6DE984acDDFfea11dd555209A82AA
Plume 98866 0xF41a468dBcD9f626ceB56E8691Df3d5B7bdd3015 OnRamp 2.0.0 0x402430ca607c52a99aa82ab4c726001d4203c9e7

The 0G factory is not a proxy, and owner() reverts, so the chain cannot upgrade the contract that is already there.

The same 1.5.1 factory is also listed on Edge (3343), Zora (7777777), Merlin (4200), and Metal L2 (1750). Their on-ramps toward Ethereum are still OnRamp 1.6.0 or EVM2EVMOnRamp 1.5.0, so a 1.5 pool still matches those lanes. The factory becomes the same problem when it is given 2.0 pool bytecode. Addresses are in the write-up.

The 1.5.1 bytecode contains deployTokenAndTokenPool (0xeb03cac1) and deployTokenPoolWithExistingToken (0x169ed058). Those are the pre-lockbox selectors. The 2.0 factory selectors are not in that bytecode.

Steps to Reproduce

  1. Call typeAndVersion() on either factory above. It returns TokenPoolFactory 1.5.1.
  2. On the burn-mint path the factory appends abi.encode(token, decimals, new address[](0), rmnProxy, router).
  3. With those five values, the third word of the head is the offset of the empty array, 0xa0 (160).
  4. The BurnMintTokenPool 2.0.0 constructor is (token, uint8 decimals, address hooks, rmnProxy, router). It stores that word as hooks, which decodes as address(160).
  5. Deployment succeeds, because a nonzero hooks address is allowed.
  6. The next lock, burn, release, or mint calls address(160) and reverts.

Until a 2.0 factory is on the chain, the workaround is to deploy BurnMintTokenPool 2.0.0 directly and pass address(0) as hooks.

Additional Information

The fix should be to deploy TokenPoolFactory 2.0.0 where the directory still lists 1.5.1. 0G and Plume are the two where the on-ramp toward Ethereum is already 2.0.0.

2.0 factory reference: https://docs.chain.link/ccip/evm/api-reference/v2.0.0/token-pool-factory

The 1.5.1 burn-mint constructor still takes the allowlist as its third argument: https://docs.chain.link/ccip/api-reference/evm/v151/burn-mint-token-pool

Write-up: https://hackmd.io/@u2135/chainlink-0g-factory-deployment-gap

Lingua principale
Go
Stelle
8.3k
Fork
2k
Merge medio
1g 17h
PR unite (30g)
120

Preparare l'ambiente

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di smartcontractkit/chainlink

Tutte le issue di smartcontractkit/chainlink

Issue simili

Altre issue su Go

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.