VietNetwork.Vn

 


Tác giả Chủ đề: How to install and uninstall APF firewall  (Đã xem 1864 lần)

0 Thành viên và 1 Khách đang xem chủ đề.

admin

  • Administrator
  • Hero Member
  • *****
  • Bài viết: 628
  • Số Lần: +94/-0
    • http://vietnetwork.vn
How to install and uninstall APF firewall
« vào: Tháng Ba 13, 2011, 02:04:03 AM »
A firewall is a very good idea for a server. Though many people think that a firewall is instant protection that will do everything it really is not. A firewall will help prevent some things but it is not going to stop everything. It is just one piece of the security network that is being woven. I recommend advanced protection firewall (APF) by rfxnetworks.

APF will block unused outgoing and incoming ports. It can also be configured to use information from some block lists. The below port list will work for cPanel. For the other control panels you will need to add in the administration ports.

You are not allowed to view links. Register or Login

—–command—–
cd /usr/local/src
wget You are not allowed to view links. Register or Login
tar -zxf apf-current.tar.gz
cd apf-0.*
./install.sh
—–command—–

Now edit config file
—–command—–
pico -w /etc/apf/conf.apf
—–command—–

Scroll down to the “Common ingress (inbound) TCP ports section. At this point you need to find the correct configuration for your control panel.

—–cPanel —–
IG_TCP_CPORTS=”20,21,22,25,26,53,80,110,143,443,465,993,995,2082,2083,2086,2087,2095,2096″
IG_UDP_CPORTS=”21,53,873″

EGF=”1″
EG_TCP_CPORTS=”21,22,25,26,27,37,43,53,80,110,113,443,465,873,2089″
EG_UDP_CPORTS=”20,21,37,53,873″


—-Ensim —–
IG_TCP_CPORTS=”21,22,25,53,80,110,143,443,19638″
IG_UDP_CPORTS=”53″

EGF=”1″
EG_TCP_CPORTS=”21,22,25,53,80,110,443″
EG_UDP_CPORTS=”20,21,53″

—-Plesk —–

IG_TCP_CPORTS=”20,21,22,25,53,80,110,143,443,465,993,995,8443″
IG_UDP_CPORTS=”37,53,873″

EGF=”1″
EG_TCP_CPORTS=”20,21,22,25,53,37,43,80,113,443,465,873,5224″
EG_UDP_CPORTS=”53,873″


Save the file and start apf via.
—–command—–
apf -s
—–command—–

If everything still works then edit the config file and turn dev mode off. Make sure you can start a new ssh session before changing dev mode off. If you are kicked out you need to go back and look at what caused the problem!
DEVEL_MODE=”0″

Now restart APF
—–command—–
apf -r
—–command—–

Uninstall Apf Firewall :

/etc/init.d/iptables stop
rm -Rfv /etc/apf
rm -fv /etc/cron.daily/fw
chkconfig apf off
rm -fv /etc/init.d/apf

Nguồn: APF


vnnetwork

  • bạn
Re: How to install and uninstall APF firewall
« Trả lời #1 vào: Tháng Tư 17, 2013, 11:07:15 AM »
 @coilua


 

Related Topics

  Tiêu đề / Tác giả Trả lời Bài mới
1 Trả lời
1663 Lượt xem
Bài mới Tháng Bảy 05, 2012, 03:38:37 PM
gửi bởi server360
1 Trả lời
1793 Lượt xem
Bài mới Tháng Bảy 16, 2012, 08:28:31 AM
gửi bởi server360
0 Trả lời
1422 Lượt xem
Bài mới Tháng Chín 20, 2012, 11:27:56 AM
gửi bởi server360
0 Trả lời
382 Lượt xem
Bài mới Tháng Tư 08, 2018, 08:40:29 PM
gửi bởi server360
0 Trả lời
349 Lượt xem
Bài mới Tháng Tư 15, 2018, 12:47:50 PM
gửi bởi server360

Copyright © VietNetwork.Vn