請教Linux L7-filter無法作用的問題



贊助商連結


coolcoco
2009-06-29, 01:47 AM
[root@test ~]# iptables -t mangle -I POSTROUTING -m layer7 --l7proto http -j DROP
/usr/local/libexec/xtables/libxt_layer7.so: /usr/local/libexec/xtables/libxt_layer7.so: undefined symbol: exit_error
iptables v1.4.4: Couldn't load match `layer7':/usr/local/libexec/xtables/libipt_layer7.so: cannot open shared object file: No such file or directory

Try `iptables -h' or 'iptables --help' for more information.


目前小弟的電腦kernel版本為2.6.28.9,iptables的版本為1.4.4

之前有上網去看了很多如何讓linux支援Layer7 filter的文章
(http://dekne.wordpress.com/2009/05/24/configuring-layer7-iptables-1-4-3-2-on-slackware-12-kernel-2-6-21/)
也照著上面的步驟完成了

但是就是找不到 libipt_layer7.so這個檔,怎麼樣都會出現上面的錯誤訊息

請教高手是否小弟在哪邊有出錯了?

贊助商連結


twu2
2009-06-29, 10:43 PM
1.4.4 的 exit_error() 改成 xtables_error() 了.
把 libxt_layer7.c 裡頭的 exit_error 都改成 xtables_error, 然後再重新編一次 iptables 來用就可以了.