OPNsense Forum

English Forums => Web Proxy Filtering and Caching => Topic started by: sined on January 16, 2023, 08:29:55 pm

Title: Nginx Webproxie causes problems on IOS devices
Post by: sined on January 16, 2023, 08:29:55 pm
Hello,

I've been using OPNsense for about a year now and so far everything is working very well.
However, have a problem with the Nginx as a web proxy.

Setup:
Running Apache2 on a Debian system (all updates installed). Use the http2 protocol and a self signed certificate. The NextCloud and Wordpress on it are published via OPNsense with the Nginx service (connection OPNsense to Apache2 is only 443).

In the Nginx Config on the OPNsense I have additionally set up URL Rewriting and a Custom Security Policy. If you need screens of this please report.

Errors:
On Windows, Linux or Android systems both websites work. If I use an IOS device I get the following error:
NSURLErrorCannotParseResponse

When I still had simple NAT publishing it still worked. Do you have any idea what I have to do to make it possible for IOS users to open my web pages?

Greetings
Title: Re: Nginx Webproxie causes problems on IOS devices
Post by: Shcshc on January 17, 2023, 08:06:20 am
same error here. i found this:
https://bookstack.borghoff.ddnss.de/books/nextcloud-home-server-on-raspberry-pi-4/page/5-installing-nginx (https://bookstack.borghoff.ddnss.de/books/nextcloud-home-server-on-raspberry-pi-4/page/5-installing-nginx)
https://forums.unraid.net/topic/117178-nextcloudpi-problem-parsen-der-antwort-nicht-möglich/ (https://forums.unraid.net/topic/117178-nextcloudpi-problem-parsen-der-antwort-nicht-möglich/)

but i don't know how i can set proxy_hide_header Upgrade; on opensense
Title: Re: Nginx Webproxie causes problems on IOS devices
Post by: Fright on January 19, 2023, 10:17:48 am
https://forum.opnsense.org/index.php?topic=19305.msg152023#msg152023
Title: Re: Nginx Webproxie causes problems on IOS devices
Post by: sined on January 21, 2023, 05:42:53 pm
Hello,

thank you very much. After the entry in my Apache2 config, it works now also with IOs devices.

In summary I have done the following:

Added the following lines in the Apache2 config of each vHost:
Code: [Select]
        <IfModule mod_headers.c>
                Header unset upgrade
        </IfModule>

If necessary you have to activate the extension Headers (for me it was already activated, but I don't know if it was from the beginning or because I already tried to fix the bug