Ignore SSL Certs

Is there a way to tell caspar/chromium to ignore SSL certificates when playing HTML5 templates?

Somewhat related question: Is there a way of seeing the javascript console output of the page which is loaded?

Setup a remote-debugging-port in the config and look at this HTML Remote Debugging: document.registerElement

IIRC you should be able to start casparcg.exe like this to ignore SSL: “casparcg.exe --allow-running-insecure-content” Otherwise check the other CLI options for CEF https://peter.sh/experiments/chromium-command-line-switches/

I run several hard-coded options in my own CCG builds:

command_line->AppendSwitchWithValue("default-encoding", "utf-8");
command_line->AppendSwitchWithValue("autoplay-policy", "no-user-gesture-required");
command_line->AppendSwitch("allow-file-access-from-files");
command_line->AppendSwitch("allow-insecure-localhost");
command_line->AppendSwitch("allow-running-insecure-content");
command_line->AppendSwitch("disable-web-security");
command_line->AppendSwitch("enable-experimental-web-platform-features");
command_line->AppendSwitch("bwsi");
command_line->AppendSwitch("disable-sync");
command_line->AppendSwitch("javascript-harmony");
command_line->AppendSwitch("no-user-gesture-required");
command_line->AppendSwitch("no-proxy-server");
command_line->AppendSwitch("disable-background-timer-throttling");
command_line->AppendSwitch("disable-backgrounding-occluded-windows");
command_line->AppendSwitch("disable-renderer-backgrounding");
command_line->AppendSwitch("use-fake-ui-for-media-stream");
command_line->AppendSwitchWithValue("default-background-color", "00000000");
command_line->AppendSwitchWithValue("force-device-scale-factor", "1");
command_line->AppendSwitchWithValue("device-scale-factor", "1");
command_line->AppendSwitch("off-screen-rendering-enabled");
command_line->AppendSwitchWithValue("off-screen-frame-rate", "50");
command_line->AppendSwitch("enable-font-aliasing");
command_line->AppendSwitchWithValue("font-render-hinting", "max");
command_line->AppendSwitchWithValue("force-color-profile", "srgb");
command_line->AppendSwitchWithValue("disable-features", "AsyncWheelEvents, TouchpadAndWheelScrollLatching, ColorCorrectRendering, HardwareMediaKeyHandling");
command_line->AppendSwitch("disable-renderer-accessibility");
command_line->AppendSwitch("disable-notifications");
command_line->AppendSwitch("disable-permissions-api");
command_line->AppendSwitch("mute-audio");
command_line->AppendSwitchWithValue("js-flags", "--expose-gc");
command_line->AppendSwitch("disable-main-frame-before-activation");
command_line->AppendSwitchWithValue("num-raster-threads", "2");
1 Like

Thanks for the suggestions.

When I try starting 2.3 with that directive I get the error: “### Invalid configuration file. ###” and Caspar quits.

When starting Caspar should Chromium command line options work?

Check your config file https://casparcg.net/validator/

Thanks. My config file checks out and Caspar works fine when I launch it directly without any command line directives. When I add the “–allow-running-insecure-content” flag I get the config error along with “At --allow-running-insecure-content:0: read error.”

What am I doing wrong?

You might need to do it as “casparcg.exe casparcg.config –allow-running-insecure-content”

Thanks again for the help. That command worked. I also got the remote Chrome console working which is pretty neat.

FWIW, the server I was connecting to was missing the intermediate SSL certificate. This error was not apparent on any other system (other browsers showed a valid certificate) but the lack of that configuration resulted in caspar not being able to connect and not returning any errors I could find. Even when starting caspar with the –allow-running-insecure-content flag, it simply would fail silently. In the end I added an intermediate cert and now Caspar is displaying HTML from that host.

I probably should have tried the --ignore-certificate-errors flag. Oh well.