git.cweiske.de
/
indieauth-openid.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
normalize identifiers when comparing them
[indieauth-openid.git]
/
www
/
index.php
diff --git
a/www/index.php
b/www/index.php
index 496d7d3bbede3e1bd271971a036ce511e03ca419..c3b784856dc7c0058931ecae8f3682f804d8eea0 100644
(file)
--- a/
www/index.php
+++ b/
www/index.php
@@
-15,6
+15,7
@@
*/
require_once 'Net/URL2.php';
*/
require_once 'Net/URL2.php';
+require_once 'OpenID.php';
require_once 'OpenID/RelyingParty.php';
require_once 'OpenID/Message.php';
require_once 'OpenID/Exception.php';
require_once 'OpenID/RelyingParty.php';
require_once 'OpenID/Message.php';
require_once 'OpenID/Exception.php';
@@
-139,7
+140,7
@@
if (isset($_GET['openid_mode']) && $_GET['openid_mode'] != '') {
$message = new \OpenID_Message($queryString, \OpenID_Message::FORMAT_HTTP);
$id = $message->get('openid.claimed_id');
$message = new \OpenID_Message($queryString, \OpenID_Message::FORMAT_HTTP);
$id = $message->get('openid.claimed_id');
- if (
$id != $_SESSION['me']
) {
+ if (
OpenID::normalizeIdentifier($id) != OpenID::normalizeIdentifier($_SESSION['me'])
) {
error(
sprintf(
'Given identity URL "%s" and claimed OpenID "%s" do not match',
error(
sprintf(
'Given identity URL "%s" and claimed OpenID "%s" do not match',