Strange behavior for reverse proxy

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

I meet a strange problem.

The website architecture is:

Internet -- (Proxy server with public and private ip)  -- (backend server)

Proxy server and backend server are both running Debian buster with apache 2.4.38-3+deb10u3

In the proxy server settings, proxy and proxy_http modules have been enabled, and here I have two example virtual server config:

conf.la.conf in proxy server apache:
https://pastebin.com/BFxzpnjN

http://conf.libreoffice.asia will be redirected to https://conf.libreoffice.asia, which will get from http://intern-conf.libreoffice.asia/ via reverse proxy
Notice in the backend part only http is used, SSL module is disabled.

The ip of intern-conf.libreoffice.asia is a private ip which is defined in /etc/hosts of the proxy server:
https://pastebin.com/gpfsnJ34

This setting works perfectly.

However another virtual server setting uses almost the same way, but the behavior is different:

limesurvey.conf in proxy server apache:
https://pastebin.com/PXs5mbiA

http://limesurvey.slat.org will be redirected to https://limesurvey.slat.org, which should get from http://limesurvey57.slat.org via reverse proxy
where the ip of limesurvey57.slat.org is also defined in /etc/hosts of proxy server like above.

But, the real behavior becomes that it will try to find https://limesurvey57.slat.org and got connection refused.

I used wget -o- https://limesurvey.slat.org and found that it returns a 302 to https://limesurvey57.slat.org

$ LANG=C wget -o- https://limesurvey.slat.org
--2020-04-13 19:49:04--  https://limesurvey.slat.org/
Resolving limesurvey.slat.org (limesurvey.slat.org)... 122.116.230.54
Connecting to limesurvey.slat.org (limesurvey.slat.org)|122.116.230.54|:443... connected.
HTTP request sent, awaiting response... 302 Found
Location: https://limesurvey57.slat.org/ [following]

--2020-04-13 19:49:04--  https://limesurvey57.slat.org/
Resolving limesurvey57.slat.org (limesurvey57.slat.org)... 192.168.xxx.57
Connecting to limesurvey57.slat.org (limesurvey57.slat.org)|192.168.xxx.57|:443... failed: Connection ref
used.


The backend apache virtual config is quite simple:
conf.la.conf:
https://pastebin.com/J8R9tVb9

limesurvey.conf:
https://pastebin.com/igR33iz2

conf.libreoffice.asia works perfectly but limesurvey.slat.org doesn't.  I don't know why the reverse proxy behaviors are different.

Would anyone please give me some hints?


Thanks, Franklin


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux