Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

use esc_url_raw() for sanitization of url as wp_http_validate_url() rejects port in urls #184

Merged
merged 4 commits into from Feb 13, 2023

Conversation

ashfame
Copy link
Member

@ashfame ashfame commented Feb 9, 2023

With this PR, values like synapse.dev:8008 for homeserver field on settings page are accepted. Fixes #183

I noticed, we are only attempting to sanitize the URL here and not really checking whether its actually valid & usable. Should we be doing that as well?

@ashfame ashfame requested a review from psrpinto February 9, 2023 11:44
@ashfame ashfame self-assigned this Feb 9, 2023
@psrpinto psrpinto added this to the 0.6 milestone Feb 10, 2023
Copy link
Member

@psrpinto psrpinto left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing!

src/Admin/Settings/settings.php Show resolved Hide resolved
@ashfame ashfame merged commit 4de7d9b into main Feb 13, 2023
@ashfame ashfame deleted the fix_hs_url_validation branch February 13, 2023 14:18
@ashfame ashfame mentioned this pull request Feb 14, 2023
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.

My homeserver has a none valid URL.
2 participants