File tree Expand file tree Collapse file tree 1 file changed +5
-3
lines changed
src/SignalR/server/SignalR/test Expand file tree Collapse file tree 1 file changed +5
-3
lines changed Original file line number Diff line number Diff line change 11// Copyright (c) .NET Foundation. All rights reserved.
22// Licensed under the Apache License, Version 2.0. See License.txt in the project root for license information.
33
4- using System . Security . Claims ;
54using Microsoft . AspNetCore . Authentication . Cookies ;
65using Microsoft . AspNetCore . Builder ;
7- using Microsoft . AspNetCore . Hosting ;
8- using Microsoft . AspNetCore . Routing ;
96using Microsoft . Extensions . DependencyInjection ;
107
118namespace Microsoft . AspNetCore . SignalR . Tests
@@ -25,11 +22,16 @@ public void ConfigureServices(IServiceCollection services)
2522 options . DefaultAuthenticateScheme = CookieAuthenticationDefaults . AuthenticationScheme ;
2623 options . DefaultChallengeScheme = CookieAuthenticationDefaults . AuthenticationScheme ;
2724 } ) . AddCookie ( ) ;
25+
26+ services . AddAuthorizationPolicyEvaluator ( ) ;
2827 }
2928
3029 public void Configure ( IApplicationBuilder app )
3130 {
3231 app . UseRouting ( ) ;
32+ app . UseAuthentication ( ) ;
33+ app . UseAuthorization ( ) ;
34+
3335 app . UseEndpoints ( endpoints =>
3436 {
3537 endpoints . MapHub < UncreatableHub > ( "/uncreatable" ) ;
You can’t perform that action at this time.
0 commit comments