clean install

This commit is contained in:
matze committed 2024-12-10 15:08:16 +01:00
commit e14eb2d8fd
31193 files changed
+3555714

No files matched your search

@@ -0,0 +1,42 @@
<?php
namespace Drupal\simple_oauth;
use Drupal\consumers\Entity\Consumer;
/**
* An interface that remembers known clients.
*/
interface KnownClientsRepositoryInterface {
/**
* Checks if a given user authorized a client for a given set of scopes.
*
* @param int $uid
* The user ID.
* @param \Drupal\consumers\Entity\Consumer $client
* The consumer entity.
* @param string[] $scopes
* List of scopes to authorize for.
*
* @return bool
* TRUE if the client is authorized, FALSE otherwise.
*/
public function isAuthorized(int $uid, Consumer $client, array $scopes): bool;
/**
* Store a client with a set of scopes as authorized for a given user.
*
* Passed in scopes are merged with already accepted scopes for the given
* client.
*
* @param int $uid
* The user ID.
* @param string $client_id
* The client ID.
* @param string[] $scopes
* List of scopes that should be authorized.
*/
public function rememberClient(int $uid, string $client_id, array $scopes);
}