How can I stream when my firewall blocks most ports?

I have a very restrictive firewall at work and it only allows a few ports through. I’d like to stream my plex music library while I work, though.

What settings do I need in order to enable streaming over a small number of ports, specifically HTTP/HTTPS/SSH?

Plex uses the same port for both http and https
Your best chance is to re-dedicate one of the well-known ports for regular internet services
like 80 (http)
or (8080) (http proxy)

Which of them are open at your company’s firewall, only you can determine. Either by testing or portscanning (careful, sometimes even a portscan is detected as malicious activity. I’d only try one port at a time).

Then use this portnumber to create a manual port forwarding in your own router.
(external: your_determined_portnumber - internal: 32400)
Then go to Settings - Server - Remote Access and put your external port number into the field
“Manually specify public port”

https://support.plex.tv/hc/en-us/articles/200931138-Troubleshooting-Remote-Access

Additionally:

  1. if your company is blocking plex.tv, your Plex client has little chance to find your server. (Somehow plex.tv was put on a blacklist of potentially harmful URLs and some company firewalls are using that list)

  2. If your company’s DNS server (or the DNS server of your company’s ISP) doesn’t resolve the TLD .direct, you cannot use secure connections (and therefore no Relay connection as well, because this only works encrypted.)

if plex.tv is not blocked: plex web is your best bet.

If blocked, what about ssh locale port forwarding? (assuming you can connect a ssh server from home)
https://blog.trackets.com/2014/05/17/ssh-tunnel-local-and-remote-port-forwarding-explained-with-examples.html

You can create a reverse proxy by setting up a web server on a computer on the same network as your plex server or even on the same computer as the plex server and then use the web browser to watch. I did the same because my works VPN blocks all ports except 80 and 443. This is a sample reverse proxy config that I’m using through nginx, dont forget to forward port 80 on your router:

server {
    listen 80;     
    server_name  webaddress.to.server.com;

    location / {

        proxy_set_header        Host                $host;
        proxy_set_header        X-Real-IP           $remote_addr;
        proxy_set_header        X-Forwarded-For     $proxy_add_x_forwarded_for;
        proxy_set_header        X-Forwarded-Proto   $scheme;
        proxy_intercept_errors  on;
        proxy_http_version      1.1;
            # Internal IP address of the Plex Server
             proxy_pass http://192.168.1.90:32400/;
    }
}