PortableRest icon indicating copy to clipboard operation
PortableRest copied to clipboard

Ignore SSL issues

Open Hades32 opened this issue 9 years ago • 1 comments

When using Windows.Web.Http.HttpClient you can do stuff like this:

        private HttpClient CreateClient()
        {
            var filter = new HttpBaseProtocolFilter();
            if (_env.IgnoreSslProblems)
            {
                filter.IgnorableServerCertificateErrors.Add(ChainValidationResult.IncompleteChain);
                filter.IgnorableServerCertificateErrors.Add(ChainValidationResult.Expired);
                filter.IgnorableServerCertificateErrors.Add(ChainValidationResult.Untrusted);
                filter.IgnorableServerCertificateErrors.Add(ChainValidationResult.InvalidName);
            }
            return new HttpClient(filter);
        }

Is it possible to do this with PortableRest? Or would we have to create a (less portable) fork?

Hades32 avatar Dec 17 '14 23:12 Hades32

I will look into it. It seems really useful for testing purposes, so if we have to create platform-specific libraries to be able to make it happen, then that might be the way to go.

robertmclaws avatar Dec 19 '14 14:12 robertmclaws