Re: [Linux-guvenlik] IP tables dan msn kısıtlaması

---------

New Message Reply About this list Date view Thread view Subject view Author view Attachment view

From: mutluerdal@netscape.net
Date: Fri 23 Jun 2006 - 10:20:04 GMT


----Original Message-----
From: mustafa ozturk <mustafaozturk82@yahoo.com>
To: linux-guvenlik@liste.linux.org.tr
Sent: Fri, 23 Jun 2006 00:18:39 -0700 (PDT)
Subject: [Linux-guvenlik] IP tables dan msn kısıtlaması

  Herkese selamlar.
Firmamdaki sistemimde Slackware 10.1 yuklu ve bu Linux server uzerinden
Nat yaparak kullanıcılarımı internete cikariyorum. Bu aralar msn
messenger cok fazla kullanılmaya baslandigi icin benden messenger larin
kisitlanmasi istendi. iptables dan bunu nasil yapabilirim.

Konfigurasyon Asagidaki Gibidir.

 IFCONFIG
eth0 Link encap:Ethernet HWaddr 00:50:04:BD:1D:A7
 inet addr:10.0.1.22 Bcast:10.0.1.255 Mask:255.255.255.0
 UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
 RX packets:1022697 errors:0 dropped:0 overruns:0 frame:0
 TX packets:903591 errors:0 dropped:0 overruns:0 carrier:1
 collisions:0 txqueuelen:1000
 RX bytes:1028707616 (981.0 Mb) TX bytes:105560608 (100.6 Mb)
 Interrupt:9 Base address:0x2000

eth1 Link encap:Ethernet HWaddr 00:0D:60:A7:CD:08
 inet addr:192.168.16.253 Bcast:192.168.16.255 Mask:255.255.255.0
 UP BROADCAST RUNNING MULTICAST MTU:1500 Metric:1
 RX packets:940748 errors:0 dropped:0 overruns:0 frame:0
 TX packets:1031657 errors:0 dropped:0 overruns:0 carrier:0
 collisions:0 txqueuelen:1000
 RX bytes:111271373 (106.1 Mb) TX bytes:1028519224 (980.8 Mb)
 Interrupt:3 Base address:0x2000

RC.LOCAL
# /etc/rc.d/rc.local: Local system initialization script.
 echo 1 /prog/sys/net/ipv4/ip_forward
 iptables -t nat -A POSTROUTING -o eth0 -j MASQUERADE
 ifconfig eth1 192.168.16.253
# Put any local setup commands in here:

  Kolay Gelsin
 www.netpro.com.tr

Merhaba,

oncelikle MSN messanger in nasil kullanildigina bakmak gerek. Bildigim
kadariyla messanger mesajlasmak icin tcp 1863 kullaniyor, ama ayni
zamanda
80'i de kullanabilir.

1863 porta giden TCP trafigini durdurmak icin:

iptables --table filter --append FORWARD --in-interface ic_eth
--out-interface dis_eth --protocol tcp --dport 1863 --jump LOG
--log-prefix "LFW 1863:"
iptables --table filter --append FORWARD --in-interface ic_eth
--out-interface dis_eth --protocol tcp --dport 1863 --jump DROP

Yukarida ic_eth ve dis_eth yerine uygun dusen eth0 ve eth1 leri
yerlestirmeniz gerek. Ilk komut izin vermedigi paketleri sistem
cetele(log) dosyasina
yazacak, ikincisi de paketleri yok edecek.

80'i port icin ise, HTTP proxy kullanmanizi oneririm.

Sevgi ve saygilarimla.
Erdal Mutlu

_______________________________________________
Linux-guvenlik mailing list
Linux-guvenlik@liste.linux.org.tr
http://liste.linux.org.tr/mailman/listinfo/linux-guvenlik


New Message Reply About this list Date view Thread view Subject view Author view Attachment view

---------

Bu arsiv hypermail 2.1.2 tarafindan uretilmistir.