interface OpenIDConnectSessionInterface in OpenID Connect / OAuth client 2.x
Creates and validates state tokens.
@package Drupal\openid_connect
Hierarchy
- interface \Drupal\Core\DependencyInjection\ContainerInjectionInterface
- interface \Drupal\openid_connect\OpenIDConnectSessionInterface
Expanded class hierarchy of OpenIDConnectSessionInterface
All classes that implement OpenIDConnectSessionInterface
5 files declare their use of OpenIDConnectSessionInterface
- OpenIDConnectAccountsForm.php in src/
Form/ OpenIDConnectAccountsForm.php - OpenIDConnectLoginForm.php in src/
Form/ OpenIDConnectLoginForm.php - OpenIDConnectRedirectController.php in src/
Controller/ OpenIDConnectRedirectController.php - OpenIDConnectStateTokenTest.php in tests/
src/ Unit/ OpenIDConnectStateTokenTest.php - OpenIDConnectTest.php in tests/
src/ Unit/ OpenIDConnectTest.php
File
- src/
OpenIDConnectSessionInterface.php, line 12
Namespace
Drupal\openid_connectView source
interface OpenIDConnectSessionInterface extends ContainerInjectionInterface {
/**
* Get the destination redirect path and langcode from the session.
*
* @param bool $clear
* The value is cleared from the session, unless this is set to FALSE.
*
* @return array
* The destination path and langcode.
*/
public function retrieveDestination(bool $clear = TRUE) : array;
/**
* Save the current path and langcode, for redirecting after authorization.
*
* @see \Drupal\openid_connect\Controller\OpenIDConnectRedirectController::authenticate()
*/
public function saveDestination();
/**
* Get the operation details from the session.
*
* @param bool $clear
* The value is cleared from the session, unless this is set to FALSE.
*
* @return array
* The operation details.
*/
public function retrieveOp(bool $clear = TRUE) : array;
/**
* Save the operation details in the session.
*
* @param string $op
* The operation.
* @param int|null $uid
* The user ID.
*/
public function saveOp(string $op, int $uid = NULL);
/**
* Get the id token from the session.
*
* @param bool $clear
* The value is cleared from the session, if this is set to TRUE.
*
* @return string|null
* The id token.
*/
public function retrieveIdToken(bool $clear = FALSE) : ?string;
/**
* Save the id token in the session.
*
* @param string $token
* The id token.
*/
public function saveIdToken(string $token);
/**
* Get the access token from the session.
*
* @param bool $clear
* The value is cleared from the session, if this is set to TRUE.
*
* @return string|null
* The access token.
*/
public function retrieveAccessToken(bool $clear = FALSE) : ?string;
/**
* Save the access token in the session.
*
* @param string $token
* The access token.
*/
public function saveAccessToken(string $token);
/**
* Get the state token from the session.
*
* @param bool $clear
* The value is cleared from the session, unless this is set to FALSE.
*
* @return string|null
* The state token.
*/
public function retrieveStateToken(bool $clear = TRUE) : ?string;
/**
* Save the state token in the session.
*
* @param string $token
* The state token.
*/
public function saveStateToken(string $token);
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
ContainerInjectionInterface:: |
public static | function | Instantiates a new instance of this class. | 75 |
OpenIDConnectSessionInterface:: |
public | function | Get the access token from the session. | 1 |
OpenIDConnectSessionInterface:: |
public | function | Get the destination redirect path and langcode from the session. | 1 |
OpenIDConnectSessionInterface:: |
public | function | Get the id token from the session. | 1 |
OpenIDConnectSessionInterface:: |
public | function | Get the operation details from the session. | 1 |
OpenIDConnectSessionInterface:: |
public | function | Get the state token from the session. | 1 |
OpenIDConnectSessionInterface:: |
public | function | Save the access token in the session. | 1 |
OpenIDConnectSessionInterface:: |
public | function | Save the current path and langcode, for redirecting after authorization. | 1 |
OpenIDConnectSessionInterface:: |
public | function | Save the id token in the session. | 1 |
OpenIDConnectSessionInterface:: |
public | function | Save the operation details in the session. | 1 |
OpenIDConnectSessionInterface:: |
public | function | Save the state token in the session. | 1 |