Linux

Caddy 2.11.9 Fixes PHP Regression and FastCGI Security Bugs

Caddy 2.11.9 fixes a PHP directory 404 regression from 2.11.8 and hardens FastCGI. Here is how to upgrade.

6 November 2026  ·  5 min read  ·  Anand

Caddy 2.11.9 Fixes PHP Regression and FastCGI Security Bugs

The Caddy project released version 2.11.9 on November 5, 2026, just one day after 2.11.8. This quick follow-up fixes a 2.11.8 regression that broke directory index handling on many PHP sites. It also closes several more security issues, most of them in the FastCGI handler behind php_fastcgi. If you run WordPress, Laravel or any other PHP application behind Caddy, upgrade to this version.

The 2.11.8 regression: 404s on PHP directories

After 2.11.8, a request for a directory with a trailing slash, such as /wp-admin/, could match the directory itself instead of the index.php inside it. You would see a 404 on pages that had always worked. WordPress admins were the most likely to notice, because the dashboard lives at exactly that kind of path.

In 2.11.9, a try_files pattern only matches a directory when the pattern itself ends in a slash. That brings back the expected behaviour for the standard php_fastcgi setup. If you moved to 2.11.8 and then saw 404s you could not explain, this regression is almost certainly why.

Security fixes in this release

  • GHSA-q34h-28rj-5hjm: a client could override HTTP_* variables you set with the FastCGI env option, including through php_fastcgi, by sending a request header with the same name. Your configured values now always win.
  • GHSA-9cr8-wmhh-39pm: on Windows, NTFS 8.3 short names and alternate data streams could make Caddy run a script that a path rule should have blocked. This finishes a fix that started in 2.11.8.
  • Encoded slashes and dot segments: a path matcher containing % could approve one script while a different script actually ran.
  • HTTP/2 host mismatch: a host field sent alongside :authority could make HTTP_HOST differ from the host Caddy actually routed the request to.
  • mTLS settings silently dropped: when several site blocks for the same hostname shared one TLS policy, a client_auth setting could be lost, which weakened client certificate checks.
  • go-jose was updated to v4.1.6 to fix GHSA-mgcc-cww5-fp2q.

The HTTP_HOST and HTTP_* issues matter because PHP applications often trust these variables to build URLs, detect HTTPS or decide which site to serve.

Behaviour changes to check in your config

Security fixes sometimes break setups that relied on the old behaviour. The release notes call out these changes:

  • Conflicting client_auth is now an error. If two site blocks for the same hostname share a TLS policy but define different client authentication, Caddy now refuses to load the Caddyfile instead of quietly keeping one setting. Merge them into one consistent setting.
  • FastCGI returns 400 for ambiguous scripts. If the escaped and decoded forms of a path would pick different scripts, Caddy now answers 400 Bad Request instead of guessing. On Windows it does the same when the path contains 8.3 short names or a colon.
  • FastCGI env values beat request headers. Clients can no longer replace values you set. If an application happened to rely on a header overriding them, it now sees your configured value.

For example, a site that tells the PHP application which scheme the visitor used might look like the block below. Before this release, a client could replace that value by sending its own X-Forwarded-Proto header. Now the configured value always wins. Change the socket path to match your PHP-FPM version.

example.com {
    root * /var/www/html
    php_fastcgi unix//run/php/php-fpm.sock {
        env HTTP_X_FORWARDED_PROTO https
    }
    file_server
}

How to upgrade safely

First check which version you are running with caddy version. Then update through the same channel you installed from. Your distribution’s own repositories may still carry an older release, so check the version after updating.

Debian and Ubuntu (official Caddy apt repository)

sudo apt update
sudo apt install --only-upgrade caddy

Fedora, RHEL, Rocky and AlmaLinux (Caddy COPR repository)

sudo dnf upgrade caddy

If you use a custom build with plugins made with xcaddy, rebuild it against v2.11.9 and swap the binary. If you run containers, pull the updated official image and redeploy.

Validate, restart and test

caddy version
caddy validate --config /etc/caddy/Caddyfile --adapter caddyfile
sudo systemctl status caddy

A config reload does not load a new binary. If systemctl status shows the service was not restarted by the package upgrade, run sudo systemctl restart caddy at a quiet moment. Then check that the fixed behaviour works:

  • Request a PHP directory path, for example curl -I https://example.com/wp-admin/. You should get a redirect to the login page, not a 404.
  • For a day or two, watch your access logs for more 400 responses than usual. A rise can point to an application that relied on the old FastCGI path handling.
  • If you use client certificates, confirm that Caddy loaded the config and that mTLS-protected sites still ask for a certificate.

How TechProvidence can help

TechProvidence looks after web servers and PHP hosting stacks for businesses, from WordPress maintenance to Caddy, NGINX and Apache upgrades with config checks and rollback plans. If you want patch releases like this applied and tested for you, contact us.

Source: Caddy v2.11.9 release notes on GitHub

Running into something similar?

We look after Linux servers, control panels and virtualization for businesses every day. If an update, vulnerability or outage here affects you, we can help.