File tree Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Expand file tree Collapse file tree 1 file changed +10
-2
lines changed Original file line number Diff line number Diff line change 12
12
using System . Security . Claims ;
13
13
using System . Threading . Tasks ;
14
14
using System . Web . Http ;
15
+ using Microsoft . Owin . Host . SystemWeb ;
15
16
using TaskWebApp . Utils ;
16
17
17
18
namespace TaskWebApp
@@ -29,7 +30,11 @@ public void ConfigureAuth(IAppBuilder app)
29
30
30
31
app . SetDefaultSignInAsAuthenticationType ( CookieAuthenticationDefaults . AuthenticationType ) ;
31
32
32
- app . UseCookieAuthentication ( new CookieAuthenticationOptions ( ) ) ;
33
+ app . UseCookieAuthentication ( new CookieAuthenticationOptions
34
+ {
35
+ // ASP.NET web host compatible cookie manager
36
+ CookieManager = new SystemWebChunkingCookieManager ( )
37
+ } ) ;
33
38
34
39
app . UseOpenIdConnectAuthentication (
35
40
new OpenIdConnectAuthenticationOptions
@@ -58,7 +63,10 @@ public void ConfigureAuth(IAppBuilder app)
58
63
} ,
59
64
60
65
// Specify the scope by appending all of the scopes requested into one string (separated by a blank space)
61
- Scope = $ "openid profile offline_access { Globals . ReadTasksScope } { Globals . WriteTasksScope } "
66
+ Scope = $ "openid profile offline_access { Globals . ReadTasksScope } { Globals . WriteTasksScope } ",
67
+
68
+ // ASP.NET web host compatible cookie manager
69
+ CookieManager = new SystemWebCookieManager ( )
62
70
}
63
71
) ;
64
72
}
You can’t perform that action at this time.
0 commit comments