Skip to content
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

Fix MsgTimeoutOnClose to verify the proof of the channel #2535

Merged
merged 6 commits into from
Aug 10, 2022

Conversation

yito88
Copy link
Contributor

@yito88 yito88 commented Aug 5, 2022

Closes: #2534

Description

  • Fix the conversion from RawMsgTimeoutOnClose to set proof_close to other_proof in MsgTimeoutOnClose
  • Replace the proof to be used for the channel verification

PR author checklist:

  • Added changelog entry, using unclog.
  • Added tests: integration (for Hermes) or unit/mock tests (for modules).
  • Linked to GitHub issue.
  • Updated code comments and documentation (e.g., docs/).
  • Tagged one reviewer who will be the one responsible for shepherding this PR.

Reviewer checklist:

  • Reviewed Files changed in the GitHub PR explorer.
  • Manually tested (in case integration/unit/mock tests are absent).

@yito88 yito88 changed the title fix message conversion and replace proof Fix MsgTimeoutOnClose to verify the proof of the channel Aug 5, 2022
Copy link
Member

@hu55a1n1 hu55a1n1 left a comment

Choose a reason for hiding this comment

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

Thanks for the PR @yito88! Nice catch! 👌
LGTM, but we're missing a .changelog entry. Please feel free to add one based on these guidelines otherwise we'll add one ourselves and hopefully merge early next week.

PS: I think we would be able to avoid such bugs in the future by converting the Proofs struct into an enum based on the suggestion presented here -> https://github.com/informalsystems/ibc-rs/issues/1696#issue-1084534755, but let's do that in a future PR.

@yito88
Copy link
Contributor Author

yito88 commented Aug 5, 2022

@hu55a1n1 Thank you for reviewing! I've added the change log.
cosmos/ibc-rs#25 suggestion sounds better!

@plafer
Copy link
Contributor

plafer commented Aug 8, 2022

Good catch @yito88 , thank you for this! Could you please add a test to make sure there are no regressions on this when we do refactor the Proofs object?

Copy link
Contributor

@plafer plafer left a comment

Choose a reason for hiding this comment

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

Thank you!

Copy link
Member

@hu55a1n1 hu55a1n1 left a comment

Choose a reason for hiding this comment

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

🙏

@hu55a1n1 hu55a1n1 merged commit 6689313 into informalsystems:master Aug 10, 2022
@yito88 yito88 deleted the yuji/fix_timeout_on_close branch August 10, 2022 13:57
yito88 added a commit to heliaxdev/ibc-rs that referenced this pull request Aug 10, 2022
…tems#2535)

* fix message conversion and replace proof

* add change log

* add a test

* add a test

* fix typo

* fix for clippy
yito88 added a commit to heliaxdev/ibc-rs that referenced this pull request Aug 10, 2022
…tems#2535)

* fix message conversion and replace proof

* add change log

* add a test

* add a test

* fix typo

* fix for clippy
hu55a1n1 pushed a commit to hu55a1n1/hermes that referenced this pull request Sep 13, 2022
…tems#2535)

* fix message conversion and replace proof

* add change log

* add a test

* add a test

* fix typo

* fix for clippy
tzemanovic pushed a commit to heliaxdev/ibc-rs that referenced this pull request Oct 19, 2022
…tems#2535)

* fix message conversion and replace proof

* add change log

* add a test

* add a test

* fix typo

* fix for clippy
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

TimeoutOnClose cannot verify the closed channel proof
3 participants