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

Tracking issue: Handler proof verification refactor proposition #15

Closed
plafer opened this issue Jun 3, 2022 · 0 comments
Closed

Tracking issue: Handler proof verification refactor proposition #15

plafer opened this issue Jun 3, 2022 · 0 comments
Assignees

Comments

@plafer
Copy link
Contributor

plafer commented Jun 3, 2022

The proof verification code, especially related to ClientState verification, is currently confusing and incomplete. The following 3 points should make the code better:

  1. Use more meaningful variable names.
  • For example, it is unclear which ClientState this client_state variable this variable refers to: the ClientState of A on B, or the ClientState of B on A? A convention should be adopted and followed consistently in all functions, be it using "host" vs "other", or "a" and "b" to distinguish between the 2 chains.
  1. There should be a specific Proof struct for each relevant context (e.g. ConnectionOpenTry proofs, ConnectionOpenAck proofs, etc). Consider the suggestions already made here.
  2. Currently, if the ClientState is not included in the MsgConnectionOpenTry, the msg verification can still succeed (see here). We should instead add a method to the context, say verify_self_client_state(client_state), and let the chain decide if it wants to do that extra verification, and how.
  • Note: this was originally added so that chains that don't need the extra ClientState verification can simply not include one in the message and still succeed in opening a connection.

This issue comes out of a discussion with @ancazamfir and @hu55a1n1.

Sub-issues:

@plafer plafer self-assigned this Jun 3, 2022
@hu55a1n1 hu55a1n1 transferred this issue from informalsystems/hermes Sep 28, 2022
@plafer plafer changed the title Handler proof verification refactor proposition Tracking issue: Handler proof verification refactor proposition Oct 11, 2022
@plafer plafer mentioned this issue Oct 12, 2022
8 tasks
@plafer plafer closed this as completed Nov 14, 2022
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

No branches or pull requests

1 participant