X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fopenid.php;h=613cd222f605e962301492f73f4a8d033fb9c7a7;hb=a5e91175243a41c77a56e73efc3672f20a7e6d23;hp=59a7530140fcac1ed0727c7c33700cdb4e4dda10;hpb=63e2695d226d195c6a97e1045d6b174591dd2487;p=friendica.git diff --git a/mod/openid.php b/mod/openid.php index 59a7530140..613cd222f6 100644 --- a/mod/openid.php +++ b/mod/openid.php @@ -1,14 +1,17 @@ config['register_policy'] == REGISTER_CLOSED) { notice( t('Account not found and OpenID registration is not permitted on this site.') . EOL); - goaway(z_root()); + goaway(System::baseUrl()); } unset($_SESSION['register']); @@ -73,10 +77,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,27 +91,27 @@ 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); + goaway(System::baseUrl() . '/register?' . $args); // NOTREACHED } } notice( t('Login failed.') . EOL); - goaway(z_root()); + goaway(System::baseUrl()); // NOTREACHED }