PHP Class SimpleSAML_XML_Shib13_AuthnResponse, simplesamlphp

Author: Andreas Åkre Solberg, UNINETT AS. ([email protected])
ファイルを表示 Open project: simplesamlphp/simplesamlphp Class Usage Examples

Public Methods

Method Description
generate ( SimpleSAML_Configuration $idp, SimpleSAML_Configuration $sp, string $shire, array | null $attributes ) : string Build a authentication response.
getAttributes ( )
getIssuer ( )
getNameID ( )
getRelayState ( )
getSessionIndex ( ) : string | null Retrieve the session index of this response.
setMessageValidated ( boolean $messageValidated ) Set whether this message was validated externally.
setRelayState ( $relayState )
setXML ( $xml )
validate ( )

Protected Methods

Method Description
checkDateConditions ( string | null $start = null, string | null $end = null ) : boolean Check if we are currently between the given date & time conditions.

Private Methods

Method Description
doXPathQuery ( $query, $node = NULL ) This function runs an xPath query on this authentication response.
enc_attribute ( string $name, array $values, boolean $base64, array $scopedAttributes ) : string Format a shib13 attribute.
isNodeValidated ( $node ) * Checks if the given node is validated by the signature on this response.

Method Details

checkDateConditions() protected static method

Note that this function allows a 10-minute leap from the initial time as marked by $start.
Author: Andreas Solberg, UNINETT AS ([email protected])
Author: Olav Morken, UNINETT AS ([email protected])
protected static checkDateConditions ( string | null $start = null, string | null $end = null ) : boolean
$start string | null A SAML2 timestamp marking the start of the period to check. Defaults to null, in which case there's no limitations in the past.
$end string | null A SAML2 timestamp marking the end of the period to check. Defaults to null, in which case there's no limitations in the future.
return boolean True if the current time belongs to the period specified by $start and $end. False otherwise.

generate() public method

Build a authentication response.
public generate ( SimpleSAML_Configuration $idp, SimpleSAML_Configuration $sp, string $shire, array | null $attributes ) : string
$idp SimpleSAML_Configuration Metadata for the IdP the response is sent from.
$sp SimpleSAML_Configuration Metadata for the SP the response is sent to.
$shire string The endpoint on the SP the response is sent to.
$attributes array | null The attributes which should be included in the response.
return string The response.

getAttributes() public method

public getAttributes ( )

getIssuer() public method

public getIssuer ( )

getNameID() public method

public getNameID ( )

getRelayState() public method

public getRelayState ( )

getSessionIndex() public method

Retrieve the session index of this response.
public getSessionIndex ( ) : string | null
return string | null The session index of this response.

setMessageValidated() public method

Set whether this message was validated externally.
public setMessageValidated ( boolean $messageValidated )
$messageValidated boolean TRUE if the message is already validated, FALSE if not.

setRelayState() public method

public setRelayState ( $relayState )

setXML() public method

public setXML ( $xml )

validate() public method

public validate ( )