From: Rob Carlson <rcarlson@kitchenandassociates.com>
To: Jozsef Kadlecsik <kadlec@blackhole.kfki.hu>
Cc: Netfilter User Mailing List <netfilter@lists.netfilter.org>
Subject: Re: IPset ports question.
Date: Tue, 19 Jul 2005 16:58:15 -0400 [thread overview]
Message-ID: <42DD6967.3050700@kitchenandassociates.com> (raw)
In-Reply-To: <Pine.LNX.4.58.0507192204230.24449@blackhole.kfki.hu>
That did it.
Thanks again, Joszef
Jozsef Kadlecsik wrote:
> Hi Rob,
>
> On Tue, 19 Jul 2005, Rob Carlson wrote:
>
>
>>iptables -A testset -m set --set testset src -j
>>LTREJECT
>>iptables -I FORWARD 2 -i eth1 -j testset
>>iptables -I INPUT 2 -i eth1 -j testset
>>
>>This works fine for blocking all traffic. However
>>since I now want specifically to only drop port 22
>>and port 25 entries (that is most of the nuisance
>>traffic) and allow port 80 for example, I did the
>>following:
>>
>>ipset -N ports portmap --from 1 --to 1024
>>ipset -A ports 22
>>ipset -A ports 25
>>ipset -B testset :default: -b ports
>
>
> You missed to replace the iptables command above with the one
> which instruct the SET target to follow bindings. What you need is
>
> iptables -A testset -m set --set testset src,dst -j LTREJECT
>
> Best regards,
> Jozsef
> -
> E-mail : kadlec@blackhole.kfki.hu, kadlec@sunserv.kfki.hu
> PGP key : http://www.kfki.hu/~kadlec/pgp_public_key.txt
> Address : KFKI Research Institute for Particle and Nuclear Physics
> H-1525 Budapest 114, POB. 49, Hungary
>
>
--
Rob Carlson, Systems and Network Administrator
Kitchen & Associates Architectural Services, PA
Architecture - Planning - Interior Design
856.854.1880
prev parent reply other threads:[~2005-07-19 20:58 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2005-07-18 18:42 IPset ports question Rob Carlson
2005-07-19 8:42 ` Jozsef Kadlecsik
2005-07-19 19:13 ` Rob Carlson
2005-07-19 20:09 ` Jozsef Kadlecsik
2005-07-19 20:58 ` Rob Carlson [this message]
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=42DD6967.3050700@kitchenandassociates.com \
--to=rcarlson@kitchenandassociates.com \
--cc=kadlec@blackhole.kfki.hu \
--cc=netfilter@lists.netfilter.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.