Add AuthSettings.validate_token_resource to check a bearer token's resource (#3447)
This commit is contained in:
parent
9771e6b59c
commit
0c9136841f
1 changed files with 293 additions and 41 deletions
|
|
@ -2848,11 +2848,11 @@ REQUIREMENTS: dict[str, Requirement] = {
|
|||
source=f"{SPEC_BASE_URL}/basic/authorization#access-token-usage",
|
||||
behavior="The resource server validates that the token audience matches its resource identifier.",
|
||||
transports=("streamable-http",),
|
||||
note="Auth is enforced at the HTTP layer.",
|
||||
note="Auth is enforced at the HTTP layer; the conformant tests enable AuthSettings.validate_token_resource.",
|
||||
divergence=Divergence(
|
||||
note=(
|
||||
"BearerAuthBackend never inspects AccessToken.resource; a token issued for a different "
|
||||
"resource is accepted. Spec MUST."
|
||||
"Off by default: without AuthSettings.validate_token_resource the bearer gate does not compare "
|
||||
"AccessToken.resource with resource_server_url and the check is the token verifier's. Spec MUST."
|
||||
),
|
||||
),
|
||||
),
|
||||
|
|
|
|||
Loading…
Reference in a new issue