Linux Netfilter discussions
 help / color / mirror / Atom feed
* RE: Hosts.Deny Question??
@ 2002-09-12 12:55 Niall Murphy
  0 siblings, 0 replies; 7+ messages in thread
From: Niall Murphy @ 2002-09-12 12:55 UTC (permalink / raw)
  To: 'Antony Stone', netfilter

just what i needed
thanx
niall :-)

-----Original Message-----
From: Antony Stone [mailto:Antony@Soft-Solutions.co.uk]
Sent: Thursday, September 12, 2002 12:53 PM
To: netfilter@lists.netfilter.org
Subject: Re: Hosts.Deny Question??


On Thursday 12 September 2002 12:38 pm, Niall Murphy wrote:

> Hi All,
> i want to use hosts.deny to block emails and ip's to my email
> server..sounds easy but i cant seem to get it to work
> do i just need to add the emails or ip's to the host.deny and then add a
> rule to my script

Why not do it with netfilter ? (after all, that's what this list is about
:-)

iptables -A FORWARD -s a.b.c.d -d w.x.y.z -p tcp --dport 25 -j DROP

where a.b.c.d is the remote IP address you want to block (repeat this rule 
for as many addresses as you want to exclude) and w.x.y.z is the IP address 
of your mail server.

Make sure this rule comes before any rule which allows general access to
your 
mail server from the outside world.

You won't be able to use either netfilter or hosts.deny to block actual
email 
addresses - you'd have to do that in your mail server itself.

Antony.

-- 

Having been asked to provide a reference for this man,
I can confidently state that you will be very lucky indeed
if you can get him to work for you.


^ permalink raw reply	[flat|nested] 7+ messages in thread
* Hosts.Deny Question??
@ 2002-09-12 11:38 Niall Murphy
  2002-09-12 11:53 ` Antony Stone
  2002-09-12 12:48 ` Ferry van Steen
  0 siblings, 2 replies; 7+ messages in thread
From: Niall Murphy @ 2002-09-12 11:38 UTC (permalink / raw)
  To: netfilter

Hi All,
i want to use hosts.deny to block emails and ip's to my email server..sounds
easy but i cant seem to get it to work
do i just need to add the emails or ip's to the host.deny and then add a
rule to my script
could some one please explain and maybe give me the rule
thanx in advance
niall


^ permalink raw reply	[flat|nested] 7+ messages in thread

end of thread, other threads:[~2002-09-12 13:16 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
     [not found] <9AB58396B028D411B2110050040C7AD801910D77@pc213-104.indigo.ie>
2002-09-12 13:01 ` Hosts.Deny Question?? Ferry van Steen
2002-09-12 13:11 ` Ferry van Steen
2002-09-12 13:16   ` Antony Stone
2002-09-12 12:55 Niall Murphy
  -- strict thread matches above, loose matches on Subject: below --
2002-09-12 11:38 Niall Murphy
2002-09-12 11:53 ` Antony Stone
2002-09-12 12:48 ` Ferry van Steen

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox