Skip to content

Commit

Permalink
[fuzz]: fix oss fuzz bug 34515, limit maglev table size (#16671)
Browse files Browse the repository at this point in the history
Signed-off-by: chaoqin-li1123 <chaoqinli@google.com>
  • Loading branch information
chaoqin-li1123 authored Jun 22, 2021
1 parent 3f2b4b6 commit 9aca65c
Show file tree
Hide file tree
Showing 5 changed files with 114 additions and 8 deletions.
4 changes: 2 additions & 2 deletions api/envoy/config/cluster/v3/cluster.proto
Original file line number Diff line number Diff line change
Expand Up @@ -413,8 +413,8 @@ message Cluster {
// The table size for Maglev hashing. The Maglev aims for ‘minimal disruption’ rather than an absolute guarantee.
// Minimal disruption means that when the set of upstreams changes, a connection will likely be sent to the same
// upstream as it was before. Increasing the table size reduces the amount of disruption.
// The table size must be prime number. If it is not specified, the default is 65537.
google.protobuf.UInt64Value table_size = 1;
// The table size must be prime number limited to 5000011. If it is not specified, the default is 65537.
google.protobuf.UInt64Value table_size = 1 [(validate.rules).uint64 = {lte: 5000011}];
}

// Specific configuration for the
Expand Down
4 changes: 2 additions & 2 deletions api/envoy/config/cluster/v4alpha/cluster.proto

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions generated_api_shadow/envoy/config/cluster/v3/cluster.proto

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

106 changes: 106 additions & 0 deletions test/server/server_corpus/big_maglev_table

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 9aca65c

Please sign in to comment.