TokenAdminRegistry - #857
Conversation
61c90bd to
39f16f8
Compare
| struct OffRamp_Deployables { | ||
| rmnRouter: address; | ||
| // Separate TokenAdminRegistry root used to derive deterministic entries. | ||
| tokenAdminRegistry: address; |
There was a problem hiding this comment.
Probably doesn't make sense to have this both here and in Config
There was a problem hiding this comment.
I agree this belongs only to the static config
There was a problem hiding this comment.
Oh, I see there's no StaticConfig struct. Why though?
There was a problem hiding this comment.
It's just the way we implemented this originally, I'm not sure there's a reason beyond that
| struct (0xaf3c62b3) CCIPSendExecutor_Execute { | ||
| onrampSend: OnRamp_Send, | ||
| // Derived by the OnRamp rather than supplied by the Router. | ||
| tokenRegistry: address?, |
There was a problem hiding this comment.
I'd put it in Config together with all the other addresses
* feat: overflow static analyzer * ref: move shared toml.ts lib * feat: run with nix * feat: add type notation * fix: fmt and wrong file * fix: comments
* Add TP <> ContextExecutor integration to support async flow continuation * Stash current behaviour - throw on error in transfer continuation * Lock or burn transfer error handling and return * LockReleaseLockboxTokenPool use ContextExecutor vs. local st * yarn fmt * Fix lint * Update Go bindings * Share code in TP lib + docs * CE - wait for deploy confirmation before continuation * Fix golangci-lint * Remove local review * Add TODOs for forwardTonAmount * Migrate CE to OffRampAccount to support async flow * Fix lock_release & lockbox flow * Embed AskToTransfer in oa withdraw, check msg.transferInitiator == null on mint * Document OffRampAccount contract * TP compose consumeIn/OutboundRateLimit functions * Replace CE on burn_mint burn path with CCT burn flow fwdPayload * Fix oplint * rm tests/debug_cells.test.ts * Add OnRampAccount + handle TP deposit auth * Improve TP error handling - return transfer * PR feedback - missing lazy * Fix lint * Fix test
* Add TP <> ContextExecutor integration to support async flow continuation * Stash current behaviour - throw on error in transfer continuation * Lock or burn transfer error handling and return * LockReleaseLockboxTokenPool use ContextExecutor vs. local st * yarn fmt * Fix lint * Update Go bindings * Share code in TP lib + docs * CE - wait for deploy confirmation before continuation * Fix golangci-lint * Remove local review * Add TODOs for forwardTonAmount * Migrate CE to OffRampAccount to support async flow * Fix lock_release & lockbox flow * Embed AskToTransfer in oa withdraw, check msg.transferInitiator == null on mint * Document OffRampAccount contract * TP compose consumeIn/OutboundRateLimit functions * Replace CE on burn_mint burn path with CCT burn flow fwdPayload * Fix oplint * rm tests/debug_cells.test.ts * Add OnRampAccount + handle TP deposit auth * Improve TP error handling - return transfer * PR feedback - missing lazy * DepositAccount contract for on/off-ramp escrows * Remove DepositAccount allowedJettonWallet * Fix lint * DepositAccount Go bindings * Simplify deposit acc bounce handling * Post merge fix - rm accounts/off_ramp_account * Remove ContextExecutor contract - replaced with deposit acc * Update Go bindings and add TP contracts to pkg archive * Fix Go bindings - exit codes * Update pool FQN and exit codes * Fix exit codes
* feat: use LockRelease TokenPool for tests * fix: go tests and deployment sequences * fix: missing Pools in the generator script * fix: DepositAccount code missing from Token Pool * fix: pin ton version
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
…851) * fix: DefaultTokenDestGasOverhead * fix: fund LockRelease Token Pool * fix: golint * feat: fetch DepositAccount from TP * fix: missmatch in Any2TVMTokenTransfer go binding * doc: TODO missing gap * fix: Execute amount didn't account for TokenTransfer flow * fix: extractDestGasAmountFromMap should handle int64 * fix: update DefaultTokenDestGasOverhead * fix: offramp missing from TokenPool config * fix: broken TokenPool funding * DataStore was outdated * error finding TP in Datastore was ignored * Missing wait and check after minting * fix: raise forwardTonAmount on offRamp account notification * fix: ExtraData is optional * fix: nix hash * test: updated gas calculation in transmiter * fix: OffRamp_DispatchValidated value too low * chore: bump imports to chainlink-ccip/deployment * chore: bump imports to chainlink-ccip/deployment * fix: unpin ton version * fix: breaking change * fix: ping ugorji/go/codec version * fix: mock UltraFastCurseMCMS
* fix: remove local replace for cciplib * fix: nix hash * fix: remove env var guard on token transfer config and pool funding * fix: bump to latest in feat/e2e-ton-as-dest
* Resolve loader relative paths via CWD * Remove stale test * Update .core_version - long running branch, build fix * Bump ContractsPackageLatestSupported to contracts/1.6.2
Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
* fix lodash & protobufjs * update lock.nix * fixes * Update to nixpkgs >= 26.11, drop x86_64-darwin support * lint * fix lint * nix * nix * nix * nix * nix * mockery --------- Co-authored-by: Kristijan <kristijan.rebernisak@gmail.com>
duck-types
left a comment
There was a problem hiding this comment.
Great PR. I'd rather pass through the TokenAdminRegistry contract for ownership changes. That way, we can change how the checks are applied, for future implementation of self registration.
| struct OffRamp_Deployables { | ||
| rmnRouter: address; | ||
| // Separate TokenAdminRegistry root used to derive deterministic entries. | ||
| tokenAdminRegistry: address; |
There was a problem hiding this comment.
I agree this belongs only to the static config
| struct OffRamp_Deployables { | ||
| rmnRouter: address; | ||
| // Separate TokenAdminRegistry root used to derive deterministic entries. | ||
| tokenAdminRegistry: address; |
There was a problem hiding this comment.
Oh, I see there's no StaticConfig struct. Why though?
| // ownership state changes such as a pending owner. | ||
| struct OnRamp_DeployablesConfig { | ||
| executor: ExecutorDeployment; | ||
| tokenAdminRegistry: address; |
There was a problem hiding this comment.
Why don't you use OnRamp_DynamicConfig? It already holds feeQuoter ande feeAggregator. I don't think deployable is the right name because the OnRamp is not deploying the tokenAdminRegistry. It's for authorization checks.
There was a problem hiding this comment.
Yeah but I still need to use the Deployable code to calculate the adderss of the TokenAdminRegistry entry.
I didn't like that I had to access the ExecutorDeployment struct to get the Deployable code to get the address of something completely unrelated to the Executor.
Tbh, I think this is just a temporary thing. I really want us to move to inlined instead of stored code cells for sub-contracts and I was planning on picking that up as a follow-up for this work
There was a problem hiding this comment.
refactor in progress to inline all deployable contract dependencies: #873
| administrator: address? | ||
| pendingAdministrator: address? |
There was a problem hiding this comment.
Why not use Ownable2Step instead?
| newAdministrator: address? | ||
| } | ||
|
|
||
| struct (0xd1fbd97c) TokenAdminRegistryEntry_AcceptAdminRole {} |
There was a problem hiding this comment.
Proposal:
- Add
queryIDs to all messages for easier traceability. - the
on<MessageName>()handlers in contract.tolk should always receive the message, even if it doesn't have data. It makes it easier to navigate the code. When you search for references of the message type, you can find the message handler directly, instead of going through the match.
| @@ -0,0 +1,51 @@ | |||
| import "types" | |||
|
|
|||
| type TokenAdminRegistryEntry_InMessage = | |||
There was a problem hiding this comment.
Shall we add SetEnabled(enabled: bool) message?
* Add TP <> ContextExecutor integration to support async flow continuation * Stash current behaviour - throw on error in transfer continuation * Lock or burn transfer error handling and return * LockReleaseLockboxTokenPool use ContextExecutor vs. local st * yarn fmt * Fix lint * Update Go bindings * Share code in TP lib + docs * CE - wait for deploy confirmation before continuation * Fix golangci-lint * Remove local review * Add TODOs for forwardTonAmount * Migrate CE to OffRampAccount to support async flow * Fix lock_release & lockbox flow * Embed AskToTransfer in oa withdraw, check msg.transferInitiator == null on mint * Document OffRampAccount contract * TP compose consumeIn/OutboundRateLimit functions * Replace CE on burn_mint burn path with CCT burn flow fwdPayload * Fix oplint * rm tests/debug_cells.test.ts * Add OnRampAccount + handle TP deposit auth * Improve TP error handling - return transfer * PR feedback - missing lazy * DepositAccount contract for on/off-ramp escrows * Remove DepositAccount allowedJettonWallet * Fix lint * DepositAccount Go bindings * Simplify deposit acc bounce handling * Add withdrawable fee jettons via JettonWithdrawable * Fix lint * Add Go bindings + tlbe.Array * Polish docs and fix lint * Remove CE files post merge, polish * Polish + rm unused compilation targets * Fix lock/release tp fee withdrawal + Go bindings * Add proper isZeroAddress check * Fix withdrawable maxAmount checks * Improve value check onWithdraw via reserve * Add Jetton_ForwardPayloadWrap, used by JettonWithdrawable * Remove duplicated field - ctx.withdrawInitiator * PR feedback + polish * Fix oplint * Fix Go binding - lock/release storage
… vv/TokenAdminRegistry
| // participant ReceiveExecutor | ||
|
|
||
| // Receiver ->> Router: Receiver_CCIPReceiveV2 (bounce) | ||
| // Receiver ->> Router: Receiver_CCIPReceive (bounce) |
There was a problem hiding this comment.
Merged incorrectly, i'll stick to CCIPReceiveV2
No description provided.