When Guzzle follows a redirect with its optional referer setting on, it can copy the URL fragment, the part after #, into the Referer header it sends to the new destination. A fragment is never meant to leave the client. If it holds a one-time login secret, an access token or other private data, the redirect target can read it.
Who is affected
Apps on guzzlehttp/guzzle before 7.15.1 that turn on allow_redirects.referer, request a URL with sensitive data in its fragment, and follow a redirect with the same scheme, such as HTTPS to HTTPS, to a less trusted host. The Guzzle advisory notes the referer setting is off by default. Apps that leave it off, keep secrets out of fragments, or don't follow redirects aren't affected.
What to do
Update to 7.15.1 or later. The fix strips the fragment before building the Referer value. Until you can update, keep referer set to false in your redirect options, or remove the fragment before sending a request that may redirect.
Reported by GrahamCampbell.