From: single-right-quote <34298117+single-right-quote@users.noreply.github.com> Date: Wed, 8 Sep 2021 00:39:36 +0000 (+0000) Subject: bugfix: respond for any sytactically valid Hosts X-Git-Tag: v1.0.0~33 X-Git-Url: https://git.xn--scling-oua.cat.family/?a=commitdiff_plain;h=7b7c7ecdc8a41ee4613c6ad7f3e7e7829be8081f;p=httpd-execline.git bugfix: respond for any sytactically valid Hosts as a fallback, make sure to send a response even when invalid hostnames are required --- diff --git a/visible-to-httpd/binaries/http-get-extra-headers.execline b/visible-to-httpd/binaries/http-get-extra-headers.execline index 0bee831..35185fa 100755 --- a/visible-to-httpd/binaries/http-get-extra-headers.execline +++ b/visible-to-httpd/binaries/http-get-extra-headers.execline @@ -17,7 +17,7 @@ # TODO: write a GUI?? with like, `yad(1)` or something??? idk multisubstitute { - importas -i hostname http_header_parse_Host + importas -D -fallback hostname http_header_parse_Host importas -i resource resource } diff --git a/visible-to-httpd/binaries/http-header-parse.execline b/visible-to-httpd/binaries/http-header-parse.execline index 26e6b0c..7a0f3f5 100755 --- a/visible-to-httpd/binaries/http-header-parse.execline +++ b/visible-to-httpd/binaries/http-header-parse.execline @@ -175,8 +175,9 @@ ifelse { s6-test \${header_name} = Host } # ifelse -n { ${supported_hostname_test} ${header_contents} } { - fdclose 0 - exit 0 + heredoc 0 "" + export http_header_parse_${header_name} ${header_contents} + ${@} } export http_header_parse_${header_name} ${header_contents}