SliTaz GNU/Linux official and community documentation wiki.
.png

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
de:handbook:networkconf [2016/11/01 15:04]
hgt created
de:handbook:networkconf [2019/11/10 17:07] (current)
hgt Änderungen aus dem englischen Text übernommen
Line 1: Line 1:
 ====== Netzwerkkonfiguration ====== ====== Netzwerkkonfiguration ======
 +<note important>​Ab SliTaz-4.0 ist netbox durch SliTaz Panel -> Netzwerk ersetzt worden</​note>​
  
 ===== Einführung ===== ===== Einführung =====
  
-Standardmäßig startet SliTaz einen DHCP-Klienten (udhcpc) ​on eth0 bei der SystemeinleitungIf your network card has been identified as an eth0 interface and you use a router, ​your connection should already be working. DHCP is dynamically configured, on each boot the client asks for a new IP address from the DHCP server which is integrated into the router, or on another computerIf you need a static ​IP, you can directly edit config files or use the //Network// tab at //System Tools// ​-//Slitaz Panel//. In a terminal or a Linux console, you can list all available network interfaces with the command ​//ifconfig// followed by the //-a// option: +Standardmäßig startet SliTaz ​bei der Systemeinleitung ​einen DHCP-Klienten (udhcpc) ​für die Ethernet-SchnittstelleWenn der Netzwerk-Adapter des Rechners als Ethernet-Schnittstelle erkannt wurde und mit einem Vermittlungsknoten („router“) verbunden istsollten Netzwerkverbindungen bereits möglich seinBei jeder Systemeinleitung fordert der DHCP-Klient erneut eine IP-Adresse vom DHCP-Server anLetzterer ist in den Vermittlungsknoten integriert oder befindet sich auf einem anderen Rechner. Bei jeder Anforderung kann eine andere ​IP-Adresse zugewiesen werden. Wenn der Rechner immer dieselbestatische IP-Adresse erhalten soll, kann diese direkt in die Konfigurationsdatei geschrieben werden oder über das Menü //Systemwerkzeuge → Slitaz Panel// ​und den Reiter ​//Netzwerk// eingegeben werden. Mit dem Kommando ​//ifconfig// können alle vorhandenen Netzwerk-Adapter angezeigt werden:
 <​code>​ $ ifconfig -a </​code>​ <​code>​ $ ifconfig -a </​code>​
  
-To display the Kernel'​s IP routing table, you can use the route command without any arguments: +Mit dem Kommando //route// ohne Parameter kann die Routentabelle ausgegeben werden:
 <​code>​ $ route </​code>​ <​code>​ $ route </​code>​
  
-The system wide network configuration file is ///​etc/​network.conf//​. ​It can be graphically configured at the //Network// tab on SliTaz Panel or directly edited by the root administrator.+Die globale Netzwerk-Konfigurationsdatei heißt ​///​etc/​network.conf//​. ​Diese kann (wie oben beschrieben) vom Administrator grafisch bearbeitet werden oder direkt editiert werden.
    
-===== Netbox - Netzwerk konfigurieren (SliTaz ​4.0) =====+===== Netbox - Netzwerk konfigurieren (bis SliTaz ​3.0) =====
  
-Netbox ​is a small GTK+ application to configure a network interface using DCHP or a fixed (static) IP addressThe tabs can be used to start/stop the connections and automatically change the values ​in the system files. Netbox ​provides a system wide tab from which you can directly edit network configuration filesand tabs to configure ​PPP/​PPPoE ​username/​passwordsServers such as SSH, DHCP, PXE, DNS, etc can also be configured and it's possible to create your own virtual private network ​(VPNusing the tools provided+Netbox ​ist eine kleine ​GTK+ -Anwendung zur Konfigurierung von Netzwerk-Adaptern mit DCHP oder einer festen ​(statischen) IP-AddresseDie Reiter können verwendet werden um die Adapter zu aktivieren oder zu deaktivieren und automatisch die eingegebenen Werte in die Systemdateien zu übernehmen. Netbox ​hat einen Reiterüber den direkt die globalen Netzwerk-Konfigurationsdateien bearbeitet werden und Reiter zum Konfigurieren von PPP/PPPoE-Benutzernamen und -KennwörternDesweiteren können Server für SSH, DHCP, PXE, DNS, usw. konfiguriert werden und es kann ein VPN („virtual private networkmit den entsprechenden Werkzeugen eingerichtet werden
  
 {{:​en:​handbook:​image:​netbox.png}} {{:​en:​handbook:​image:​netbox.png}}
  
