Definition at line 9 of file NameIDAttribute.php.
◆ __construct()
sspmod_saml_Auth_Process_NameIDAttribute::__construct |
( |
|
$config, |
|
|
|
$reserved |
|
) |
| |
Initialize this filter, parse configuration.
- Parameters
-
array | $config | Configuration information about this filter. |
mixed | $reserved | For future use. |
Definition at line 34 of file NameIDAttribute.php.
References $config, and $format.
36 parent::__construct(
$config, $reserved);
39 if (isset(
$config[
'attribute'])) {
40 $this->attribute = (string)
$config[
'attribute'];
42 $this->attribute =
'nameid';
51 $this->format = self::parseFormat(
$format);
◆ parseFormat()
static sspmod_saml_Auth_Process_NameIDAttribute::parseFormat |
( |
|
$format | ) |
|
|
staticprivate |
Parse a NameID format string into an array.
- Parameters
-
string | $format | The format string. |
- Returns
- array The format string broken into its individual components.
- Exceptions
-
Definition at line 63 of file NameIDAttribute.php.
References $format, and $ret.
69 while (($next = strpos(
$format,
'%', $pos)) !==
false) {
72 $replacement =
$format[$next + 1];
73 switch ($replacement) {
78 $ret[] =
'NameQualifier';
81 $ret[] =
'SPNameQualifier';
◆ process()
sspmod_saml_Auth_Process_NameIDAttribute::process |
( |
& |
$state | ) |
|
Convert NameID to attribute.
- Parameters
-
array | &$state | The request state. |
Definition at line 106 of file NameIDAttribute.php.
References $attribute, $state, and SAML2\Constants\NAMEID_UNSPECIFIED.
109 assert(isset(
$state[
'Source'][
'entityid']));
110 assert(isset(
$state[
'Destination'][
'entityid']));
112 if (!isset(
$state[
'saml:sp:NameID'])) {
116 $rep =
$state[
'saml:sp:NameID'];
117 assert(isset($rep->value));
120 if (!isset($rep->Format)) {
123 if (!isset($rep->NameQualifier)) {
124 $rep->NameQualifier =
$state[
'Source'][
'entityid'];
126 if (!isset($rep->SPNameQualifier)) {
127 $rep->SPNameQualifier =
$state[
'Destination'][
'entityid'];
132 foreach ($this->format as $element) {
136 $value .= $rep->$element;
138 $isString = !$isString;
const NAMEID_UNSPECIFIED
Unspecified NameID format.
if(!array_key_exists('stateid', $_REQUEST)) $state
Handle linkback() response from LinkedIn.
◆ $attribute
sspmod_saml_Auth_Process_NameIDAttribute::$attribute |
|
private |
◆ $format
sspmod_saml_Auth_Process_NameIDAttribute::$format |
|
private |
The documentation for this class was generated from the following file:
- libs/composer/vendor/simplesamlphp/simplesamlphp/modules/saml/lib/Auth/Process/NameIDAttribute.php