phpCAS  version 1.3.6
Modules | Functions | Variables
Configuration

Modules

 Internal behaviour of phpCAS
 
 HTML output
 
 Internationalization
 

Functions

 CAS_Client::getServerVersion ()
 
 CAS_Client::_getServerHostname ()
 
 CAS_Client::_getServerPort ()
 
 CAS_Client::_getServerURI ()
 
 CAS_Client::_getServerBaseURL ()
 
 CAS_Client::getServerLoginURL ($gateway=false, $renew=false)
 
 CAS_Client::setServerLoginURL ($url)
 
 CAS_Client::setServerServiceValidateURL ($url)
 
 CAS_Client::setServerProxyValidateURL ($url)
 
 CAS_Client::setServerSamlValidateURL ($url)
 
 CAS_Client::getServerServiceValidateURL ()
 
 CAS_Client::getServerSamlValidateURL ()
 
 CAS_Client::getServerProxyValidateURL ()
 
 CAS_Client::getServerProxyURL ()
 
 CAS_Client::getServerLogoutURL ()
 
 CAS_Client::setServerLogoutURL ($url)
 
 CAS_Client::setExtraCurlOption ($key, $value)
 
 CAS_Client::__construct ( $server_version, $proxy, $server_hostname, $server_port, $server_uri, $changeSessionID=true)
 
 CAS_Client::_setChangeSessionID ($allowed)
 
 CAS_Client::getChangeSessionID ()
 

Variables

 CAS_Client::$_server
 
 CAS_Client::$_curl_options = array()
 
 CAS_Client::$_change_session_id
 

Detailed Description

Function Documentation

◆ __construct()

CAS_Client::__construct (   $server_version,
  $proxy,
  $server_hostname,
  $server_port,
  $server_uri,
  $changeSessionID = true 
)

CAS_Client constructor.

Parameters
string$server_versionthe version of the CAS server
bool$proxytrue if the CAS client is a CAS proxy
string$server_hostnamethe hostname of the CAS server
int$server_portthe port the CAS server is running on
string$server_urithe URI the CAS server is responding on
bool$changeSessionIDAllow phpCAS to change the session_id (Single Sign Out/handleLogoutRequests is based on that change)
Returns
a newly created CAS_Client object

Definition at line 902 of file Client.php.

References CAS_Client\_isCallbackMode(), CAS_Client\_isHttps(), CAS_Client\_isLogoutRequest(), CAS_Client\_setCallbackMode(), CAS_Client\_setChangeSessionID(), CAS_VERSION_1_0, CAS_VERSION_2_0, CAS_VERSION_3_0, phpCAS\error(), CAS_Client\isProxy(), CAS_Client\isSessionAuthenticated(), SAML_VERSION_1_1, phpCAS\trace(), phpCAS\traceBegin(), and phpCAS\traceEnd().

◆ _getServerBaseURL()

CAS_Client::_getServerBaseURL ( )
private

◆ _getServerHostname()

CAS_Client::_getServerHostname ( )
private

This method is used to retrieve the hostname of the CAS server.

Returns
string the hostname of the CAS server.

Definition at line 283 of file Client.php.

Referenced by CAS_Client\_getServerBaseURL(), and CAS_Client\handleLogoutRequests().

◆ _getServerPort()

CAS_Client::_getServerPort ( )
private

This method is used to retrieve the port of the CAS server.

Returns
string the port of the CAS server.

Definition at line 293 of file Client.php.

Referenced by CAS_Client\_getServerBaseURL().

◆ _getServerURI()

CAS_Client::_getServerURI ( )
private

This method is used to retrieve the URI of the CAS server.

Returns
string a URI.

Definition at line 303 of file Client.php.

Referenced by CAS_Client\_getServerBaseURL().

◆ _setChangeSessionID()

CAS_Client::_setChangeSessionID (   $allowed)
private

Set a parameter whether to allow phpCas to change session_id

Parameters
bool$allowedallow phpCas to change session_id
Returns
void

Definition at line 1062 of file Client.php.

Referenced by CAS_Client\__construct().

◆ getChangeSessionID()

CAS_Client::getChangeSessionID ( )

Get whether phpCas is allowed to change session_id

Returns
bool

Definition at line 1072 of file Client.php.

References CAS_Client\$_change_session_id.

Referenced by CAS_Client\_renameSession(), and CAS_Client\handleLogoutRequests().

◆ getServerLoginURL()

CAS_Client::getServerLoginURL (   $gateway = false,
  $renew = false 
)

This method is used to retrieve the login URL of the CAS server.

Parameters
bool$gatewaytrue to check authentication, false to force it
bool$renewtrue to force the authentication with the CAS server
Returns
a URL.
Note
It is recommended that CAS implementations ignore the "gateway" parameter if "renew" is set

Definition at line 337 of file Client.php.

References CAS_Client\_buildQueryUrl(), CAS_Client\_getServerBaseURL(), CAS_Client\getURL(), phpCAS\traceBegin(), and phpCAS\traceEnd().

Referenced by CAS_Client\redirectToCas().

◆ getServerLogoutURL()

CAS_Client::getServerLogoutURL ( )

This method is used to retrieve the logout URL of the CAS server.

Returns
string logout URL.

Definition at line 541 of file Client.php.

References CAS_Client\_getServerBaseURL().

Referenced by CAS_Client\logout().

◆ getServerProxyURL()

CAS_Client::getServerProxyURL ( )

