Analyze Proxy Contract Storage

Use a real proxy, implementation, block, and slot to distinguish the state address from the code and layout source.

Case objective

Determine where proxy state is stored, which contract supplies the storage layout, and how to read and verify a raw slot at a specific block.

Example transaction and context

This case continues with the transaction from block 17806056:

0xa84aa065ce61dbb1eb50ab6ae67fc31a9da50dd2c74eefd561661bfce2f1620c

Open the transaction in Skylens

The target is the Curve pETH-ETH-f pool. Users interact with minimal proxy 0x9848482da3Ee3076165ce6497eDA906E66bB85C5, while implementation 0x6326DEbBAa15bCFE603d831e7D75f4fc10d9B43E supplies the executable code.

Questions to answer

  1. Should state be read from the proxy or the implementation?
  2. Which address supplies the storage layout?
  3. How does slot 8 at the target block map to SSTORE operations in the transaction?

Investigation steps

  1. Open the proxy address and load its implementation in Proxy Storage.
  2. Keep the proxy as the state address; use the implementation only as the source of code and storage layout.
  3. Locate slot 8 in Storage Layout. If the variable cannot be decoded reliably, preserve the raw slot as the query key.
  4. Query the slot at block 17806056 and compare it with the transaction's State Changes.
  5. Jump from State Changes to Execution Trace and verify that SSTORE operations in implementation code write to the proxy context.

Key evidence

EvidenceValue
State addressProxy 0x9848482da3Ee3076165ce6497eDA906E66bB85C5
Layout / code sourceImplementation 0x6326DEbBAa15bCFE603d831e7D75f4fc10d9B43E
Query block17806056
Storage keyslot 8 (0x...0008)
Before0x00000000000000000000000000000000000000000000014f4ef71451a6d37997
After0x00000000000000000000000000000000000000000000003f3278e0363aaefcf
SSTORE traces69, 87, 105, 144, 194

These facts preserve three distinct identities:

  • State identity: the proxy address.
  • Code and layout identity: the implementation address.
  • Historical context: the transaction and block 17806056.

Reading slot 8 directly from the implementation would return the implementation's own storage, not the pool's business state.

Conclusion

The implementation supplies code for the pETH-ETH-f pool, but slot 8 is stored on the proxy. Five SSTORE operations execute implementation code while State Changes correctly attributes the state to the proxy. Reading proxy state therefore requires the implementation layout, proxy storage, and target block together.

Caveats

  • The historical block must use the implementation active at that time; the current implementation may not explain old state.
  • An implementation can itself be a proxy, requiring another nested implementation lookup.
  • Namespaced layouts using @custom:storage-location should be decoded with EIP-7201 Decoder.
  • Until a layout is verified, report the address, slot, and raw value instead of presenting a guessed variable name as fact.