Synology Quickconnect reverse proxy


It's funny how bureaucracy changes daily life. If there is problem with a social service, just kill the service so there won't be any problems.

In this case, the Asian Games imposes limited internet cut out on local institutions, just so hackers will not have any chance to sabotage. As a result, I now have trouble connecting back into campus LAN through reliable proxies.


Reverse proxy always work, it's just you need an extra server. In this case, I found that Synology Quickconnect works perfectly as an emergency backup. The speed is about 7MB/2MB, enough for light use.

sudo tee /usr/syno/share/nginx/conf.d/ <<EOF
location /some-path/ {
  proxy_redirect off;
  proxy_http_version 1.1;
  proxy_set_header Upgrade $http_upgrade;
  proxy_set_header Connection "upgrade";
  proxy_set_header Host $http_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;

Refer to /etc/nginx/nginx.conf for server conf path pattern.

The trick is that the Quickconnect service checks cookies, otherwise it will return 307. You will have to connect normally with a browser, then copy paste the cookies in the headers of your websocket request for it to pass the check.