LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Newbie
User Name
Password
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!

Notices


Reply
  Search this Thread
Old 05-30-2009, 02:44 AM   #1
mervs00024
LQ Newbie
 
Registered: Jun 2008
Posts: 12

Rep: Reputation: 0
Squid


Hello,

CAn some one help how can I configure my squid?
My scenerio is this, I have a DSL connection at home and we are 10 users connectd to this connection with an ip of 192.168.1.xxx, some users are using P2P so our connection is getting slower, i decided to install centos to use it as a proxy to block th P2P downloading my centos ip is 192.168.1.xxx, my question is how can i block the P2P downloading using my centos system?


Thanks in advance...
 
Old 05-30-2009, 04:26 AM   #2
Samotnik
Member
 
Registered: Jun 2006
Location: Belarus
Distribution: Debian GNU/Linux testing/unstable
Posts: 471

Rep: Reputation: 40
Blocking p2p traffic is rather hard problem yet unsolved entirely. You can try to block all connections on non-standard ports with iptables, or use some modules matching packets depending on software, e.g. this or this one
 
Old 05-30-2009, 09:58 AM   #3
mervs00024
LQ Newbie
 
Registered: Jun 2008
Posts: 12

Original Poster
Rep: Reputation: 0
Thanks for the reply,If you don't mind how can make a simple iptables for my centos.
because i only wnat is to prohibit the other users for downloading.we are connected in ADSL router modem with wifi connection and iwant to prohibit them from my centos system.

Thanks.
 
Old 05-31-2009, 12:48 AM   #4
baig
Member
 
Registered: Nov 2008
Location: وادی ھنزہ
Distribution: Solaris 5.10, Debian Server 5.2, CentOS 5.6
Posts: 226
Blog Entries: 3

Rep: Reputation: 38
Have a look

Code:
http://easyfwgen.morizot.net/gen/
Cheers!!
 
Old 05-31-2009, 04:59 AM   #5
mervs00024
LQ Newbie
 
Registered: Jun 2008
Posts: 12

Original Poster
Rep: Reputation: 0
Thanks baig,
This could help me a lot.
Once question where should i put my iptable script, example myfirewall.sh

Thanks
 
Old 05-31-2009, 01:29 PM   #6
baig
Member
 
Registered: Nov 2008
Location: وادی ھنزہ
Distribution: Solaris 5.10, Debian Server 5.2, CentOS 5.6
Posts: 226
Blog Entries: 3

Rep: Reputation: 38
you may want to put it in

Code:
/etc/rc.local

or you may also put it in a corntab

corntab -e

@reboot /your/full/script/path



Cheers!!
 
Old 05-31-2009, 01:34 PM   #7
baig
Member
 
Registered: Nov 2008
Location: وادی ھنزہ
Distribution: Solaris 5.10, Debian Server 5.2, CentOS 5.6
Posts: 226
Blog Entries: 3

Rep: Reputation: 38
you may want to put it in

Code:
/etc/rc.local
(i don't remember full path to rc.local) but the place you are looking for is "rc.local" it may be in /etc. sorry am not on linux at this moment.

Code:
whereis rc.local
or you can put it as corn job..

Code:
corntab -e


Cheers!!
 
Old 05-31-2009, 01:39 PM   #8
emgee3
LQ Newbie
 
Registered: May 2009
Posts: 14

Rep: Reputation: 1
I've personally found Firehol http://firehol.sourceforge.net to be the easy, powerful iptables frontend. The nice thing about it is you can make a change to your firewall, test it and have it revert automatically if it doesn't do exactly what you want.

download the rpm, install with:
Code:
rpm -i firehol-1.273-rh7up.noarch.rpm
update the ipv4 address space:
Code:
/usr/share/doc/firehol-1.273/get-iana.sh
you can then edit the /etc/firehol.conf file to do what you want. If you only route the traffic you'd like to let through, web, e-mail, etc., that would handle a lot of your P2P problems.

enable firehol on startup:
Code:
chkconfig firehol on
Anyway, it's something you could look at.
 
Old 06-09-2009, 02:58 AM   #9
mervs00024
LQ Newbie
 
Registered: Jun 2008
Posts: 12

Original Poster
Rep: Reputation: 0
Thank you so much for all your support.
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off



Similar Threads
Thread Thread Starter Forum Replies Last Post
[SOLVED] Squid+DansGuardian not working properly. squid blocking sites that should be linuxlover.chaitanya Linux - Server 13 11-10-2014 11:34 AM
squid conf: squid failed when I type insert redirect_program /usr/bin/squidguard laxmantsharma Linux - Software 1 02-24-2009 07:02 AM
squid - limited time slot for accessing the internet via squid. shahg_shahg Linux - Server 1 09-20-2008 07:41 AM
Squid 2.6 Reverse Proxy from Squid(3128) to OrginServer(80) Not working rraj Linux - Server 0 06-06-2008 03:29 PM
squid conf: squid failed when I type insert redirect_program /usr/bin/squidguard Niceman2005 Linux - Software 1 11-24-2004 03:29 PM


All times are GMT -5. The time now is 12:15 PM.

Main Menu
Advertisement
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration