UbuntuHelp:Firewall
来自Ubuntu中文
点击翻译: |
English |
请不要直接编辑翻译本页,本页将定期与来源同步。 |
目录
Introduction
The Linux kernel includes the netfilter
subsystem, which is used to manipulate or decide the fate of network traffic headed into or through your server or desktop system. All modern Linux firewall solutions use this system for packet filtering.
The kernel's packet filtering system would be of little use to administrators without a userspace interface to manage it. This is the purpose of iptables
. When a packet reaches your server, it will be handed off to the netfilter
subsystem for acceptance, manipulation, or rejection based on the rules supplied to it from userspace via iptables
. Thus, iptables
is all you need to manage your firewall if you're familiar with it, but many frontends are available to simplify the task.
The upshot of all this is that users can configure the firewall to allow certain types of network traffic to pass into and out of a system (for instance SSH or web server traffic). This is done by opening and closing TCP and UDP ports in the firewall, and can be configured in more detail by restricting access to specific IPs or IP address ranges. Read on for options about managing the firewall.
Managing the Firewall
Here are your options for manipulating the firewall in Ubuntu. Each program has its own wiki page describing how to install and configure it.
iptables
Iptables is the traditional interface for configuring the firewall in Linux operating systems, as explained above. All configuration is performed from the terminal.
Uncomplicated Firewall
UFW (Uncomplicated Firewall) is a frontend for iptables and is particularly well-suited for host-based firewalls. UFW was developed specifically for Ubuntu (but is available in other distributions), and is also configured from the terminal. Gufw is a graphical frontend to UFW, and is recommended for beginners. UFW was introduced in Ubuntu 8.04 LTS (Hardy Heron), and is available by default in all Ubuntu installations after 8.04 LTS.
Firestarter
Firestarter is a popular graphical frontend for configuring iptables in Linux systems, however it is no longer actively maintained. Please note that it conflicts with ufw.
See Also
Other:
- DynamicFirewall
- firewall/ipkungfu
- firewall/Linux_UPnP_Internet_Gateway_Device_(linux-idg)
- Router/Firewall
External Links
- http://en.wikipedia.org/wiki/Firewall
- http://www.netfilter.org/ - Netfilter and iptables homepage
- http://www.fs-security.com/ - Firestarter homepage
- UbuntuWiki:UbuntuFirewall - Uncomplicated Firewall homepage