diff --git a/build.ps1 b/build.ps1
index 1d0b808590..abfbce2b11 100644
--- a/build.ps1
+++ b/build.ps1
@@ -5,9 +5,8 @@ param(
[string]$root=$PSScriptRoot,
[string]$runTests="YES",
[string]$failBuildOnTest="YES",
- [string]$slnFile="wilson.sln",
- [switch]$runApiCompat,
- [switch]$generateContractAssemblies)
+ [string]$slnFile="wilson.sln"
+)
################################################# Functions ############################################################
@@ -47,21 +46,6 @@ function CreateArtifactsRoot($folder)
mkdir $folder | Out-Null
}
-function GenerateContractAssemblies($root)
-{
- # clear content of baseline files as it is not relevant for the next version
- ClearBaselineFiles($root)
-
- # execute generateContractAssemblies script
- & "$root\generateContractAssemblies.ps1".
-}
-
-function ClearBaselineFiles($root)
-{
- Write-Host ">>> Clear-Content $root\Tools\apiCompat\baseline\*.txt"
- Clear-Content $root\Tools\apiCompat\baseline\*.txt
-}
-
################################################# Functions ############################################################
if ($env:VSINSTALLDIR)
@@ -79,8 +63,6 @@ Write-Host "root: " $root;
Write-Host "runTests: " $runTests;
Write-Host "failBuildOnTest: " $failBuildOnTest;
Write-Host "slnFile: " $slnFile;
-Write-Host "runApiCompat: " $runApiCompat;
-Write-Host "generateContractAssemblies: " $generateContractAssemblies;
WriteSectionFooter("End build.ps1 - parameters");
[xml]$buildConfiguration = Get-Content $PSScriptRoot\buildConfiguration.xml
@@ -105,17 +87,17 @@ WriteSectionFooter("End Environment");
$ErrorActionPreference = "Stop"
-WriteSectionHeader("VerifyResourceUsage.pl");
+ WriteSectionHeader("VerifyResourceUsage.pl");
-Write-Host ">>> Start-Process -Wait -PassThru -NoNewWindow perl $root\src\VerifyResourceUsage.pl"
-$verifyResourceUsageResult = Start-Process -Wait -PassThru -NoNewWindow perl $root\src\VerifyResourceUsage.pl
+ Write-Host ">>> Start-Process -Wait -PassThru -NoNewWindow perl $root\src\VerifyResourceUsage.pl"
+ $verifyResourceUsageResult = Start-Process -Wait -PassThru -NoNewWindow perl $root\src\VerifyResourceUsage.pl
-if($verifyResourceUsageResult.ExitCode -ne 0)
-{
- throw "VerifyResourceUsage.pl failed."
-}
+ if($verifyResourceUsageResult.ExitCode -ne 0)
+ {
+ throw "VerifyResourceUsage.pl failed."
+ }
-WriteSectionFooter("End VerifyResourceUsage.pl");
+ WriteSectionFooter("End VerifyResourceUsage.pl");
WriteSectionHeader("Build");
@@ -138,10 +120,10 @@ CreateArtifactsRoot($artifactsRoot);
pushd
Set-Location $root
Write-Host ""
-Write-Host ">>> Start-Process -wait -NoNewWindow $msbuildexe /restore:True /p:UseSharedCompilation=false /nr:false /verbosity:m /p:Configuration=$buildType /p:RunApiCompat=$runApiCompat $slnFile"
+Write-Host ">>> Start-Process -wait -NoNewWindow $msbuildexe /restore:True /p:UseSharedCompilation=false /nr:false /verbosity:m /p:Configuration=$buildType $slnFile"
Write-Host ""
Write-Host "msbuildexe: " $msbuildexe
-$p = Start-Process -Wait -PassThru -NoNewWindow $msbuildexe "/r:True /p:UseSharedCompilation=false /nr:false /verbosity:m /p:Configuration=$buildType /p:RunApiCompat=$runApiCompat $slnFile"
+$p = Start-Process -Wait -PassThru -NoNewWindow $msbuildexe "/r:True /p:UseSharedCompilation=false /nr:false /verbosity:m /p:Configuration=$buildType $slnFile"
if($p.ExitCode -ne 0)
{
@@ -149,13 +131,6 @@ if($p.ExitCode -ne 0)
}
popd
-if ($generateContractAssemblies.IsPresent)
-{
- WriteSectionHeader("Generating Contract Assemblies");
- GenerateContractAssemblies($root);
- WriteSectionFooter("End Generating Contract Assemblies");
-}
-
foreach($project in $buildConfiguration.SelectNodes("root/projects/src/project"))
{
$name = $project.name;
diff --git a/build/CodeCoverage.runsettings b/build/CodeCoverage.runsettings
new file mode 100644
index 0000000000..68c61eff5e
--- /dev/null
+++ b/build/CodeCoverage.runsettings
@@ -0,0 +1,49 @@
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+ .*\microsoft.identitymodel.abstractions.dll
+ .*\microsoft.identitymodel.jsonwebtokens.dll
+ .*\microsoft.identitymodel.keyvaultextensions.dll
+ .*\microsoft.identitymodel.logging.dll
+ .*\microsoft.identitymodel.loggingextensions.dll
+ .*\microsoft.identitymodel.managedkeyvaultsecuritykey.dll
+ .*\microsoft.identitymodel.protocols.openidconnect.dll
+ .*\microsoft.identitymodel.protocols.signedhttprequest.dll
+ .*\microsoft.identitymodel.protocols.wsfederation.dll
+ .*\microsoft.identitymodel.protocols.dll
+ .*\microsoft.identitymodel.testextensions.dll
+ .*\microsoft.identitymodel.tokens.saml.dll
+ .*\microsoft.identitymodel.tokens.dll
+ .*\microsoft.identitymodel.validators.dll
+ .*\microsoft.identitymodel.xml.dll
+ .*\system.identitymodel.tokens.jwt.dll
+
+
+
+
+
+
+
+
+
diff --git a/build/apiCompat.props b/build/apiCompat.props
deleted file mode 100644
index e6b867f914..0000000000
--- a/build/apiCompat.props
+++ /dev/null
@@ -1,49 +0,0 @@
-
-
-
- false
- true
- false
- true
- $(SolutionDir)Tools\apiCompat\baseline\ApiCompatBaseline.$(TargetFramework).txt
- $(SolutionDir)Tools\apiCompat\ApiCompatExcludeAttributeList.txt
- true
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
-
- <_DependencyDirectoriesTemp Include="@(ReferencePath->'%(RootDir)%(Directory)')" />
- <_ContractDependencyDirectories Include="%(_DependencyDirectoriesTemp.Identity)" />
-
-
-
diff --git a/build/apiCompat.ps1 b/build/apiCompat.ps1
deleted file mode 100644
index 7aac440258..0000000000
--- a/build/apiCompat.ps1
+++ /dev/null
@@ -1,224 +0,0 @@
-param(
- [string]$feedLocation = "ADO", # or 'ADO' or 'NuGet'
- [string]$packageNames="", # comma-separated list of packages
- [string]$packageVersion="latest", # or the exact version e.g. "5.4.0-preview"
- [string]$adoFeedSource="", # required only for ADO feeds
- [string]$adoFeedName="", # required only for ADO feeds
- [string]$adoFeedUsername="VssSessionToken", # required only for ADO feeds
- [string]$adoFeedPat="", # required only for ADO feeds
- [string]$apiCompatRoot="$PSScriptRoot\tools\ApiCompat",
- [string]$nugetPackageProviderVersion="2.8.5.208",
- [string]$adoAllowPrerelease ="false" # uses the latest release (including preview releases) if packageVersion is 'latest'
-)
-
-################################################# Functions ############################################################
-
-function CreateBasicAuthHeader {
-Param(
- [string]$Username,
- [string]$PAT
-)
-
-$Auth = '{0}:{1}' -f $Username, $PAT
-$Auth = [System.Text.Encoding]::UTF8.GetBytes($Auth)
-$Auth = [System.Convert]::ToBase64String($Auth)
-$Header = @{Authorization=("Basic {0}" -f $Auth)}
-$Header
-}
-
-function CreatePsCredential {
-Param(
- [string]$Username,
- [string]$PAT
-)
-
- $password = ConvertTo-SecureString $PAT -AsPlainText -Force
- $pSCredential = New-Object System.Management.Automation.PSCredential $Username, $password
- $pSCredential
-}
-
-function CreateFolder {
-Param(
- [string]$Folder
-)
- if (Test-Path($folder))
- {
- Write-Host ">>> $folder already exists!"
- }
- else
- {
- Write-Host ">>> New-Item -ItemType directory $Folder | Out-Null"
- New-Item -ItemType directory $Folder | Out-Null
- }
-}
-
-function DownloadPackage {
-Param(
- [string]$PackageDownloadUrl,
- [string]$OutFile,
- [System.Collections.IDictionary]$Headers,
- [string]$apiCompatRoot
-)
- Write-Host ">>> Invoke-WebRequest -Uri $PackageDownloadUrl -OutFile $OutFile -Headers $Headers"
- Invoke-WebRequest -Uri $PackageDownloadUrl -OutFile $OutFile -Headers $Headers
-}
-
-function FormAdoPackageDownloadUrl {
-Param(
- [string]$FeedSource,
- [string]$FeedName,
- [string]$PackageName,
- [string]$PackageVersion
-)
-
- $scheme = ([System.Uri]$FeedSource).Scheme
- $baseUrl = ([System.Uri]$FeedSource).Host
- $packageDownloadUrl = "$scheme`://$baseUrl/_apis/packaging/feeds/$FeedName/nuget/packages/$PackageName/versions/$PackageVersion/content"
- Write-Host ">>> Formed ADO package download URL: $packageDownloadUrl"
- $packageDownloadUrl
-}
-
-function FormNugetPackageDownloadUrl {
- Param(
- [string]$PackageName,
- [string]$PackageVersion
- )
-
- if ($PackageVersion -Eq 'latest') {
- $packageDownloadUrl = "https://www.nuget.org/api/v2/package/$PackageName"
- } else {
- $packageDownloadUrl = "https://www.nuget.org/api/v2/package/$PackageName/$PackageVersion"
- }
-
- Write-Host ">>> Formed NuGet package download URL: $packageDownloadUrl"
- $packageDownloadUrl
-}
-
-function PlaceContractAssemblies([String] $apiCompatRoot) {
- Get-ChildItem "$apiCompatRoot\unzippedPackages" -Recurse -Include '*.dll' | Foreach-Object `
- {
- # resolve target framework, destination directory and destination assembly file path
- $targetFramework = Split-Path $_.Directory -leaf
- $contractAssembliesPath = "$apiCompatRoot\contractAssemblies"
- $destDir = Join-Path -Path $contractAssembliesPath -ChildPath $targetFramework
-
- CreateFolder($destDir)
-
- Write-Host ">>> Copy-Item $_ -Destination $destDir"
- Copy-Item $_ -Destination $destDir
- }
-}
-
-function RemoveFolder {
-Param(
- [string]$Folder
-)
- if (Test-Path($Folder)) {
-
- Write-Host ">>> Remove-Item -Recurse -Force $Folder -Confirm:$false"
- Remove-Item -Recurse -Force $Folder -Confirm:$false
- } else {
- Write-Host ">>> $Folder doesn't exist!"
- }
-}
-
-function UzipPackage {
-Param(
- [string]$Package,
- [string]$DestinationPath
-)
- Write-Host ">>> Expand-Archive -Path $Package -DestinationPath $DestinationPath -Force"
- Expand-Archive -Path $Package -DestinationPath $DestinationPath -Force
-}
-
-################################################# Functions ############################################################
-
-Write-Host (">>> Start ApiCompat - Prepare contract assemblies (v2) - parameters");
-Write-Host "feedLocation: " $feedLocation;
-Write-Host "adoFeedSource: " $adoFeedSource;
-Write-Host "adoFeedName: " $adoFeedName;
-Write-Host "adoFeedUsername: " $adoFeedUsername;
-Write-Host "packageNames: " $packageNames;
-Write-Host "packageVersion: " $packageVersion;
-Write-Host "apiCompatRoot: " $apiCompatRoot;
-Write-Host "nugetPackageProviderVersion: " $nugetPackageProviderVersion;
-Write-Host "adoAllowPrerelease: " $adoAllowPrerelease;
-Write-Host (">>> End ApiCompat - Prepare contract assemblies (v2) - parameters");
-
-if ($feedLocation -Eq 'ADO' -And ($adoFeedPat -Eq '' -Or $adoFeedSource -Eq '' -Or $adoFeedName -Eq '' -Or $adoFeedUsername -Eq '')) {
- throw ">>> adoFeedPat, adoFeedSource, adoFeedName, and adoFeedUsername are required when feed location is set to 'ADO'. Run the script again and set the required values."
-}
-
-if ($packageNames -Eq '') {
- throw ">>> List of packageNames is empty. Run the script again and set the packageNames."
-}
-
-$packageNamesArray = $packageNames.split(" ")
-
-if ($packageVersion -Eq 'latest') {
- $useLatestVersion = 'true'
-} else {
- $useLatestVersion = 'false'
-}
-
-# determine the latest package version from an ADO feed
-if ($packageVersion -Eq 'latest' -And $feedLocation -Eq "ADO") {
- $nugetPackageProviderResult = Get-PackageProvider -Name Nuget -ErrorAction SilentlyContinue
- if ($null -Eq $nugetPackageProviderResult -Or $nugetPackageProviderResult.Version -ne [System.Version]$nugetPackageProviderVersion) {
- Write-Host ">>> Install-PackageProvider Nuget -RequiredVersion $nugetPackageProviderVersion -Force -Scope CurrentUser | Out-Null"
- Install-PackageProvider Nuget -RequiredVersion $nugetPackageProviderVersion -Force -Scope CurrentUser | Out-Null
- } else {
- Write-Host (">>> Nuget package provider (" + $nugetPackageProviderResult.Version + ") is already installed.")
- }
-
- $credential = CreatePsCredential -Username $adoFeedUsername -PAT $adoFeedPat
-
- $getFeedResult = Get-PSRepository -Name $adoFeedName -ErrorAction SilentlyContinue
- if ($null -Eq $getFeedResult) {
- Write-Host ">>> Register-PSRepository -Name $adoFeedName -SourceLocation $adoFeedSource -InstallationPolicy Trusted -Credential $credential"
- Register-PSRepository -Name $adoFeedName -SourceLocation $adoFeedSource -InstallationPolicy Trusted -Credential $credential
- } else
- {
- Write-Host ">>> Feed $adoFeedName is already registered."
- }
-}
-
-# prepare directories
-RemoveFolder -Folder "$apiCompatRoot\contractAssemblies"
-CreateFolder -Folder "$apiCompatRoot\contractAssemblies"
-CreateFolder("$apiCompatRoot\downloadedPackages")
-
-# download and unzip packages
-foreach($packageName in $packageNamesArray) {
- $packageName = $packageName.trim()
- $outFile = "$apiCompatRoot\downloadedPackages\$packageName.zip"
- $unzippedDir = "$apiCompatRoot\unzippedPackages\$packageName"
-
- if ($useLatestVersion -Eq 'true' -And $feedLocation -Eq "ADO") {
- if ($adoAllowPrerelease -Eq 'true') {
- $packageVersion = (Find-Module -Name $packageName -Repository $adoFeedName -Credential $credential -AllowPrerelease)[0].Version
- } else {
- $packageVersion = (Find-Module -Name $packageName -Repository $adoFeedName -Credential $credential)[0].Version
- }
- }
-
- Write-Host (">>> Latest " + $packageName + " version: $packageVersion")
-
- if ($feedLocation -eq 'ADO') {
- $header = CreateBasicAuthHeader -Username $adoFeedUsername -PAT $adoFeedPat
- $downloadPackageUrl = FormAdoPackageDownloadUrl -FeedSource $adoFeedSource -FeedName $adoFeedName -PackageName $packageName -PackageVersion $PackageVersion
- DownloadPackage -packageDownloadUrl $downloadPackageUrl -header $header -outFile $outFile -apiCompatRoot $apiCompatRoot
- } else {
- $downloadPackageUrl = FormNugetPackageDownloadUrl -PackageName $packageName -PackageVersion $PackageVersion
- DownloadPackage -packageDownloadUrl $downloadPackageUrl -outFile $outFile -apiCompatRoot $apiCompatRoot
- }
-
- UzipPackage -package $outFile -destinationPath $unzippedDir
-}
-
-# place the contract assemblies and clean-up
-PlaceContractAssemblies($apiCompatRoot)
-RemoveFolder -Folder "$apiCompatRoot\downloadedPackages"
-RemoveFolder -Folder "$apiCompatRoot\unzippedPackages"
-
-Write-Host ">>> Done - ApiCompat - Prepare contract assemblies (v2)."
\ No newline at end of file
diff --git a/build/common.props b/build/common.props
index 7db1892715..5837af03d3 100644
--- a/build/common.props
+++ b/build/common.props
@@ -1,5 +1,5 @@
-
+
@@ -34,9 +34,19 @@
7.3
+
+ true
+ 6.33.0
+
+
true
+
+
+ $(NoWarn);SYSLIB0050
+ $(NoWarn);SYSLIB0051
+
diff --git a/build/commonTest.props b/build/commonTest.props
index 9d82ef294a..080204bf77 100644
--- a/build/commonTest.props
+++ b/build/commonTest.props
@@ -13,6 +13,8 @@
true
0618
true
+ false
+ 11
$(TestTargets)
$(TestOnlyCoreTargets)
$(DotNetCoreAppRuntimeVersion)
diff --git a/build/releaseBuild.yml b/build/releaseBuild.yml
index 27c213b91f..dcea38ceec 100644
--- a/build/releaseBuild.yml
+++ b/build/releaseBuild.yml
@@ -70,20 +70,6 @@ jobs:
filePath: ./updateAssemblyInfo.ps1
arguments: '-packageType $(BuildConfiguration)'
- - task: PowerShell@2
- displayName: 'Prepare contract assemblies'
- inputs:
- targetType: 'filePath'
- filePath: $(Agent.BuildDirectory)\s\build\apiCompat.ps1
- arguments: >
- -feedLocation "NuGet"
- -packageNames $(Wilson6xPackageList)
- -packageVersion: "latest"
- -adoFeedSource: $(AdoFeedSource)
- -adoFeedName: $(AdoFeedName)
- -adoAllowPrerelease: "false"
- -apiCompatRoot: $(ApiCompatRootWilson)
- -nugetPackageProviderVersion: "2.8.5.208"
- task: MSBuild@1
displayName: Build
diff --git a/build/template-sign-binary.yml b/build/template-sign-binary.yml
index cf61a57fd6..6212927159 100644
--- a/build/template-sign-binary.yml
+++ b/build/template-sign-binary.yml
@@ -35,11 +35,11 @@ steps:
"parameters": [
{
"parameterName": "OpusName",
- "parameterValue": "TestSign"
+ "parameterValue": "Microsoft"
},
{
"parameterName": "OpusInfo",
- "parameterValue": "http://test"
+ "parameterValue": "http://www.microsoft.com"
},
{
"parameterName": "PageHash",
diff --git a/build/version.props b/build/version.props
index 196745cf46..6ab18636f9 100644
--- a/build/version.props
+++ b/build/version.props
@@ -4,4 +4,14 @@
0.0.1
preview
+
+
+
+ $(VersionPrefix)
+
+
+
+ $(VersionPrefix)-$(VersionSuffix)
+
+
diff --git a/generateContractAssemblies.ps1 b/generateContractAssemblies.ps1
deleted file mode 100644
index 65f0314d8f..0000000000
--- a/generateContractAssemblies.ps1
+++ /dev/null
@@ -1,70 +0,0 @@
-# Generate Contract Assemblies, for each Target Framework, which will be used as reference assemblies during ApiCompat validation
-# Directory structure under contractAssemblies will be as following:
-# $contractAssembliesPath\{TargetFramework}\{ReferenceAssembly.dll}
-
-$implementationAssembliesRootPath = "$PSScriptRoot\src"
-$contractAssembliesPath = "$PSScriptRoot\Tools\apiCompat\contractAssemblies"
-
-Write-Host "============================ `n"
-Write-Host "implementationAssembliesRootPath: $implementationAssembliesRootPath"
-Write-Host "contractAssembliesPath: $contractAssembliesPath `n"
-
-# remove existing contract assemblies
-if (Test-Path $contractAssembliesPath)
-{
- Write-Host ">>> Remove-Item -Recurse -Force $contractAssembliesPath"
- Remove-Item -Recurse -Force $contractAssembliesPath
-}
-
-# create contractAssembliesDir
-Write-Host ">>> mkdir $contractAssembliesPath"
-mkdir $contractAssembliesPath | Out-Null
-
-# recursively iterate implAssembliesRootPath and include DLLs whose name contain 'IdentityModel'
-Get-ChildItem $implementationAssembliesRootPath -Recurse -Include '*IdentityModel*.dll' | Foreach-Object `
-{
- # get partialAssemblyName - remove text before the first dot e.g. System.IdentityModel.Tokens.Jwt -> IdentityModel.Tokens.Jwt
- # this hack is in place as there are cases when a project is producing an assembly with a name different than its name (special builds)
- $null = $_.Name -match "^*\.(?.*).dll$"
- $partialAssemblyName = $matches["partialName"]
-
- # continue if source path [string] of current item (assembly) doesn't contain partialAssemblyName
- # we don't want assemblies that don't belong to IdentityModel-extensions solution in contractAssemblies e.g. 'Microsoft.IdentityModel.Clients.ActiveDirectory.dll'
- if (!($_.Directory -match $partialAssemblyName))
- {
- # think continue;
- return
- }
-
- # resolve target framework, destination directory and destination assembly file path
- $targetFramework = Split-Path $_.Directory -leaf
- $destDir = Join-Path -Path $contractAssembliesPath -ChildPath $targetFramework
- $destAssemblyFilePath = Join-Path -Path $destDir -ChildPath $_.Name
-
- # create directory if it doesn't exist already
- if (!(Test-Path $destDir))
- {
- Write-Host ">>> New-Item -ItemType directory $destDir | Out-Null"
- New-Item -ItemType directory $destDir | Out-Null
- }
-
- # if an assembly with the same name as the current item (assembly) already exists in destination dir
- # overwrite it only if curent item's LastWriteTime is greater than LastWriteTime of an existing assembly
- if (Test-Path $destAssemblyFilePath)
- {
- $destAssemblyFile = Get-Item $destAssemblyFilePath
-
- if ($_.LastWriteTime -gt $destAssemblyFile.LastWriteTime)
- {
- Write-Host ">>> Copy-Item $_ -Destination $destDir"
- Copy-Item $_ -Destination $destDir
- }
- }
- else # copy assembly to destination dir
- {
- Write-Host ">>> Copy-Item $_ -Destination $destDir"
- Copy-Item $_ -Destination $destDir
- }
-}
-
-Write-Host "`nDone!`n"
diff --git a/src/Microsoft.IdentityModel.TestExtensions/Microsoft.IdentityModel.TestExtensions.csproj b/src/Microsoft.IdentityModel.TestExtensions/Microsoft.IdentityModel.TestExtensions.csproj
index f31717c2ec..1f3b13be6b 100644
--- a/src/Microsoft.IdentityModel.TestExtensions/Microsoft.IdentityModel.TestExtensions.csproj
+++ b/src/Microsoft.IdentityModel.TestExtensions/Microsoft.IdentityModel.TestExtensions.csproj
@@ -10,6 +10,7 @@
true
Microsoft.IdentityModel.TestExtensions
true
+ false
diff --git a/test/Microsoft.IdentityModel.JsonWebTokens.Tests/JsonWebTokenHandlerTests.cs b/test/Microsoft.IdentityModel.JsonWebTokens.Tests/JsonWebTokenHandlerTests.cs
index 961277cb3f..dc11805d3f 100644
--- a/test/Microsoft.IdentityModel.JsonWebTokens.Tests/JsonWebTokenHandlerTests.cs
+++ b/test/Microsoft.IdentityModel.JsonWebTokens.Tests/JsonWebTokenHandlerTests.cs
@@ -3427,8 +3427,14 @@ public static TheoryData JweDecompressSizeTheoryData
TokenValidationParameters validationParameters = new TokenValidationParameters { TokenDecryptionKey = key };
TheoryData theoryData = new TheoryData();
+#if NETCOREAPP2_1
+ string strU = new string('U', 20_000_000);
+ string strUU = new string('U', 15_000_000);
+#else
string strU = new string('U', 100_000_000);
string strUU = new string('U', 40_000_000);
+#endif
+
string payload = $@"{{""U"":""{strU}"", ""UU"":""{strUU}""}}";
string token = jwth.CreateToken(payload, encryptingCredentials, "DEF");
diff --git a/test/System.IdentityModel.Tokens.Jwt.Tests/JwtSecurityTokenHandlerTests.cs b/test/System.IdentityModel.Tokens.Jwt.Tests/JwtSecurityTokenHandlerTests.cs
index b0430cd37a..0ad6ebc079 100644
--- a/test/System.IdentityModel.Tokens.Jwt.Tests/JwtSecurityTokenHandlerTests.cs
+++ b/test/System.IdentityModel.Tokens.Jwt.Tests/JwtSecurityTokenHandlerTests.cs
@@ -1102,8 +1102,13 @@ public static TheoryData JweDecompressSizeTheoryData
TheoryData theoryData = new TheoryData();
+#if NETCOREAPP2_1
+ string strU = new string('U', 20_000_000);
+ string strUU = new string('U', 15_000_000);
+#else
string strU = new string('U', 100_000_000);
string strUU = new string('U', 40_000_000);
+#endif
string payload = $@"{{""U"":""{strU}"", ""UU"":""{strUU}""}}";
string token = jwth.CreateToken(payload, encryptingCredentials, "DEF");
diff --git a/updateAssemblyInfo.ps1 b/updateAssemblyInfo.ps1
index ce9655bc73..ac2aae99b7 100644
--- a/updateAssemblyInfo.ps1
+++ b/updateAssemblyInfo.ps1
@@ -43,7 +43,7 @@ Write-Host "assemblyInformationalVersion: " $assemblyInformationalVersion
$nugetSuffix = [string]$buildConfiguration.SelectSingleNode("root/nugetSuffix").InnerText
if ( $packageType -eq "release")
{
- $versionSuffix = ""
+ $versionSuffix = $nugetSuffix
}
else
{