X-Git-Url: https://git.mxchange.org/?a=blobdiff_plain;f=mod%2Fopenid.php;h=45b80638d5e3723ea306c8ed09cf1df112a85dd6;hb=f22fe7118d52251dbd0898279ef078b797885ec4;hp=ce707c4150b1195dd84572bf79cacc99cc7221de;hpb=6e44acfed6b029818ad094771919184c485f9c16;p=friendica.git diff --git a/mod/openid.php b/mod/openid.php index ce707c4150..45b80638d5 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 +76,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 +90,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 }