Commit Graph
783 Commits
Author SHA1 Message Date
Eric Eilebrecht 05b00b4f54 Merge pull request dotnet/corefx#7898 from ericeil/TODOcomments
Associate issues with more TODO comments in System.Net

Commit migrated from https://github.com/dotnet/corefx/commit/0f0a4bcc03db4bc709e100b2107d241f826dd1bb
2016-04-20 12:09:17 -07:00
Davis Goodin 5be2da2fc2 Change non-existent package dependencies to actual versions.
Commit migrated from https://github.com/dotnet/corefx/commit/28f021d9f269ea8207ede73d56b3cd99c8e19c96
2016-04-20 14:06:56 -05:00
Eric Eilebrecht 7f737404b9 Reference dotnet/corefx#5523 from TODO comment
Commit migrated from https://github.com/dotnet/corefx/commit/ae2c11dc4dc683e7cf7f6a98f6437262f1fe70bc
2016-04-20 10:05:54 -07:00
Lakshmi Priya Sekar 74c34921f1 Update xunit.netcore.extensions version.
Commit migrated from https://github.com/dotnet/corefx/commit/2134c046fa998522aa60159a2516b2f6bd7cc330
2016-04-19 19:16:41 -07:00
Stephen Toub 5dcde2e75d Merge pull request dotnet/corefx#7831 from dotnet-bot/UpdateDependencies20160418054051
Updating CoreFX dependencies to rc3-24018-00

Commit migrated from https://github.com/dotnet/corefx/commit/8d183a03d1800214c8e402fc846b5bbf6f91e79e
2016-04-18 15:23:47 -04:00
dotnet-bot cdbab74187 Updating CoreFX dependencies to rc3-24018-00
Commit migrated from https://github.com/dotnet/corefx/commit/b2e960386a786002b5cb724e64814dbb90eb4af4
2016-04-18 17:40:51 +00:00
stephentoub df6cdf3dc1 Ensure WinHttpHandler exceptions have a good stack trace
WinHttpHandler often creates an exception in response to some native error code and then stores that exception into a Task.  As the exception isn't actually thrown until it's propagated out at the eventual await site, the these exceptions often lack a good stack trace to help highlight where the error came from.

This commit ensures that such exceptions have a stack trace by throwing and catching them before storing them into either another exception as an inner exception or directly into a Task.  I've not touched cases where the exception was already being thrown or where an exception was wrapping another exception that has a stack trace.


Commit migrated from https://github.com/dotnet/corefx/commit/31bd97c86fd90faeb977d67c495198dbb2a96000
2016-04-18 09:36:09 -04:00
David Shulman 28e1f8bf95 Merge pull request dotnet/corefx#7747 from StephenBonikowsky/patch-2
Find test builds files deeper in file structure.

Commit migrated from https://github.com/dotnet/corefx/commit/0d33c8cc3d5a730b2508e294b209fa666dc6cf55
2016-04-15 14:49:34 -07:00
David Shulman 16faebe1f0 Fix build problem in WinHttpHandler tests
PR dotnet/corefx#7760 broke the compilation of these tests but wasn't discovered in CI since WinHttpHandler
tests weren't building properly. This PR will fix the compiler error while PR dotnet/corefx#7747 will make
sure that these tests get built/run again in CI.


Commit migrated from https://github.com/dotnet/corefx/commit/948e7fd48cd680cae332efb5d2ebdb777399377e
2016-04-15 11:08:41 -07:00
dotnet-bot 03fd4d1c42 Updating CoreFX dependencies to rc3-24015-00
Commit migrated from https://github.com/dotnet/corefx/commit/a70774dac4088849551525d3ddd750d4e0cc4fbc
2016-04-15 06:40:27 +00:00
Stephen Bonikowsky ecd4e3032a Find test builds files deeper in file structure.
*

 In WCF repo many of our test projects are more than one level below the 'tests' directory.

*
If this doesn't break anything in corefx could we take this change?

* Amending to remove corefx\src\System.Net.Sockets\tests\PerformanceTests\System.Net.Sockets.Async.Performance.Tests.builds

* Amending again with more test .builds files that needed to be removed.


