Skip to content

Commit

Permalink
Add support for lowercase transfer-encoding header
Browse files Browse the repository at this point in the history
Some services seem to use lowercase transfer-encoding headers. This change allows both to work.
  • Loading branch information
rudybrian committed Jul 18, 2022
1 parent 403f6db commit cbb6fc0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lib/http_server.pl
Original file line number Diff line number Diff line change
Expand Up @@ -354,7 +354,7 @@ sub http_process_request {
read $socket, $buf, $cl;
$buf = $http_data.$buf if $http_data;
$http_data = '';
} elsif ($Http{'Transfer-Encoding'} && ($Http{'Transfer-Encoding'} eq 'chunked')) {
} elsif (($Http{'Transfer-Encoding'} && ($Http{'Transfer-Encoding'} eq 'chunked')) || (($Http{'transfer-encoding'} && ($Http{'transfer-encoding'} eq 'chunked')))) {
print "http POST query has chunked Transfer-Encoding\n" if $main::Debug{http};
# We can't read the post body from the socket, so need to get this from $http_data instead
# Note that this only works with one chunk right now.
Expand Down

0 comments on commit cbb6fc0

Please sign in to comment.