-You can start netbox from the System tools menu or via a terminal: +Netbox kann über das Menü //​Systemwerkzeuge//​ oder mit dem Kommando
 <​code>​ $ subox netbox </​code>​ <​code>​ $ subox netbox </​code>​
 +gestartet werden.
  
-===== Wifi-box - Grafisches ​konfigurieren ​des Drahtlosnetzwerks (SliTaz 4.0 and 5.0 Weekly) =====+===== Wifi-box - Grafisches ​Konfigurieren ​des Drahtlosnetzwerks (SliTaz 4.0 and 5.0 „rolling“) ===== 
 +<note important>​Ab SliTaz-4.0: \\ 
 +wifi-box wurde in wifibox umbenannt \\ 
 +SliTaz Panel -> Netzwerk -> Drahtlos-Netzwerk bietet dieselbe Funktionalität \\ 
 + 
 +Ab SliTaz-5.0 gibt es mit 
 +<​code>#​ slitaz-config 
 +   ​wifi-setup 
 +</​code>​ 
 +eine Konfigurationsanwendung mit ncurses als Oberfläche. 
 +</​note>​
  
-Wifi-box ​is small interface to configure a network connection ​(Wifi, WLAN, or Wireless). ​The '​Networks'​ tab displays a list of available networks, just double click on a network name to connectIf the network is securethe key will then be sought+Wifi-box ​ist eine kleine Anwendung zum Konfigurieren des Drahtlosnetzwerks ​(Wifi, WLAN, oder „Wireless). Der Reiter Netzwerke zeigt eine Liste erreichbarer Funknetzwerke. Mit einem Doppelklick auf den Netzwerknamen wird eine Verbindung aufgebautWenn das Netzwerk gesichert istwird der Schlüssel gesucht
  
 {{:​en:​handbook:​image:​wifibox.png}} {{:​en:​handbook:​image:​wifibox.png}}
  
-The '​Favorites'​ tab allows you to set your preferred networksOnce a network is added, just double click on the network name to connectThe '​Configuration'​ tab lets you configure a connection manually using the advanced settings such as the mode or channelThe '​Drivers'​ tab allows you to configure a network cardthere are 3 options:+Mit dem Reiter Favoriten können bevorzugte Netzwerkverbindungen gespeichert werdenMit einem Doppelklick auf den Namen einer gespeicherten Netzwerkverbindung wird eine Verbindung aufgebautMit dem Reiter Konfiguration kann eine Netzwerkverbindung manuell konfiguriert werden, wobei auch erweiterte Einstellungen wie Modus oder Kanal eingegeben werden könnenMit dem Reiter Treiber kann der Netzwerk-Adapter konfiguriert werdendazu gibt es drei Möglichkeiten:
  
-  -   The card is supported directly by the kernel via a module+  -   Der Netzwerk-Adapter wird vom Linux-Kern direkt durch einem Modul unterstützt
-  -   The card needs a module and non-free firmware that can be installed automatically via the auto-detect tool (tazhw)+  -   Der Netzwerk-Adapter benötigt einen Modul und nicht-freie Firmware, die automatisch mit //tazhw// installiert werden kann
-  -   The card is not supported by Linux and a Windows driver must be installed via the Windows driver manager ​(tazndis).+  -   Der Netzwerk-Adapter wird von Linux nicht unterstützt und es muss mit //tazndis// („Windows driver managerein Windows-Treiber installiert werden.
  
-You can start wifi-box ​via a terminal:+Wifi-box kann mit dem Kommando 
 +<​code>​ # wifi-box</​code>​ 
 +gestartet werden.
  
-<​code>​ # wifi-box</​code>​ 
 ===== /​etc/​hostname - Der Rechnername ===== ===== /​etc/​hostname - Der Rechnername =====
  
