BearerTokenValidator:validateAuthorization 似乎错误地使用了受众声明。
作者: michaeldnelson创建于 2018年2月18日更新于 2026年8月7日
标签Future VersionSpec Compliance
// 返回带有附加属性的请求 return $request ->withAttribute('oauth_access_token_id', $token->getClaim('jti')) ->withAttribute('oauth_client_id', $token->getClaim('aud')) ->withAttribute('oauth_user_id', $token->getClaim('sub')) ->withAttribute('oauth_scopes', $token->getClaim('scopes'));
这似乎期望客户端标识符作为受众,这似乎与此处的承载规范相冲突。 我可能误解了此规范,因为可以根据客户端 ID 和授权服务器之间的关系拒绝令牌,但这对我来说并不清楚。
内容来源: thephpleague/oauth2-server