-
Notifications
You must be signed in to change notification settings - Fork 4
Open
Description
The DelegatedPermissionTrait is missing the part of setting the cacheKey when the access token is null. According to the documentation, the cache key should be {tenantId}-{clientId} but is missing that part
Possible fix: Update the setCacheKey method with the proper fallback.
public function setCacheKey(?AccessToken $accessToken = null): void
{
if ($accessToken && $accessToken->getToken()) {
$uniqueIdentifier = hash("sha256", $accessToken->getToken());
$this->cacheKey = "{$this->getTenantId()}-{$this->getClientId()}-{$uniqueIdentifier}";
} else {
// If access is not provided fallback to default {tenantId}-{clientId}.
$this->cacheKey = "{$this->getTenantId()}-{$this->getClientId()}";
}
}Metadata
Metadata
Assignees
Labels
No labels
Type
Projects
Status
Needs Triage 🔍