0

I need to connect to another server from IIS 7.5 using TLS 1.1. I'm trying to run the code I found on this SO question, but I cannot write to nor read from httpRequest.option(9) -- the system says, invalid procedure call or argument: 'Option'. When I try Option(8) or other values, everything's OK. What am I doing wrong?

Here's the full code:

Const   WinHttpRequestOption_SecureProtocols = 9
Const   SecureProtocol_TLS1_1 = 512

Set WinHttpReq = Server.CreateObject("WinHttp.WinHttpRequest.5.1")
WinHttpReq.Open "POST", url, false
WinHttpReq.Option(WinHttpRequestOption_SecureProtocols) = SecureProtocol_TLS1_1 'WinHttpReq.Option(9) = 512
Community
  • 1
  • 1
ulu
  • 5,872
  • 4
  • 42
  • 51
  • 1
    You could see [if this](http://stackoverflow.com/questions/29127018/classic-asp-iis6-win2003-server-cant-communicate-with-tls-server) is any help. – Paul Jul 13 '15 at 08:00
  • Thanks, I did see it, but the problem there was attempting to read the response immediately after sending an async request. – ulu Jul 15 '15 at 20:40

0 Answers0