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

[Hotfix] block deep recursive query #584

Merged
merged 3 commits into from
Oct 19, 2021

Conversation

yun-yeo
Copy link
Contributor

@yun-yeo yun-yeo commented Oct 19, 2021

Summary of changes

Reject tx which is executing deep recursive query to prevent node crash.

  • Set max query depth to 20

Report of required housekeeping

  • Github issue OR spec proposal link
  • Wrote tests
  • Updated API documentation (client/lcd/swagger-ui/swagger.yaml)
  • Added a relevant changelog entry: clog add [section] [stanza] [message]

(FOR ADMIN) Before merging

  • Added appropriate labels to PR
  • Squashed all commits, uses message "Merge pull request #XYZ: [title]" (coding standards)
  • Confirm added tests are consistent with the intended behavior of changes
  • Ensure all tests pass

@yun-yeo yun-yeo requested a review from hanjukim October 19, 2021 05:37
@yun-yeo yun-yeo self-assigned this Oct 19, 2021
@yun-yeo yun-yeo added the bug Something isn't working label Oct 19, 2021
hanjukim
hanjukim previously approved these changes Oct 19, 2021
@codecov
Copy link

codecov bot commented Oct 19, 2021

Codecov Report

Merging #584 (08e5a7b) into main (1581f2f) will increase coverage by 0.00%.
The diff coverage is 52.63%.

Impacted file tree graph

@@           Coverage Diff           @@
##             main     #584   +/-   ##
=======================================
  Coverage   44.75%   44.75%           
=======================================
  Files         121      122    +1     
  Lines        6998     7011   +13     
=======================================
+ Hits         3132     3138    +6     
- Misses       3620     3627    +7     
  Partials      246      246           
Impacted Files Coverage Δ
x/wasm/types/wasmer_engine.go 0.00% <0.00%> (ø)
x/wasm/keeper/keeper.go 81.81% <77.77%> (+0.50%) ⬆️
x/wasm/keeper/contract.go 78.84% <100.00%> (+0.24%) ⬆️

@yun-yeo yun-yeo requested a review from hanjukim October 19, 2021 06:36
@yun-yeo yun-yeo merged commit ef9adfb into main Oct 19, 2021
@yun-yeo yun-yeo deleted the hotfix/prevent-depth-recursive-query branch October 19, 2021 08:03
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