Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All

Using Secure Sockets Layer

The WebRequest and WebResponse classes use Secure Sockets Layer (SSL) to communicate with hosts that support SSL automatically. The decision to use SSL is made by the WebRequest class, based on the URI it is given. If the URI begins with "https:", SSL is used; if the URI begins with "http:", SSL is not used.

The following example illustrates using SSL.

Dim MyURI As String = "https://www.contoso.com/"
Dim Wreq As WebRequest = WebRequest.Create(MyURI)
String MyURI = "https://www.contoso.com/";
WebRequest WReq = WebRequest.Create(MyURI);

See Also

Internet Security | Accessing the Internet

© 2015 Microsoft