pnp / pnpframework

PnP Framework is a .NET library targeting Microsoft 365 containing the PnP Provisioning engine and a ton of other useful extensions
https://pnp.github.io/pnpframework/
MIT License
205 stars 143 forks source link

Connection was forcibly closed by the remote host #1006

Open matthewfitzmaurice opened 5 months ago

matthewfitzmaurice commented 5 months ago

I'm getting the following error when creating a PnPContext:

System.Net.Http.HttpRequestException: The SSL connection could not be established, see inner exception.
System.IO.IOException: Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host..

It happens when I run the following line of code: PnPCoreSdk.Instance.GetPnPContext(context)

The code works fine when I use a VPN, but I get this error when the VPN is not connected. Can someone please help?