This method is used to retrieve the proxy URL of the CAS server.

Returns
string proxy URL.

Definition at line 519 of file Client.php.

References CAS_Client\_getServerBaseURL(), CAS_VERSION_1_0, CAS_VERSION_2_0, CAS_VERSION_3_0, and CAS_Client\getServerVersion().

Referenced by CAS_Client\retrievePT().

◆ getServerProxyValidateURL()

CAS_Client::getServerProxyValidateURL ( )

This method is used to retrieve the proxy validating URL of the CAS server.

Returns
string proxyValidate URL.

Definition at line 488 of file Client.php.

References CAS_Client\_buildQueryUrl(), CAS_Client\_getServerBaseURL(), CAS_VERSION_1_0, CAS_VERSION_2_0, CAS_VERSION_3_0, CAS_Client\getServerVersion(), CAS_Client\getURL(), phpCAS\traceBegin(), and phpCAS\traceEnd().

Referenced by CAS_Client\validateCAS20().

◆ getServerSamlValidateURL()

CAS_Client::getServerSamlValidateURL ( )

This method is used to retrieve the SAML validating URL of the CAS server.

Returns
string samlValidate URL.

Definition at line 463 of file Client.php.

References CAS_Client\_buildQueryUrl(), CAS_Client\_getServerBaseURL(), CAS_Client\getServerVersion(), CAS_Client\getURL(), SAML_VERSION_1_1, phpCAS\traceBegin(), and phpCAS\traceEnd().

◆ getServerServiceValidateURL()

CAS_Client::getServerServiceValidateURL ( )

This method is used to retrieve the service validating URL of the CAS server.

Returns
string serviceValidate URL.

Definition at line 431 of file Client.php.

References CAS_Client\_buildQueryUrl(), CAS_Client\_getServerBaseURL(), CAS_VERSION_1_0, CAS_VERSION_2_0, CAS_VERSION_3_0, CAS_Client\getServerVersion(), CAS_Client\getURL(), phpCAS\traceBegin(), and phpCAS\traceEnd().

Referenced by CAS_Client\validateCAS10(), and CAS_Client\validateCAS20().

◆ getServerVersion()

CAS_Client::getServerVersion ( )

◆ setExtraCurlOption()

CAS_Client::setExtraCurlOption (   $key,
  $value 
)

This method is used to set additional user curl options.

Parameters
string$keyname of the curl option
string$valuevalue of the curl option
Returns
void

Definition at line 579 of file Client.php.

◆ setServerLoginURL()

CAS_Client::setServerLoginURL (   $url)

This method sets the login URL of the CAS server.

Parameters
string$urlthe login URL
Returns
string login url

Definition at line 365 of file Client.php.

◆ setServerLogoutURL()

CAS_Client::setServerLogoutURL (   $url)

This method sets the logout URL of the CAS server.

Parameters
string$urlthe logout URL
Returns
string logout url

Definition at line 557 of file Client.php.

◆ setServerProxyValidateURL()

CAS_Client::setServerProxyValidateURL (   $url)

This method sets the proxyValidate URL of the CAS server.

Parameters
string$urlthe proxyValidate URL
Returns
string proxyValidate URL

Definition at line 399 of file Client.php.

◆ setServerSamlValidateURL()

CAS_Client::setServerSamlValidateURL (   $url)

This method sets the samlValidate URL of the CAS server.

Parameters
string$urlthe samlValidate URL
Returns
string samlValidate URL

Definition at line 416 of file Client.php.

◆ setServerServiceValidateURL()

CAS_Client::setServerServiceValidateURL (   $url)

This method sets the serviceValidate URL of the CAS server.

Parameters
string$urlthe serviceValidate URL
Returns
string serviceValidate URL

Definition at line 382 of file Client.php.

Variable Documentation

◆ $_change_session_id

CAS_Client::$_change_session_id
private

A variable to whether phpcas will use its own session handling. Default = true

Definition at line 1053 of file Client.php.

Referenced by CAS_Client\getChangeSessionID().

◆ $_curl_options

CAS_Client::$_curl_options = array()
private

An array to store extra curl options.

Definition at line 569 of file Client.php.

◆ $_server

CAS_Client::$_server
private

a record to store information about the CAS server.

  • $_server['version']: the version of the CAS server
  • $_server['hostname']: the hostname of the CAS server
  • $_server['port']: the port the CAS server is running on
  • $_server['uri']: the base URI the CAS server is responding on
  • $_server['base_url']: the base URL of the CAS server
  • $_server['login_url']: the login URL of the CAS server
  • $_server['service_validate_url']: the service validating URL of the CAS server
  • $_server['proxy_url']: the proxy URL of the CAS server
  • $_server['proxy_validate_url']: the proxy validating URL of the CAS server
  • $_server['logout_url']: the logout URL of the CAS server

$_server['version'], $_server['hostname'], $_server['port'] and $_server['uri'] are written by CAS_Client::CAS_Client(), read by CAS_Client::getServerVersion(), CAS_Client::_getServerHostname(), CAS_Client::_getServerPort() and CAS_Client::_getServerURI().

The other fields are written and read by CAS_Client::_getServerBaseURL(), CAS_Client::getServerLoginURL(), CAS_Client::getServerServiceValidateURL(), CAS_Client::getServerProxyValidateURL() and CAS_Client::getServerLogoutURL().

Definition at line 262 of file Client.php.