logger('mod_openid ' . print_r($_REQUEST,true), LOGGER_DATA);
if((x($_GET,'openid_mode')) && (x($_SESSION,'openid'))) {
+
$openid = new LightOpenID;
if($openid->validate()) {
$r = q("SELECT `user`.*, `user`.`pubkey` as `upubkey`, `user`.`prvkey` as `uprvkey`
FROM `user` WHERE `openid` = '%s' AND `blocked` = 0
- AND `account_expired` = 0 AND `verified` = 1 LIMIT 1",
+ AND `account_expired` = 0 AND `account_removed` = 0 AND `verified` = 1 LIMIT 1",
dbesc($authid)
);
if($r && count($r)) {
+
+ // successful OpenID login
+
unset($_SESSION['openid']);
require_once('include/security.php');
goaway(z_root());
}
- // new registration?
+ // Successful OpenID login - but we can't match it to an existing account.
+ // New registration?
if($a->config['register_policy'] == REGISTER_CLOSED) {
notice( t('Account not found and OpenID registration is not permitted on this site.') . EOL);