function theme_cas_service_validate_whitelist_failure in CAS 7
Returns a CAS 2.0 service response for a service not on the whitelist.
Parameters
$variables: An associative array containing the keys 'service' and 'error_code'.
File
- ./
cas_server.response.inc, line 102 - Response callbacks for the CAS Server module.
Code
function theme_cas_service_validate_whitelist_failure($variables) {
$service = $variables['service'];
$error_code = $variables['error_code'];
$output = "<cas:serviceReponse xmlns:cas='http://www.yale.edu/tp/cas'>\n" . "<cas:authenticationFailure code=\"{$error_code}\">\n" . "Service {$service} not recognized.\n" . "</cas:authenticationFailure>\n" . "</cas:serviceResponse>\n";
return $output;
}