Apache2-AuthAny

 view release on metacpan or  search on metacpan

lib/Apache2/AuthAny/DB.pm  view on Meta::CPAN

    $self->useDB();
    if ( $dbHandle->do($sql, undef, @passed_values) ) {
        my $UID = $dbHandle->last_insert_id(undef, undef, undef, undef);
        return $UID;
    } else {
        warn $dbHandle->errstr;
        return undef;
    }
}

sub updateUser {
    my $self = shift;
    my %user = @_;

    my $existingUser = $self->getUserByUsername($user{username}) || {};
    my $UID = $existingUser->{UID};
    unless ($UID) {
        warn "User, '$user{username}' does not exists\n";
        return;
    }

lib/Apache2/AuthAny/FixupHandler.pm  view on Meta::CPAN

        # not already timed out
        my $pid = $r->pnotes('pid');
        $aaDB = Apache2::AuthAny::DB->new() unless $aaDB;
        $aaDB->updatePCookieLastAccess($pid->{PID}) || warn "Could not update last access";
    }
    return Apache2::Const::DECLINED;
}

###!!!! MOVE THIS TO Cookie.pm
# called after basic login
sub update_logout_key {
    my $r = shift;
    my $pid = $r->pnotes('pid');
    $aaDB = Apache2::AuthAny::DB->new() unless $aaDB;
    $aaDB->updatePCookieLogoutKey($pid->{PID})  || warn "Could not update last access";
    return Apache2::Const::DECLINED;
}

1;

 view all matches for this distribution
 view release on metacpan -  search on metacpan

( run in 1.442 second using v1.00-cache-2.02-grep-82fe00e-cpan-4673cadbf75 )