Site certificates and httpWebRequest

Discussion in 'ASP.NET / ASP.NET Core' started by ubersyscom0, May 20, 2010.

  1. I have a aspx.vb program that makes an httpWebRequest call to a secure web service.

    I installed the site certificate (supplied by the company running the web service) on my development computer and the httpwebrequest call works fine.

    I am trying to port this program to my account on DiscountAsp and have discovered that they will not install the site certificate on their servers for me (not a big surprise). I receive this message on my DiscountAsp domain :

    The underlying connection was closed: Could not establish trust relationship for the SSL/TLS secure channel.

    Is there any way I can call the web service either by attaching the certificate to the httpwebrequest call or dumbing down its need to establish the trust relationship with the server?

    I've attached a code sample of what is failing. Specifically it dies at line 57 with the command:

    TheRequestStream = TheRequest.GetRequestStream()

    Any help would be appreciated.
     

    Attached Files:

Share This Page