Merhaba putty Baglantınızı Kurunuz
Komut Satırına :
Kod:
sysinstall

Ardından çıkan ekranda

Kod:
Configure

Kod:
Distributions
Kod:
sys
Ardından yukarı çıkıp exit diyoruz enterliyoruz.
Sonra tekrar exit diyoruz.
Gelen ekranda

Hepsini "Backspace" Tusu ile siliyoruz aşağidaki kodu yapiştirip enterliyoruz
Kod:
ftp://ftp-archive.freebsd.org/pub/Fr...86/7.2-RELEASE
Yükleme bittikten sonra tab tusu ile cancel gelip enterleyip cıkıyoruz.
Kod:
cd /boot/defaults && ee loader.conf
Bu Kodu yazıyoruz Bayaği bi aşağida ipfw_ 'leri göreceksiniz.
Kod:
ipfw_load"NO" #Firewall
Yazacaktir bunu buldugunuzda

Kod:
cd /usr/src/sys/i386/confcp PAE Memento ee Memento
Karsımıza bir sayfa gelecek yine
options PAE satırını bulun arasında bir bosluk bırakıp
Kod:
options IPFIREWALL # required for IPFW options IPFIREWALL_VERBOSE # optional; logging options IPFIREWALL_VERBOSE_LIMIT=10 # optional; don't get too many log entries options IPDIVERT # needed for natd
Yukarıdaki kodlarımızı yazıyoruz.
Ekledikten daha sonra su komutu giriyoruz
Kod:
config Memento
Kod:
cd ../compile/Memento
Kod:
make

# yani komut satırı geldikten sonra
Kod:
make install
Kod:
cd /usr/src/sys/i386/conf
Kod:
cp /boot/kernel.old/geom_* /boot/kernel
Kod:
ee /etc/rc.conf
Kod:
firewall_enable="YES"firewall_script="/etc/fw" firewall_type="OPEN"
Yazip ESC

Şimdi Kural

Kod:
ee /etc/ipfw
Kod:
IPF="ipfw -q add"ipfw -q -f flush #loopback #$IPF 1 deny tcp from any to me 11005 via em0 tcpflags syn,!fin $IPF 10 allow all from any to any via lo0 $IPF 20 deny all from any to 127.0.0.0/8 $IPF 30 deny all from 127.0.0.0/8 to any $IPF 40 deny tcp from any to any frag $IPF 42 deny all from any to me 12001 $IPF 42 deny all from any to me 14001 $IPF 42 deny all from any to me 14002 $IPF 42 deny all from any to me 14003 $IPF 42 deny all from any to me 14004 $IPF 42 deny all from any to me 14061 $IPF 42 deny all from any to me 17001 $IPF 42 deny all from any to me 17002 $IPF 42 deny all from any to me 17003 $IPF 42 deny all from any to me 17004 $IPF 42 deny all from any to me 17061 $IPF 42 deny all from any to me 14000 $IPF 42 deny all from any to me 17000 $IPF 42 deny all from any to me 14099 # statefull $IPF 50 check-state $IPF 60 allow tcp from any to any established $IPF 70 allow all from any to any out keep-state $IPF 80 deny icmp from any to any $IPF 81 allow tcp from any to any 1024-65000 keep-state $IPF 120 allow tcp from any to any 22 out $IPF 130 allow tcp from any to any 22 in $IPF 150 allow tcp from any to any 3306 in $IPF 170 deny udp from any to any 53 in $IPF 175 deny tcp from any to any 53 in $IPF 180 deny udp from any to any 53 out $IPF 185 deny tcp from any to any 53 out $IPF 198 deny tcp from any to any 25 in #ch1 ports $IPF 200 allow tcp from any to any 11002 in $IPF 210 allow tcp from any to any 11002 out $IPF 200 allow udp from any to any 11002 in $IPF 210 allow udp from any to any 11002 out $IPF 200 allow tcp from any to any 13000 in $IPF 210 allow tcp from any to any 13000 out $IPF 201 allow udp from any to any 13000 in $IPF 211 allow udp from any to any 13000 out $IPF 200 allow tcp from any to any 13001 in $IPF 210 allow tcp from any to any 13001 out $IPF 200 allow tcp from any to any 13002 in $IPF 210 allow tcp from any to any 13002 out $IPF 200 allow tcp from any to any 13003 in $IPF 210 allow tcp from any to any 13003 out $IPF 200 allow tcp from any to any 13004 in $IPF 210 allow tcp from any to any 13004 out $IPF 200 allow tcp from any to any 13061 in $IPF 210 allow tcp from any to any 13061 out $IPF 200 allow tcp from any to any 13099 in $IPF 210 allow tcp from any to any 13099 out #ch2 ports $IPF 200 allow tcp from any to any 16000 in $IPF 210 allow tcp from any to any 16000 out $IPF 201 allow udp from any to any 16000 in $IPF 211 allow udp from any to any 16000 out $IPF 200 allow tcp from any to any 16001 in $IPF 210 allow tcp from any to any 16001 out $IPF 200 allow tcp from any to any 16002 in $IPF 210 allow tcp from any to any 16002 out $IPF 200 allow tcp from any to any 16003 in $IPF 210 allow tcp from any to any 16003 out $IPF 200 allow tcp from any to any 16004 in $IPF 210 allow tcp from any to any 16004 out $IPF 200 allow tcp from any to any 16061 in $IPF 210 allow tcp from any to any 16061 out

Firewall

Kod:
/etc/rc.d/ipfw restart

Kod:
/etc/rc.d/ipfw stop
İp Ban atma komutunuz :
Kod:
/sbin/ipfw -q add banlanacakipadresi


Biraz Karışık Ama Ne Yapalım Bizde Bildiğimizi Anlatıyoruz
.gif)
Bir Teşekkürü Çok Görmeyin
0 yorum: