You are here

public function SamlService::getAttributes in SAML Authentication 4.x

Same name and namespace in other branches
  1. 8.3 src/SamlService.php \Drupal\samlauth\SamlService::getAttributes()
  2. 8.2 src/SamlService.php \Drupal\samlauth\SamlService::getAttributes()

Returns all attributes in a SAML response.

This method will return valid data after a response is processed (i.e. after samlAuth->processResponse() is called).

Return value

array An array with all returned SAML attributes..

2 calls to SamlService::getAttributes()
SamlService::doLogin in src/SamlService.php
Logs a user in, creating / linking an account; synchronizes attributes.
SamlService::synchronizeUserAttributes in src/SamlService.php
Synchronizes user data with attributes in the SAML request.

File

src/SamlService.php, line 768

Class

SamlService
Governs communication between the SAML toolkit and the IdP / login behavior.

Namespace

Drupal\samlauth

Code

public function getAttributes() {
  $attributes = $this
    ->getSamlAuth('acs')
    ->getAttributes();
  $friendly_attributes = $this
    ->getSamlAuth('acs')
    ->getAttributesWithFriendlyName();
  return $attributes + $friendly_attributes;
}