Commit Graph
19 Commits
Author SHA1 Message Date
Stephen Toub fd63714f4a Re-enable ManagedHandler_HttpClientHandler_ClientCertificates_Test and ManagedHandler_HttpClientHandler_ServerCertificates_Test
The tests that verify PNSEs getting thrown were failing incorrectly when the managed handler was used on platforms like CentOS where our CI system has an old libcurl installed.  For now, I've worked around it in a very manual fashion, but longer term we need a better way of using the same tests against multiple handlers substituted dynamically.


Commit migrated from https://github.com/dotnet/corefx/commit/fb2f2e8be64d6bf2c26030ef63d1e5cb004e8a64
2017-07-05 12:43:12 -04:00
Santiago Fernandez Madero c65dd7a4bd Test attributes cleanup for Uap now that Uap flag includes UapAot (dotnet/corefx#20108)
* Update xunit extensions to unify TargetFrameworkMonikers.Uap to include UapAot

Commit migrated from https://github.com/dotnet/corefx/commit/652d12bf31606eeef8fe8b9a7bf1cc7af06f6352
2017-05-22 15:10:24 -07:00
David Shulman d899bda510 Disable System.Net.Http tests on UAP/UAPAOT (dotnet/corefx#20017)
Disable a bunch of System.Net.Http tests on UAP/UAPAOT platform.

Both inner and outer loop tests now run clean for System.Net.Http

Commit migrated from https://github.com/dotnet/corefx/commit/38cd7f91dbbc5ac4001bf15762a8e244f5ec3a70
2017-05-19 14:28:54 -07:00
Daniel Harvey 252cdc5e95 Bulk updates of tests for AssertExtensions (dotnet/corefx#18491)
Bulk update to AssertExtensions.Throws for AOT support. This doesn't disable Assert.Throws.

Commit migrated from https://github.com/dotnet/corefx/commit/b43b4df2e0e2182154bb0f425cb4a61bc1269828
2017-04-18 09:52:02 -07:00
Caesar Chen b6892a28ed change the test label and add string to the resource file of WinHttpHandler to correct build error
Commit migrated from https://github.com/dotnet/corefx/commit/f57d3f2b4ee02c1e7cdc0a7d649eeda7d7a680d4
2017-03-16 14:48:58 -07:00
Caesar Chen eb24955a77 fix the HttpClientHandler.ClientCertificates behaviour when ClientCertificateOption.Automatic is set
Commit migrated from https://github.com/dotnet/corefx/commit/72322773ec42b011622e8162acfdff4ecc3beb0c
2017-03-16 13:21:12 -07:00
Jeremy Barton b978bc6f2c Merge remote-tracking branch 'dotnet/master' into master_to_applecrypto
Conflicts:
	netci.groovy
	src/System.Net.Security/src/System/Net/Security/SecureChannel.cs
	src/System.Security.Cryptography.X509Certificates/src/Internal/Cryptography/Pal.Unix/OpenSslX509Encoder.cs
	src/System.Security.Cryptography.X509Certificates/src/Resources/Strings.resx
	src/System.Security.Cryptography.X509Certificates/tests/Cert.cs
	src/System.Security.Cryptography.X509Certificates/tests/CollectionImportTests.cs
	src/System.Security.Cryptography.X509Certificates/tests/CollectionTests.cs
	src/System.Security.Cryptography.X509Certificates/tests/PfxTests.cs
	src/System.Security.Cryptography.X509Certificates/tests/X509StoreTests.cs


Commit migrated from https://github.com/dotnet/corefx/commit/5d7aec3e00afd35d0211b50c0630a1614a548726
2017-03-10 17:44:40 -08:00
Jeremy Barton 74fbe34b84 Initial implementation of X509Certificates, HttpClient, and SslStream for macOS (dotnet/corefx#16445)
Broken by this change:
* A lot of TLS CipherSuites have no metadata defined.
* macOS does not support version skipping in TLS.  So `Tls | Tls12` is an invalid choice.

In this change:
General:
* All OSStatus related exceptions now look up the error message.

X509Certificates:
* X509Certificate moves to using SecCertificateRef from OpenSSL's X509.
* X509 metadata comes from a managed reader after being loaded by Security.framework,
due to the significant amount of data that has no public export in Apple's libraries.
* Significant code was factored out to be shared by OpenSSL and Apple implementations for X500DistinguishedName and X509Certficate2Collection.Find.
* Loading a PFX (or, rather, the private keys from a PFX) via Apple's platform
requires importing into a Keychain, and a Keychain requires a file on disk.
A temporary keychain is created during cert loading and erased when safe.
Like the perphemeral key load on Windows this can leak files due to
abnormal program termination.
* The X.509 My store for CurrentUser and LocalMachine are the default (user) and System keychains.
* The X.509 Root store is an interpretation of the Apple SecTrustSettings data.
* The X.509 Disallowed store hasn't been implemented yet, but should be a very small change.
* Other X.509 stores cannot be created due to keychain complexity.

HttpClient:
* Initialization no longer wakes up OpenSSL

SslStream:
* New implementation based on Apple SecureTransport.
* Currently has support for SNI (for AuthenticateAsClient)


Commit migrated from https://github.com/dotnet/corefx/commit/3b19899963606a34e1623e0926b90fe907197ee6
2017-03-01 14:45:41 -08:00
Steve Harter 4fc05a19f5 Improve CI: change Http test ActiveIssue(Windows) to (Any) (dotnet/corefx#16368)
Commit migrated from https://github.com/dotnet/corefx/commit/8bf03424d20922170572803fa3f3c17671e4d197
2017-02-21 18:24:25 -06:00
Steve Harter be18ea33cc Disable network test that is failing regularly (dotnet/corefx#16167)
Commit migrated from https://github.com/dotnet/corefx/commit/7df0cd05c67c28f869a997dfc4423813c2bd9f2a
2017-02-14 16:58:24 -08:00
Lakshmi Priya Sekar 6bff1b3000 Fix networking test activeissues in System.Net.Http
Commit migrated from https://github.com/dotnet/corefx/commit/dd65f89ef9806067779eb63b884d9317dad68202
2017-02-03 12:31:59 -08:00
Eric St. John f6f23740a5 Update Http tests to target ns1.7 + ns1.3
I had to add a namespace alias due to System.Configuration now being
defined by System.Runtime.


Commit migrated from https://github.com/dotnet/corefx/commit/6e86da5cc3efb88db6b932f01c9a4f9e66e84f8c
2016-10-20 14:31:18 -07:00
Justin Van Patten aa68f5ce2f Replace uses of Xunit.PlatformID with renamed TestPlatforms
Replace uses of `Xunit.PlatformID` with renamed `TestPlatforms` because
the old name conflicts with `System.PlatformID` and should be plural
according to the design guidelines for flags enums.


Commit migrated from https://github.com/dotnet/corefx/commit/5179dda7331b1e201519adf76ce9ae69ffe2a0f6
2016-10-01 17:18:41 -07:00
David Shulman 935520c1dc Disable most networking tests for default CI runs
Lately, the CI system and test server infrastructure has been overloaded with many PRs. This is causing many networking tests to randomly fail due to resource exhaustion caused by so many simultaneous PR runs on the same CI machines. This occurrs not only when using an external test server endpoint (corefx-net.cloudapp.net) but also loopback servers.

To improve engineering efficiency for the team, we are moving most of the tests in the networking libraries from the default CI runs (innerloop). For developers working on networking libraries, the networking tests can be run by invoking the "outerloop" tests.

We will not be allowing any merges of PRs in the networking libraries unless the outerloop tests are also run by the developer.

This affects tests in the following libraries right now:

* System.Net.Http
* System.Net.Http.WinHttpHandler
* System.Net.Sockets
* System.Net.Security
* System.Net.WebSockets.Client

I will be working on fine tuning these exclusions (issue dotnet/corefx#11345) to try to bring back tests into the innerloop runs when we have begun to address the infrastructure issues.


Commit migrated from https://github.com/dotnet/corefx/commit/defbb8afd11b317f6b5cc2f4422a03d701b6dba3
2016-09-01 11:23:40 -07:00
David Shulman 9449dda9a7 Enhance LoopbackServer to return received data
Modified the test LoopbackServer so that it can return the received data in the helper methods. This allows more use of the
simple ReadRequestAndSendResponseAsync() method instead of having to use the more complex methods.

Modified a few HttpClient tests to take advantage of this. More tests will be simplified in future PRs.


Commit migrated from https://github.com/dotnet/corefx/commit/14c8ddd89be1fac31a472efdcaee184ba9d62e58
2016-08-26 12:11:43 -07:00
Cristian Pop 7a3d76b180 Adding multi-machine scripts and unifying configuration.
Commit migrated from https://github.com/dotnet/corefx/commit/c354b2d44f6988a20a9f7be4a1b996ef7fbc873a
2016-06-28 12:38:07 -07:00
Stephen Toub def7b43d50 Mark another ActiveIssue
Commit migrated from https://github.com/dotnet/corefx/commit/daa30fcf33d57203456ed6c0ce8c42650074d5db
2016-06-20 14:48:11 -04:00
Stephen Toub 5a23884046 Tweak HTTP client certificates test and add ActiveIssue
With forced GC/finalization at the right moment, the test currently fails on Windows.


Commit migrated from https://github.com/dotnet/corefx/commit/4cdb8dc1ba73ef02ef719b9a0ee336dbefca3b10
2016-06-20 08:37:30 -04:00
Stephen Toub ea6cd05418 Add some HttpClientHandler client certificate tests
And fix a small bug discovered from this, lack of argument validation when setting the enum value.


Commit migrated from https://github.com/dotnet/corefx/commit/483aa5a3012fe78ea001ece1b0404b18c0b90a29
2016-06-03 13:09:23 -04:00