Commit migrated from https://github.com/dotnet/corefx/commit/8cac0d4afab96e15837818ca1abfbd9068008458
2016-04-14 18:20:32 -07:00
dotnet-bot 875bffd0a5 Updating CoreFX dependencies to rc3-24014-01
Commit migrated from https://github.com/dotnet/corefx/commit/0c97843892b744f01ef65a5684a911f50a38ed93
2016-04-14 06:39:49 +00:00
David Shulman dbbd669af6 Initial System.Net.Http 4.1 contract
To support important customer scenarios for CoreFx RTM, we will be updating the System.Net.Http contract from 4.0 to 4.1. We are focusing on HttpClientHandler enhancements.

We will be submitting the final proposed list of additions as part of issue dotnet/corefx#7623. As part of updating the contract to 4.1, we are also OOB'ing the Desktop (net46 Windows) implementation so that the package won't be a facade over Desktop but rather a full implementation. This is possible since System.Net.Http has always been a standalone dll in the .NET Framework. As part of this, we are changing the implementation for Desktop from the legacy HttpWebRequest sockets stack to the WinHttpHandler stack based on native WinHTTP. This will give us a good path forward as WinHttpHandler stack will be getting HTTP/2.0 support with newer versions of Windows 10.

This initial PR has a few API additions that we are definitely going to be adding. It's important to get these changes into the builds so that we can fully bake the OOB Http.dll assembly on all the platforms and continue package testing.

There is an existing System.Net.Http.WebRequestHandler class in the .NET Framework located in System.Net.Http.WebRequest.dll. This class is a subclass of HttpClientHandler. Due to this, we are being careful not to cause collisions with some of these added properties. WebRequestHandler has a 'ClientCertificates' property and a 'ServerCertificateValidationCallback' property. So, we are aligning/renaming the properties as we add them to HttpClientHandler OOB assembly. This may get altered slightly as we finalize the 4.1 System.Net.Http API.


Commit migrated from https://github.com/dotnet/corefx/commit/97c940eec1f6afe3e4af31e72d79c3a11e7b1ff1
2016-04-13 09:50:34 -07:00
dotnet-bot ea45391f54 Updating CoreFX dependencies to rc3-24013-00
Commit migrated from https://github.com/dotnet/corefx/commit/32d2d84ff16efa0ed04dd2780c62db36bbf0bf01
2016-04-13 06:13:25 +00:00
Eric Mellino f57a495784 Overhaul usage of test-runtime.
This change uses some features available in an updated version of
buildtools. Instead of resolving the test-runtime for each of our test
projects as a separate step, we will now add a "reference" to it from the
project.json of each test project. This will allow us to resolve the nuget
assets from both it and the test project at the same time. This will be
more robust than our current process, which is very fragile and
error-prone.

The above is made possible by an updated version of
"PrereleaseResolveNuGetPackageAssets", which is the buildtools task
responsible for resolving test assets from nuget packages. This task also
has a lot of additional validation, which triggers a lot of warnings in
corefx. I've made various changes to csproj's and to project.json's around
the repository in order to satisfy those warnings.


Commit migrated from https://github.com/dotnet/corefx/commit/622ee8f512497fc07621de15e41c6bd575f387c9
2016-04-12 07:12:36 -07:00
dotnet-bot 203d37ef1e Updating CoreFX dependencies to rc3-24012-00
Commit migrated from https://github.com/dotnet/corefx/commit/f89a8267334562ab363ce19d4a2bfa0618bb1f00
2016-04-12 05:34:15 +00:00
dotnet-bot 83f02c753f Updating CoreFX dependencies to rc3-24011-00
Commit migrated from https://github.com/dotnet/corefx/commit/406378b88f0485b549ec2b8c242c79329a5b3ef5
2016-04-11 16:13:03 +00:00
dotnet-bot 6883e89fc3 Updating CoreFX dependencies to rc3-24008-00
Commit migrated from https://github.com/dotnet/corefx/commit/30b74738cdac9c75a2dd165d339f206b1070f3cd
2016-04-08 06:40:37 +00:00
dotnet-bot 0f0193e356 Updating CoreFX dependencies to rc3-24007-00
Commit migrated from https://github.com/dotnet/corefx/commit/d9fdf25de0e1cf35219a26d4f840302e5379f292
2016-04-07 05:37:12 +00:00
Stephen Toub d3980a698e Merge pull request dotnet/corefx#7523 from ellismg/run-tests
Remove "UnsupportedPlatforms" metadata

