Title: RFC 9207 iss param != discovery issuer (trailing-slash mismatch) breaks strict OIDC clients · Issue #524 · JavaScriptSolidServer/JavaScriptSolidServer · GitHub
Open Graph Title: RFC 9207 iss param != discovery issuer (trailing-slash mismatch) breaks strict OIDC clients · Issue #524 · JavaScriptSolidServer/JavaScriptSolidServer
X Title: RFC 9207 iss param != discovery issuer (trailing-slash mismatch) breaks strict OIDC clients · Issue #524 · JavaScriptSolidServer/JavaScriptSolidServer
Description: Summary The IdP advertises an issuer with a trailing slash in the discovery doc, but emits the RFC 9207 iss authorization-response parameter without one. RFC 9207 requires the iss value to be identical to the issuer identifier. Strict cl...
Open Graph Description: Summary The IdP advertises an issuer with a trailing slash in the discovery doc, but emits the RFC 9207 iss authorization-response parameter without one. RFC 9207 requires the iss value to be ident...
X Description: Summary The IdP advertises an issuer with a trailing slash in the discovery doc, but emits the RFC 9207 iss authorization-response parameter without one. RFC 9207 requires the iss value to be ident...
Opengraph URL: https://github.com/JavaScriptSolidServer/JavaScriptSolidServer/issues/524
X: @github
Domain: github.com
IPv4 address: 140.82.113.4
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"RFC 9207 iss param != discovery issuer (trailing-slash mismatch) breaks strict OIDC clients","articleBody":"## Summary\n\nThe IdP advertises an issuer **with** a trailing slash in the discovery doc, but emits the RFC 9207 `iss` authorization-response parameter **without** one. RFC 9207 requires the `iss` value to be identical to the issuer identifier. Strict clients that compare them byte-for-byte reject the callback.\n\n## Where\n\n`src/idp/index.js` (well-known handler):\n\n```js\n// Ensure issuer has trailing slash for CTH compatibility\nconst normalizedIssuer = issuer.endsWith('/') ? issuer : issuer + '/';\nconst baseUrl = issuer.endsWith('/') ? issuer.slice(0, -1) : issuer;\n...\nissuer: normalizedIssuer, // discovery doc => trailing slash\n```\n\nBut the provider is created with the raw issuer:\n\n```js\n// src/idp/provider.js:451\nconst provider = new Provider(issuer, configuration);\n```\n\nso oidc-provider's `iss` param (enabled via `authorization_response_iss_parameter_supported: true`) is the **raw** issuer. When the configured issuer has no trailing slash:\n\n- discovery `issuer` → `http://host:port/`\n- callback `iss` → `http://host:port`\n\n## Symptom\n\n`solid-oidc` (the client behind the `xlogin` widget) stores `config.issuer` from discovery and then strict-compares it to the callback `iss`:\n\n```js\n// solid-oidc handleRedirectFromLogin()\nif (!idp || iss !== idp) throw new Error(`Issuer mismatch: ${iss} !== ${idp}`);\n```\n\n(Note: its `login()` is slash-tolerant via `trimSlash()`, but `handleRedirectFromLogin()` is not.) The throw happens **before** the token request, so `POST /idp/token` never fires and sign-in silently bounces back to the app with no session. Reproduced embedding JSS on Android (nodejs-mobile) with `idpIssuer` lacking a trailing slash; tracked in #522.\n\n## Fix options\n\n1. Make the `iss` param and discovery `issuer` identical — feed oidc-provider the same normalized (trailing-slash) issuer used in the discovery doc, or drop the discovery-only normalization so both are slash-free.\n2. At minimum, document that the configured issuer must already carry the canonical trailing slash.\n\n(Workaround on the embedding side: pass `idpIssuer` already ending in `/`, which makes `normalizedIssuer === issuer` and aligns both. That fixed sign-in for the Android app.)","author":{"url":"https://github.com/melvincarvalho","@type":"Person","name":"melvincarvalho"},"datePublished":"2026-05-23T20:06:23Z","url":"https://github.com/JavaScriptSolidServer/JavaScriptSolidServer/issues/524"}
| react-profiling | 0 |
| react-import-map | react,react-dom,react-dom/client,react-dom/profiling,react-is,react/compiler-runtime,react/jsx-dev-runtime,react/jsx-runtime,scheduler@b8488ee2c322 |
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:447bd814-510f-c930-76e9-443db6327737 |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | B794:1827E:2D131A1:3B86EA9:6B0398D8 |
| html-safe-nonce | 5038e63456b209f1d239bd247e715f501711828ada15e39319e56fdf7d0a43e5 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJCNzk0OjE4MjdFOjJEMTMxQTE6M0I4NkVBOTo2QjAzOThEOCIsInZpc2l0b3JfaWQiOiI1MjQyMTA0Nzk4ODUzMTc1NTEyIiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0= |
| visitor-hmac | eb4f6167c06ed340da742efda2658408f4221fb73e6ac86124accb61aa6c289c |
| hovercard-subject-tag | issue:4509461581 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/JavaScriptSolidServer/JavaScriptSolidServer/524/issue_layout |
| twitter:image | https://opengraph.githubassets.com/19bbb92c202aa969e35f3400ead79e64159292a9bcf9a421f3bebd99dfa5af5b/JavaScriptSolidServer/JavaScriptSolidServer/issues/524 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/19bbb92c202aa969e35f3400ead79e64159292a9bcf9a421f3bebd99dfa5af5b/JavaScriptSolidServer/JavaScriptSolidServer/issues/524 |
| og:image:alt | Summary The IdP advertises an issuer with a trailing slash in the discovery doc, but emits the RFC 9207 iss authorization-response parameter without one. RFC 9207 requires the iss value to be ident... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | melvincarvalho |
| hostname | github.com |
| expected-hostname | github.com |
| None | 87e774ee7c6b3bee0490394e4d3e57ec9dbc956f74b87ea685dc8996c1676456 |
| turbo-cache-control | no-preview |
| go-import | github.com/JavaScriptSolidServer/JavaScriptSolidServer git https://github.com/JavaScriptSolidServer/JavaScriptSolidServer.git |
| octolytics-dimension-user_id | 205442424 |
| octolytics-dimension-user_login | JavaScriptSolidServer |
| octolytics-dimension-repository_id | 958025407 |
| octolytics-dimension-repository_nwo | JavaScriptSolidServer/JavaScriptSolidServer |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 958025407 |
| octolytics-dimension-repository_network_root_nwo | JavaScriptSolidServer/JavaScriptSolidServer |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 423dbb54c5e7bfecc838eb387c1435eb3d0e760d |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
| react-app-name | issues |
Links:
| Server | github.com |
| Content-Type | text/html; charset=utf-8 |
| Cache-Control | max-age=0, private, must-revalidate |
Viewport: width=device-width