Roku Developer Program

Developers and content creators—a complete solution for growing an audience directly.
Showing results for 
Show  only  | Search instead for 
Did you mean: 
Level 7

HTTPS image url in Poster node

I'm using the sample code provided by Roku SDK. 
In the scene graph xml, I have the following Poster node declared
<Poster id="cover" loadDisplayMode="scaleToZoom"/>

then in the br initialization code I tried to set the ca cert bundle for any https image urls. However, my https images do not show up consistently, but http images show up fine.  Sometimes when I launch the app, no HTTPS images load, and then I relaunch the app, the same images might occur. This seems to happen randomly with the same code ... 
function Init()
   m.cover ="cover")
   m.cover.AddHeader("developer ID", "")   

   m.isLandScapeMode = true
   m.itemInfo       ="itemInfo")
   m.title          ="title")
   m.description    ="description")
   m.itemDetails    ="itemDetails")
   m.backgroundPoster ="backgroundPoster")
   m.cover.observeField("loadStatus", "OnCoverLoadStatusChanged")
 end function

Any ideas?

0 Kudos
3 Replies
Level 9

Re: HTTPS image url in Poster node

The good news is that rOS 7.2 has introduced this:
"HTTPS support is now available for all Scene Graph nodes (roHttpAgent)."

The bad news is that i am not quite clear how this works? In particualr since say that one is already created and set for all roSgNodes already. This is a shot in the dark, but it appears that ifHttpAgent listed to be supported by roSGNode. Now, for the tricky part - both of these combined, it seems to me it should be as easy for you as doing"common:/certs/ca-bundle.crt")
in the main scene init and in result all your other nodes should start automaGically working with https too!

PS. let me know if that works?
0 Kudos
Level 7

Re: HTTPS image url in Poster node

thanks for the reply. I tried it in HomeScene.brs which is my main scene.

 I simply did what you asked in the init function:
sub init()"common:/certs/ca-bundle.crt")

I'm still not getting thumbnails for the most of time. Like I mentioned before, there are rare times when I relaunch the app and somehow https images started showing, and the next time they don't anymore... All these images I've verified to be working on a desktop browser. 

I wonder if this inconsistency is related to developer mode? 
0 Kudos
Level 7

Re: HTTPS image url in Poster node

actually I just updated the OS to 7.5, now it seems to be working consistently. Thanks for your help!
0 Kudos