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

Fee amount computation may overflow #1555

Closed
5 tasks done
Tracked by #1562
tomtau opened this issue Nov 9, 2021 · 0 comments · Fixed by #1568
Closed
5 tasks done
Tracked by #1562

Fee amount computation may overflow #1555

tomtau opened this issue Nov 9, 2021 · 0 comments · Fixed by #1568
Assignees
Labels
A: bug Admin: something isn't working I: logic Internal: related to the relaying logic
Milestone

Comments

@tomtau
Copy link
Contributor

tomtau commented Nov 9, 2021

Crate

relayer

Summary of Bug

The fee amount is estimated using u64: https://github.com/informalsystems/ibc-rs/blob/9d1f86b9e7bdb06a3fb2c5b3ed05fc8004650784/relayer/src/chain/cosmos.rs#L2286

This may not be work in certain networks and it will result in transactions not being relayed due to an insufficient fee being paid.

Version

v0.8.0

Steps to Reproduce

  1. network A: start up a Cosmos SDK-based network and configure its fee token to have many decimal places (e.g. 18) and configure a non-zero gas price
  2. configure Hermes to create and relay on a channel to a network B (it can be anything)
  3. start sending many IBC transfers of any coin from the network B to the network A

Acceptance Criteria

Large batches of transactions being relayed successfully on networks with fee tokens that have higher decimal places, such as networks working with Ethermint where a gas token has by default 18 decimal places.


For Admin Use

  • Not duplicate issue
  • Appropriate labels applied
  • Appropriate milestone (priority) applied
  • Appropriate contributors tagged
  • Contributor assigned/self-assigned
@romac romac added this to the v0.8.1 milestone Nov 9, 2021
@romac romac added A: bug Admin: something isn't working I: logic Internal: related to the relaying logic P-medium labels Nov 9, 2021
@romac romac changed the title relayer fee estimation amount may overflow Fee estimation amount computation may overflow Nov 9, 2021
@romac romac changed the title Fee estimation amount computation may overflow Fee amount computation may overflow Nov 10, 2021
@romac romac mentioned this issue Nov 11, 2021
7 tasks
@romac romac self-assigned this Nov 15, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A: bug Admin: something isn't working I: logic Internal: related to the relaying logic
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants