Meteor (I think) is throwing some weird errors, dependent on client environment

So we have a Meteor application on an internal network, which users VPN into so they can access the app. There are two ways of doing this:

  1. To use a SSL-VPN desktop application to log into the network and then they can access the app normally through the browser, because their computers are added to the LAN normally.

  2. To log into a web-portal that uses an SSL-VPN proxy to forward their requests on that specific browser to the internal network. Should, theoretically, work the same way.

The first method works perfectly for all users, regardless of client machine or how they’re accessing the internet, no errors or failed requests anywhere. The second method fails spectacularly: empty responses, weird syntax (???) errors, Websockets refusing to connect, etc.

SyntaxError: Unexpected token ;
    at new Function (<anonymous>)
    at bn.compile (25d037b….js?meteor_js_resource=true:formatted:11436)
    at _o.parse (25d037b….js?meteor_js_resource=true:formatted:12175)
    at s (25d037b….js?meteor_js_resource=true:formatted:7843)
    at u (25d037b….js?meteor_js_resource=true:formatted:7253)
    at le (25d037b….js?meteor_js_resource=true:formatted:6378)
    at z (25d037b….js?meteor_js_resource=true:formatted:5933)
    at B (25d037b….js?meteor_js_resource=true:formatted:5869)
    at B (25d037b….js?meteor_js_resource=true:formatted:5872)
    at B (25d037b….js?meteor_js_resource=true:formatted:5872)
(anonymous) @ 25d037b….js?meteor_js_resource=true:formatted:7608
(unknown) WebSocket connection to 'wss://<internal_ip_here>/sockjs/583/uc7352kv/websocket' failed: Error in connection establishment: net::ERR_INSECURE_RESPONSE

Thing is, the firewall is configured the same way for both methods of accessing the VPN so I’m at a loss, from a networking standpoint. I’ve only ever encountered strange syntax errors like that when problems occurred during the build process, minification and whatnot. Since the app works just fine through the direct VPN tunnel, I can only assume that there’s some incompatibility between the application and the way the VPN web-portal is designed or configured.

Has anybody encountered this issue before? If not, do you have any ideas where the problem might be originating from? Obvious answer is that the web-portal software itself has a bug, but I want to avoid going down that road if I can.