Commit migrated from https://github.com/dotnet/corefx/commit/0cdc8e39f80a749bfa25eb559ab014be4f7ec557
2016-04-06 09:21:15 -04:00
dotnet-bot be7ca463ae Updating CoreFX dependencies to rc3-24006-00
Commit migrated from https://github.com/dotnet/corefx/commit/aff79bf3fa8ce8c13b6084d82aca30e534142b81
2016-04-06 05:21:19 +00:00
Matt Ellis e631e1c680 Remove UnsupportedPlatforms metadata
Commit migrated from https://github.com/dotnet/corefx/commit/f5252c0c0d19622132e0edcf0b64783b798e3bbf
2016-04-05 14:38:52 -07:00
Matt Ellis 68e4373e9a Reconsile .builds and UnsupportedPlatform metadata
There were a handful of test projects that just didn't have .builds
files and some other cases where the data in the .builds file did not
match what was in the UnsupportedPlatforms metadata.

Some of the projects said the tests were unsupported on FreeBSD and
nowhere else. Given that these tests should most likely be supported on
FreeBSD (given that OSX and Linux both supported them), I've not moved
that logic into the .builds files.

If there ends up being a specific set of tests that the FreeBSD port
team wants to disable long term, they can add .builds metadata as they
see fit.


Commit migrated from https://github.com/dotnet/corefx/commit/836c6f12e1a05749d7d5bf27d02bd28f98eb76aa
2016-04-05 11:51:49 -07:00
dotnet-bot 8c6d7acd5d Updating CoreFX dependencies to rc3-24005-00
Commit migrated from https://github.com/dotnet/corefx/commit/afbf526ac0fae250fc47623f2c43d2caa1abb803
2016-04-05 06:23:55 -04:00
dotnet-bot 9f65b1e1ef Updating CoreFX dependencies to rc3-24004-00
Commit migrated from https://github.com/dotnet/corefx/commit/9fd2c8863f2be58ee5d1431f0c658de61e991551
2016-04-04 20:19:10 -04:00
Lakshmi Priya Sekar 2a3abf12b4 Update xunit.netcore.extensions to latest.
Commit migrated from https://github.com/dotnet/corefx/commit/a7bb9eb3327f5cc791d39b4cff764dd7dd29fda5
2016-04-01 14:04:56 -07:00
Jonathan Miller 0e43cc624e Merge pull request dotnet/corefx#6572 from sokket/builds
Adding builds files to the test projects

Commit migrated from https://github.com/dotnet/corefx/commit/e8326c3dab65e2e8eac466f346a9693788d41ca9
2016-03-31 11:41:43 -07:00
Jonathan Miller 7c2ce6913c Adding builds files for the test projects
Commit migrated from https://github.com/dotnet/corefx/commit/752599494fce80b5d0059a9090fdc010d8c7f45b
2016-03-31 10:46:26 -07:00
stephentoub 025ea3f97f Update packages to rc3-23931-00
Commit migrated from https://github.com/dotnet/corefx/commit/e421dd9c41c308f83511e350c1e407d1f728ba78
2016-03-31 08:26:49 -04:00
stephentoub dabfe7fc9d Update packages to rc3-23930-00
Commit migrated from https://github.com/dotnet/corefx/commit/64a2b6c70977e33b4e8fb90e8f5d3b019b843e61
2016-03-30 07:30:59 -04:00
stephentoub aa64955b41 Update packages to rc3-23925-00
Commit migrated from https://github.com/dotnet/corefx/commit/268eea1b538fa80a0042a1eabc4e51c84473d7b0
2016-03-25 20:23:47 -04:00
David Shulman 7275cf4bd1 Merge pull request dotnet/corefx#7185 from davidsh/win7_bug
Fix WinHttpHandler session handle initialization

Commit migrated from https://github.com/dotnet/corefx/commit/962578a4f53dd69fbfe2ee4759d927e38b0dcaa2
2016-03-23 18:11:18 -07:00
David Shulman 5bed169f64 Fix WinHttpHandler session handle initialization
A test running on Windows 7 was doing multiple parallel requests using the same HttpClient but throwing an unexpected winHTTP error. The problem only occurred on Windows 7 because the proxy initialization code in WinHttpHandler is different for that platform. In general, there is only one session handle created per handler and it is shared with multiple requests. The "init once" logic was faulty because it was setting the `_sessionHandle` field too early before everything was init'd. In addition, this exposed another bug where the session handle options were repeatedly set for each request even though they should only have been set once.

