@inrupt/solid-client-authn-browser 1.17.4 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (45) hide show
  1. package/dist/ClientAuthentication.d.ts +1 -0
  2. package/dist/Session.d.ts +4 -67
  3. package/dist/defaultSession.d.ts +0 -28
  4. package/dist/dependencies.d.ts +1 -2
  5. package/dist/index.d.ts +2 -3
  6. package/dist/index.js +16 -124
  7. package/dist/index.js.map +1 -1
  8. package/dist/index.mjs +9 -113
  9. package/dist/index.mjs.map +1 -1
  10. package/dist/login/oidc/__mocks__/IOidcOptions.d.ts +2 -0
  11. package/dist/login/oidc/incomingRedirectHandler/AuthCodeRedirectHandler.d.ts +4 -0
  12. package/dist/solid-client-authn.bundle.js +19 -19
  13. package/dist/solid-client-authn.bundle.js.map +1 -1
  14. package/package.json +6 -7
  15. package/rollup.config.mjs +28 -14
  16. package/src/ClientAuthentication.spec.ts +1 -12
  17. package/src/Session.spec.ts +11 -178
  18. package/src/Session.ts +6 -98
  19. package/src/defaultSession.spec.ts +0 -18
  20. package/src/defaultSession.ts +0 -40
  21. package/src/dependencies.ts +1 -2
  22. package/src/index.spec.ts +1 -2
  23. package/src/index.ts +9 -3
  24. package/src/login/oidc/ClientRegistrar.spec.ts +8 -9
  25. package/src/login/oidc/IssuerConfigFetcher.spec.ts +17 -32
  26. package/src/login/oidc/IssuerConfigFetcher.ts +1 -5
  27. package/src/login/oidc/incomingRedirectHandler/AuthCodeRedirectHandler.spec.ts +9 -29
  28. package/src/login/oidc/incomingRedirectHandler/AuthCodeRedirectHandler.ts +6 -19
  29. package/src/login/oidc/incomingRedirectHandler/ErrorOidcHandler.spec.ts +0 -11
  30. package/src/login/oidc/incomingRedirectHandler/FallbackRedirectHandler.spec.ts +1 -12
  31. package/.prettierignore +0 -3
  32. package/sampleFlows/SolidAuthClientArchitecture.png +0 -0
  33. package/sampleFlows/authorization-code-with-pkce.png +0 -0
  34. package/sampleFlows/authorization-code-with-pkce.seqdiag +0 -46
  35. package/sampleFlows/authorization-code.png +0 -0
  36. package/sampleFlows/authorization-code.seqdiag +0 -50
  37. package/sampleFlows/client-credentials.png +0 -0
  38. package/sampleFlows/client-credentials.seqdiag +0 -38
  39. package/sampleFlows/legacy-implicit-flow.png +0 -0
  40. package/sampleFlows/legacy-implicit-flow.seqdiag +0 -43
  41. package/sampleFlows/self-signed.png +0 -0
  42. package/sampleFlows/self-signed.seqdiag +0 -49
  43. package/sampleFlows/signatory-access-control.seqdiag +0 -36
  44. package/sampleFlows/signatory-access-control.svg +0 -1
  45. package/sonar-project.properties +0 -15
