You are here

public function OpenIDConnectClaims::getClaims in OpenID Connect / OAuth client 8

Same name and namespace in other branches
  1. 2.x src/OpenIDConnectClaims.php \Drupal\openid_connect\OpenIDConnectClaims::getClaims()

Returns OpenID Connect claims.

Allows them to be extended via an alter hook.

Return value

array List of claims.

See also

http://openid.net/specs/openid-connect-core-1_0.html#StandardClaims

http://openid.net/specs/openid-connect-core-1_0.html#ScopeClaims

2 calls to OpenIDConnectClaims::getClaims()
OpenIDConnectClaims::getOptions in src/OpenIDConnectClaims.php
Returns OpenID Connect standard Claims as a Form API options array.
OpenIDConnectClaims::getScopes in src/OpenIDConnectClaims.php
Returns scopes that have to be requested based on the configured claims.

File

src/OpenIDConnectClaims.php, line 86

Class

OpenIDConnectClaims
The OpenID Connect claims service.

Namespace

Drupal\openid_connect

Code

public function getClaims() {
  if (!isset(self::$claims)) {
    $claims = $this
      ->getDefaultClaims();
    $this->moduleHandler
      ->alter('openid_connect_claims', $claims);
    self::$claims = $claims;
  }
  return self::$claims;
}