1
0
Fork 0
mirror of https://github.com/processone/ejabberd synced 2025-10-03 01:39:35 +02:00

mod_http_upload: Encode URL before parsing, as done before bba1a1e3c (#4450)

This commit is contained in:
Badlop 2025-08-29 16:56:51 +02:00
parent fd8aba6d41
commit 2951281115

View file

@ -921,7 +921,7 @@ mk_slot(PutURL, GetURL, XMLNS, Query) ->
end.
reencode_url(UrlString) ->
{ok, _, _, Host, _, _, _} = yconf:parse_uri(UrlString),
{ok, _, _, Host, _, _, _} = yconf:parse_uri(misc:url_encode(UrlString)),
HostDecoded = misc:uri_decode(Host),
HostIdna = idna:encode(HostDecoded),
re:replace(UrlString, Host, HostIdna, [{return, binary}]).