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

double nil return in grpc query handler crash the node when using GRPCClient #13351

Closed
yihuang opened this issue Sep 21, 2022 · 0 comments · Fixed by #13352
Closed

double nil return in grpc query handler crash the node when using GRPCClient #13351

yihuang opened this issue Sep 21, 2022 · 0 comments · Fixed by #13352

Comments

@yihuang
Copy link
Collaborator

yihuang commented Sep 21, 2022

Summary of Bug

We updated ethermint to use GRPCClient(introduced here) to enjoy concurrency, but there's a query handler that return nil, nil under certain conditions, when that happens, it'll crash the whole node.
Currently, we fix that by returning a proper error, but since crashing the node could be a DoS vulnability, it'd be good that we eliminate that possibility.

the panic happens here, I guess the nil value is not caught by the previous check as the comment suggested.

Version

0.46

Steps to Reproduce

yihuang added a commit to yihuang/cosmos-sdk that referenced this issue Sep 21, 2022
Closes: cosmos#13351
- check the case that grpc query handler returns a nil response.
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 a pull request may close this issue.

1 participant