relay_read_http: defer header parsing until after line continuation
authormillert <millert@openbsd.org>
Wed, 29 Nov 2023 15:35:07 +0000 (15:35 +0000)
committermillert <millert@openbsd.org>
Wed, 29 Nov 2023 15:35:07 +0000 (15:35 +0000)
commiteefb3de5799409f8689b849d8a069ad293a002c0
treeefb389956669f9492f227ecf3a8564c368483186
parent0088b80467830d84e0be7b97d234d8c5f6331713
relay_read_http: defer header parsing until after line continuation

Wait until we have a complete line before parsing the Content-Length,
Transfer-Encoding and Host headers.  This prevents potential request
smuggling attacks.  Filtering already happens after header line
continuation has been performed.  Reported by Ben Kallus.
OK claudio@
usr.sbin/relayd/relay_http.c