Fixed up the EnsureSessionHandleExists method to do the proper initialization. Also added more tracing.

Fixes dotnet/corefx#7085


Commit migrated from https://github.com/dotnet/corefx/commit/e9cacdcaef8a09c236de3362fa62429d80b6ecc6
2016-03-23 14:17:56 -07:00
stephentoub 0de8ee2b33 Update packages to rc3-23923
Commit migrated from https://github.com/dotnet/corefx/commit/123180cde4aadbed151ffbc00c09b85b7532da68
2016-03-23 11:56:57 -04:00
stephentoub b60997fa74 Update packages to rc3-23921
Commit migrated from https://github.com/dotnet/corefx/commit/3eb508d41d476e4ca0c74d106584c7a7f0d51a17
2016-03-21 12:10:10 -04:00
stephentoub 15713c4b05 Dispose of X509Certificate used in WinHttp server callback
Commit migrated from https://github.com/dotnet/corefx/commit/ef46cce05c310534aad268188c94994c2f68e262
2016-03-21 09:04:08 -04:00
Jon Hanna 1c58a2a42a Fix multiple typos [5]
Commit migrated from https://github.com/dotnet/corefx/commit/00a0871c5cc4ff6af7f036946eef48644ed1e27d
2016-03-20 19:15:44 +00:00
Eric St. John 6aeccb0bae Fix tests to restore using the latest packages
We removed the lifting from the lineup so tests should reference the
latest packages in order to ensure an implementation is available.

The latest pacakges exclude implementation dependencies so I needed to
add these to projects that were depending on them coming in transitively.


Commit migrated from https://github.com/dotnet/corefx/commit/bef9061fd1238adf47b864d8924d121e4134465b
2016-03-19 08:01:11 -07:00
Eric St. John ff75367f93 Update packages to rc3-23918
Commit migrated from https://github.com/dotnet/corefx/commit/d3d217b2ab336b862c27a3e605e32dc0c0a6d472
2016-03-19 08:01:09 -07:00
Eric St. John 12e01eeda2 Add dummy impl for platform specific API
This adds dummy implementations for platform specific API.  The
implementation assemblies throw PlatformNotSupported for all methods.

This will satisfy NuGet's guardrails check and also let folks compile
against these assemblies and load them at runtime without JIT failures.

We will not be placing these packages in any of the shared-framework
layouts, nor should any of these ever be depended on by CoreFx
libraries.  But we will provide them to enable folks to write platform
lightup code without having to worry about using reflection or guarding
calls in separate methods disabling JIT inlining.

These assemblies are marked with AssemblyMetadata("NotSupported",
"True"), so that future dev-time tooling can detect them and warn/error
in the case of accidental dependence on platform specific API.

One notable difference is
System.Runtime.InteropSerivices.WindowsRuntime: this assembly was
previously part of portable profiles and implementation exists in
mscorlib.  For this we will forward to mscorlib on all platforms and it
is up to mscorlib to determine implementation (throw vs noop).
Fixes https://github.com/dotnet/corefx/issues/6684

Other platform specific contracts that have been excluded:
System.IO.IsolatedStorage: currently only supported for netcore50 so no
need to address this problem for x-plat.
System.Runtime.WindowsRuntime & System.Runtime.WindowsRuntime.UI.Xaml:
both are WinRT specific and not exposed in any PCL profiles that we
expect folks to use with x-plat NET core.


Commit migrated from https://github.com/dotnet/corefx/commit/b12b5604c442c13b983f530e5bccfc0867f160cf
2016-03-17 14:21:08 -07:00
stephentoub 1cbe15bf38 Query for the right proxy creds in HttpClient
Both the WinHttp and libcurl implementations are using the target Uri to lookup the right proxy credentials rather than using the proxy's Uri.


Commit migrated from https://github.com/dotnet/corefx/commit/d0cc5116a9906834f5ebd1813c9b9eed68ea054b
2016-03-17 10:34:06 -04:00
David Shulman a592a0b661 Address PR feedback
Commit migrated from https://github.com/dotnet/corefx/commit/4c8bd342f9e3ed7eb05dc51f115e40a94c5e3325
2016-03-15 10:10:22 -07:00
David Shulman 7ea6f917d6 Optimize WinHTTP notification callbacks
Modify WinHttpHandler and WinHttpWebSocket notification callbacks to only receive those notifications that are actually being used in the status callback. This will improve performance.

