Skip to content

[fuzz] Fixed divide by zero bug#13545

Merged
htuch merged 4 commits intoenvoyproxy:masterfrom
zasweq:admission-control-divide-by-zero
Oct 19, 2020
Merged

[fuzz] Fixed divide by zero bug#13545
htuch merged 4 commits intoenvoyproxy:masterfrom
zasweq:admission-control-divide-by-zero

Conversation

@zasweq
Copy link
Contributor

@zasweq zasweq commented Oct 13, 2020

Signed-off-by: Zach Reyes zasweq@google.com

Commit Message: Fixed divide by zero bug in admission control filter for HTTP.
Additional Description: Fixes issues: https://oss-fuzz.com/testcase-detail/5914972389113856
Risk Level: Low
Testing: Added regression test
Docs Changes: N/A
Release Notes: N/A

Signed-off-by: Zach <zasweq@google.com>
@zasweq zasweq requested a review from mattklein123 as a code owner October 13, 2020 16:53
Signed-off-by: Zach <zasweq@google.com>
const double pct = sr_threshold_ ? sr_threshold_->value() : defaultSuccessRateThreshold;
// The threshold value should not be 0. Since you cannot add a validation on a widely used Runtime
// percent value, simply map a 0 percent for the field to the default success rate threshold.
if (pct == 0) {
Copy link
Member

Choose a reason for hiding this comment

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

Should we instead throw during config ingest? (not here)

@htuch htuch self-assigned this Oct 13, 2020
Signed-off-by: Zach <zasweq@google.com>
Signed-off-by: Zach <zasweq@google.com>
Copy link
Member

@htuch htuch left a comment

Choose a reason for hiding this comment

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

LGTM, thanks!

@htuch htuch merged commit 9f10cfe into envoyproxy:master Oct 19, 2020
mpuncel added a commit to mpuncel/envoy that referenced this pull request Oct 21, 2020
* master: (22 commits)
  ci: various improvements (envoyproxy#13660)
  dns: fix defunct fd bug in apple resolver (envoyproxy#13641)
  build: support ppc64le with wasm (envoyproxy#13657)
  [fuzz] Added random load balancer fuzz (envoyproxy#13400)
  dependencies: compute and check release dates via GitHub API. (envoyproxy#13582)
  mac ci: try ignoring update failure (envoyproxy#13658)
  watchdog: Optimize WatchdogImpl::touch in preparation to more frequent petting of the watchdog. (envoyproxy#13103)
  typos: fix a couple 'enovy' mispellings (envoyproxy#13645)
  lua: Expose stream info downstreamLocalAddress and downstreamDirectRemoteAddress for Lua filter (envoyproxy#13536)
  tap: fix upstream streamed transport socket taps (envoyproxy#13638)
  Revert "delay health checks until transport socket secrets are ready. (envoyproxy#13516)" (envoyproxy#13639)
  Watchdog: use abort action as a default if killing is enabled. (envoyproxy#13523)
  [fuzz] Fixed divide by zero bug (envoyproxy#13545)
  wasm: flip the meaning of the "repository" in envoy_wasm_cc_binary(). (envoyproxy#13621)
  fix: record recovered local address (envoyproxy#13581)
  docs: fix incorrect compressor filter doc (envoyproxy#13611)
  docs: clean up docs for azp migration (envoyproxy#13558)
  wasm: fix building Wasm example. (envoyproxy#13619)
  test: Refactor flood tests into a separate test file (envoyproxy#13556)
  wasm: re-enable tests with precompiled modules. (envoyproxy#13583)
  ...

Signed-off-by: Michael Puncel <mpuncel@squareup.com>
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.

3 participants