From cd521b2dcc7cb1727b25c231a5d43bbb5cc1d50e Mon Sep 17 00:00:00 2001 From: Sandro Santilli Date: Sun, 23 Apr 2017 13:48:46 +0200 Subject: [PATCH] Urlencode query parameters --- mod/openid.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/mod/openid.php b/mod/openid.php index 1841edc5f3..60de55a509 100644 --- a/mod/openid.php +++ b/mod/openid.php @@ -73,10 +73,10 @@ function openid_content(App $a) { $first = notags(trim($v)); } if($k === 'namePerson') { - $args .= '&username=' . notags(trim($v)); + $args .= '&username=' . urlencode(notags(trim($v))); } if ($k === 'contact/email') { - $args .= '&email=' . notags(trim($v)); + $args .= '&email=' . urlencode(notags(trim($v))); } if ($k === 'media/image/aspect11') { $photosq = bin2hex(trim($v)); @@ -87,20 +87,20 @@ function openid_content(App $a) { } } if ($nick) { - $args .= '&nickname=' . $nick; + $args .= '&nickname=' . urlencode($nick); } elseif ($first) { - $args .= '&nickname=' . $first; + $args .= '&nickname=' . urlencode($first); } if ($photosq) { - $args .= '&photo=' . $photosq; + $args .= '&photo=' . urlencode($photosq); } elseif ($photo) { - $args .= '&photo=' . $photo; + $args .= '&photo=' . urlencode($photo); } - $args .= '&openid_url=' . notags(trim($authid)); + $args .= '&openid_url=' . urlencode(notags(trim($authid))); goaway(App::get_baseurl() . '/register?' . $args); -- 2.39.5