From 92729af0d1a0a2cf218db51994f646f4ce4d8b40 Mon Sep 17 00:00:00 2001 From: Jakob Botsch Nielsen Date: Mon, 31 Oct 2022 14:32:50 +0100 Subject: [PATCH 1/5] Update a few dependencies Fix some component governance warnings. --- eng/Versions.props | 4 ++-- src/tasks/MonoTargetsTasks/MonoTargetsTasks.csproj | 1 - src/tasks/WasmAppBuilder/WasmAppBuilder.csproj | 5 ----- 3 files changed, 2 insertions(+), 8 deletions(-) diff --git a/eng/Versions.props b/eng/Versions.props index 1f8f149c5dfe2..f49abe8d03216 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -110,7 +110,7 @@ 4.5.5 4.5.0 6.0.1 - 4.7.1 + 6.0.0 4.7.0 4.7.0 4.7.0 @@ -155,7 +155,7 @@ 2.0.3 1.0.4-preview6.19326.1 1.0.27 - 16.10.0 + 17.3.2 $(MicrosoftBuildVersion) 6.2.1 6.2.1 diff --git a/src/tasks/MonoTargetsTasks/MonoTargetsTasks.csproj b/src/tasks/MonoTargetsTasks/MonoTargetsTasks.csproj index a37d59c75ec5a..cff933d43c4e6 100644 --- a/src/tasks/MonoTargetsTasks/MonoTargetsTasks.csproj +++ b/src/tasks/MonoTargetsTasks/MonoTargetsTasks.csproj @@ -17,7 +17,6 @@ - diff --git a/src/tasks/WasmAppBuilder/WasmAppBuilder.csproj b/src/tasks/WasmAppBuilder/WasmAppBuilder.csproj index 4deea6aa434e0..6f8529f3100c2 100644 --- a/src/tasks/WasmAppBuilder/WasmAppBuilder.csproj +++ b/src/tasks/WasmAppBuilder/WasmAppBuilder.csproj @@ -21,11 +21,6 @@ - - - - From 2cbfc4ba235ab59b80f869a106c753c4f711c0b3 Mon Sep 17 00:00:00 2001 From: Jakob Botsch Nielsen Date: Mon, 31 Oct 2022 16:57:21 +0100 Subject: [PATCH 2/5] Remove System.Reflection.MetadataLoadContext reference that was also get through Microsoft.Build --- src/tasks/WasmAppBuilder/WasmAppBuilder.csproj | 1 - 1 file changed, 1 deletion(-) diff --git a/src/tasks/WasmAppBuilder/WasmAppBuilder.csproj b/src/tasks/WasmAppBuilder/WasmAppBuilder.csproj index 6f8529f3100c2..c18167fcd2149 100644 --- a/src/tasks/WasmAppBuilder/WasmAppBuilder.csproj +++ b/src/tasks/WasmAppBuilder/WasmAppBuilder.csproj @@ -20,7 +20,6 @@ - From 9bf94422f871f07dd0194e7ff347824b82f2340d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexander=20K=C3=B6plinger?= Date: Wed, 23 Nov 2022 11:25:38 +0100 Subject: [PATCH 3/5] Update NugetPackagingVersion and NugetProjectModelVersion to 6.2.2 --- eng/Versions.props | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/eng/Versions.props b/eng/Versions.props index f49abe8d03216..5c4af05bbc4b4 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -157,8 +157,8 @@ 1.0.27 17.3.2 $(MicrosoftBuildVersion) - 6.2.1 - 6.2.1 + 6.2.2 + 6.2.2 1.1.0 17.4.0-preview-20220707-01 From c97be3f17ed9279a32c83116e62dda1d37f0f3e6 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexander=20K=C3=B6plinger?= Date: Wed, 23 Nov 2022 22:52:09 +0100 Subject: [PATCH 4/5] Bump System.Data.SqlClient to 4.8.5 (#78774) It addresses a component governance warning. (cherry picked from commit fcff85766b3e638b4accc53e37ca6e7a77f62380) --- eng/Versions.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eng/Versions.props b/eng/Versions.props index 5c4af05bbc4b4..27453ea91c36e 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -103,7 +103,7 @@ 4.5.1 6.0.0 5.0.0 - 4.8.3 + 4.8.5 4.5.0 5.0.0 5.0.0 From 21c1a6022ed32d54fdb79b784387a73421927883 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Alexander=20K=C3=B6plinger?= Date: Thu, 24 Nov 2022 00:37:01 +0100 Subject: [PATCH 5/5] Remove code for CoreFxNetCloudService classic Azure Cloud Service (#78773) It was replaced by a new endpoint (see https://github.com/dotnet/corefx/pull/41603) and the corefx-net.cloudapp.net endpoint was turned off. (cherry picked from commit da1afc8c45afa7a980e5be450cfb1c65dc80f4d7) --- .../tests/System/Net/Prerequisites/README.md | 7 - .../CoreFxNetCloudService.sln | 28 --- .../CoreFxNetCloudService.ccproj | 57 ------ .../ServiceConfiguration.Cloud.cscfg | 17 -- .../ServiceConfiguration.Local.cscfg | 17 -- .../ServiceDefinition.csdef | 26 --- .../WebServerContent/diagnostics.wadcfgx | 38 ---- .../ecf/WebServerContent/diagnostics.wadcfgx | 38 ---- .../WebServer/AuthenticationHelper.cs | 121 ----------- .../WebServer/ContentHelper.cs | 53 ----- .../WebServer/Deflate.ashx | 1 - .../WebServer/Deflate.ashx.cs | 35 ---- .../CoreFxNetCloudService/WebServer/Echo.ashx | 1 - .../WebServer/Echo.ashx.cs | 53 ----- .../WebServer/EmptyContent.ashx | 1 - .../WebServer/EmptyContent.ashx.cs | 30 --- .../CoreFxNetCloudService/WebServer/GZip.ashx | 1 - .../WebServer/GZip.ashx.cs | 35 ---- .../WebServer/NameValueCollectionConverter.cs | 76 ------- .../WebServer/Properties/AssemblyInfo.cs | 30 --- .../IIS_PublishToLocalPath_CHK.pubxml | 17 -- .../IIS_PublishToLocalPath_RET.pubxml | 17 -- .../WebServer/Redirect.ashx | 1 - .../WebServer/Redirect.ashx.cs | 88 -------- .../WebServer/RequestHelper.cs | 43 ---- .../WebServer/RequestInformation.cs | 86 -------- .../WebServer/StatusCode.ashx | 1 - .../WebServer/StatusCode.ashx.cs | 39 ---- .../CoreFxNetCloudService/WebServer/Test.ashx | 1 - .../WebServer/Test.ashx.cs | 45 ---- .../WebServer/VerifyUpload.ashx | 1 - .../WebServer/VerifyUpload.ashx.cs | 82 -------- .../WebServer/Web.Debug.config | 29 --- .../WebServer/Web.Release.config | 30 --- .../WebServer/Web.config | 60 ------ .../WebServer/WebRole.cs | 23 --- .../WebServer/WebServer.csproj | 193 ------------------ .../WebServer/WebSocket/Default.htm | 14 -- .../WebServer/WebSocket/EchoWebSocket.ashx | 1 - .../WebServer/WebSocket/EchoWebSocket.ashx.cs | 167 --------------- .../WebSocket/EchoWebSocketHeaders.ashx | 1 - .../WebSocket/EchoWebSocketHeaders.ashx.cs | 89 -------- .../WebServer/index.html | 11 - .../WebServer/packages.config | 11 - .../Prerequisites/Servers/buildAndPackage.ps1 | 32 --- 45 files changed, 1747 deletions(-) delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService.sln delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/CoreFxNetCloudService.ccproj delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ServiceConfiguration.Cloud.cscfg delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ServiceConfiguration.Local.cscfg delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ServiceDefinition.csdef delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/WebServerContent/diagnostics.wadcfgx delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ecf/WebServerContent/diagnostics.wadcfgx delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/AuthenticationHelper.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/ContentHelper.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Deflate.ashx delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Deflate.ashx.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Echo.ashx delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Echo.ashx.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/EmptyContent.ashx delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/EmptyContent.ashx.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/GZip.ashx delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/GZip.ashx.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/NameValueCollectionConverter.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Properties/AssemblyInfo.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Properties/PublishProfiles/IIS_PublishToLocalPath_CHK.pubxml delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Properties/PublishProfiles/IIS_PublishToLocalPath_RET.pubxml delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Redirect.ashx delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Redirect.ashx.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/RequestHelper.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/RequestInformation.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/StatusCode.ashx delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/StatusCode.ashx.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Test.ashx delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Test.ashx.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/VerifyUpload.ashx delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/VerifyUpload.ashx.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Web.Debug.config delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Web.Release.config delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Web.config delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebRole.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebServer.csproj delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/Default.htm delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocket.ashx delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocket.ashx.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocketHeaders.ashx delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocketHeaders.ashx.cs delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/index.html delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/packages.config delete mode 100644 src/libraries/Common/tests/System/Net/Prerequisites/Servers/buildAndPackage.ps1 diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/README.md b/src/libraries/Common/tests/System/Net/Prerequisites/README.md index b273f0c48b902..a1f766b07fe55 100644 --- a/src/libraries/Common/tests/System/Net/Prerequisites/README.md +++ b/src/libraries/Common/tests/System/Net/Prerequisites/README.md @@ -38,10 +38,3 @@ This will join all machines to a test Active Directory and enable Windows Remoti Running as the Active Directory Administrator, run .\setup.ps1 from any of the machines within the environment. The script will use WinRM to connect and update all other roles. - -## Deployment Instructions to update the Azure-based environment - -1. Create a _Classic_ Azure WebService role. -2. Create a server certificate and add it to the subscription with the name: `CoreFxNetCertificate` -3. Edit `Servers\CoreFxNetCloudService\CoreFxNetCloudService\ServiceConfiguration.Cloud.cscfg` and ensure that the `CoreFxNetCertificate` `thumbprint` and `thumbprintAlgorithm` are correct. -4. Open the solution in Visual Studio and Run the Azure Publishing wizard to create and deploy the application. diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService.sln b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService.sln deleted file mode 100644 index b905dfaeecf72..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService.sln +++ /dev/null @@ -1,28 +0,0 @@ - -Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 14 -VisualStudioVersion = 14.0.25123.0 -MinimumVisualStudioVersion = 10.0.40219.1 -Project("{CC5FD16D-436D-48AD-A40C-5A424C6E3E79}") = "CoreFxNetCloudService", "CoreFxNetCloudService\CoreFxNetCloudService.ccproj", "{57E639CE-BD4D-4CB3-A913-AE51E18CD4A0}" -EndProject -Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "WebServer", "WebServer\WebServer.csproj", "{6ACFF710-5F63-4E46-B0DA-0D1FE36EF4A7}" -EndProject -Global - GlobalSection(SolutionConfigurationPlatforms) = preSolution - Debug|Any CPU = Debug|Any CPU - Release|Any CPU = Release|Any CPU - EndGlobalSection - GlobalSection(ProjectConfigurationPlatforms) = postSolution - {57E639CE-BD4D-4CB3-A913-AE51E18CD4A0}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {57E639CE-BD4D-4CB3-A913-AE51E18CD4A0}.Debug|Any CPU.Build.0 = Debug|Any CPU - {57E639CE-BD4D-4CB3-A913-AE51E18CD4A0}.Release|Any CPU.ActiveCfg = Release|Any CPU - {57E639CE-BD4D-4CB3-A913-AE51E18CD4A0}.Release|Any CPU.Build.0 = Release|Any CPU - {6ACFF710-5F63-4E46-B0DA-0D1FE36EF4A7}.Debug|Any CPU.ActiveCfg = Debug|Any CPU - {6ACFF710-5F63-4E46-B0DA-0D1FE36EF4A7}.Debug|Any CPU.Build.0 = Debug|Any CPU - {6ACFF710-5F63-4E46-B0DA-0D1FE36EF4A7}.Release|Any CPU.ActiveCfg = Release|Any CPU - {6ACFF710-5F63-4E46-B0DA-0D1FE36EF4A7}.Release|Any CPU.Build.0 = Release|Any CPU - EndGlobalSection - GlobalSection(SolutionProperties) = preSolution - HideSolutionNode = FALSE - EndGlobalSection -EndGlobal diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/CoreFxNetCloudService.ccproj b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/CoreFxNetCloudService.ccproj deleted file mode 100644 index 17b2a50c043d3..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/CoreFxNetCloudService.ccproj +++ /dev/null @@ -1,57 +0,0 @@ - - - - Debug - AnyCPU - 2.9 - 57e639ce-bd4d-4cb3-a913-ae51e18cd4a0 - Library - Properties - CoreFxNetCloudService - CoreFxNetCloudService - True - CoreFxNetCloudService - False - - - true - full - false - bin\Debug\ - DEBUG;TRACE - - - pdbonly - true - bin\Release\ - TRACE - - - - - - - - - - WebServer - {6acff710-5f63-4e46-b0da-0d1fe36ef4a7} - True - Web - WebServer - True - - - - - - - - - - - 10.0 - $(MSBuildExtensionsPath)\Microsoft\VisualStudio\v$(VisualStudioVersion)\Windows Azure Tools\2.9\ - - - diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ServiceConfiguration.Cloud.cscfg b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ServiceConfiguration.Cloud.cscfg deleted file mode 100644 index 410b90b4dcc49..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ServiceConfiguration.Cloud.cscfg +++ /dev/null @@ -1,17 +0,0 @@ - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ServiceConfiguration.Local.cscfg b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ServiceConfiguration.Local.cscfg deleted file mode 100644 index 473d8b0ce2c98..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ServiceConfiguration.Local.cscfg +++ /dev/null @@ -1,17 +0,0 @@ - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ServiceDefinition.csdef b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ServiceDefinition.csdef deleted file mode 100644 index 66e00f2fd7803..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ServiceDefinition.csdef +++ /dev/null @@ -1,26 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/WebServerContent/diagnostics.wadcfgx b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/WebServerContent/diagnostics.wadcfgx deleted file mode 100644 index 8ca93efc6ebdd..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/WebServerContent/diagnostics.wadcfgx +++ /dev/null @@ -1,38 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - true - \ No newline at end of file diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ecf/WebServerContent/diagnostics.wadcfgx b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ecf/WebServerContent/diagnostics.wadcfgx deleted file mode 100644 index df40d84e9c3b5..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/CoreFxNetCloudService/ecf/WebServerContent/diagnostics.wadcfgx +++ /dev/null @@ -1,38 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - devstoreaccount1 - - - - - true - \ No newline at end of file diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/AuthenticationHelper.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/AuthenticationHelper.cs deleted file mode 100644 index e6ce64cbebb3f..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/AuthenticationHelper.cs +++ /dev/null @@ -1,121 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.Collections.Generic; -using System.Linq; -using System.Text; -using System.Web; - -namespace WebServer -{ - public static class AuthenticationHelper - { - public static bool HandleAuthentication(HttpContext context) - { - string authType = context.Request.QueryString["auth"]; - string user = context.Request.QueryString["user"]; - string password = context.Request.QueryString["password"]; - string domain = context.Request.QueryString["domain"]; - - if (string.Equals("basic", authType, StringComparison.OrdinalIgnoreCase)) - { - if (!HandleBasicAuthentication(context, user, password, domain)) - { - context.Response.End(); - return false; - } - } - else if (string.Equals("Negotiate", authType, StringComparison.OrdinalIgnoreCase) || - string.Equals("NTLM", authType, StringComparison.OrdinalIgnoreCase)) - { - if (!HandleChallengeResponseAuthentication(context, authType, user, password, domain)) - { - context.Response.End(); - return false; - } - } - else if (authType != null) - { - context.Response.StatusCode = 501; - context.Response.StatusDescription = "Unsupported auth type: " + authType; - context.Response.End(); - return false; - } - - return true; - } - - private static bool HandleBasicAuthentication(HttpContext context, string user, string password, string domain) - { - const string WwwAuthenticateHeaderValue = "Basic realm=\"corefx-networking\""; - - string authHeader = context.Request.Headers["Authorization"]; - if (authHeader == null) - { - context.Response.StatusCode = 401; - context.Response.Headers.Add("WWW-Authenticate", WwwAuthenticateHeaderValue); - return false; - } - - string[] split = authHeader.Split(new char[] { ' ' }); - if (split.Length < 2) - { - context.Response.StatusCode = 500; - context.Response.StatusDescription = "Invalid Authorization header: " + authHeader; - return false; - } - - if (!string.Equals("basic", split[0], StringComparison.OrdinalIgnoreCase)) - { - context.Response.StatusCode = 500; - context.Response.StatusDescription = "Unsupported auth type: " + split[0]; - return false; - } - - // Decode base64 username:password. - byte[] bytes = Convert.FromBase64String(split[1]); - string credential = Encoding.ASCII.GetString(bytes); - string[] pair = credential.Split(new char[] { ':' }); - - // Prefix "domain\" to username if domain is specified. - if (domain != null) - { - user = domain + "\\" + user; - } - - if (pair.Length != 2 || pair[0] != user || pair[1] != password) - { - context.Response.StatusCode = 401; - context.Response.Headers.Add("WWW-Authenticate", WwwAuthenticateHeaderValue); - return false; - } - - // Success. - return true; - } - private static bool HandleChallengeResponseAuthentication( - HttpContext context, - string authType, - string user, - string password, - string domain) - { - string authHeader = context.Request.Headers["Authorization"]; - if (authHeader == null) - { - context.Response.StatusCode = 401; - context.Response.Headers.Add("WWW-Authenticate", authType); - return false; - } - - // We don't fully support this authentication method. - context.Response.StatusCode = 501; - context.Response.StatusDescription = string.Format( - "Attempt to use unsupported challenge/response auth type. {0}: {1}", - authType, - authHeader); - return false; - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/ContentHelper.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/ContentHelper.cs deleted file mode 100644 index ba64f862628f3..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/ContentHelper.cs +++ /dev/null @@ -1,53 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.IO; -using System.IO.Compression; -using System.Security.Cryptography; -using System.Text; - -namespace WebServer -{ - public static class ContentHelper - { - public static byte[] GetDeflateBytes(string data) - { - byte[] bytes = Encoding.UTF8.GetBytes(data); - var compressedStream = new MemoryStream(); - - using (var compressor = new DeflateStream(compressedStream, CompressionMode.Compress, true)) - { - compressor.Write(bytes, 0, bytes.Length); - } - - return compressedStream.ToArray(); - } - - public static byte[] GetGZipBytes(string data) - { - byte[] bytes = Encoding.UTF8.GetBytes(data); - var compressedStream = new MemoryStream(); - - using (var compressor = new GZipStream(compressedStream, CompressionMode.Compress, true)) - { - compressor.Write(bytes, 0, bytes.Length); - } - - return compressedStream.ToArray(); - } - - public static byte[] ComputeMD5Hash(string data) - { - return ComputeMD5Hash(Encoding.UTF8.GetBytes(data)); - } - - public static byte[] ComputeMD5Hash(byte[] data) - { - using (MD5 md5 = MD5.Create()) - { - return md5.ComputeHash(data); - } - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Deflate.ashx b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Deflate.ashx deleted file mode 100644 index 2a039a03b134d..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Deflate.ashx +++ /dev/null @@ -1 +0,0 @@ -<%@ WebHandler Language="C#" CodeBehind="Deflate.ashx.cs" Class="WebServer.Deflate" %> diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Deflate.ashx.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Deflate.ashx.cs deleted file mode 100644 index ec90095d7bfe6..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Deflate.ashx.cs +++ /dev/null @@ -1,35 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.Web; - -namespace WebServer -{ - /// - /// Summary description for Deflate - /// - public class Deflate : IHttpHandler - { - public void ProcessRequest(HttpContext context) - { - string responseBody = "Sending DEFLATE compressed"; - - context.Response.Headers.Add("Content-MD5", Convert.ToBase64String(ContentHelper.ComputeMD5Hash(responseBody))); - context.Response.Headers.Add("Content-Encoding", "deflate"); - - context.Response.ContentType = "text/plain"; - - byte[] bytes = ContentHelper.GetDeflateBytes(responseBody); - context.Response.BinaryWrite(bytes); - } - - public bool IsReusable - { - get - { - return true; - } - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Echo.ashx b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Echo.ashx deleted file mode 100644 index 05b60371b0c1c..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Echo.ashx +++ /dev/null @@ -1 +0,0 @@ -<%@ WebHandler Language="C#" CodeBehind="Echo.ashx.cs" Class="WebServer.Echo" %> diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Echo.ashx.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Echo.ashx.cs deleted file mode 100644 index 406193a506f5c..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Echo.ashx.cs +++ /dev/null @@ -1,53 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.Security.Cryptography; -using System.Text; -using System.Web; - -namespace WebServer -{ - public class Echo : IHttpHandler - { - public void ProcessRequest(HttpContext context) - { - RequestHelper.AddResponseCookies(context); - - if (!AuthenticationHelper.HandleAuthentication(context)) - { - context.Response.End(); - return; - } - - // Add original request method verb as a custom response header. - context.Response.Headers.Add("X-HttpRequest-Method", context.Request.HttpMethod); - - // Echo back JSON encoded payload. - RequestInformation info = RequestInformation.Create(context.Request); - string echoJson = info.SerializeToJson(); - - // Compute MD5 hash to clients can verify the received data. - using (MD5 md5 = MD5.Create()) - { - byte[] bytes = Encoding.UTF8.GetBytes(echoJson); - byte[] hash = md5.ComputeHash(bytes); - string encodedHash = Convert.ToBase64String(hash); - - context.Response.Headers.Add("Content-MD5", encodedHash); - context.Response.ContentType = "application/json"; - context.Response.Write(echoJson); - } - - context.Response.End(); - } - - public bool IsReusable - { - get - { - return true; - } - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/EmptyContent.ashx b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/EmptyContent.ashx deleted file mode 100644 index a647c9a5da6b3..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/EmptyContent.ashx +++ /dev/null @@ -1 +0,0 @@ -<%@ WebHandler Language="C#" CodeBehind="EmptyContent.ashx.cs" Class="WebServer.EmptyContent" %> diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/EmptyContent.ashx.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/EmptyContent.ashx.cs deleted file mode 100644 index 66c09205cd574..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/EmptyContent.ashx.cs +++ /dev/null @@ -1,30 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.Collections.Generic; -using System.Linq; -using System.Web; - -namespace WebServer -{ - /// - /// Summary description for EmptyContent - /// - public class EmptyContent : IHttpHandler - { - public void ProcessRequest(HttpContext context) - { - // By default, this empty method sends back a 200 status code with 'Content-Length: 0' response header. - // There are no other entity-body related (i.e. 'Content-Type') headers returned. - } - - public bool IsReusable - { - get - { - return true; - } - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/GZip.ashx b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/GZip.ashx deleted file mode 100644 index b6ee5e1f5d8fc..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/GZip.ashx +++ /dev/null @@ -1 +0,0 @@ -<%@ WebHandler Language="C#" CodeBehind="GZip.ashx.cs" Class="WebServer.GZip" %> diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/GZip.ashx.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/GZip.ashx.cs deleted file mode 100644 index 64b334b32655b..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/GZip.ashx.cs +++ /dev/null @@ -1,35 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.Web; - -namespace WebServer -{ - /// - /// Summary description for Gzip - /// - public class GZip : IHttpHandler - { - public void ProcessRequest(HttpContext context) - { - string responseBody = "Sending GZIP compressed"; - - context.Response.Headers.Add("Content-MD5", Convert.ToBase64String(ContentHelper.ComputeMD5Hash(responseBody))); - context.Response.Headers.Add("Content-Encoding", "gzip"); - - context.Response.ContentType = "text/plain"; - - byte[] bytes = ContentHelper.GetGZipBytes(responseBody); - context.Response.BinaryWrite(bytes); - } - - public bool IsReusable - { - get - { - return false; - } - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/NameValueCollectionConverter.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/NameValueCollectionConverter.cs deleted file mode 100644 index d0d78a366bdd2..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/NameValueCollectionConverter.cs +++ /dev/null @@ -1,76 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.Collections.Specialized; - -using Newtonsoft.Json; - -namespace WebServer -{ - public class NameValueCollectionConverter : JsonConverter - { - public override void WriteJson(JsonWriter writer, object value, JsonSerializer serializer) - { - var collection = value as NameValueCollection; - if (collection == null) - { - return; - } - - writer.Formatting = Formatting.Indented; - writer.WriteStartObject(); - foreach (var key in collection.AllKeys) - { - writer.WritePropertyName(key); - writer.WriteValue(collection.Get(key)); - } - writer.WriteEndObject(); - } - - public override object ReadJson(JsonReader reader, Type objectType, object existingValue, JsonSerializer serializer) - { - var nameValueCollection = new NameValueCollection(); - var key = ""; - while (reader.Read()) - { - if (reader.TokenType == JsonToken.StartObject) - { - nameValueCollection = new NameValueCollection(); - } - if (reader.TokenType == JsonToken.EndObject) - { - return nameValueCollection; - } - if (reader.TokenType == JsonToken.PropertyName) - { - key = reader.Value.ToString(); - } - if (reader.TokenType == JsonToken.String) - nameValueCollection.Add(key, reader.Value.ToString()); - } - return nameValueCollection; - } - - public override bool CanConvert(Type objectType) - { - return IsTypeDerivedFromType(objectType, typeof(NameValueCollection)); - } - - private bool IsTypeDerivedFromType(Type childType, Type parentType) - { - Type testType = childType; - while (testType != null) - { - if (testType == parentType) - { - return true; - } - - testType = testType.BaseType; - } - - return false; - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Properties/AssemblyInfo.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Properties/AssemblyInfo.cs deleted file mode 100644 index a32dd585a9ff6..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Properties/AssemblyInfo.cs +++ /dev/null @@ -1,30 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System.Reflection; -using System.Runtime.CompilerServices; -using System.Runtime.InteropServices; - -// General Information about an assembly is controlled through the following -// set of attributes. Change these attribute values to modify the information -// associated with an assembly. -[assembly: AssemblyTitle("WebServer")] -[assembly: AssemblyDescription("")] -[assembly: AssemblyConfiguration("")] -[assembly: AssemblyCompany("")] -[assembly: AssemblyProduct("WebServer")] -[assembly: AssemblyCopyright("Copyright \u00A9 2016")] -[assembly: AssemblyTrademark("")] -[assembly: AssemblyCulture("")] - -// Version information for an assembly consists of the following four values: -// -// Major Version -// Minor Version -// Build Number -// Revision -// -// You can specify all the values or you can default the Revision and Build Numbers -// by using the '*' as shown below: -[assembly: AssemblyVersion("1.0.0.0")] -[assembly: AssemblyFileVersion("1.0.0.0")] diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Properties/PublishProfiles/IIS_PublishToLocalPath_CHK.pubxml b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Properties/PublishProfiles/IIS_PublishToLocalPath_CHK.pubxml deleted file mode 100644 index 885092287ea9a..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Properties/PublishProfiles/IIS_PublishToLocalPath_CHK.pubxml +++ /dev/null @@ -1,17 +0,0 @@ - - - - - FileSystem - Debug - Any CPU - - True - False - .\PublishToIIS - False - - \ No newline at end of file diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Properties/PublishProfiles/IIS_PublishToLocalPath_RET.pubxml b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Properties/PublishProfiles/IIS_PublishToLocalPath_RET.pubxml deleted file mode 100644 index 15494e57a62e8..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Properties/PublishProfiles/IIS_PublishToLocalPath_RET.pubxml +++ /dev/null @@ -1,17 +0,0 @@ - - - - - FileSystem - Release - Any CPU - - True - False - .\PublishToIIS - False - - \ No newline at end of file diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Redirect.ashx b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Redirect.ashx deleted file mode 100644 index 819e88ec0d60b..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Redirect.ashx +++ /dev/null @@ -1 +0,0 @@ -<%@ WebHandler Language="C#" CodeBehind="Redirect.ashx.cs" Class="WebServer.Redirect" %> diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Redirect.ashx.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Redirect.ashx.cs deleted file mode 100644 index 4c6ca5c342d1a..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Redirect.ashx.cs +++ /dev/null @@ -1,88 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.Web; - -namespace WebServer -{ - /// - /// Summary description for Redirect - /// - public class Redirect : IHttpHandler - { - public void ProcessRequest(HttpContext context) - { - int statusCode = 302; - string statusCodeString = context.Request.QueryString["statuscode"]; - if (!string.IsNullOrEmpty(statusCodeString)) - { - try - { - statusCode = int.Parse(statusCodeString); - if (statusCode < 300 || statusCode > 307) - { - context.Response.StatusCode = 500; - context.Response.StatusDescription = "Invalid redirect statuscode: " + statusCodeString; - return; - } - } - catch (Exception) - { - context.Response.StatusCode = 500; - context.Response.StatusDescription = "Error parsing statuscode: " + statusCodeString; - return; - } - } - - string redirectUri = context.Request.QueryString["uri"]; - if (string.IsNullOrEmpty(redirectUri)) - { - context.Response.StatusCode = 500; - context.Response.StatusDescription = "Missing redirection uri"; - return; - } - - string hopsString = context.Request.QueryString["hops"]; - int hops = 1; - if (!string.IsNullOrEmpty(hopsString)) - { - try - { - hops = int.Parse(hopsString); - } - catch (Exception) - { - context.Response.StatusCode = 500; - context.Response.StatusDescription = "Error parsing hops: " + hopsString; - return; - } - } - - RequestHelper.AddResponseCookies(context); - - if (hops <= 1) - { - context.Response.Headers.Add("Location", redirectUri); - } - else - { - context.Response.Headers.Add( - "Location", - string.Format("/Redirect.ashx?uri={0}&hops={1}", - redirectUri, - hops - 1)); - } - - context.Response.StatusCode = statusCode; - } - - public bool IsReusable - { - get - { - return true; - } - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/RequestHelper.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/RequestHelper.cs deleted file mode 100644 index 39d5d3cf967ec..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/RequestHelper.cs +++ /dev/null @@ -1,43 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.Net; -using System.Web; - -namespace WebServer -{ - public static class RequestHelper - { - public static void AddResponseCookies(HttpContext context) - { - // Turn all 'X-SetCookie' request headers into 'Set-Cookie' response headers. - string headerName; - string headerValue; - for (int i = 0; i < context.Request.Headers.Count; i++) - { - headerName = context.Request.Headers.Keys[i]; - headerValue = context.Request.Headers[i]; - - if (string.Equals(headerName, "X-SetCookie", StringComparison.OrdinalIgnoreCase)) - { - context.Response.Headers.Add("Set-Cookie", headerValue); - } - } - } - - public static CookieCollection GetRequestCookies(HttpRequest request) - { - var cookieCollection = new CookieCollection(); - HttpCookieCollection cookies = request.Cookies; - - for (int i = 0; i < cookies.Count; i++) - { - var cookie = new Cookie(cookies[i].Name, cookies[i].Value); - cookieCollection.Add(cookie); - } - - return cookieCollection; - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/RequestInformation.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/RequestInformation.cs deleted file mode 100644 index 795f1a18e3527..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/RequestInformation.cs +++ /dev/null @@ -1,86 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.Collections.Specialized; -using System.IO; -using System.Net; -using System.Web; - -using Newtonsoft.Json; - -namespace WebServer -{ - public class RequestInformation - { - public string Method { get; private set; } - - public string Url { get; private set; } - - public NameValueCollection Headers { get; private set; } - - public NameValueCollection Cookies { get; private set; } - - public string BodyContent { get; private set; } - - public int BodyLength { get; private set; } - - public bool SecureConnection { get; private set; } - - public bool ClientCertificatePresent { get; private set; } - - public HttpClientCertificate ClientCertificate { get; private set; } - - public static RequestInformation Create(HttpRequest request) - { - var info = new RequestInformation(); - info.Method = request.HttpMethod; - info.Url = request.RawUrl; - info.Headers = request.Headers; - - var cookies = new NameValueCollection(); - CookieCollection cookieCollection = RequestHelper.GetRequestCookies(request); - foreach (Cookie cookie in cookieCollection) - { - cookies.Add(cookie.Name, cookie.Value); - } - info.Cookies = cookies; - - Stream stream = request.GetBufferedInputStream(); - using (var reader = new StreamReader(stream)) - { - string body = reader.ReadToEnd(); - info.BodyContent = body; - info.BodyLength = body.Length; - } - - info.SecureConnection = request.IsSecureConnection; - - var cs = request.ClientCertificate; - info.ClientCertificatePresent = cs.IsPresent; - if (cs.IsPresent) - { - info.ClientCertificate = request.ClientCertificate; - } - - return info; - } - - public static RequestInformation DeSerializeFromJson(string json) - { - return (RequestInformation)JsonConvert.DeserializeObject( - json, - typeof(RequestInformation), - new NameValueCollectionConverter()); - } - - public string SerializeToJson() - { - return JsonConvert.SerializeObject(this, new NameValueCollectionConverter()); - } - - private RequestInformation() - { - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/StatusCode.ashx b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/StatusCode.ashx deleted file mode 100644 index ea27244f48d5f..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/StatusCode.ashx +++ /dev/null @@ -1 +0,0 @@ -<%@ WebHandler Language="C#" CodeBehind="StatusCode.ashx.cs" Class="WebServer.StatusCode" %> diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/StatusCode.ashx.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/StatusCode.ashx.cs deleted file mode 100644 index 02e3165759bfb..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/StatusCode.ashx.cs +++ /dev/null @@ -1,39 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.Web; - -namespace WebServer -{ - public class StatusCode : IHttpHandler - { - public void ProcessRequest(HttpContext context) - { - string statusCodeString = context.Request.QueryString["statuscode"]; - string statusDescription = context.Request.QueryString["statusdescription"]; - try - { - int statusCode = int.Parse(statusCodeString); - context.Response.StatusCode = statusCode; - if (statusDescription != null) - { - context.Response.StatusDescription = statusDescription; - } - } - catch (Exception) - { - context.Response.StatusCode = 500; - context.Response.StatusDescription = "Error parsing statuscode: " + statusCodeString; - } - } - - public bool IsReusable - { - get - { - return true; - } - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Test.ashx b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Test.ashx deleted file mode 100644 index 07bfc94e625d6..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Test.ashx +++ /dev/null @@ -1 +0,0 @@ -<%@ WebHandler Language="C#" CodeBehind="Test.ashx.cs" Class="WebServer.Test" %> diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Test.ashx.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Test.ashx.cs deleted file mode 100644 index ad698047e5d92..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Test.ashx.cs +++ /dev/null @@ -1,45 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.Collections.Generic; -using System.Collections.Specialized; -using System.Net; -using System.Net.Http; -using System.Security.Cryptography; -using System.Text; -using System.Web; - -using Newtonsoft.Json; - -namespace WebServer -{ - public class Test : IHttpHandler - { - public void ProcessRequest(HttpContext context) - { - RequestInformation info = RequestInformation.Create(context.Request); - - string echoJson = info.SerializeToJson(); - - // Compute MD5 hash to clients can verify the received data. - MD5 md5 = MD5.Create(); - byte[] bytes = Encoding.ASCII.GetBytes(echoJson); - var hash = md5.ComputeHash(bytes); - string encodedHash = Convert.ToBase64String(hash); - context.Response.Headers.Add("Content-MD5", encodedHash); - - RequestInformation newEcho = RequestInformation.DeSerializeFromJson(echoJson); - context.Response.ContentType = "text/plain"; //"application/json"; - context.Response.Write(echoJson); - } - - public bool IsReusable - { - get - { - return false; - } - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/VerifyUpload.ashx b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/VerifyUpload.ashx deleted file mode 100644 index c50104d4f49e2..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/VerifyUpload.ashx +++ /dev/null @@ -1 +0,0 @@ -<%@ WebHandler Language="C#" CodeBehind="VerifyUpload.ashx.cs" Class="WebServer.VerifyUpload" %> diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/VerifyUpload.ashx.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/VerifyUpload.ashx.cs deleted file mode 100644 index 67fd31989d836..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/VerifyUpload.ashx.cs +++ /dev/null @@ -1,82 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.IO; -using System.Security.Cryptography; -using System.Web; - -namespace WebServer -{ - public class VerifyUpload : IHttpHandler - { - public void ProcessRequest(HttpContext context) - { - // Report back original request method verb. - context.Response.Headers.Add("X-HttpRequest-Method", context.Request.HttpMethod); - - // Report back original entity-body related request headers. - string contentLength = context.Request.Headers["Content-Length"]; - if (!string.IsNullOrEmpty(contentLength)) - { - context.Response.Headers.Add("X-HttpRequest-Headers-ContentLength", contentLength); - } - - string transferEncoding = context.Request.Headers["Transfer-Encoding"]; - if (!string.IsNullOrEmpty(transferEncoding)) - { - context.Response.Headers.Add("X-HttpRequest-Headers-TransferEncoding", transferEncoding); - } - - // Get expected MD5 hash of request body. - string expectedHash = context.Request.Headers["Content-MD5"]; - if (string.IsNullOrEmpty(expectedHash)) - { - context.Response.StatusCode = 500; - context.Response.StatusDescription = "Missing 'Content-MD5' request header"; - return; - } - - // Compute MD5 hash of received request body. - string actualHash; - using (MD5 md5 = MD5.Create()) - { - byte[] hash = md5.ComputeHash(ReadAllRequestBytes(context)); - actualHash = Convert.ToBase64String(hash); - } - - if (expectedHash == actualHash) - { - context.Response.StatusCode = 200; - } - else - { - context.Response.StatusCode = 500; - context.Response.StatusDescription = "Request body not verfied"; - } - } - - public bool IsReusable - { - get - { - return true; - } - } - - private static byte[] ReadAllRequestBytes(HttpContext context) - { - Stream requestStream = context.Request.GetBufferedInputStream(); - byte[] buffer = new byte[16 * 1024]; - using (MemoryStream ms = new MemoryStream()) - { - int read; - while ((read = requestStream.Read(buffer, 0, buffer.Length)) > 0) - { - ms.Write(buffer, 0, read); - } - return ms.ToArray(); - } - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Web.Debug.config b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Web.Debug.config deleted file mode 100644 index 392bd6ae1652b..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Web.Debug.config +++ /dev/null @@ -1,29 +0,0 @@ - - - - - - - - - \ No newline at end of file diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Web.Release.config b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Web.Release.config deleted file mode 100644 index eac2ffb30d72b..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Web.Release.config +++ /dev/null @@ -1,30 +0,0 @@ - - - - - - - - - - \ No newline at end of file diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Web.config b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Web.config deleted file mode 100644 index 1474319672d81..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/Web.config +++ /dev/null @@ -1,60 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebRole.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebRole.cs deleted file mode 100644 index faf1a3d4e147c..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebRole.cs +++ /dev/null @@ -1,23 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.Collections.Generic; -using System.Linq; -using Microsoft.WindowsAzure; -using Microsoft.WindowsAzure.Diagnostics; -using Microsoft.WindowsAzure.ServiceRuntime; - -namespace WebServer -{ - public class WebRole : RoleEntryPoint - { - public override bool OnStart() - { - // For information on handling configuration changes - // see the MSDN topic at https://go.microsoft.com/fwlink/?LinkId=166357. - - return base.OnStart(); - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebServer.csproj b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebServer.csproj deleted file mode 100644 index 65dc1c23c46ba..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebServer.csproj +++ /dev/null @@ -1,193 +0,0 @@ - - - - - - Debug - AnyCPU - - - 2.0 - {349c5851-65df-11da-9384-00065b846f21};{fae04ec0-301f-11d3-bf4b-00c04f79efbc} - Library - Properties - WebServer - WebServer - v4.5.1 - true - - - - - - - - bin\ - - - - - ..\packages\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.1.0.0\lib\net45\Microsoft.CodeDom.Providers.DotNetCompilerPlatform.dll - True - - - - ..\packages\Microsoft.Data.Edm.5.8.4\lib\net40\Microsoft.Data.Edm.dll - True - - - ..\packages\Microsoft.Data.OData.5.8.4\lib\net40\Microsoft.Data.OData.dll - True - - - ..\packages\Microsoft.Data.Services.Client.5.8.4\lib\net40\Microsoft.Data.Services.Client.dll - True - - - ..\packages\Microsoft.WindowsAzure.ConfigurationManager.2.0.3\lib\net40\Microsoft.WindowsAzure.Configuration.dll - True - - - True - - - False - - - ..\packages\WindowsAzure.Storage.4.3.0\lib\net40\Microsoft.WindowsAzure.Storage.dll - True - - - ..\packages\Newtonsoft.Json.5.0.8\lib\net45\Newtonsoft.Json.dll - True - - - - - - - - - - - ..\packages\System.Spatial.5.8.4\lib\net40\System.Spatial.dll - True - - - - - - - - - - - - - - - - - - - - - - - - - - Web.config - - - Web.config - - - - - - - Designer - - - - - - - Deflate.ashx - - - Echo.ashx - - - EmptyContent.ashx - - - GZip.ashx - - - - - Redirect.ashx - - - - - StatusCode.ashx - - - Test.ashx - - - VerifyUpload.ashx - - - - EchoWebSocket.ashx - - - EchoWebSocketHeaders.ashx - - - - 10.0 - $(MSBuildExtensionsPath32)\Microsoft\VisualStudio\v$(VisualStudioVersion) - - - - - - - - - True - True - 42127 - / - http://localhost:42127/ - False - False - - - False - - - - - - - This project references NuGet package(s) that are missing on this computer. Use NuGet Package Restore to download them. For more information, see http://go.microsoft.com/fwlink/?LinkID=322105. The missing file is {0}. - - - - - - - - diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/Default.htm b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/Default.htm deleted file mode 100644 index 105c4b5fee7d7..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/Default.htm +++ /dev/null @@ -1,14 +0,0 @@ - - - - - -

Redirecting to the websocket.org test client in 5 seconds...

- -

Use the following URIs to test the local endpoint:

-
-    ws://testserver.contoso.com/WebSocket/EchoWebSocket.ashx
-    wss://testserver.contoso.com/WebSocket/EchoWebSocket.ashx
-    
- - diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocket.ashx b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocket.ashx deleted file mode 100644 index 411704bca698a..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocket.ashx +++ /dev/null @@ -1 +0,0 @@ -<%@ WebHandler Language="C#" CodeBehind="EchoWebSocket.ashx.cs" Class="WebServer.EchoWebSocket" %> diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocket.ashx.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocket.ashx.cs deleted file mode 100644 index 95ea6119f16a2..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocket.ashx.cs +++ /dev/null @@ -1,167 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.Net.WebSockets; -using System.Web; -using System.Web.WebSockets; -using System.Text; -using System.Threading; -using System.Threading.Tasks; - -namespace WebServer -{ - public class EchoWebSocket : IHttpHandler - { - private const int MaxBufferSize = 128 * 1024; - private bool _replyWithPartialMessages = false; - - public void ProcessRequest(HttpContext context) - { - _replyWithPartialMessages = context.Request.Url.Query.Contains("replyWithPartialMessages"); - - string subProtocol = context.Request.QueryString["subprotocol"]; - - if (context.Request.Url.Query.Contains("delay10sec")) - { - Thread.Sleep(10000); - } - - try - { - if (!context.IsWebSocketRequest) - { - context.Response.StatusCode = 200; - context.Response.ContentType = "text/plain"; - context.Response.Write("Not a websocket request"); - - return; - } - - if (!string.IsNullOrEmpty(subProtocol)) - { - var wsOptions = new AspNetWebSocketOptions(); - wsOptions.SubProtocol = subProtocol; - - context.AcceptWebSocketRequest(ProcessWebSocketRequest, wsOptions); - } - else - { - context.AcceptWebSocketRequest(ProcessWebSocketRequest); - } - } - catch (Exception ex) - { - context.Response.StatusCode = 500; - context.Response.StatusDescription = ex.Message; - } - } - - public bool IsReusable - { - get - { - return false; - } - } - - private async Task ProcessWebSocketRequest(WebSocketContext wsContext) - { - WebSocket socket = wsContext.WebSocket; - var receiveBuffer = new byte[MaxBufferSize]; - var throwAwayBuffer = new byte[MaxBufferSize]; - - // Stay in loop while websocket is open - while (socket.State == WebSocketState.Open || socket.State == WebSocketState.CloseSent) - { - var receiveResult = await socket.ReceiveAsync(new ArraySegment(receiveBuffer), CancellationToken.None); - if (receiveResult.MessageType == WebSocketMessageType.Close) - { - if (receiveResult.CloseStatus == WebSocketCloseStatus.Empty) - { - await socket.CloseAsync(WebSocketCloseStatus.Empty, null, CancellationToken.None); - } - else - { - await socket.CloseAsync( - receiveResult.CloseStatus.GetValueOrDefault(), - receiveResult.CloseStatusDescription, - CancellationToken.None); - } - - continue; - } - - // Keep reading until we get an entire message. - int offset = receiveResult.Count; - while (receiveResult.EndOfMessage == false) - { - if (offset < MaxBufferSize) - { - receiveResult = await socket.ReceiveAsync( - new ArraySegment(receiveBuffer, offset, MaxBufferSize - offset), - CancellationToken.None); - } - else - { - receiveResult = await socket.ReceiveAsync( - new ArraySegment(throwAwayBuffer), - CancellationToken.None); - } - - offset += receiveResult.Count; - } - - // Close socket if the message was too big. - if (offset > MaxBufferSize) - { - await socket.CloseAsync( - WebSocketCloseStatus.MessageTooBig, - string.Format("{0}: {1} > {2}", WebSocketCloseStatus.MessageTooBig.ToString(), offset, MaxBufferSize), - CancellationToken.None); - - continue; - } - - bool sendMessage = false; - if (receiveResult.MessageType == WebSocketMessageType.Text) - { - string receivedMessage = Encoding.UTF8.GetString(receiveBuffer, 0, offset); - if (receivedMessage == ".close") - { - await socket.CloseAsync(WebSocketCloseStatus.NormalClosure, receivedMessage, CancellationToken.None); - } - if (receivedMessage == ".shutdown") - { - await socket.CloseOutputAsync(WebSocketCloseStatus.NormalClosure, receivedMessage, CancellationToken.None); - } - else if (receivedMessage == ".abort") - { - socket.Abort(); - } - else if (receivedMessage == ".delay5sec") - { - await Task.Delay(5000); - } - else if (socket.State == WebSocketState.Open) - { - sendMessage = true; - } - } - else - { - sendMessage = true; - } - - if (sendMessage) - { - await socket.SendAsync( - new ArraySegment(receiveBuffer, 0, offset), - receiveResult.MessageType, - !_replyWithPartialMessages, - CancellationToken.None); - } - } - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocketHeaders.ashx b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocketHeaders.ashx deleted file mode 100644 index 72e742e93e169..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocketHeaders.ashx +++ /dev/null @@ -1 +0,0 @@ -<%@ WebHandler Language="C#" CodeBehind="EchoWebSocketHeaders.ashx.cs" Class="WebServer.EchoWebSocketHeaders" %> diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocketHeaders.ashx.cs b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocketHeaders.ashx.cs deleted file mode 100644 index 28abef11fbddd..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/WebSocket/EchoWebSocketHeaders.ashx.cs +++ /dev/null @@ -1,89 +0,0 @@ -// Licensed to the .NET Foundation under one or more agreements. -// The .NET Foundation licenses this file to you under the MIT license. - -using System; -using System.Web; -using System.Net.WebSockets; -using System.Text; -using System.Threading; -using System.Threading.Tasks; - -namespace WebServer -{ - public class EchoWebSocketHeaders : IHttpHandler - { - private const int MaxBufferSize = 1024; - - public void ProcessRequest(HttpContext context) - { - try - { - if (!context.IsWebSocketRequest) - { - context.Response.StatusCode = 200; - context.Response.ContentType = "text/plain"; - context.Response.Write("Not a websocket request"); - - return; - } - - context.AcceptWebSocketRequest(ProcessWebSocketRequest); - } - catch (Exception ex) - { - context.Response.StatusCode = 500; - context.Response.StatusDescription = ex.Message; - } - } - - public bool IsReusable - { - get - { - return false; - } - } - - private async Task ProcessWebSocketRequest(WebSocketContext wsContext) - { - WebSocket socket = wsContext.WebSocket; - var receiveBuffer = new byte[MaxBufferSize]; - - // Reflect all headers and cookies - var sb = new StringBuilder(); - sb.AppendLine("Headers:"); - - foreach (string header in wsContext.Headers.AllKeys) - { - sb.Append(header); - sb.Append(":"); - sb.AppendLine(wsContext.Headers[header]); - } - - byte[] sendBuffer = Encoding.UTF8.GetBytes(sb.ToString()); - await socket.SendAsync(new ArraySegment(sendBuffer), WebSocketMessageType.Text, true, new CancellationToken()); - - // Stay in loop while websocket is open - while (socket.State == WebSocketState.Open || socket.State == WebSocketState.CloseSent) - { - var receiveResult = await socket.ReceiveAsync(new ArraySegment(receiveBuffer), CancellationToken.None); - if (receiveResult.MessageType == WebSocketMessageType.Close) - { - if (receiveResult.CloseStatus == WebSocketCloseStatus.Empty) - { - await socket.CloseAsync(WebSocketCloseStatus.Empty, null, CancellationToken.None); - } - else - { - await socket.CloseAsync( - receiveResult.CloseStatus.GetValueOrDefault(), - receiveResult.CloseStatusDescription, - CancellationToken.None); - } - - continue; - } - } - } - } -} diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/index.html b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/index.html deleted file mode 100644 index 6deebf937f165..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/index.html +++ /dev/null @@ -1,11 +0,0 @@ - - - - Networking Test Server - - - -

NetworkingTestServer

-

Networking test server in Azure. Used by dotnet/corefx repo.

- - diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/packages.config b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/packages.config deleted file mode 100644 index d0a39047efb50..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/CoreFxNetCloudService/WebServer/packages.config +++ /dev/null @@ -1,11 +0,0 @@ - - - - - - - - - - - diff --git a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/buildAndPackage.ps1 b/src/libraries/Common/tests/System/Net/Prerequisites/Servers/buildAndPackage.ps1 deleted file mode 100644 index bb3828e448338..0000000000000 --- a/src/libraries/Common/tests/System/Net/Prerequisites/Servers/buildAndPackage.ps1 +++ /dev/null @@ -1,32 +0,0 @@ -# Licensed to the .NET Foundation under one or more agreements. -# The .NET Foundation licenses this file to you under the MIT license. - -# Requires Visual Studio Command Prompt -# Requires Azure SDK and .NET Framework SDK installed on the build machine. - -$cdir = pwd -$folderName = "CoreFxNetCloudService" -$src = Join-Path $cdir $folderName -$tmp = Join-Path $Env:TEMP $folderName -$tmpOut = Join-Path $tmp "WebServer\PublishToIIS" -$dst = Join-Path $cdir "..\Deployment\IISApplications" - -$nugetSrc = "https://dist.nuget.org/win-x86-commandline/latest/nuget.exe" - -if (Test-Path $tmp) -{ - rm -Recurse $tmp -} - -copy -Recurse $src $Env:TEMP -Start-BitsTransfer -Source $nugetSrc -Destination $tmp - -cd $tmp - -.\nuget restore -msbuild /p:DeployOnBuild=true /p:PublishProfile=IIS_PublishToLocalPath_RET - -copy -Recurse $tmpOut $dst - -cd $cdir -rm -Recurse $tmp