File tree 1 file changed +3
-2
lines changed
src/Servers/Kestrel/samples/SampleApp
1 file changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -116,9 +116,10 @@ public static Task Main(string[] args)
116
116
listenOptions . UseHttps ( ( stream , clientHelloInfo , state , cancellationToken ) =>
117
117
{
118
118
// Here you would check the name, select an appropriate cert, and provide a fallback or fail for null names.
119
- if ( clientHelloInfo . ServerName != null && clientHelloInfo . ServerName != "localhost" )
119
+ var serverName = clientHelloInfo . ServerName ;
120
+ if ( serverName != null && serverName != "localhost" )
120
121
{
121
- throw new AuthenticationException ( $ "The endpoint is not configured for sever name '{ clientHelloInfo . ServerName } '.") ;
122
+ throw new AuthenticationException ( $ "The endpoint is not configured for server name '{ clientHelloInfo . ServerName } '.") ;
122
123
}
123
124
124
125
return new ValueTask < SslServerAuthenticationOptions > ( new SslServerAuthenticationOptions
You can’t perform that action at this time.
0 commit comments