Hello eveyone, I am trying to run a chatscript on our server apache/ubuntu the site is SSL enabled everything works fine but one of my content is being blocked by major browsers due to mix-content error Mixed Content: The page at '<URL>' was loaded over HTTPS, but attempted to connect to the insecure WebSocket endpoint 'ws:<URL>/websocket'. This request has been blocked; this endpoint must be available over WSS. Code (markup): The script is a javascript and I tried to change the prefix from WS to WSS but it didnt help, after a bit of research I came to know that we can use Proxy Tunnel. Can someone tell me where to begin, and how to setup a proxy tunnel so it can convert WS to WSS ? thank you for you time
A Proxy Auto-Configuration (PAC) file is a JavaScript function which figure's out whether web browser requests HTTPS, HTTPS & FTP move straight to the destination or directly to the internet proxy server. The JavaScript function included in the PAC file explains the function: The auto-config file must be saved to a .pac filename extension: proxy.pac And the MIME type set to: application/x-ns-proxy-autoconfig The file includes a function named FindProxyForURL. The illustration given below well describes in which the internal DNS server is set up so that it can only resolve internal host names and the goal is to use a proxy only for hosts that can't be resolved. function FindProxyForURL(url, host) { if (isResolvable(host)) return "DIRECT"; else return "PROXY proxy.mydomain.com:8080"; } hope this helps