With HTTPS URL image not load with Poster Grid

拜拜、爱过 提交于 2020-07-09 12:13:07

问题


I created one RSG Component and stored content using content-meta-data like below.  Inside a content-meta-data field is hdgridposterurl here, I put Both URL HTTP and HTTPS and Checked Roku side, It's working or not. Http is Working. But, Https is not Working. I also checked both URLs on a different platform. Both URLs Working well for other platforms like Android, IOS, Google Chrome, Amazon Fire Stick.

I also add SetCertificatesFile("common:/root/www_mysite_com.csr"). It's not working. This is the same problem with all RSG components and simple Poster node. Does anyone know any solution for this? 

PosterGrid Example :

<component name = "PosterGridExample" extends = "Scene" initialFocus = "examplePosterGrid" > 
  <script type = "text/brightscript" >
    <![CDATA[
    sub init()
      m.top.backgroundURI = "pkg:/images/rsgde_bg_hd.jpg"
      m.top.setFocus(true)
      m.postergrid = m.top.findNode("examplePosterGrid")
      m.postergrid.translation = [ 130, 160 ]
      m.readPosterGridTask = createObject("roSGNode", "ContentReader")
      m.readPosterGridTask.contenturi = "http://www.sdktestinglab.com/Tutorial/content/rendergridps.xml"
      m.readPosterGridTask.observeField("content", "showpostergrid")
      m.readPosterGridTask.control = "RUN"
    end sub
    sub showpostergrid()
      m.postergrid.content = m.readPosterGridTask.content
    end sub
    ]]>
  </script>
  <children>
    <PosterGrid
      id = "examplePosterGrid"
      basePosterSize = "[ 512, 288 ]"
      caption1NumLines = "1"
      numColumns = "2"
      numRows = "2"
      itemSpacing = "[ 20, 20 ]" />
  </children> 
</component>

Content-Meta-Data : 

<Content >
  <item hdgridposterurl = "https://simultv.com:1400//nodeapi/Channels/file-1591699694712.jpg"
    shortdescriptionline1 = "Rectangle Node"
    x = "0" y = "0" />
  ...
</Content>

Edited:

I added a certificate like below and display loadStatus and FailedBitmapUri. here, loadStatus = "failed" display. But, the FailedBitmapUri image is not displaying. In Google Chrome successfully Loading But, Roku not loaded. I think Roku does not decode the image. But, I don't know why? I'm Still not Found any solution for this.

sub init()
m.poster = m.top.findNode("testPoster")
m.poster.SetCertificatesFile("pkg:/certificates/cacert.crt")
m.poster.InitClientCertificates()
m.poster.uri="https://simultv.com:1400//nodeapi/Channels/file-1591699694712.jpg"
m.poster.failedBitmapUri="pkg:/images/splash_hd.jpg"
m.poster.observeField("loadStatus","OnLoadStatusChanged")
m.top.SetFocus(true)
End sub

function OnLoadStatusChanged()
?"m.poster.loadStatus : "m.poster.loadStatus
end function

I tried some below URLs with the same image. It's Results Like below in Roku. I tested these URLs in all Cooper Devices. the result is the same for all.

'm.poster.uri = "https://simultv.com/ace.jpg" It's Working
'm.poster.uri="https://simultv.com:1400/nodeapi/iphone/101.jpg" 'It's not Working 'm.poster.uri="https://simultv.com:1400/nodeapi/Channels/file-1592530892572.jpg" 'It's not Working


回答1:


Do you have debug open (telnet to port 8085 on your Roku's LAN ip), what is it showing you?
Depending on your component type, you can use SetCertificatesFile usually on m.top:

m.top.SetCertificatesFile("common:/certs/ca-bundle.crt")  
m.top.InitClientCertificates()

but not on the poster node itself (afaik?) Assuming testPoster is indeed a poster then I believe SetCertificatesFile is not a valid method on poster (or Group or Node)

Also, it appears you are using the incorrect cert? (cacert.crt) Try the bundle: ca-bundle.crt



来源:https://stackoverflow.com/questions/62411763/with-https-url-image-not-load-with-poster-grid

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!