Änderungen von Dokument RangeeOS - Firewall mit ipables Skript
Zuletzt geändert von Tobias Wintrich am 2022/10/28 10:30
<
>
bearbeitet von Tobias Wintrich
am 2022/10/28 10:15
am 2022/10/28 10:15
bearbeitet von Tobias Wintrich
am 2022/10/28 10:16
am 2022/10/28 10:16
Änderungskommentar:
Es gibt keinen Kommentar für diese Version
Zusammenfassung
-
Seiteneigenschaften (1 geändert, 0 hinzugefügt, 0 gelöscht)
Details
- Seiteneigenschaften
-
- Inhalt
-
... ... @@ -14,24 +14,10 @@ 14 14 15 15 Hier finden Sie verschiedene Regeln um nur definierten, eingehenden Datenverkehr zum RangeeOS auf Netzwerkebene zu erlauben . Das Blockieren ausgehender Verbindungen auf Clientseite wird nicht empfohlen. 16 16 17 -In folgenden Beispielen werden diese Parameter von iptables verwendet: 17 + {{info}}Weitere Informationen zur Verwendung von iptables finden Sie hier:* [[https:~~/~~/linux.die.net/man/8/iptables>>url:https://linux.die.net/man/8/iptables]] 18 +* [[https:~~/~~/wiki.ubuntuusers.de/iptables/>>url:https://wiki.ubuntuusers.de/iptables/]]{{/info}} 18 18 19 -{{{-A => --append 20 --p => --protocol 21 --s => --source 22 --m => --match 23 --j => --jump 24 --F => --flush 25 --P => --policy 26 ---dport => --destination-ports}}} 27 - 28 -{{info}} 29 -Weitere Informationen zur Verwendung von iptables finden Sie hier: 30 - 31 -* [[https:~~/~~/linux.die.net/man/8/iptables>>url:https://linux.die.net/man/8/iptables]] 32 -* [[https:~~/~~/wiki.ubuntuusers.de/iptables/>>url:https://wiki.ubuntuusers.de/iptables/]] 33 -{{/info}} 34 - 20 +((( 35 35 == Standard verwerfen == 36 36 37 37 **Entfernt alle bestehenden Regeln:** ... ... @@ -50,19 +50,19 @@ 50 50 51 51 **Erlaubt Kontakt zur Kommbox per Browser / TCMS auf Port 443 TCP von dem 24er Subnetz 192.168.255.0/24:** 52 52 53 -{{{iptables --append INPUT --protocol tcp --dport 443 --source 192.168.255.0/24 --jump ACCEPT}}} 39 +{{{iptables --append INPUT --protocol tcp --destination-port 443 --source 192.168.255.0/24 --jump ACCEPT}}} 54 54 55 55 **Erlaubt SSH zum Client auf Port 22 TCP von einzelner IP 192.168.255.56/32:** 56 56 57 -{{{iptables --append INPUT --protocol tcp --dport 22 --source 192.168.255.56/32 --jump ACCEPT}}} 43 +{{{iptables --append INPUT --protocol tcp --destination-port 22 --source 192.168.255.56/32 --jump ACCEPT}}} 58 58 59 59 **Erlaubt VNC zum Client auf Port 5900 TCP vom 16er Subnetz 192.168.0.0/16:** 60 60 61 -{{{iptables --append INPUT --protocol tcp --dport 5900 --source 192.168.0.0/16 --jump ACCEPT}}} 47 +{{{iptables --append INPUT --protocol tcp --destination-port 5900 --source 192.168.0.0/16 --jump ACCEPT}}} 62 62 63 63 **Für WebVNC aus Kommbox oder TCMS zusätzlich Port 80 TCP vom 16er Subnetz 192.168.0.0/16:** 64 64 65 -{{{iptables --append INPUT --protocol tcp --dport 80 --source 192.168.0.0/16 --jump ACCEPT}}} 51 +{{{iptables --append INPUT --protocol tcp --destination-port 80 --source 192.168.0.0/16 --jump ACCEPT}}} 66 66 67 67 **Erlaubt ICMP (Ping) von überall** 68 68 ... ... @@ -86,14 +86,14 @@ 86 86 iptables --flush 87 87 iptables --policy INPUT DROP 88 88 iptables --append INPUT --match state --state RELATED,ESTABLISHED --jump ACCEPT 89 -iptables --append INPUT --protocol tcp --dport 443 --source 192.168.255.0/24 --jump ACCEPT 75 +iptables --append INPUT --protocol tcp --destination-port 443 --source 192.168.255.0/24 --jump ACCEPT 90 90 91 91 # Erlaube SSH Admin PC 92 -iptables --append INPUT --protocol tcp --dport 22 --source 192.168.255.56/32 --jump ACCEPT 78 +iptables --append INPUT --protocol tcp --destination-port 22 --source 192.168.255.56/32 --jump ACCEPT 93 93 94 94 # Erlaube VNC 95 -iptables --append INPUT --protocol tcp --dport 5900 --source 192.168.0.0/16 --jump ACCEPT 96 -iptables --append INPUT --protocol tcp --dport 80 --source 192.168.0.0/16 --jump ACCEPT 81 +iptables --append INPUT --protocol tcp --destination-port 5900 --source 192.168.0.0/16 --jump ACCEPT 82 +iptables --append INPUT --protocol tcp --destination-port 80 --source 192.168.0.0/16 --jump ACCEPT 97 97 98 98 # Erlaube PING 99 99 iptables --append INPUT --protocol icmp --jump ACCEPT}}} ... ... @@ -103,9 +103,4 @@ 103 103 |(% style="width:160px" %)Verbindungsname *|(% style="width:1346px" %)Frei wählbarer Anzeigename der Verbindung 104 104 |(% style="width:160px" %)Als root ausführen *|(% style="width:1346px" %)an - Führt das Skript mit den benötigten rechten aus 105 105 |(% style="width:160px" %)Automatischer Start|(% style="width:1346px" %)an - Sorgt dafür, dass die Firewall beim Start des geräts aktiviert wird 106 -|(% style="width:160px" %)Desktop-Verknüpfung erstellen|(% style="width:1346px" %)aus 107 -|(% style="width:160px" %)Verknüpfung im Startmenü erstellen|(% style="width:1346px" %)aus 108 - 109 -[[image:RangeeOS-Firewall.png||height="446" width="600"]] 110 - 111 -Das fertige Skript wird nun bei jedem Systemstart ausgeführt und wendet die definierten Regeln an. Das Skript kann beliebig per TCMS Konfiguration auf andere Geräte verteilt werden. 92 +|(% style="width:160px" %)Desktop-Verknüpfung erstellen