Skip to content

fix(gateway): fix withdrawal edge-case #19

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Oct 23, 2024
Merged

Conversation

swift1337
Copy link
Contributor

This should not happen, but if so - the gateway could have been drained by gas fees and infinite retry when the signed withdrawal amount is larger than total_locked funds

@swift1337 swift1337 added the bug Something isn't working label Oct 22, 2024
@swift1337 swift1337 self-assigned this Oct 22, 2024
Copy link

@fbac fbac left a comment

Choose a reason for hiding this comment

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

LGTM, left a minor comment.

@swift1337 swift1337 merged commit fbf587f into main Oct 23, 2024
3 checks passed
github-merge-queue bot pushed a commit to zeta-chain/node that referenced this pull request Oct 30, 2024
* Apply changes from recent Gateway refactoring

* Move GW logic to pkg/contracts/ton. Fix E2E tests

* Implement watchRPCStatus() for TON

* Implement watchGasPrice() for TON

* Add Withdraw message w/ payload signature

* Minor refactoring

* Add TON signer

* Add withdrawal parsing; Update Gateway with a fix of zeta-chain/protocol-contracts-ton#19

* Add signer tests

* Add addOutboundTracker to *observer*; Add TSS cache for signatures

* Update GW (zeta-chain/protocol-contracts-ton#20)

* Add test cases for withdrawals in observeGateway()

* Add observe outbound

* Enforce additional validation on withdrawal parsing

* Implement TON cctx scheduler

* Implement TON VoteOutboundIfConfirmed

* TON withdrawal E2E

* Update changelog

* gosec

* Address PR comments [1]

* Address PR comments [2]

* Address PR comments [3]

* Address PR comments [4]

* Bump ton-docker image version

* gosec

* Address PR comments [5]

* Rollback to prev. ton-docker

* Address PR comments [6]
github-merge-queue bot pushed a commit to zeta-chain/node that referenced this pull request Oct 30, 2024
* Apply changes from recent Gateway refactoring

* Move GW logic to pkg/contracts/ton. Fix E2E tests

* Implement watchRPCStatus() for TON

* Implement watchGasPrice() for TON

* Add Withdraw message w/ payload signature

* Minor refactoring

* Add TON signer

* Add withdrawal parsing; Update Gateway with a fix of zeta-chain/protocol-contracts-ton#19

* Add signer tests

* Add addOutboundTracker to *observer*; Add TSS cache for signatures

* Update GW (zeta-chain/protocol-contracts-ton#20)

* Add test cases for withdrawals in observeGateway()

* Add observe outbound

* Enforce additional validation on withdrawal parsing

* Implement TON cctx scheduler

* Implement TON VoteOutboundIfConfirmed

* TON withdrawal E2E

* Update changelog

* gosec

* Address PR comments [1]

* Address PR comments [2]

* Address PR comments [3]

* Address PR comments [4]

* Bump ton-docker image version

* gosec

* Address PR comments [5]

* Rollback to prev. ton-docker

* Address PR comments [6]
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants