Access-Control-Allow-Origin header to allow local html5 communication

Want to write your own code to work with a HDHomeRun or work with the HDHomeRun DVR? We are happy to help with concepts, APIs, best practices.
Post Reply
mcglynnj
Posts: 12
Joined: Fri Sep 18, 2020 5:28 am
Device ID: 12515AA4

Access-Control-Allow-Origin header to allow local html5 communication

Post by mcglynnj »

I've been for a while trying to get some level of behaviour with HTML5 video with my HDHR5-4DT, but have had no luck because all browsers I've used says that "no Access-Control-Allow-Origin header is present on the requested resource".

I remember making a separate thread about having a Access-Control-Allow-Origin header added to the port 5004 streams in a future firmware update more than a year ago, as well as staff member nick making a post about telling the developers about this, but the thread seems to have vanished without a trace, and most web browsers won't talk to "different" domains/hosts via XHR or other means unless this header is present (i.e. * to allow all).

EDIT: Just to expand, this header is indeed present on port 80 which provides the web console, but not on the video streams themselves served up via port 5004.

nickk
Silicondust
Posts: 20163
Joined: Tue Jan 13, 2004 9:39 am
x 376

Re: Access-Control-Allow-Origin header to allow local html5 communication

Post by nickk »

Added. It will be in the next beta firmware release (likely later this week).

Nick

mcglynnj
Posts: 12
Joined: Fri Sep 18, 2020 5:28 am
Device ID: 12515AA4

Re: Access-Control-Allow-Origin header to allow local html5 communication

Post by mcglynnj »

nickk wrote: Wed May 24, 2023 1:00 pm Added. It will be in the next beta firmware release (likely later this week).

Nick
Bless you Nick! CORS blockages, even for internal-only communication, is a right headache!

Post Reply