Login
Timing out the user's session
- If your application decides that the user's authentication is no longer valid, you can force a relogin
- You provide a method to test the username and password:
sub _relogin_test {
my $self = shift;
my $now = time;
my $then = $self->session->{_timestamp};
if ( ($now - $then) < 15 * 60) {
return 1; # session ok
}
return;
}