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

Client in device authorization flow should be considered public #1876

Open
srook opened this issue Jan 15, 2025 · 0 comments
Open

Client in device authorization flow should be considered public #1876

srook opened this issue Jan 15, 2025 · 0 comments
Labels
type: bug A general bug

Comments

@srook
Copy link

srook commented Jan 15, 2025

When using device authorization flow, device initiating the flow is public client and should be able to access endpoints /oauth2/device_authorization and /oauth2/token without providing additional authorization.

To Reproduce
With following configuration:

oauth2:
  authorizationserver:
    issuer: http://localhost:8070
    client:
      test-client:
        registration:
          client-id: test-client
          client-name: Test Client
          client-authentication-methods:
            - none
          authorization-grant-types:
            - urn:ietf:params:oauth:grant-type:device_code
            - refresh_token
          scopes:
            - test.read

Requests

curl --request POST \
  --url http://localhost:8070/oauth2/device_authorization \
  --header 'content-type: application/x-www-form-urlencoded' \
  --data client_id=test-client \
  --data scope=test.read

and

curl --request POST \
  --url http://localhost:8070/oauth2/token \
  --header 'content-type: application/x-www-form-urlencoded' \
  --data device_code=device-code-returned-by-authorization-server \
  --data client_id=test-client \
  --data grant_type=urn:ietf:params:oauth:grant-type:device_code

Expected behavior
Request should return successful response since client is public and should not be required to send additional Authorization header.

Currently only Authorization Code with PKCE flow does not require sending additional authorization.

@srook srook added the type: bug A general bug label Jan 15, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
type: bug A general bug
Projects
None yet
Development

No branches or pull requests

1 participant