Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- LocalService
- LocalSystem
- NetworkService
- ApplicationPoolIdentity
- Public Class ServiceCall
- Private _binding As BasicHttpBinding
- Private _endPoint As EndpointAddress
- Public Sub New()
- _binding = New BasicHttpBinding()
- _binding.Security.Mode = BasicHttpSecurityMode.Transport
- _binding.Security.Transport.ClientCredentialType = HttpClientCredentialType.Certificate
- End Sub
- Public Sub Connect()
- _endPoint = New EndpointAddress("https://www.theirhostname.com/WebServices/Test")
- Dim client As New TestServiceClient(_binding, _endPoint)
- client.ClientCredentials.ClientCertificate.SetCertificate(
- StoreLocation.LocalMachine,
- StoreName.My,
- X509FindType.FindBySubjectName,
- "ServiceEndPoint- Testing")
Add Comment
Please, Sign In to add comment