@@ -1 +0,0 @@
1
- <svg xmlns="http://www.w3.org/2000/svg" width="1326.3203125px" height="1442.453125px" class="sequence simple"><desc>Legacy Implicit Flow</desc><defs><marker viewBox="0 0 5 5" markerWidth="5" markerHeight="5" orient="auto" refX="5" refY="2.5" id="markerArrowBlock"><path d="M 0 0 L 5 2.5 L 0 5 z"/></marker><marker viewBox="0 0 9.6 16" markerWidth="4" markerHeight="16" orient="auto" refX="9.6" refY="8" id="markerArrowOpen"><path d="M 9.6,8 1.92,16 0,13.7 5.76,8 0,2.286 1.92,0 9.6,8 z"/></marker></defs><g class="title"><rect x="10" y="10" width="201.984375" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="15" y="29.40625" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="15">Legacy Implicit Flow</tspan></text></g><g class="actor"><rect x="230.578125" y="48.015625" width="39.203125" height="38.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="240.578125" y="72.421875" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="240.578125">RP</tspan></text></g><g class="actor"><rect x="230.578125" y="1384.4375" width="39.203125" height="38.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="240.578125" y="1408.84375" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="240.578125">RP</tspan></text></g><line x1="250.1796875" x2="250.1796875" y1="86.03125" y2="1384.4375" stroke="#000000" fill="none" style="stroke-width: 2;"/><g class="actor"><rect x="427.9609375" y="48.015625" width="144.796875" height="38.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="437.9609375" y="72.421875" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="437.9609375">Alice's WebId</tspan></text></g><g class="actor"><rect x="427.9609375" y="1384.4375" width="144.796875" height="38.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="437.9609375" y="1408.84375" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="437.9609375">Alice's WebId</tspan></text></g><line x1="500.359375" x2="500.359375" y1="86.03125" y2="1384.4375" stroke="#000000" fill="none" style="stroke-width: 2;"/><g class="actor"><rect x="630.1484375" y="48.015625" width="116" height="38.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="640.1484375" y="72.421875" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="640.1484375">Alice's OP</tspan></text></g><g class="actor"><rect x="630.1484375" y="1384.4375" width="116" height="38.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="640.1484375" y="1408.84375" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="640.1484375">Alice's OP</tspan></text></g><line x1="688.1484375" x2="688.1484375" y1="86.03125" y2="1384.4375" stroke="#000000" fill="none" style="stroke-width: 2;"/><g class="actor"><rect x="789.3515625" y="48.015625" width="183.1875" height="38.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="799.3515625" y="72.421875" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="799.3515625">badguys.com WebId</tspan></text></g><g class="actor"><rect x="789.3515625" y="1384.4375" width="183.1875" height="38.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="799.3515625" y="1408.84375" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="799.3515625">badguys.com WebId</tspan></text></g><line x1="880.9453125" x2="880.9453125" y1="86.03125" y2="1384.4375" stroke="#000000" fill="none" style="stroke-width: 2;"/><g class="actor"><rect x="992.5390625" y="48.015625" width="154.390625" height="38.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="1002.5390625" y="72.421875" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="1002.5390625">Bob's Pod (RS)</tspan></text></g><g class="actor"><rect x="992.5390625" y="1384.4375" width="154.390625" height="38.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="1002.5390625" y="1408.84375" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="1002.5390625">Bob's Pod (RS)</tspan></text></g><line x1="1069.734375" x2="1069.734375" y1="86.03125" y2="1384.4375" stroke="#000000" fill="none" style="stroke-width: 2;"/><g class="note"><rect x="95.3828125" y="106.03125" width="134.796875" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="100.3828125" y="125.4375" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="100.3828125">AUTHORIZATION</tspan></text></g><g class="note"><rect x="86.7890625" y="154.046875" width="326.78125" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="91.7890625" y="173.453125" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="91.7890625">1. Alice navigates to badguys.com</tspan></text></g><g class="note"><rect x="91.5859375" y="202.0625" width="317.1875" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="96.5859375" y="221.46875" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="96.5859375">2. Alice selects her OP or WebID</tspan></text></g><g class="signal"><text x="279.27734375" y="260.4765625" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="279.27734375">2.1 Retrieve Profile</tspan></text><line x1="250.1796875" x2="500.359375" y1="268.09375" y2="268.09375" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="signal"><text x="375.26953125" y="293.09375" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="375.26953125"/></text><line x1="500.359375" x2="250.1796875" y1="288.09375" y2="288.09375" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="signal"><text x="358.7734375" y="318.4921875" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="358.7734375">3. Get OP configuration</tspan></text><line x1="250.1796875" x2="688.1484375" y1="326.109375" y2="326.109375" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="signal"><text x="469.1640625" y="351.109375" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="469.1640625"/></text><line x1="688.1484375" x2="250.1796875" y1="346.109375" y2="346.109375" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="signal"><text x="401.96875" y="376.5078125" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="401.96875">4. Get OP JWKS</tspan></text><line x1="250.1796875" x2="688.1484375" y1="384.125" y2="384.125" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="signal"><text x="469.1640625" y="409.125" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="469.1640625"/></text><line x1="688.1484375" x2="250.1796875" y1="404.125" y2="404.125" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="note"><rect x="72.390625" y="424.125" width="355.578125" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="77.390625" y="443.53125" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="77.390625">5. Generates Private/Public key pair</tspan></text></g><g class="note"><rect x="10" y="472.140625" width="480.359375" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="15" y="491.546875" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="15">6. Saves Private/Public key pair to local storage</tspan></text></g><g class="signal"><text x="353.96875" y="530.5546875" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="353.96875">7. Authorization Request</tspan></text><line x1="250.1796875" x2="688.1484375" y1="538.171875" y2="538.171875" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="signal"><text x="698.1484375" y="568.5703125" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="698.1484375">8. Retrieves WebID</tspan></text><line x1="688.1484375" x2="880.9453125" y1="576.1875" y2="576.1875" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="signal"><text x="784.546875" y="601.1875" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="784.546875"/></text><line x1="880.9453125" x2="688.1484375" y1="596.1875" y2="596.1875" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="note"><rect x="510.359375" y="616.1875" width="355.578125" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="515.359375" y="635.59375" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="515.359375">9. Validates redirect_url with WebID</tspan></text></g><g class="note"><rect x="567.953125" y="664.203125" width="240.390625" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="572.953125" y="683.609375" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="572.953125">10. Gets Alice's consent</tspan></text></g><g class="note"><rect x="543.953125" y="712.21875" width="288.390625" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="548.953125" y="731.625" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="548.953125">11. Generates an access_token</tspan></text></g><g class="signal"><text x="339.5703125" y="770.6328125" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="339.5703125">12. Returns to redirect_url</tspan></text><line x1="688.1484375" x2="250.1796875" y1="778.25" y2="778.25" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="note"><rect x="76.1796875" y="798.25" width="154" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="81.1796875" y="817.65625" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="81.1796875">SENDING REQUEST</tspan></text></g><g class="note"><rect x="139.5859375" y="846.265625" width="221.1875" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="144.5859375" y="865.671875" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="144.5859375">1. Creates a pop_token</tspan></text></g><g class="signal"><text x="587.95703125" y="904.6796875" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="587.95703125">2. Request sent</tspan></text><line x1="250.1796875" x2="1069.734375" y1="912.296875" y2="912.296875" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="note"><rect x="930.34375" y="932.296875" width="278.78125" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="935.34375" y="951.703125" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="935.34375">3. Checks pop_token Audience</tspan></text></g><g class="note"><rect x="939.9453125" y="980.3125" width="259.578125" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="944.9453125" y="999.71875" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="944.9453125">4. Checks client signature</tspan></text></g><g class="signal"><text x="650.65625" y="1038.7265625" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="650.65625">5. Retrieves Subject Profile</tspan></text><line x1="1069.734375" x2="500.359375" y1="1046.34375" y2="1046.34375" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="signal"><text x="785.046875" y="1071.34375" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="785.046875"/></text><line x1="500.359375" x2="1069.734375" y1="1066.34375" y2="1066.34375" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="note"><rect x="987.9375" y="1086.34375" width="163.59375" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="992.9375" y="1105.75" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="992.9375">6. Checks Issuer</tspan></text></g><g class="signal"><text x="739.74609375" y="1144.7578125" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="739.74609375">7. Retrieves OP configuration</tspan></text><line x1="1069.734375" x2="688.1484375" y1="1152.375" y2="1152.375" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="signal"><text x="878.94140625" y="1177.375" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="878.94140625"/></text><line x1="688.1484375" x2="1069.734375" y1="1172.375" y2="1172.375" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="signal"><text x="802.14453125" y="1202.7734375" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="802.14453125">8. Requests JWKS</tspan></text><line x1="1069.734375" x2="688.1484375" y1="1210.390625" y2="1210.390625" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="signal"><text x="878.94140625" y="1235.390625" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="878.94140625"/></text><line x1="688.1484375" x2="1069.734375" y1="1230.390625" y2="1230.390625" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g><g class="note"><rect x="939.9453125" y="1250.390625" width="259.578125" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="944.9453125" y="1269.796875" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="944.9453125">9. Performs Authentication</tspan></text></g><g class="note"><rect x="939.9453125" y="1298.40625" width="259.578125" height="28.015625" stroke="#000000" fill="#ffffff" style="stroke-width: 2;"/><text x="944.9453125" y="1317.8125" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="944.9453125">10. Performs Authorization</tspan></text></g><g class="signal"><text x="573.55859375" y="1356.8203125" style="font-size: 16px; font-family: &quot;Andale Mono&quot;, monospace;"><tspan x="573.55859375">11. Returns Result</tspan></text><line x1="1069.734375" x2="250.1796875" y1="1364.4375" y2="1364.4375" stroke="#000000" fill="none" style="stroke-width: 2; marker-end: url(&quot;#markerArrowBlock&quot;);"/></g></svg>
@@ -1,15 +0,0 @@
1
- sonar.projectKey=inrupt_solid-client-authn-browser
2
- sonar.projectName=solid-client-authn-browser
3
- sonar.organization=inrupt
4
-
5
- # Path is relative to the sonar-project.properties file. Defaults to .
6
- sonar.sources=src
7
-
8
- # Typescript tsconfigPath JSON file
9
- sonar.typescript.tsconfigPath=.
10
-
11
- # Comma-delimited list of paths to LCOV coverage report files. Paths may be absolute or relative to the project root.
12
- sonar.javascript.lcov.reportPaths=./coverage/lcov.info
13
-
14
- # Exclude tests from analysis
15
- sonar.exclusions=**/*.test.ts