⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 firewall

📁 linux下桥接软件源码
💻
字号:
Bridging and firewalling------------------------It is possible to use bridging in combination with firewalling.  This isa blatant violation of the OSI model, but it's very useful, so we don'tcare.How do bridging and firewalling go together?  First of all, you need akernel patch against the 2.4 kernel to actually make firewalling bridgedpackets possible.  You need to apply this patch to your kernel and recompileit, or alternatively, download a pre-patched Red Hat 7.2 kernel RPM and usethat.  The patch and kernel RPM are located at:	http://bridge.sourceforge.net/devel/bridge-nf/Now if you boot with this kernel, you can use the regular iptablesfirewalling as if you were doing routing.  So, rules for forwarding areadded to the FORWARD chain, rules for input to the local machine areadded to the INPUT chain, etc.  Things will work like you expect them to.So a rule like	# iptables -A INPUT -i eth0 -j DROPwill drop all traffic coming from 'eth0', even if the interface the packetsare logically from is, say, 'br0'.Lennert Buytenhek, November 7th 2001<buytenh@gnu.org>--------------------------Bridge+firewalling with 2.2 kernels is also possible, but deprecated.  Iwould severely recommend against using a 2.2 kernel and ipchains for bridgefirewalling.  But if there's really a need, it's still possible.  Apply theextra firewalling patch available from the 'patches' section to youralready-patched-with-the-vanilla-bridge-patch 2.2 kernel, and recompile.  Nowif you boot this kernel, the bridging code will check each to-be-forwardedpacket against the ipchains chain which has the same name as the bridge. So..if a packet on eth0 is to be forwarded to eth1, and those interfaces areboth part of the bridge group br0, the bridging code will check the packetagainst the chain called 'br0'.  If the chain does not exist, the packet willbe forwarded. So if you want to do firewalling, you'll have to create thechain yourself. This is important!

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -