Enumerations | Functions

Access to external services
[User interface]

Enumerations

enum  PHPCAS_SERVICE_OK
enum  PHPCAS_SERVICE_PT_NO_SERVER_RESPONSE
enum  PHPCAS_SERVICE_PT_BAD_SERVER_RESPONSE
enum  PHPCAS_SERVICE_PT_FAILURE
enum  PHPCAS_SERVICE_NOT_AVAILABLE
enum  PHPCAS_PROXIED_SERVICE_HTTP_GET
enum  PHPCAS_PROXIED_SERVICE_HTTP_POST
enum  PHPCAS_PROXIED_SERVICE_IMAP

Functions

static phpCAS::getProxiedService ($type)
static phpCAS::initializeProxiedService (CAS_ProxiedService $proxiedService)
static phpCAS::serviceWeb ($url, &$err_code, &$output)
static phpCAS::serviceMail ($url, $service, $flags, &$err_code, &$err_msg, &$pt)

Enumeration Type Documentation

phpCAS::getProxiedService() type for HTTP GET

Definition at line 190 of file CAS.php.

phpCAS::getProxiedService() type for HTTP POST

Definition at line 194 of file CAS.php.

phpCAS::getProxiedService() type for IMAP

Definition at line 198 of file CAS.php.

phpCAS::service() error code when the service was not available.

Definition at line 182 of file CAS.php.

phpCAS::service() error code on success

Definition at line 163 of file CAS.php.

phpCAS::service() error code when the PT could not retrieve because the response of the CAS server was ill-formed.

Definition at line 173 of file CAS.php.

phpCAS::service() error code when the PT could not retrieve because the CAS server did not want to.

Definition at line 178 of file CAS.php.

phpCAS::service() error code when the PT could not retrieve because the CAS server did not respond.

Definition at line 168 of file CAS.php.


Function Documentation

static phpCAS::getProxiedService ( type  )  [static, inherited]

Answer a proxy-authenticated service handler.

Parameters:
string $type The service type. One of: PHPCAS_PROXIED_SERVICE_HTTP_GET PHPCAS_PROXIED_SERVICE_HTTP_POST PHPCAS_PROXIED_SERVICE_IMAP
Returns:
CAS_ProxiedService
Exceptions:
InvalidArgumentException If the service type is unknown.

Definition at line 820 of file CAS.php.

References phpCAS::error(), phpCAS::traceBegin(), and phpCAS::traceEnd().

static phpCAS::initializeProxiedService ( CAS_ProxiedService proxiedService  )  [static, inherited]

Initialize a proxied-service handler with the proxy-ticket it should use.

Parameters:
CAS_ProxiedService $proxiedService
Returns:
void
Exceptions:
CAS_ProxyTicketException If there is a proxy-ticket failure. The code of the Exception will be one of: PHPCAS_SERVICE_PT_NO_SERVER_RESPONSE PHPCAS_SERVICE_PT_BAD_SERVER_RESPONSE PHPCAS_SERVICE_PT_FAILURE

Definition at line 857 of file CAS.php.

References phpCAS::error().

Referenced by CAS_ProxiedService_Abstract::initializeProxyTicket().

static phpCAS::serviceMail ( url,
service,
flags,
&$  err_code,
&$  err_msg,
&$  pt 
) [static, inherited]

This method is used to access an IMAP/POP3/NNTP service.

Parameters:
$url a string giving the URL of the service, including the mailing box for IMAP URLs, as accepted by imap_open().
$service a string giving for CAS retrieve Proxy ticket
$flags options given to imap_open().
$err_code an error code Possible values are PHPCAS_SERVICE_OK (on success), PHPCAS_SERVICE_PT_NO_SERVER_RESPONSE, PHPCAS_SERVICE_PT_BAD_SERVER_RESPONSE, PHPCAS_SERVICE_PT_FAILURE, PHPCAS_SERVICE_NOT_AVAILABLE.
$err_msg an error message on failure
$pt the Proxy Ticket (PT) retrieved from the CAS server to access the URL on success, FALSE on error).
Returns:
an IMAP stream on success, FALSE otherwise (in this later case, $err_code gives the reason why it failed and $err_msg contains an error message).

Definition at line 932 of file CAS.php.

References phpCAS::error(), phpCAS::traceBegin(), and phpCAS::traceEnd().

static phpCAS::serviceWeb ( url,
&$  err_code,
&$  output 
) [static, inherited]

This method is used to access an HTTP[S] service.

Parameters:
$url the service to access.
$err_code an error code Possible values are PHPCAS_SERVICE_OK (on success), PHPCAS_SERVICE_PT_NO_SERVER_RESPONSE, PHPCAS_SERVICE_PT_BAD_SERVER_RESPONSE, PHPCAS_SERVICE_PT_FAILURE, PHPCAS_SERVICE_NOT_AVAILABLE.
$output the output of the service (also used to give an error message on failure).
Returns:
TRUE on success, FALSE otherwise (in this later case, $err_code gives the reason why it failed and $output contains an error message).

Definition at line 889 of file CAS.php.

References phpCAS::error(), phpCAS::traceBegin(), and phpCAS::traceEnd().