Skip to content

Delayed ClaimsIdentity by calling into JsonWebTokenHandler #1940

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

Merged
merged 1 commit into from
Sep 8, 2022

Conversation

brentschmaltz
Copy link
Member

When delaying creation of the ClaimsIdentity, the call graph needs to go through JsonWebTokenHandler.CreateClaimsIdentity for extensibility.

@brentschmaltz brentschmaltz merged commit a502b0f into dev Sep 8, 2022
@brentschmaltz brentschmaltz deleted the brentsch/claimsMapping branch September 8, 2022 23:49
renovate bot referenced this pull request in orso-co/Orso.Arpa.Api Sep 12, 2022

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature. The key has expired.
[![Mend
Renovate](https://app.renovatebot.com/images/banner.svg)](https://renovatebot.com)

This PR contains the following updates:

| Package | Type | Update | Change |
|---|---|---|---|
|
[System.IdentityModel.Tokens.Jwt](https://togithub.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet)
| nuget | minor | `6.22.1` -> `6.23.1` |

---

### Release Notes

<details>

<summary>AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet</summary>

###
[`v6.23.1`](https://togithub.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/releases/tag/6.23.1)

[Compare
Source](https://togithub.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/compare/6.23.0...6.23.1)

A simple 'dot' release to fix an issue where JsonWebTokenHandler virtual
CreateClaimsIdentity was not called.

[https://github.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/pull/1940](https://togithub.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/pull/1940)

###
[`v6.23.0`](https://togithub.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/blob/HEAD/CHANGELOG.md#Next-release-6221-or-6230)

[Compare
Source](https://togithub.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/compare/6.22.1...6.23.0)

\=========

##### New Features:

Microsoft.IdentityModel has two assemblies to manipulate JWT tokens:

System.IdentityModel.Tokens.Jwt, which is the legacy assembly. It
defines JwtSecurityTokenHandler class to manipulate JWT tokens.
Microsoft.IdentityModel.JsonWebTokens, which defines the JsonWebToken
class and JsonWebTokenHandler, more modern, and more efficient.
When using JwtSecurityTokenHandler, the short named claims (oid, tid),
used to be transformed into the long named claims (with a namespace).
With JsonWebTokenHandler this is no longer the case, but when you
migrate your application from using JwtSecurityTokenHandler to
JsonWebTokenHandler (or use a framework that does), you will only get
original claims sent by the IdP. This is more efficient, and occupies
less space, but might trigger a lot of changes in your application. In
order to make it easier for people to migrate without changing their app
too much, this PR offers extensibility to re-add the claims mapping.

##### Bug Fixes:

</details>

---

### Configuration

📅 **Schedule**: Branch creation - "after 10pm every weekday,every
weekend,before 5am every weekday" in timezone Europe/Berlin, Automerge -
At any time (no schedule defined).

🚦 **Automerge**: Enabled.

♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the
rebase/retry checkbox.

🔕 **Ignore**: Close this PR and you won't be reminded about this update
again.

---

- [ ] <!-- rebase-check -->If you want to rebase/retry this PR, click
this checkbox.

---

This PR has been generated by [Mend
Renovate](https://www.mend.io/free-developer-tools/renovate/). View
repository job log
[here](https://app.renovatebot.com/dashboard#github/orso-co/Orso.Arpa.Api).

<!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzMi4xOTIuMyIsInVwZGF0ZWRJblZlciI6IjMyLjE5NC4yIn0=-->

Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants