empty result with AngleSharp 0.9.11
See original GitHub issueI am using AngleSharp v0.9.11.
Because our project is targeting .NET Framework 4.5.2. So the latest version of AngleSharp I can upgrade is 0.9.11.
Now, with same code but the project with .NET 4.6 returns ok but not ok in project with .NET 4.5.2
private async Task<string> GetPageAsync() { string result = "ok"; var page = "https://www.esuperfund.com.au/bank-account/transaction-account/interest-rates/cba-transaction-account"; var config = Configuration.Default.WithDefaultLoader(); var doc = await BrowsingContext.New(config).OpenAsync(page); if (string.IsNullOrEmpty(doc.Body.InnerHtml)) result = "Not ok"; return result; }
I think there are some codes/libraries which make that web returns empty as I tested with other urls (e.g. stackoverflow.com) and all are ok. I don’t know what should I do to make it works for .NET 4.5.2 project.
Many thanks
Issue Analytics
- State:
- Created 4 years ago
- Comments:5 (3 by maintainers)
Top GitHub Comments
Thanks, I added
ServicePointManager.SecurityProtocol = SecurityProtocolType.Tls12;
and it works now.Just another link for you to read (and the person in this post has a page that uses the same CA as esuperfund.com.au; GeoTrust): https://forums.asp.net/t/2145653.aspx?C+WebRequest+Could+not+create+SSL+TLS+secure+channel