http://127.0.0.1 Rückgabe von 401 nicht autorisiert

916
pavsid

Ich habe eine CentOS 7-Box und einen Dienst, der auf dem Port 32400 (Plex Media Server) ausgeführt wird, der versucht, einige Informationen über HTTP abzurufen, http://127.0.0.1:32400/library/changestampaber eine 401-Antwort wird zurückgegeben. Ich habe die loSchnittstelle zur aktiven Zone in firewalld hinzugefügt, aber immer noch 401 erhalten.

Die IP-Adresse des Servers lautet 192.168.1.77 und http://192.168.1.77:32400/library/changestampgibt 200 zurück (ich habe die entsprechenden Regeln hinzugefügt firewalld).

Wie kann ich also http://127.0.0.1:32400/library/changestamp200 zurückgeben? Wenn ich es firewalldabschalte, tut es das, aber natürlich muss ich firewalldaktiviert sein.

0

1 Antwort auf die Frage

0
pavsid

OK, it turns out that enabling masquerading on the zone is preventing traffic to 127.0.0.1

So, what I have done is set up 2 zones - external and internal. I assigned the lo interface to the internal zone and the NIC (eno1) to the external zone.

I then left masquerading enabled on the external zone, but disabled it for the internal zone, allowing traffic to the lo interface (127.0.0.1) through.

Not sure if this is the correct/best way to do it, so I welcome any comments!

Hope this helps others.