title: Securing a private IP address (https certificate)
body: <p>I have an unusual use case :</p>
  
  <ul>
  <li>a web server on the Internet is serving pages through HTTPS,</li>
  <li>inside those web pages, there are calls to XMLHttpRequests to a locally connected device (IP over USB)
  
  <ul>
  <li>the device supports both HTTP and HTTPS,</li>
  <li>the device is accessible on <code>http(s)://192.168.0.1</code></li>
  </ul></li>
  <li>the http calls fail because of insecure content in a https page,</li>
  <li>the https calls fail because the certificate is not trusted (self-signed),</li>
  </ul>
  
  <p><em>Side question</em>: Since the device is locally connected to the PC, the encryption is pretty useless: Does a http header exists that allows insecure connections to a specific URL ? (like CORS for cross domain)</p>
  
  <p><em>Main question</em>: Is it possible to obtain a certificate for a private IP address ?</p>
  
  <p>Edit: it seems that Plex had a similar problem and solved it the way described on this <a href="https://blog.filippo.io/how-plex-is-doing-https-for-all-its-users/" rel="noreferrer">blog</a>. This is a way too big for me.</p>