AzureAD / azure-activedirectory-identitymodel-extensions-for-dotnet

IdentityModel extensions for .Net
MIT License
1.06k stars 401 forks source link

Replace the dependency on Newtonsoft.Json with new .NET Json APIs #1060

Closed natemcmaster closed 1 year ago

natemcmaster commented 5 years ago

As recently announced, the .NET team is adding new APIs for JSON parsing. IdentityModel currently relies on Newtonsoft.Json for JSON parsing. This often causes problems for customers who want to use a different version of Newtonsoft.Json. It also makes it more difficult to enable complete customer support for products like ASP.NET Core because Microsoft does not have ownership of Newtonsoft.Json.

I believe these problems will be resolved by replacing the Newtonsoft.Json dependency with the new JSON APIs announced in https://github.com/dotnet/announcements/issues/90

This will unblock https://github.com/aspnet/AspNetCore/issues/4260.

brentschmaltz commented 5 years ago

we need the 3.0 api's

Seyden commented 5 years ago

Whats the status? As far as i know, the 3.0 APIs are already released, i would like to remove my Newtonsoft.JSON references.. i only need it right now for the identityModel

brentschmaltz commented 5 years ago

@Seyden in our 6.x release, we have removed our references to Newtonsoft. We plan on releasing a 6.x in the .NET 3.0 timeline.

OliverRC commented 4 years ago

We've began moving all our stuff over to System.Text.Json in .NET Core 3.1. Would be great to fully drop Newtonsoft, this library is one of the last few which still has a Newtonsoft dependency 👍

@brentschmaltz any idea when we can expect 6.x to drop?

brentschmaltz commented 4 years ago

@OliverRC we are figuring that out. It's a bit more complicated than just removal as some types used by asp.net and other runtimes depend on our types that have newtonsoft dependencies.

kevinchalet commented 2 years ago

@brentschmaltz you mentioned in https://github.com/dotnet/aspnetcore/issues/36175#issuecomment-1012326509 you were making good progress on that. Could you please tell us more about your plans? E.g what does that mean for the older TFMs that can't reference STJ? Will they keep using the internal JSON.NET copy or will they be removed?

lechu445 commented 2 years ago

@kevinchalet https://github.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/pull/1768#issuecomment-965666920 of @brentschmaltz says that you can track progress on Json.NET in branch https://github.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/tree/brentsch/SystemTextJson

brentschmaltz commented 2 years ago

@kevinchalet we are shooting for an April release.

brentschmaltz commented 1 year ago

@cakescience it looks like a june / july release.

jennyf19 commented 1 year ago

Included in IdentityModel7x.