LinuxQuestions.org
Welcome to the most active Linux Forum on the web.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Security
User Name
Password
Linux - Security This forum is for all security related questions.
Questions, tips, system compromises, firewalls, etc. are all included here.

Notices

Reply
 
Search this Thread
Old 10-03-2005, 01:55 AM   #1
nkutty
Member
 
Registered: Aug 2005
Posts: 34

Rep: Reputation: 15
block some sites


Dear all

i wnat to block some websites like msn.com, microsoft.com hotmail.com.. like that

i want to stop or block using iptables can u give some sample example entry


thanks

nkutty
 
Old 10-03-2005, 04:15 AM   #2
nixcraft
Member
 
Registered: Nov 2004
Location: BIOS
Distribution: RHEL3.0, FreeBSD 5.x, Debian 3.x, Soaris x86 v10
Posts: 379

Rep: Reputation: 30
If you are using squid then it is quit easy to setup deny filter. Or you can use iptables.

First find out ip address of site such as hotmail.com
Code:
nslookup hotmail.com
Server:         203.145.xxx.xx
Address:        203.145.xxx.xx#53

Non-authoritative answer:
Name:   hotmail.com
Address: 64.4.33.7
Name:   hotmail.com
Address: 64.4.32.7
and use iptables to append rule to exisitng tables (better in script)
Code:
iptables -A OUTPUT -d 64.4.32.7 -j DROP
See for more example http://www.cyberciti.biz/nixcraft/vi...-outgoing.html
 
  


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
How to BLOCK SLEEZE SITES? saugato Linux - Security 3 02-11-2005 08:39 PM
Looking to block out certain webb sites HenchmenResourc Suse/Novell 1 12-02-2004 08:13 AM
allow certain sites and block rest all of them mcgrath Programming 1 11-24-2004 10:53 AM
Make MozillaFirebird block sites *not popup/ads* GT_Onizuka Linux - Software 4 11-02-2003 03:52 PM
how to block sites with squid.conf boakiba Linux - Networking 1 08-11-2003 05:45 AM


All times are GMT -5. The time now is 09:12 AM.

Main Menu
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
identi.ca: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration