I have to call web service available at external IP like https://XX.XX.XX.XX:XXXXX in my console application for development purpose. While calling service from C# code, its giving error- “The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel.”
The client exposing service will provide SSL certificate for production server. Currently I have to create SSL certificate which will remove errors for development purpose. I don't want to write the code to ignore certificate errors or to trust relation.
I fount many articles about creating certificate with server domain name. But when i replace my server IP address for domain name. it's not working. Is there any way to create SSL for server with its IP address?
Also how to use that certificate with console application to get service response?