NethServer / nethsecurity

NethSecurity image and build environment
https://www.nethsecurity.org/
Other
98 stars 6 forks source link

Proxy pass: WebTop does not work #622

Closed gsanchietti closed 3 months ago

gsanchietti commented 3 months ago

After a migration from NS7 to NS8, a proxy pass to WebTop does not work anymore: the client is redirect to https://127.0.0.1/webtop/;jsessionid=FE16465413BF5CFA9A4F38D39230D2BF upon login and logout.

How to manually fix it

  1. Configure the proxy pass as follows:
  2. Locate the location type record in /etc/config/nginx
  3. Remove the extra header and apply the configuration:
    uci del_list nginx.<id>.proxy_set_header='X-Forwarded-Proto $scheme'
    uci commit nginx
    /etc/init.d/nginx restart
  4. Access webtop using: https://webtop.nethesis.it/webtop (note /webtop at the end)

Proposed changes Since the bug can't be solved from upstream, change current proxy pass impelementation and remove the X-Forwarded-Proto : this should eventually improve backward compatibility also with other applications.

References (private):

gsanchietti commented 3 months ago

Testing image: 23.05.3-ns.1.0.1-56-g1d700e8 (https://github.com/NethServer/nethsecurity/actions/runs/9758641733)

Test case 1

Test case 2 The issue also include another change inside the reverse proxy default: the max body size has been increased from 1MB (default) to 1GB as in NethServer 7.

mamengoni commented 3 months ago

Tested and verified!