Browse Source

Bug 8279: CAS Debugging improvements

Adds more precise debug informations for easier CAS troubleshootings resolution.

  Before this patch, whenever ticket validation failed, the debug message was "Invalid ticket".
  But ticket validation may fail for other reasons: CAS server not reachable, casServerUrl syspref is wrong...

  This patch adds the reason for ticket validation failing.

Signed-off-by: Chris Cormack <chris@bigballofwax.co.nz>
Signed-off-by: Paul Poulain <paul.poulain@biblibre.com>
3.10.x
Matthias Meusburger 12 years ago
committed by Paul Poulain
parent
commit
07e30a78d3
  1. 5
      C4/Auth_with_cas.pm

5
C4/Auth_with_cas.pm

@ -145,7 +145,10 @@ sub checkpw_cas {
$debug and warn "User $userid is not a valid Koha user";
} else {
$debug and warn "Invalid session ticket : $ticket";
$debug and warn "Problem when validating ticket : $ticket";
$debug and warn "Authen::CAS::Client::Response::Error: " . $val->error() if $val->is_error();
$debug and warn "Authen::CAS::Client::Response::Failure: " . $val->message() if $val->is_failure();
$debug and warn Data::Dumper::Dumper($@) if $val->is_error() or $val->is_failure();
return 0;
}
}

Loading…
Cancel
Save