-
Notifications
You must be signed in to change notification settings - Fork 463
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
b367283
commit dacde23
Showing
25 changed files
with
269 additions
and
128 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<?xml version="1.0" encoding="utf-8"?> | ||
<Project ToolsVersion="15.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003"> | ||
|
||
<Choose> | ||
<When Condition="'$(TargetFramework)' == 'net462' OR '$(TargetFramework)' == 'netstandard2.0' OR '$(TargetFramework)' == 'net6.0'"> | ||
<PropertyGroup> | ||
<DefineConstants>$(DefineConstants);SYSTEM_TEXT_JSON</DefineConstants> | ||
</PropertyGroup> | ||
</When> | ||
<Otherwise> | ||
<PropertyGroup> | ||
<DefineConstants>$(DefineConstants);NEWTONSOFT_JSON</DefineConstants> | ||
</PropertyGroup> | ||
</Otherwise> | ||
</Choose> | ||
|
||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,55 +1,64 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<TargetFrameworks>netstandard1.3;netstandard2.0;net6.0;net35;net40;net46;</TargetFrameworks> | ||
</PropertyGroup> | ||
|
||
<PropertyGroup Condition="'$(TargetFramework)' == 'net35'"> | ||
<FrameworkPathOverride>$(MSBuildProgramFiles32)\Reference Assemblies\Microsoft\Framework\.NETFramework\v3.5\Profile\Client</FrameworkPathOverride> | ||
<AutomaticallyUseReferenceAssemblyPackages>false</AutomaticallyUseReferenceAssemblyPackages> | ||
</PropertyGroup> | ||
<PropertyGroup Condition="'$(TargetFramework)' == 'net35' OR '$(TargetFramework)' == 'net40' OR '$(TargetFramework)' == 'net46'"> | ||
<TargetFrameworkIdentifier>.NETFramework</TargetFrameworkIdentifier> | ||
</PropertyGroup> | ||
<PropertyGroup Condition="'$(TargetFramework)' == 'netstandard1.3' OR '$(TargetFramework)' == 'netstandard2.0'"> | ||
<TargetFrameworkIdentifier>.NETStandard</TargetFrameworkIdentifier> | ||
</PropertyGroup> | ||
<PropertyGroup Condition="'$(TargetFramework)' == 'net6.0'"> | ||
<TargetFrameworkIdentifier>.NETFramework,Version=6.0</TargetFrameworkIdentifier> | ||
</PropertyGroup> | ||
|
||
<PropertyGroup> | ||
<Copyright>Public Domain</Copyright> | ||
<PackageDescription>Jwt.Net, a JWT (JSON Web Token) implementation for .NET</PackageDescription> | ||
<Authors>Alexander Batishchev, John Sheehan, Michael Lehenbauer</Authors> | ||
<PackageTags>jwt;json;authorization</PackageTags> | ||
<PackageLicense>CC0-1.0</PackageLicense> | ||
<Version>9.0.0-beta5</Version> | ||
<FileVersion>9.0.0.0</FileVersion> | ||
<AssemblyVersion>9.0.0.0</AssemblyVersion> | ||
<RootNamespace>JWT</RootNamespace> | ||
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects> | ||
</PropertyGroup> | ||
|
||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'"> | ||
<DefineConstants>TRACE;DEBUG</DefineConstants> | ||
<OutputPath>bin\Debug\</OutputPath> | ||
</PropertyGroup> | ||
|
||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'"> | ||
<DefineConstants>TRACE</DefineConstants> | ||
<OutputPath>bin\Release\</OutputPath> | ||
<GenerateDocumentationFile>true</GenerateDocumentationFile> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="Newtonsoft.Json" Version="10.0.3" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup Condition="'$(TargetFramework)' == 'netstandard1.3' OR '$(TargetFramework)' == 'netstandard2.0'"> | ||
<PackageReference Include="System.ComponentModel.Primitives" Version="4.3.0" /> | ||
<PackageReference Include="System.Reflection.TypeExtensions" Version="4.7.0" /> | ||
<PackageReference Include="System.Security.Cryptography.Csp" Version="4.3.0" /> | ||
</ItemGroup> | ||
|
||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<TargetFrameworks>net6.0;netstandard2.0;netstandard1.3;net462;net40;net35</TargetFrameworks> | ||
</PropertyGroup> | ||
|
||
<PropertyGroup Condition="'$(TargetFramework)' == 'net35'"> | ||
<FrameworkPathOverride>$(MSBuildProgramFiles32)\Reference Assemblies\Microsoft\Framework\.NETFramework\v3.5\Profile\Client</FrameworkPathOverride> | ||
<AutomaticallyUseReferenceAssemblyPackages>false</AutomaticallyUseReferenceAssemblyPackages> | ||
</PropertyGroup> | ||
<PropertyGroup Condition="'$(TargetFramework)' == 'net35' OR '$(TargetFramework)' == 'net40' OR '$(TargetFramework)' == 'net462'"> | ||
<TargetFrameworkIdentifier>.NETFramework</TargetFrameworkIdentifier> | ||
</PropertyGroup> | ||
<PropertyGroup Condition="'$(TargetFramework)' == 'netstandard1.3' OR '$(TargetFramework)' == 'netstandard2.0'"> | ||
<TargetFrameworkIdentifier>.NETStandard</TargetFrameworkIdentifier> | ||
</PropertyGroup> | ||
<PropertyGroup Condition="'$(TargetFramework)' == 'net6.0'"> | ||
<TargetFrameworkIdentifier>.NETFramework,Version=6.0</TargetFrameworkIdentifier> | ||
</PropertyGroup> | ||
|
||
<PropertyGroup> | ||
<Copyright>Public Domain</Copyright> | ||
<PackageDescription>Jwt.Net, a JWT (JSON Web Token) implementation for .NET</PackageDescription> | ||
<Authors>Alexander Batishchev, John Sheehan, Michael Lehenbauer</Authors> | ||
<PackageTags>jwt;json;authorization</PackageTags> | ||
<PackageLicense>CC0-1.0</PackageLicense> | ||
<Version>9.0.0-beta5</Version> | ||
<FileVersion>9.0.0.0</FileVersion> | ||
<AssemblyVersion>9.0.0.0</AssemblyVersion> | ||
<RootNamespace>JWT</RootNamespace> | ||
<AutoGenerateBindingRedirects>true</AutoGenerateBindingRedirects> | ||
</PropertyGroup> | ||
|
||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'"> | ||
<DefineConstants>$(DefineConstants);TRACE;DEBUG</DefineConstants> | ||
<OutputPath>bin\Debug\</OutputPath> | ||
</PropertyGroup> | ||
|
||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'"> | ||
<DefineConstants>$(DefineConstants);TRACE</DefineConstants> | ||
<OutputPath>bin\Release\</OutputPath> | ||
<GenerateDocumentationFile>true</GenerateDocumentationFile> | ||
</PropertyGroup> | ||
|
||
<Choose> | ||
<When Condition="$(DefineConstants.Contains(SYSTEM_TEXT_JSON))"> | ||
<ItemGroup> | ||
<PackageReference Include="System.Text.Json" Version="6.0.2" /> | ||
</ItemGroup> | ||
</When> | ||
<When Condition="$(DefineConstants.Contains(NEWTONSOFT_JSON))"> | ||
<ItemGroup> | ||
<PackageReference Include="Newtonsoft.Json" Version="10.0.3" /> | ||
</ItemGroup> | ||
</When> | ||
</Choose> | ||
|
||
<ItemGroup Condition="'$(TargetFramework)' == 'netstandard1.3' OR '$(TargetFramework)' == 'netstandard2.0'"> | ||
<PackageReference Include="System.ComponentModel.Primitives" Version="4.3.0" /> | ||
<PackageReference Include="System.Reflection.TypeExtensions" Version="4.7.0" /> | ||
<PackageReference Include="System.Security.Cryptography.Csp" Version="4.3.0" /> | ||
</ItemGroup> | ||
|
||
</Project> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
namespace JWT.Serializers | ||
{ | ||
internal static class JsonSerializerFactory | ||
{ | ||
public static IJsonSerializer CreateSerializer() | ||
{ | ||
#if SYSTEM_TEXT_JSON | ||
return new SystemTextSerializer(); | ||
#elif NEWTONSOFT_JSON | ||
return new JsonNetSerializer(); | ||
#else | ||
throw new System.NotSupportedException(); | ||
#endif | ||
} | ||
} | ||
} |
Oops, something went wrong.