Roku Developer Program

Join our online forum to talk to Roku developers and fellow channel creators. Ask questions, share tips with the community, and find helpful resources.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 
dbulli
Visitor

roURLTransfer issue SSL from GoDaddy (wildcard)

I am not having any success with a .pem, that has a wild card common name *.DOMAIN.COM. I am trying to connect to "https://lab.DOMAIN.com" and I am getting no response?

xfer = CreateObject("roURLTransfer")
xfer.SetURL('https://lab.DOMAIN.com/somescript'))
xfer.AddHeader("X-Roku-Reserved-Dev-Id", "")
xfer.SetCertificatesFile("pkg:/cert/DOMAIN.pem")
xfer.InitClientCertificates()
response = xfer.GetToString()

print "Failure Reason: " + xfer.GetFailureReason()
print "Response: " + response


Both "Failure Reason" and "Response" are coming back empty, and when I hit from a browser I get the a Response.

Anyone has any ideas?

Thanks
- Daniel
http://dbulli.com
0 Kudos
2 REPLIES 2
RokuJoel
Binge Watcher

Re: roURLTransfer issue SSL from GoDaddy (wildcard)

If you want to get more data back about what is going on, use the AsyncGetTostring() function in combination with a message port.

- Joel
0 Kudos
dbulli
Visitor

Re: roURLTransfer issue SSL from GoDaddy (wildcard)

Thanks Joel,

Here is what I tried

  
http = CreateObject("roUrlTransfer")
port = CreateObject("roMessagePort")
url = 'https://abc.DOMAIN.com/blah'
http.SetPort(port)
http.SetCertificatesFile("pkg:/cert/DOMAIN.pem")
http.AddHeader("X-Roku-Reserved-Dev-Id", "")
http.InitClientCertificates()
http.SetUrl(Url)

timeout% = 1500
num_retries% = 10

while num_retries% > 0
print "httpget try " + itostr(num_retries%)
if (http.AsyncGetToString())
msg = wait(0,port)
print "message> " + msg.GetString()
if type(msg) = "roUrlEvent" then
print "getint"; msg.getint()
print "getstring"; msg.getstring()
print "getfailurereason"; msg.getfailurereason()
print "getresponsecode"; msg.GetResponseCode()
end if
end if
num_retries% = num_retries% - 1
end while


And here is the response:

getfailurereasonerror:14077458:SSL routines:SSL23_GET_SERVER_HELLO:reason(1112)
getresponsecode-35
- Daniel
http://dbulli.com
0 Kudos
Need Assistance?
Welcome to the Roku Community! Feel free to search our Community for answers or post your question to get help.

Become a Roku Streaming Expert!

Share your expertise, help fellow streamers, and unlock exclusive rewards as part of the Roku Community. Learn more.