Quantcast
Channel: Active questions tagged https - Stack Overflow
Viewing all articles
Browse latest Browse all 1854

QZ Tray HTTPS Localhost – Invalid Certificate Error Even After Providing Certificates [closed]

$
0
0

screenshotI'm working on a local React app that needs to connect to QZ Tray over HTTPS. I want the app to run locally at https://192.168.1.35:3010, and I've tried providing all the necessary certificates in Node.js. My server.js looks like this:

const https = require("https");const fs = require("fs");const { Express } = require("./app");const port = 3010;const options = {  key: fs.readFileSync("./certs/192.168.1.35-key.pem"),  cert: fs.readFileSync("./certs/192.168.1.35.txt"),};https.createServer(options, Express).listen(port, () => {  console.log(`Server running on https://192.168.1.35:${port}`);});

In the browser console, I see:

GET https://192.168.1.35:3010/qz-public-cert net::ERR_CERT_AUTHORITY_INVALIDFailed to get certificate: TypeError: Failed to fetch

And QZ Tray shows:

  • "An anonymous request wants to connect to QZ Tray – Untrusted website"
  • Certificate details show Common Name: An anonymous request

I've tried providing .pem, .key, and .txt files as certificates, but it still doesn't work.

My questions:

  1. How can I make QZ Tray trust my local HTTPS server certificate?
  2. Is there a recommended way to generate self-signed certificates for QZ Tray on a local network?
  3. Can I run QZ Tray with https:// locally without manually approving every request?

Environment:

  • Windows 11
  • Node.js 22
  • React 19
  • QZ Tray 2.2.5

Viewing all articles
Browse latest Browse all 1854

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>