Fixes dotnet/corefx#5036


Commit migrated from https://github.com/dotnet/corefx/commit/e7e993cb8caaea9255d1babae6afd5f8ce5db680
2016-03-15 10:06:40 -07:00
David Shulman e0781372ea Address PR feedback
Commit migrated from https://github.com/dotnet/corefx/commit/5441deab3daaa92fa5bbcfdf4eb3c5b3bce75891
2016-03-14 09:53:16 -07:00
David Shulman 26901aeb5b Fix WinHttpHandler proxy discovery behavior
In order to support WindowsProxyUsePolicy.UseWinInetProxy, WinHTTP provides the WINHTTP_ACCESS_TYPE_AUTOMATIC_PROXY option. This allows for reading the per-user registry settings to determine how to find a proxy for a given url. This includes using WPAD protocol to find and execute a Javascript PAC file. The WINHTTP_ACCESS_TYPE_AUTOMATIC_PROXY only works on Windows 8.1 and above. For Windows 7 and Windows 8, we have to manually do the work and the WinInetProxyHelper class provides for that by calling various WinHTTP APIs.

This fix is about having the AUTOMATIC_PROXY behaviors work the same whether done automatically by WinHTTP or manually using the WinInetProxyHelper class. In general, errors processing the auto discovery logic should be ignored and the proxy settings should fallback to manual settings if present in the registry.

This is difficult to test in an Xunit test since registry settings need to be changed as well as recycling the "WinHTTP Web Proxy Autodiscover Discovery Service" since it caches PAC file processing. So, this was tested manually for now and additional traces were added to the WinInetProxyHelper class.

Fixes dotnet/corefx#6011


Commit migrated from https://github.com/dotnet/corefx/commit/25ebb1bff1526bbc81d622ba7fc7749181c458fa
2016-03-13 17:46:38 -07:00
David Shulman 420449a472 Fix WinHttpHandler when no proxy creds after 407 response
We were getting an assert if we had an authenticating proxy but didn't have any credentials to send. After the initial 407 was received from the proxy, we then tried to set credentials for a retry. But since we didn't have any, we triggered an assert in SetWinHttpCredential.

The fix is to check for null credentials after getting the 407 response. If there are no credentials, then we end the retry loop with the final 407 status code.


Commit migrated from https://github.com/dotnet/corefx/commit/89966ef37a1269471069c2ee14cdb6af51d8a707
2016-03-10 19:18:38 -08:00
stephentoub d5e591e45a Update packages to rc3-23910
Commit migrated from https://github.com/dotnet/corefx/commit/ab3948bfab039aac2afc1b521883425a171b982d
2016-03-10 09:37:40 -05:00
Justin Van Patten 0d18ce8a1d HttpClient should not miss Set-Cookie response headers
Recent changes due to PR dotnet/corefx#3199 caused `HttpClient` on Windows to miss
`Set-Cookie` response headers when one of the header values was large
enough to cause `WinHttpQueryHeaders` to fail with
`ERROR_INSUFFICIENT_BUFFER` and advance the index.

This commit addresses the regression, by always setting the index
back to the index we want to retrieve.

Added a new test to validate this change.

Fixes dotnet/corefx#6737.


Commit migrated from https://github.com/dotnet/corefx/commit/f7e9f00aba800d2ea63e040deafcc7ee220331fc
2016-03-09 02:35:42 -08:00
Eric St. John 8cba463a08 Update crypto package dependency versions
System.Security.Cryptography.Algorithms, Cng, and X509Certificates are
now 4.1.0.  Update dependencies to ensure we get the right build.


Commit migrated from https://github.com/dotnet/corefx/commit/6e3e29dbec3705094a539b6b2dc863c5a8ee270c
2016-03-08 21:40:47 -08:00
Eric St. John f4d3d8121e Undo X509Certificates workarounds
Fixes https://github.com/dotnet/corefx/issues/6718

Previously NETStandard1.3 packages couldn't consume X509Certificates
due to a missing reference assembly.  That's been fixed so we can undo
the workarounds.


Commit migrated from https://github.com/dotnet/corefx/commit/13f225a650f40b5661cccc93985facb1b07f3786
2016-03-08 08:46:51 -08:00