Skip to content

Fix SFTP path corruption for root-path URLs - #107

Merged
langemeijer merged 1 commit into
php:masterfrom
transcendtient:patch-1
Oct 14, 2026
Merged

langemeijer merged 1 commit into
php:masterfrom
transcendtient:patch-1

Conversation

@transcendtient

@transcendtient transcendtient commented Aug 28, 2026 •

Copy link
Copy Markdown
Contributor

strstr() can match resource->path against the "://" scheme separator instead of the actual path when the path is short (e.g. "/"), corrupting ssh2.sftp:/// URLs used for directory listings. Only run the search when # or ? is present, since that's the only case it's needed for.

Fixes #99

strstr() can match resource->path against the "://" scheme separator
instead of the actual path when the path is short (e.g. "/"), corrupting
ssh2.sftp://<id>/ URLs used for directory listings. Only run the search
when # or ? is present, since that's the only case it's needed for.

See php#99
@transcendtient

Copy link
Copy Markdown
Contributor Author

Friendly ping. The CI run needs maintainer approval to start. Happy to make any changes.

@langemeijer
langemeijer merged commit 20e3013 into php:master Oct 14, 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.

Module regression from 1.4.1 to 1.5.0

2 participants