Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

oauth2: Add access control to token introspection endpoint #655

Closed
ruhavingfun22 opened this issue Nov 17, 2017 · 3 comments
Closed

oauth2: Add access control to token introspection endpoint #655

ruhavingfun22 opened this issue Nov 17, 2017 · 3 comments
Assignees
Labels
feat New feature or request.

Comments

@ruhavingfun22
Copy link

ruhavingfun22 commented Nov 17, 2017

Right now any valid token can be used to introspect any other token.

From the token introspection RFC: https://tools.ietf.org/html/rfc7662 bottom of page 11 If left unprotected and un-throttled, the introspection endpoint could present a means for an attacker to poll a series of possible token values, fishing for a valid token. To prevent this, the authorization server MUST require authentication of protected resources that need to access the introspection endpoint and SHOULD require protected resources to be specifically authorized to call the introspection endpoint.

The request is to implement the "SHOULD require protected resources to be specifically authorized to call the introspection endpoint" otherwise one oauth user can introspect another oauth user's token.

@aeneasr aeneasr added the feat New feature or request. label Nov 21, 2017
@aeneasr aeneasr self-assigned this Nov 21, 2017
@aeneasr
Copy link
Member

aeneasr commented Nov 21, 2017

Also, if revoke doesn't have a similar scope or policy restriction, any token could be used to revoke any other token. (I have not tested this scenario yet)

RFC states:

The authorization server first validates the client credentials (in
case of a confidential client) and then verifies whether the token
was issued to the client making the revocation request. If this
validation fails, the request is refused and the client is informed
of the error by the authorization server as described below.

Which is currently not the case (nice catch):

https://github.com/ory/fosite/blob/master/handler/oauth2/revocation.go

@aeneasr
Copy link
Member

aeneasr commented Dec 4, 2017

Revokation is now tracked as #676

@aeneasr aeneasr changed the title Add Scope for TokenIntrospection and Revoke oauth2: Add access control to token introspection endpoint Dec 4, 2017
@aeneasr
Copy link
Member

aeneasr commented Dec 7, 2017

Both are resolved

@aeneasr aeneasr closed this as completed Dec 7, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feat New feature or request.
Projects
None yet
Development

No branches or pull requests

2 participants