-The file ///​etc/​hostname// ​sets the machine nameThis is loaded at system startup with the command 'hostname', without an argument this command returns the current machine name: +In der Datei ///​etc/​hostname// ​wird der Rechnername festgelegtDaraus wird bei der Systemeinleitung mit dem Kommando //hostname// der Rechnername gesetzt. Das Kommando //​hostname//​ ohne Parameter zeigt den aktuellen Rechnernamen:
 <​code>​ $ hostname </​code>​ <​code>​ $ hostname </​code>​
  
-To change the hostnameyou can use the echo command or a text editor available on SliTaz ​(you must be root). Example using echo and the machine name kayam: +Der Rechnername kann geändert werdenindem z.B. mit dem Kommando //echo// oder mit einem Texteditor ein anderer Name in diese Datei geschrieben wird (das darf nur der Administrator). Im folgenden Beispiel wird mit dem Kommando //echo// der Rechnername 'kayam' eingetragen:
 <​code>​ # echo "​kayam"​ > /​etc/​hostname </​code>​ <​code>​ # echo "​kayam"​ > /​etc/​hostname </​code>​
  
 ===== /​etc/​network.conf ===== ===== /​etc/​network.conf =====
  
-///​etc/​network.conf// ​is the SliTaz ​system network configuration fileIt's syntax is simple and you can edit its contents with a text editor such as Nano. ///​etc/​network.conf// is used by the script ​///etc/init.d/network.sh// to configure the network interface at boot time.+Die Datei ///​etc/​network.conf// ​enthält bei SliTaz ​die Netzwerk-Konfiguration. Die Syntax ist einfach und die Datei kann mit einem Texteditor (z.B. Nano) bearbeitet werdenBei der Systemeinleitung greift die Kommandoprozedur ​///etc/init.d/network.sh// auf ///​etc/​network.conf// zu, um die Netzwerk-Adapter zu konfigurieren.
  
 ===== Dynamische IP-Adresse - DHCP-Klient udhcpc ===== ===== Dynamische IP-Adresse - DHCP-Klient udhcpc =====
  
-The DHCP client ​udhcpc ​supplied with Busybox uses the ///​usr/​share/​udhcpc/​default.script// ​to get an IP address dynamically at boot. It supports various options which you can view with the <​nowiki>​--help</nowiki> option: +Der in Busybox enthaltene ​DHCP-Klient ​udhcpc ​verwendet bei der Systemeinleitung ​///​usr/​share/​udhcpc/​default.script// ​um eine dynamische ​IP-Addresse zu erhalten. Die Optionen von //udhcpc/können mit
 <​code>​ # udhcpc --help </​code>​ <​code>​ # udhcpc --help </​code>​
 +angezeigt werden.
  
-To disable ​udhcpc ​on eth0 or modify the interface ​(eg eth1), ​you must edit the ///​etc/​network.conf// ​file and place the value "​no" ​in the variable DHCP=: +Um //udhcpc// für die Ethernet-Schnittstelle zu deaktivieren oder die Ethernet-Schnittstelle zu ändern ​(z.B. eth1), ​muss die Datei ///​etc/​network.conf// ​bearbeitet werden. Indem der Wert der Variablen DHCP auf "​no" ​gesetzt wird, wird //udhcpc// deaktiviert:
 <​file>​ <​file>​
 # Dynamische IP-Adresse. # Dynamische IP-Adresse.
-Enable/​disable ​DHCP client at boot time.+# DHCP-Klienten aktivieren (yes) oder deaktivieren (no).
 DHCP="​no"​ DHCP="​no"​
 </​file>​ </​file>​
Line 68: Line 75:
 ===== Statische IP-Adresse - Eine bestimmte Adresse verwenden ===== ===== Statische IP-Adresse - Eine bestimmte Adresse verwenden =====
  
-You can specify a fixed IP address to configure at boot time by using the value "​yes" ​in the variable STATIC=:+Damit immer eine bestimmte ​IP-Adresse verwendet wird, muss der Wert der Variablen STATIC auf "​yes" ​gesetzt werden:
  
 <​file>​ <​file>​
