diff --git a/src/Microsoft.Net.Http.Server/AuthenticationManager.cs b/src/Microsoft.Net.Http.Server/AuthenticationManager.cs index 26670dfa48..9be0a01897 100644 --- a/src/Microsoft.Net.Http.Server/AuthenticationManager.cs +++ b/src/Microsoft.Net.Http.Server/AuthenticationManager.cs @@ -163,9 +163,7 @@ namespace Microsoft.Net.Http.Server && requestInfo->InfoType == UnsafeNclNativeMethods.HttpApi.HTTP_REQUEST_INFO_TYPE.HttpRequestInfoTypeAuth && requestInfo->pInfo->AuthStatus == UnsafeNclNativeMethods.HttpApi.HTTP_AUTH_STATUS.HttpAuthStatusSuccess) { -#if !ASPNETCORE50 return true; -#endif } return false; } @@ -176,10 +174,8 @@ namespace Microsoft.Net.Http.Server && requestInfo->InfoType == UnsafeNclNativeMethods.HttpApi.HTTP_REQUEST_INFO_TYPE.HttpRequestInfoTypeAuth && requestInfo->pInfo->AuthStatus == UnsafeNclNativeMethods.HttpApi.HTTP_AUTH_STATUS.HttpAuthStatusSuccess) { -#if !ASPNETCORE50 return new WindowsPrincipal(new WindowsIdentity(requestInfo->pInfo->AccessToken, GetAuthTypeFromRequest(requestInfo->pInfo->AuthType).ToString())); -#endif } return new ClaimsPrincipal(new ClaimsIdentity()); // Anonymous / !IsAuthenticated } diff --git a/src/Microsoft.Net.Http.Server/project.json b/src/Microsoft.Net.Http.Server/project.json index 01dab743c5..0b54d7ca45 100644 --- a/src/Microsoft.Net.Http.Server/project.json +++ b/src/Microsoft.Net.Http.Server/project.json @@ -33,6 +33,7 @@ "System.Security.Claims": "4.0.0-beta-*", "System.Security.Cryptography.X509Certificates": "4.0.0-beta-*", "System.Security.Principal": "4.0.0-beta-*", + "System.Security.Principal.Windows": "4.0.0-beta-*", "System.Text.Encoding": "4.0.10-beta-*", "System.Text.Encoding.Extensions": "4.0.10-beta-*", "System.Threading": "4.0.0-beta-*",