Sometimes you may see following error when running SSIS Dynamics CRM Source or Target
Unable to download the authentication policy from WSDL "https://yourhostname.api.crm.dynamics.com/XRMServices/2011/Organization.svc?wsdl". ---> System.Net.WebException: The underlying connection was closed: An unexpected error occurred on a send. ---> System.IO.IOException: Unable to read data from the transport connection: An existing connection was forcibly closed by the remote host. ---> System.Net.Sockets.SocketException: An existing connection was forcibly closed by the remote host
Possible reason for this could be your system is still using older SSL Protocol and you have not applied this patch and your API calls are made using TLS 1.0 Protocol rather than TLS 1.2.
You can validate this by using FREE web debugging proxy tool Fiddler (See failure when TLS 1.0 is used by system.
Here is the fix for this problem. Basically we have to set SSL Protocol to 3.0 or Higher before we call any Dynamics CRM Component.
- Goto control flow > Right click in the designer surface > Click Properties > and set DelayValidation=True
- Goto data flow task (with CRM Source or Target)
- Right click in the the designer surface > Click Properties > and set DelayValidation=True
- Now go to Control Flow again Drag ZS REST API Task from Tool box.
- Enter URL as https://httpbin.org/get (Or you can call any website with https://)
- Goto Advanced Tab (Change HTTPS protocol to SSL v3.0 or Higher)
- Now connect REST API task to before calling CRM Component like below.
- Run the package and verify see it works. You can also confirm Fiddler see which protocol being used after the change.