Skip to content

Fix SOAP client failing to follow a scheme-less redirect Location#93

Closed
iliaal wants to merge 3 commits into
PHP-8.5from
fix-soap-relative-redirect
Closed

Fix SOAP client failing to follow a scheme-less redirect Location#93
iliaal wants to merge 3 commits into
PHP-8.5from
fix-soap-relative-redirect

Conversation

@iliaal

@iliaal iliaal commented Jun 16, 2026

Copy link
Copy Markdown
Owner

On a 3xx redirect with a scheme-less Location (relative or absolute-path), the redirect handler copied scheme/host/port from the freshly parsed Location URI itself rather than the previous request URI, leaving the host NULL so the retry aborted with "Unable to parse URL". Read the inherited components and the relative-path base from the request URI, restoring the pre-refactor behaviour.

@iliaal iliaal force-pushed the fix-soap-relative-redirect branch from 6c3b40b to 5679aad Compare June 16, 2026 20:00
@iliaal iliaal force-pushed the fix-soap-relative-redirect branch from 5679aad to 7c36a99 Compare June 16, 2026 21:22
The HTTP redirect handler inherited scheme, host and port from the newly
parsed Location URI itself instead of the previous request URI, so a
scheme-less (relative or absolute-path) Location left the host NULL and
the retry aborted with "Unable to parse URL". Read the inherited
components and the path base from the request URI, restoring the
behaviour the URI-parser refactor changed.

Closes phpGH-22341
@iliaal iliaal force-pushed the fix-soap-relative-redirect branch from 7c36a99 to ef896b2 Compare June 16, 2026 21:22
@iliaal

iliaal commented Jun 16, 2026

Copy link
Copy Markdown
Owner Author

Submitted upstream as php#22341.

@iliaal iliaal closed this Jun 16, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants