Moin zusammen,
ich möchte meine neue IP Kamera wie folgt einbinden...
<ftui-grid-tile row="7" col="11" height="14" width="22" style="margin-left:-0.7em;">
<ftui-image src="https://ipcam1/cgi-bin/api.cgi?cmd=Snap&channel=0&rs=123456ABCDEF&user=user&password=xxxxxx&width=640&height=360" nocache interval="0.25" style="width:100%; height:100%;"></ftui-image>
</ftui-grid-tile>
Im Browser ohne FTUI3 wird das Bild angezeit jedoch in FTUI nicht und in der Debgging-Konsole erhalte ich den folgeden Fehler bzw. Hinweis.
Hat jemand eine Idee wie ich das umgehen kann bzw. eine Möglichkeit das abzuschalten?
Cross-Origin Read Blocking (CORB) hat die ursprungsübergreifende Antwort https://ipcam1/cgi-bin/api.cgi?cmd=Snap&channel=0&rs=123456ABCDEF&user=user&password=xxxxxx&width=640&height=360&_=1658993536222 mit dem MIME-Typ text/html blockiert. Weitere Informationen findest du unter https://www.chromestatus.com/feature/5629709824032768.
Danke Grüße
Olli
Ja, ist in Chrome standardmäßig aktiv:
https://chromestatus.com/feature/5629709824032768
Es sollte in den meisten Fällen keine Auswirkung haben, aber:
https://www.chromium.org/Home/chromium-security/corb-for-developers/#what-should-i-do-about-corb-warnings-reported-by-chrome
die soll es wohl geben wie bei dir.
Könntest ja mal FF mit FTUI3 testen.
Oder einen Iframe einbinden.
<iframe frameborder="0" scrolling="no" width="100%" height="100%"
src="https://ipcam1/cgi-bin/api.cgi?cmd=Snap&channel=0&rs=123456ABCDEF&user=user&password=xxxxxx&width=640&height=360">
</iframe>
oder als img:
<img src="https://ipcam1/cgi-bin/api.cgi?cmd=Snap&channel=0&rs=123456ABCDEF&user=user&password=xxxxxx&width=640&height=360">
Zusätzlich könntest du noch eine referrerpolicy anhängen:
https://www.w3schools.com/tags/att_img_referrepolicy.asp
Kameraupdate??
Edit: Gibt es noch einen anderen Aufruf eines snap? Was hast du für eine Kamera (Reolink?)? Und mal ohne &width=640&height=360 probieren...
Kann es sein das ein Token fehlt?
http://192.168.1.238/cgi-bin/api.cgi?cmd=Snap&channel=0&rs=flsYJfZgM6RTB_os&token=TOKEN
Wenn es eine Reolink ist:
Api Doc (https://www.domoticz.com/forum/download/file.php?id=27849&sid=9e4207a7effcafd0fc78972dcdd662a1)
3.6.7 Snap
Interface Description
It is used to capture an image.
Interface call instructions
Request URL http://192.168.1.238/cgi-bin/api.cgi?cmd=Snap&channel=0&rs=flsYJfZgM6RTB_os&token=TOKEN
Request parameter description
Parameter M/O Description
channel M Channel number
rs M Random character with fixed length. It's used to prevent browser caching.
Return data description
Return data correctly
Content-Type: image/jpeg
Content-Length: 171648
Connection: keep-alive
X-Frame-Options: SAMEORIGIN
X-XSS-Protection: 1; mode=block
X-Content-Type-Options: nosniff
.............................(File content)
Field description
Field description
name Picture name
Liegt wohl an den X-Content-Type-Options: nosniff von der Antwort der Kamera im Header
ps Chrome mal mit:
--disable-features=CrossSiteDocumentBlockingAlways,CrossSiteDocumentBlockingIfIsolating
starten und schauen ob es danach geht...
LG