Skip to content

Commit 368b665

Browse files
authored
Releasing 1.0.14 (#656)
* Minor fix for aspnetcore 3.0 (#652) * minor fix for aspnetcore 3.0 * retry UT. * extend ack TTL to stable UT. * Upgrade jwt and fix potential memory leak (#653) * Update version to 1.0.14 (#648) * Update version to 1.0.14
1 parent 50c0877 commit 368b665

File tree

15 files changed

+45
-21
lines changed

15 files changed

+45
-21
lines changed

build/dependencies.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
<MicrosoftAzureKeyVaultPackageVersion>2.3.2</MicrosoftAzureKeyVaultPackageVersion>
1313
<SystemBuffersPackageVersion>4.5.0</SystemBuffersPackageVersion>
1414
<SystemMemoryPackageVersion>4.5.0</SystemMemoryPackageVersion>
15-
<SystemIdentityModelTokensJwtPackageVersion>5.2.1</SystemIdentityModelTokensJwtPackageVersion>
15+
<SystemIdentityModelTokensJwtPackageVersion>5.5.0</SystemIdentityModelTokensJwtPackageVersion>
1616
<MicrosoftExtensionsDependencyInjectionPackageVersion>2.1.0</MicrosoftExtensionsDependencyInjectionPackageVersion>
1717
<MicrosoftExtensionsLoggingPackageVersion>2.1.0</MicrosoftExtensionsLoggingPackageVersion>
1818
<MicrosoftExtensionsPrimitivesPackageVersion>2.1.0</MicrosoftExtensionsPrimitivesPackageVersion>

src/Microsoft.Azure.SignalR.Common/ServiceConnections/ConnectionFactory.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,7 +76,7 @@ public Task DisposeAsync(ConnectionContext connection)
7676
{
7777
return Task.CompletedTask;
7878
}
79-
#if !NETCOREAPP3_0
79+
#if NETSTANDARD2_0
8080
return ((HttpConnection)connection).DisposeAsync();
8181
#else
8282
return ((HttpConnection)connection).DisposeAsync().AsTask();

src/Microsoft.Azure.SignalR.Common/Utilities/AuthenticationHelper.cs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -68,7 +68,10 @@ private static string GenerateJwtBearer(
6868
SigningCredentials credentials = null;
6969
if (!string.IsNullOrEmpty(signingKey))
7070
{
71+
// Refer: https://github.com/AzureAD/azure-activedirectory-identitymodel-extensions-for-dotnet/releases/tag/5.5.0
72+
// From version 5.5.0, SignatureProvider caching is turned On by default, assign KeyId to enable correct cache for same SigningKey
7173
var securityKey = new SymmetricSecurityKey(Encoding.UTF8.GetBytes(signingKey));
74+
securityKey.KeyId = signingKey;
7275
credentials = new SigningCredentials(securityKey, SecurityAlgorithms.HmacSha256);
7376
}
7477

src/Microsoft.Azure.SignalR/DependencyInjectionExtensions.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ private static ISignalRServerBuilder AddAzureSignalRCore(this ISignalRServerBuil
8181
builder.Services.TryAddSingleton(typeof(IEndpointRouter), typeof(DefaultEndpointRouter));
8282
builder.Services.TryAddSingleton(typeof(IConnectionRequestIdProvider), typeof(DefaultConnectionRequestIdProvider));
8383

84-
#if NETCOREAPP3_0
84+
#if !NETSTANDARD2_0
8585
builder.Services.TryAddSingleton<AzureSignalRHostedService>();
8686
builder.Services.TryAddEnumerable(ServiceDescriptor.Singleton<IStartupFilter, AzureSignalRStartupFilter>());
8787
builder.Services.TryAddEnumerable(ServiceDescriptor.Singleton<MatcherPolicy, NegotiateMatcherPolicy>());

src/Microsoft.Azure.SignalR/HubHost/ServiceHubConnectionContext.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ internal class ServiceHubConnectionContext : HubConnectionContext
3030
public const string ItemsUnavailableError = nameof(Items) + UnavailableErrorTemplate;
3131
public const string ProtocolUnavailableError = nameof(Protocol) + UnavailableErrorTemplate;
3232

33-
#if NETCOREAPP3_0
33+
#if !NETSTANDARD2_0
3434
public ServiceHubConnectionContext(HttpContext context)
3535
: base(new DummyConnectionContext(context),
3636
new HubConnectionContextOptions() { KeepAliveInterval = TimeSpan.MaxValue },

src/Microsoft.Azure.SignalR/HubHost/ServiceLifetimeManager.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ public ServiceLifetimeManager(IServiceConnectionManager<THub> serviceConnectionM
2828
: base(serviceConnectionManager, protocolResolver)
2929
{
3030
// after core 3.0 UseAzureSignalR() is not required.
31-
#if !NETCOREAPP3_0
31+
#if NETSTANDARD2_0
3232
if (!marker.IsConfigured)
3333
{
3434
throw new InvalidOperationException(MarkerNotConfiguredError);

src/Microsoft.Azure.SignalR/Startup/AzureSignalRHostedService.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// Copyright (c) Microsoft. All rights reserved.
22
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
33

4-
#if NETCOREAPP3_0
4+
#if !NETSTANDARD2_0
55
using System;
66
using Microsoft.AspNetCore.Connections;
77
using Microsoft.AspNetCore.Http.Connections;

src/Microsoft.Azure.SignalR/Startup/AzureSignalRHostingStartup.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// Copyright (c) Microsoft. All rights reserved.
22
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
33

4-
#if NETCOREAPP3_0
4+
#if !NETSTANDARD2_0
55
using Microsoft.AspNetCore.Hosting;
66
using Microsoft.Azure.SignalR;
77
using Microsoft.Extensions.Configuration;

src/Microsoft.Azure.SignalR/Startup/AzureSignalRStartupFilter.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// Copyright (c) Microsoft. All rights reserved.
22
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
33

4-
#if NETCOREAPP3_0
4+
#if !NETSTANDARD2_0
55
using System;
66
using Microsoft.AspNetCore.Builder;
77
using Microsoft.AspNetCore.Hosting;

src/Microsoft.Azure.SignalR/Startup/NegotiateMatcherPolicy.cs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
// Copyright (c) Microsoft. All rights reserved.
22
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
33

4-
#if NETCOREAPP3_0
4+
#if !NETSTANDARD2_0
55
using System.Collections.Concurrent;
66
using System.Collections.Generic;
77
using System.Threading.Tasks;
@@ -62,6 +62,9 @@ private Endpoint CreateNegotiateEndpoint(Endpoint endpoint)
6262
routeEndpoint.RoutePattern,
6363
routeEndpoint.Order);
6464

65+
// Set DisplayName
66+
routeEndpointBuilder.DisplayName = routeEndpoint.DisplayName;
67+
6568
// Preserve the metadata
6669
foreach (var metadata in endpoint.Metadata)
6770
{

0 commit comments

Comments
 (0)