-Static ​IP address+Statische ​IP-Adresse
-Enable/​disable static ​IP at boot time.+Statische ​IP-Adresse aktivieren (yes) oder deaktivieren (no).
 STATIC="​yes"​ STATIC="​yes"​
 </​file>​ </​file>​
  
-For the configuration to work, you must specify an IP addressits subnet maskdefault gateway ​(gatewayand DNS server to useExample: +Zusätzlich muss natürlich eine IP-Adressedie Netzmaskeein Standard-Netzkoppler („default gatewayund ein DNS-Server angegeben werdenBeispiel:
- +
 <​file>​ <​file>​
-Set IP address, and netmask for a static ​IP.+statische ​IP-Adresse und Netzmaske.
 IP="​192.168.0.6"​ IP="​192.168.0.6"​
 NETMASK="​255.255.255.0"​ NETMASK="​255.255.255.0"​
  
-Set route gateway for a static IP.+Standard-Netzkoppler.
 GATEWAY="​192.168.0.1"​ GATEWAY="​192.168.0.1"​
  
-Set DNS server. for a static IP.+# DNS-Server.
 DNS_SERVER="​192.168.0.1"​ DNS_SERVER="​192.168.0.1"​
  
Line 93: Line 98:
  
 ===== Statische Routen ===== ===== Statische Routen =====
-Static routes can be added at any time via the route add command:+Statische Routen können jederzeit mit dem Kommando //route add// hinzugefügt werden:
  
 <​file>​ <​file>​
Line 99: Line 104:
 </​file>​ </​file>​
  
-The static route will remain active until the next reboot.  +Statische Routen bleiben bis zur Systembeendigung wirksam.  
-In order to make these routes persistentadd them to /​etc/​init.d/​local.sh+Wenn sie permanent wirksam sein sollenkönnen //​route//​-Kommandos in ///​etc/​init.d/​local.sh// eingefügt werden.
  
 +===== PPPoE-Verbindung =====
  
- +Um eine PPPoE-Verbindung ​von SliTaz aus aufzubauen, werden zwei Dateien benötigtDie erste Datei ist ///​etc/​ppp/​options//​, worin der Benutzername angegeben werden muss:
-===== PPPoE-Verbindung ​kernel-mode ===== +
- +
-PPPoE connection in kernel-mode needs 2 filesThe first file is ///​etc/​ppp/​options// ​where you must specify your login name:+
  
 <​file>​ <​file>​
 plugin rp-pppoe.so plugin rp-pppoe.so
-name <your_login>+name <benutzername>
 noipdefault noipdefault
 defaultroute defaultroute
Line 118: Line 121:
 </​file>​ </​file>​
  
-Now you have to configure ​///​etc/​ppp/​pap-secrets// ​or ///​etc/​ppp/​chap-secrets//:​ +Die zweite ist ///​etc/​ppp/​pap-secrets// ​oder ///​etc/​ppp/​chap-secrets//:​
  
 <​file>​ <​file>​
 # client  ​      ​server  ​      ​secret IP addresses # client  ​      ​server  ​      ​secret IP addresses
-"your_login" ​      ​* ​              "​your_password"+"<​benutzername>​" ​      ​* ​              "​<​kennwort>​"
 </​file>​ </​file>​
  
-The config file /​etc/​resolv.conf ​will be automatically loadedFinished, you can now connect to the internet with pppd:+Die Konfigurationsdatei ///​etc/​resolv.conf// wird automatisch geladenJetzt kann eine Internetverbindung mit //pppd// hergestellt werden:
  
 <​code>​ # pppd eth0  <​code>​ # pppd eth0 
 </​code>​ </​code>​
  
-On an installed system you can start pppd on each boot using the local startup script: ​///​etc/​init.d/​local.sh//​+Damit //pppd// bei jeder Systemeinleitung gestartet wird, kann das Kommando in ///​etc/​init.d/​local.sh// ​eingefügt werden.
  
-===== Ethernet ​PPPoE ADSL-Modem - PPPoE mit rp-pppoe ===== +===== PPPoE-Verbindung über ein ADSL-Modem - PPPoE mit rp-pppoe =====
- +
-This section is about setting up an ADSL Internet connection using an ethernet PPPoE modem in bridge mode. To set an ASDL protocol via PPPoE, SliTaz provides the utilities package //​rp-pppoe//​. Using pppoe-setup is a snap and you can quickly configure the network. If you use DCHP it's even easier, because the server from your ISP will take care of everything. If you do not have DHCP, you must first disable its use via DHCP="​no"​ in the configuration file ///​etc/​network.conf//​. It should be noted that to modify configuration files and system logs you must first become root. To install and change the variable DHCP with Nano (ctrl + X to save & exit):+
  
 +In diesem Abschnitt wird beschrieben,​ wie eine Internet-Verbindung über ein Ethernet-ADSL-PPPoE-Modem im „bridge mode“ konfiguriert werden kann. Dazu gibt es in SliTaz das Paket //​rp-pppoe//​. Mit //​pppoe-setup//​ kann die Verbindung schnell konfiguriert werden. Wenn DCHP verwendet wird, ist es noch einfacher, da auf Seite des Netzdienstanbieters für alles gesorgt wird. Wenn DHCP nicht verwendet werden soll, muss (vom Administrator) DHCP="​no"​ in der Konfigurationsdatei ///​etc/​network.conf//​ gesetzt werden. Mit den folgenden Kommandos wird //​rp-pppoe//​ installiert und die Konfigurationsdatei ///​etc/​network.conf//​ bearbeitet:
  
 <​code>​ <​code>​
Line 146: Line 147:
 === Konfigurieren mit pppoe-setup === === Konfigurieren mit pppoe-setup ===
  
-To begin to configure your PPPoE connection, you must first open an Xterm or Linux console and launch ​pppoe-setup ​and then begin to answer the following questions: +Eine PPPoE-Verbindung kann mit dem Kommando //pppoe-setup// konfiguriert werden, wobei die folgenden Fragen beantwortet werden müssen:
- +
 <​code> ​ # pppoe-setup ​ <​code> ​ # pppoe-setup ​
 </​code>​ </​code>​
  
-    -  Enter your usernameplease note that this is the username with which you communicate with your ISP+    - Benutzernamen eingeben (der Benutzernameden Ihr Netzdienstanbieter Ihnen gegeben hat)
-    - Internet interfacedefault is eth0 unless you have more than onein which case you will have eth1, eth2, etcUsually the Enter key is sufficient+    - NetzwerkschnittstelleStandard ist //eth0//oder wenn mehrere vorhanden sind: eth1, eth2, uswNormalerweise genügt es, die Enter-Taste zu drücken
-    - If you have a permanent ​ASDL link answer ​yes, otherwise answer ​no (default). +    - Wenn Sie eine permanente ​ASDL-Verbindung haben, geben Sie 'yes' einsonst 'no' ​(Standard). 
-    - Specify the primary and secondary ​DNS your ISP uses (you may have to ask). +    - Den primären und sekundären ​DNS-Server des Netzdienstanbieter angeben ​(muss dort eventuell erfragt werden). 
-    - Enter the password with which you communicate with your ISP (you need to enter it twice). +    - Kennwort eingeben ​(das Kennwort, das Ihr Netzdienstanbieter Ihnen gegeben hat), zweimal 
-    - Choose the firewall settings depending on your hardware. ​If you have a router ​you can enter or 2. If in doubt enter 1.+    - Die Einstellungen des Zugangsschutzsystems,​ abhängig von der hardware, angebenWenn Sie einen Vermittlungsknoten („router“) haben, können Sie oder eingeben, im Zweifel ​1.
  
 === Auf- und Abbauen der Verbindung === === Auf- und Abbauen der Verbindung ===
  
-Still using the command line, simply type pppoe-start ​to start the connectionA few seconds later the system tells you that it is connectedIf it gives you a message like TIMED OUT, you may have poorly configured or the connection is defectivePlease check the wiring and repeat the installation from the beginningTo start the connection:+Mit dem Kommando //pppoe-start// kann dann die Verbindung aufgebaut werdenKurz darauf wird der Verbindungsaufbau bestätigtWenn eine Meldung wie 'TIMED OUT' ausgegeben wirdist die Verbindung falsch konfiguriert oder nicht funktionsfähigPrüfen Sie die Verkabelung und wiederholen Sie die Installation von Anfang anVerbindungsaufbau:
  
 <​code>​ # pppoe-start <​code>​ # pppoe-start
 </​code>​ </​code>​
  
-To stop the connection, you can type:+Mit dem Kommando
 <​code>​ # pppoe-stop ​ <​code>​ # pppoe-stop ​
 </​code>​ </​code>​
 +kann die Verbindung wieder abgebaut werden.
  
-To check the connection status: +Mit dem Kommando
 <​code>#​ pppoe-status</​code>​ <​code>#​ pppoe-status</​code>​
 +kann der Verbindungszustand geprüft werden.
  
 ===== Treiber für eine Netzwerkschnittstelle installieren ===== ===== Treiber für eine Netzwerkschnittstelle installieren =====
  
-In case you need a network card driver and don't know the driver nameyou can use the command ​lspci to find your card and then modprobe ​to load a moduleIn Live mode you can use the SliTaz ​boot option ​modprobe=modules ​to automatically load Kernel modulesTo get a list of all available network card driversdisplay PCI eth cards and load a module: +Wenn Sie einen Treiber für einen Netzwerkadapter benötigenwissen aber seinen Namen nicht, so können Sie mit dem Kommando //lspci// den Netzwerkadapter ermitteln und dann mit dem Kommando //modprobe// einen Modul ladenIm „Live“-Modus kann bei der Systemeinleitung die SliTaz-Option //modprobe=modules// angegeben werden, um automatisch Module des Linux-Kerns zu ladenIm folgenden Beispiel werden alle vorhandenen Treiber für Netzwerkadapter angezeigtalle Ethernet-Netzwerkadapter aufgelistet und der Modul module_name geladen:
  
 <​code>​ <​code>​
Line 185: Line 184:
 </​code>​ </​code>​
  
-On an installed system you just need to add the module_name to the variable ​LOAD_MODULES in ///​etc/​rcS.conf// ​to load your module on each boot.+Soll ein Modul bei jeder Systemeinleitung geladen werden, so genügt es, seinen Namen der Variablen ​LOAD_MODULES in der Datei ///​etc/​rcS.conf// ​hinzuzufügen.
  
-===== Verwalten des Zugangsschutzsystems ​(firewall) using Iptables ​=====+===== Verwalten des Zugangsschutzsystems ===== 
 +<note important>​ 
 +Ab SliTaz-4.0: Statt /​etc/​firewall.conf wird /​etc/​slitaz/​firewall.conf verwendet\\ 
 +Die iptables-Regeln befinden sich jetzt in der Datei /​etc/​slitaz/​firewall.sh statt /​etc/​init.d/​firewall.sh \\ 
 +Siehe: http://​hg.slitaz.org/​slitaz-tools/​rev/​769 
 +</​note>​
  
-SliTaz ​provides a very basic firewallthe kernel security rules are launched at boot time and iptables ​rules are disabled by defaultYou can activate/​disable these at startup by using the configuration file ///​etc/​firewall.conf//​.+SliTaz ​bietet ein sehr einfaches Zugangsschutzsystem auf Basis von Regeln: Die Sicherheitsregeln des Linux-Kerns werden bei der Systemeinleitung aktiviertdie „iptables“-Regeln sind standardmäßig deaktiviertDurch Bearbeiten der Konfigurationsdatei ​///​etc/​firewall.conf// ​können letztere aktiviert oder deaktiviert werden.
  
-The default firewall script begins with its own set options for the Kernel ie. ICMP redirects, source routing, ​logs for unresolved addresses and spoof filtersThe script then launches the rules defined ​in the //​iptables_rules()// ​function of the configuration file: ///​etc/​firewall.conf//​.+Die Standard-Kommandoprozedur des Zugangsschutzsystems beginnt mit den Einstellungen für den Linux-Kern, d.h. ICMP-Umleitungensource routingProtokollierung nicht aufgelöster Adressen und „spoof“-FilterDann werden die Regeln ​in der Funktion ​//​iptables_rules()// ​aus der Konfigurationsdatei ​///​etc/​firewall.conf// ​aktiviert.
  
-The firewall uses Iptablesit consists of two files: ​///​etc/​firewall.conf// ​and ///​etc/​init.d/​firewall//, ​you shouldn'​t need to modify theseNote Iptables ​has lots of optionsFor more infomation see the official documentation available online: ​http://​www.netfilter.org/​documentation/​.+Das Zugangsschutzsystem verwendet //​iptables//​was aus den beiden Dateien ​///​etc/​firewall.conf// ​und ///​etc/​init.d/​firewall// ​bestehtdie nicht angepasst werden müssen. Iptables ​hat viele OptionenWeiterführende Informationen findet man bei [[http://​www.netfilter.org/​documentation/​]].
  
 === Starten, Beenden und Neustarten des Zugangsschutzsystems === === Starten, Beenden und Neustarten des Zugangsschutzsystems ===
  
-The script ​///​etc/​init.d/​firewall// ​lets you start/​restartstop or display the status of the firewallThe restart ​option is often used to test new rules after editing the configuration fileExample: +Mit der Kommandoprozedur ​///​etc/​init.d/​firewall// ​kann das Zugangsschutzsystem gestartetneu gestartet, oder angehalten sowie sein Zustand angezeigt werdenDie Option //restart// wird häufig benutzt, um neue Regeln nach Änderung der Konfigurationsdatei zu testenBeispiel:
  
 <​code>​ <​code>​
Line 204: Line 207:
 </​code>​ </​code>​
  
-=== Zugangsschutzsystems ​bei der Systemeinleitung aktivieren oder deaktivieren === +=== Zugangsschutzsystem ​bei der Systemeinleitung aktivieren oder deaktivieren ===
- +
-To enable/​disable options specific to the Kernel place "​yes"​ or "​no"​ in the variable KERNEL_SECURITY= :+
  
 +Durch Setzen des Wertes der Variablen KERNEL_SECURITY auf '​yes'​ oder '​no'​ werden die
 +Sicherheitsregeln des Linux-Kerns aktiviert oder deaktiviert:​
 <​file>​ <​file>​
-Enable/​disable kernel security at boot time.+Sicherheitsregeln des Linux-Kerns aktivieren:
 KERNEL_SECURITY="​yes"​ KERNEL_SECURITY="​yes"​
 </​file>​ </​file>​
  
-And to activate/​deactivate the iptables rules, it is necessary to modify the IPTABLES_RULES= variable : +Durch Setzen des Wertes der Variablen ​IPTABLES_RULES ​auf '​yes'​ oder '​no'​ werden die 
 +„iptables“-Regeln aktiviert oder deaktiviert:​
 <​file>​ <​file>​
-Enable/​disable ​iptables ​rules.+iptables“-Regeln aktivieren:
 IPTABLES_RULES="​yes"​ IPTABLES_RULES="​yes"​
 </​file>​ </​file>​
Line 222: Line 225:
 === Iptables-Regeln hinzufügen,​ ändern oder entfernen === === Iptables-Regeln hinzufügen,​ ändern oder entfernen ===
  
-At the bottom of the configuration file: ///​etc/​firewall.conf//​, you will find a function named: ​//​iptables_rules()//​. ​This function contains all of the //​iptables// ​commands to launch when the firewall startsTo delete a ruleIt is advisable to comment out the corresponding line with a #. It is not advisable to leave the function completely emptyif you want to disable the iptables ​rules just add //"​no"//​ to the variable ​//​IPTABLES_RULES=// in the configuration file.+Am Ende der Konfigurationsdatei ​///​etc/​firewall.conf// ​befindet sich die Funktion ​//​iptables_rules()//​. ​Diese Funktion enthält alle //​iptables//​-Kommandos, die beim Starten des Zugangsschutzsystems ausgeführt werden sollenEs empfiehlt sichRegeln die gelöscht werden sollen, durch ein Kommentarzeichen ​am Anfang der entsprechenden Zeile unwirksam zu machenEs ist nicht ratsamdie Funktion vollständig leer zu lassen; wenn alle „iptables“-Regeln deaktiviert werden sollen, ist es besser den Wert der Variablen ​//​IPTABLES_RULES//​ in der Konfigurationsdatei auf '​no'​ zu setzen.
  
-Here's an example of using iptables ​rulesIt only allows connections on the localhost ​and the local network, and ports 80, 22, and 21 used by the web server ​HTTP, the SSH secure server and FTP respectivelyAll other incoming and outgoing connections are refused, so it's fairly restrictive.+Es folgt ein Beispiel für „iptables“-RegelnEs werden nur Verbindungen von //localhost// und aus dem lokalen Netzwerk zugelassen sowie an den Ports 80, 22 und 21die beziehungsweise vom HTTP-Webserverdem SSH-Server und FTP benutzt werdenAlle anderen ein- und abgehenden Verbindungswünsche werden abgewiesen; die Einstellungen sind also ziemlich restriktiv.
  
 <​file>​ <​file>​
-# Netfilter/​iptables ​rules+# Netfilter/​iptables-Regeln
-This shell function is included ​in /​etc/​init.d/​firewall.sh +Diese Funktion ist in /​etc/​init.d/​firewall.sh ​enthalten 
-to start iptables ​rules.+um iptables-Regeln zu aktivieren.
 # #
 iptables_rules() iptables_rules()
 { {
  
-Drop all connections.+Alle Verbindungswünsche ablehnen.
 iptables -P INPUT DROP iptables -P INPUT DROP
 iptables -P OUTPUT DROP iptables -P OUTPUT DROP
  
-Accept all on localhost (127.0.0.1).+Alle Verbindungswünsche von und nach localhost (127.0.0.1) ​akzeptieren.
 iptables -A INPUT -i lo -j ACCEPT iptables -A INPUT -i lo -j ACCEPT
 iptables -A OUTPUT -o lo -j ACCEPT iptables -A OUTPUT -o lo -j ACCEPT
  
-Accept all on the local network (192.168.0.0/​24).+Alle Verbindungswünsche von und nach dem lokalen Netzwerk akzeptieren
 iptables -A INPUT -s 192.168.0.0/​24 -j ACCEPT iptables -A INPUT -s 192.168.0.0/​24 -j ACCEPT
 iptables -A OUTPUT -d 192.168.0.0/​24 -j ACCEPT iptables -A OUTPUT -d 192.168.0.0/​24 -j ACCEPT
  
-Accept port 80 for the HTTP server.+Alle Verbindungswünsche auf Port 80 akzeptieren
 iptables -A INPUT -i $INTERFACE -p tcp --sport 80 -j ACCEPT iptables -A INPUT -i $INTERFACE -p tcp --sport 80 -j ACCEPT
 iptables -A OUTPUT -o $INTERFACE -p tcp --dport 80 -j ACCEPT iptables -A OUTPUT -o $INTERFACE -p tcp --dport 80 -j ACCEPT
  
-Accept port 22 for SSH.+Alle Verbindungswünsche auf Port 22 akzeptieren
 iptables -A INPUT -i $INTERFACE -p tcp --dport 22 -j ACCEPT iptables -A INPUT -i $INTERFACE -p tcp --dport 22 -j ACCEPT
 iptables -A OUTPUT -o $INTERFACE -tcp --sport 22 -j ACCEPT iptables -A OUTPUT -o $INTERFACE -tcp --sport 22 -j ACCEPT
  
-Accept port 21 for active FTP connections.+Alle Verbindungswünsche auf Port 22 akzeptieren
 iptables -A INPUT -i $INTERFACE -p tcp --dport 21 -j ACCEPT iptables -A INPUT -i $INTERFACE -p tcp --dport 21 -j ACCEPT
 iptables -A OUTPUT -i $INTERFACE -p tcp --sport 21 -j ACCEPT iptables -A OUTPUT -i $INTERFACE -p tcp --sport 21 -j ACCEPT
 
de/handbook/networkconf.1478009078.txt.gz · Last modified: 2016/11/01 15:04 by hgt