0
Fork 0
mirror of https://github.com/caddyserver/caddy.git synced 2024-12-23 22:27:38 -05:00
caddy/modules/caddyhttp
Wynn Wolf Arbor fa4cdde7d8
fastcgi: Make sure splitPos handles empty SplitPath correctly (#3491)
In commit f2ce81c, support for multiple path splitters was added. The
type of SplitPath changed from string to []string, and splitPos was
changed to loop through all values in SplitPath.

Before that commit, if SplitPath was empty, strings.Index returned 0 and
PATH_INFO was set correctly in buildEnv.

Currently, however, splitPos returns -1 for empty values of SplitPath,
behaving as if a split position could not be found at all. PATH_INFO is
then never set in buildEnv and remains empty.

Restore the old behaviour by explicitly checking whether SplitPath is
empty and returning 0 in splitPos.

Closes #3490
2020-06-12 10:07:59 -06:00
..
caddyauth caddyhttp: Add client cert SAN placeholders 2020-06-11 16:19:07 -06:00
encode gzip: Use klauspost/gzip, an optimized gzip implementation 2020-04-01 14:09:57 -06:00
fileserver cmd: file-server: add --access-log flag (#3454) 2020-05-26 15:04:04 -06:00
headers headers: Trim any trailing colon from field names as a courtesy 2020-03-30 11:52:11 -06:00
requestbody Remove some non-essential plugins from this repo (#2780) 2020-03-24 10:37:47 -06:00
reverseproxy fastcgi: Make sure splitPos handles empty SplitPath correctly (#3491) 2020-06-12 10:07:59 -06:00
rewrite httpcaddyfile: New handle_path directive (#3281) 2020-05-26 15:27:51 -06:00
standard Remove some non-essential plugins from this repo (#2780) 2020-03-24 10:37:47 -06:00
templates templates: trim windows whitespace in SplitFrontMatter; fix #3386 (#3387) 2020-05-18 13:01:04 -06:00
app.go caddyhttp: Add client cert SAN placeholders 2020-06-11 16:19:07 -06:00
autohttps.go caddyhttp: Auto-redirects from all bind addresses (fix #3443) 2020-06-03 10:56:26 -06:00
caddyhttp.go reverseproxy: Enable changing only the status code (close #2920) 2020-06-04 12:06:38 -06:00
celmatcher.go chore: forego the use of deprecated cel func NewIdent in favor of NewVar (#3444) 2020-05-25 03:59:38 +00:00
errors.go http: Change routes to sequential matcher evaluation (#2967) 2020-01-09 10:00:13 -07:00
marshalers.go http: Fix ciphersuite logging 2020-01-16 15:44:49 -06:00
matchers.go caddyhttp: Refactor header matching 2020-05-26 17:35:27 -06:00
matchers_test.go caddyhttp: Refactor header matching 2020-05-26 17:35:27 -06:00
replacer.go caddyhttp: Add client cert SAN placeholders 2020-06-11 16:19:07 -06:00
replacer_test.go caddyhttp: Add client cert SAN placeholders 2020-06-11 16:19:07 -06:00
responsewriter.go caddyhttp: Fix trailers when recording responses (fixes #3236) 2020-04-22 11:10:13 -06:00
routes.go caddyhttp: Minor refactoring for preparing requests 2020-05-11 12:14:47 -06:00
server.go caddyhttp: Match hostnames with wildcards to loggers (#3378) 2020-05-11 14:17:59 -06:00
staticerror.go Fix some godocs 2020-04-11 09:01:40 -06:00
staticresp.go caddyhttp: Default to error status if found in context 2020-06-04 10:32:01 -06:00
staticresp_test.go Implement config adapters and beginning of Caddyfile adapter 2019-08-09 12:05:47 -06:00
subroute.go reverseproxy: Enable changing only the status code (close #2920) 2020-06-04 12:06:38 -06:00
vars.go v2: Implement RegExp Vars Matcher (#2997) 2020-02-08 12:26:31 -07:00