Is it possible to specify the version of SSL Protocol to use when using a web service via WSHttpBinding?
I've been using a trace log to try and determine why my calls to a web service, over SSL using a client certificate have been failing.
The final logging shows an alert 15 03 01 00 02
and the alert code 02 0A
which is an unexpected_error. I suspect this error is because the server is unable to handle the version of SSL that I'm throwing at it.
System.Net.Sockets Verbose: 0 : [13908] Exiting Socket#15927457::Send() -> Int32#138
System.Net.Sockets Verbose: 0 : [13908] Socket#15927457::Receive()
System.Net.Sockets Verbose: 0 : [13908] Data from Socket#15927457::Receive
System.Net.Sockets Verbose: 0 : [13908] 00000000 : 15 03 01 00 02 : .....
System.Net.Sockets Verbose: 0 : [13908] Exiting Socket#15927457::Receive() -> Int32#5
System.Net.Sockets Verbose: 0 : [13908] Socket#15927457::Receive()
System.Net.Sockets Verbose: 0 : [13908] Data from Socket#15927457::Receive
System.Net.Sockets Verbose: 0 : [13908] 00000005 : 02 0A : ..
System.Net.Sockets Verbose: 0 : [13908] Exiting Socket#15927457::Receive() -> Int32#2
System.Net Information: 0 : [13908] InitializeSecurityContext(credential = System.Net.SafeFreeCredential_SECURITY, context = 79d80e8:7a0e230, targetName = dsl-wholesale-testing.iinet.net.au, inFlags = ReplayDetect, SequenceDetect, Confidentiality, AllocateMemory, InitManualCredValidation)
System.Net Information: 0 : [13908] InitializeSecurityContext(In-Buffers count=2, Out-Buffer length=0, returned code=IllegalMessage).
System.Net.Sockets Verbose: 0 : [13908] Socket#15927457::Dispose()
System.Net Error: 0 : [13908] Exception in HttpWebRequest#41613110:: - The request was aborted: Could not create SSL/TLS secure channel..
System.Net Error: 0 : [13908] Exception in HttpWebRequest#41613110::GetResponse - The request was aborted: Could not create SSL/TLS secure channel..
I have a PHP based client that does work with the same web service, and I specify SSL version 3 via cURL ( curl_setopt($ch, CURLOPT_SSLVERSION, 3);
).
The version can be set as follows:
System.Net.ServicePointManager.SecurityProtocol = System.Net.SecurityProtocolType.Ssl3;
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.