Skip to content

Commit

Permalink
Adds better sanity checks around the method IX
Browse files Browse the repository at this point in the history
  • Loading branch information
zwoop committed Feb 28, 2018
1 parent 9fc730b commit e7517f3
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion proxy/http/remap/UrlRewrite.cc
Expand Up @@ -405,7 +405,7 @@ UrlRewrite::PerformACLFiltering(HttpTransact::State *s, url_mapping *map)
bool match = true;

if (rp->method_restriction_enabled) {
if (method_wksidx != -1) {
if (method_wksidx >= 0 && method_wksidx < HTTP_WKSIDX_METHODS_CNT) {
match = rp->standard_method_lookup[method_wksidx];
} else if (!rp->nonstandard_methods.empty()) {
match = false;
Expand Down

0 comments on commit e7517f3

Please sign in to comment.