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

bug: OIDC server returns "resource indicator must be an absolute URI" error #5779

Closed
4 tasks done
charIeszhao opened this issue Apr 23, 2024 · 1 comment · Fixed by panva/node-oidc-provider#1258 or #5782
Closed
4 tasks done
Assignees
Labels
bug Something isn't working status/wip We are working on it

Comments

@charIeszhao
Copy link
Member

Describe the bug

If we create the API resource identifier as a valid simple domain without pathname, such as https://logto.io, the OIDC server will return an unexpected "resource indicator must be an absolute URI" error, even though the identifier is a valid URL.

Currently, the workaround is to use an identifier URL followed by either a trailing slash / or a pathname /foo instead.

Expected behavior

Resource identifiers like https://logto.io should also work.

How to reproduce?

  • Create an API resource in Logto Console, and input a simple domain http://example.com as the indicator.
  • Use this api resource in a client app, say "react sample", and pass it into Logto configs as resources: ['https://example.com']
  • Sign in, and the OIDC auth server will report an error in its redirect URL: resource indicator must be an absolute URI

Context

  • Logto Cloud
  • Self-hosted, Logto version =
    • Container (Docker image)
    • Raw Node.js

Screenshots

@charIeszhao
Copy link
Member Author

The root cause was found in our underlying service library. A pull request has been filed and will update it on our end as soon as the patch is available.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working status/wip We are working on it
1 participant