All of lore.kernel.org
 help / color / mirror / Atom feed
* macro & iptables
@ 2005-08-31  3:55 Agung
  2005-08-31 11:29 ` /dev/rob0
  2005-09-08 21:08 ` Kenneth Kalmer
  0 siblings, 2 replies; 7+ messages in thread
From: Agung @ 2005-08-31  3:55 UTC (permalink / raw)
  To: netfilter

hi there,

is it possible using macro *like pf did* with iptables
?? while i'm googling i found nothing about this, any
suggestion ?? :-)


regards,
Agung

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


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

* Re: macro & iptables
  2005-08-31  3:55 macro & iptables Agung
@ 2005-08-31 11:29 ` /dev/rob0
  2005-08-31 14:13   ` Agung
  2005-09-08 21:08 ` Kenneth Kalmer
  1 sibling, 1 reply; 7+ messages in thread
From: /dev/rob0 @ 2005-08-31 11:29 UTC (permalink / raw)
  To: netfilter

On Tuesday 2005-August-30 22:55, Agung wrote:
> is it possible using macro *like pf did* with iptables

Since I don't know pf, you should explain more about what you want. No, 
I don't think iptables has any built-in macro capabilities, but you can 
use shell (or other) scripts to generate your rules. A script could 
either run all the iptables(8) commands in order, or it could generate 
iptables-save(8) format rules to be piped to iptables-restore(8) stdin.

> ?? while i'm googling i found nothing about this, any
> suggestion ?? :-)

Don't assume everyone else knows what your examples mean. Give detail.

Stick with pf if you know it and are comfortable.
-- 
    mail to this address is discarded unless "/dev/rob0"
    or "not-spam" is in Subject: header


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

* Re: macro & iptables
  2005-08-31 11:29 ` /dev/rob0
@ 2005-08-31 14:13   ` Agung
  2005-08-31 14:23     ` /dev/rob0
       [not found]     ` <65aa6af905083107354ca663e0@mail.gmail.com>
  0 siblings, 2 replies; 7+ messages in thread
From: Agung @ 2005-08-31 14:13 UTC (permalink / raw)
  To: netfilter

let say... i have lists of ip in /etc/iplist.txt
is it possible to call that list, like perhaps in pf
table <ip> persist file "/etc/iplist.txt" ?
or i should use some bash scripting ?
thank you for your assistance :-)


		
____________________________________________________
Start your day with Yahoo! - make it your home page 
http://www.yahoo.com/r/hs 
 


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

* Re: macro & iptables
  2005-08-31 14:13   ` Agung
@ 2005-08-31 14:23     ` /dev/rob0
       [not found]     ` <65aa6af905083107354ca663e0@mail.gmail.com>
  1 sibling, 0 replies; 7+ messages in thread
From: /dev/rob0 @ 2005-08-31 14:23 UTC (permalink / raw)
  To: netfilter

On Wednesday 2005-August-31 09:13, Agung wrote:
> let say... i have lists of ip in /etc/iplist.txt
> is it possible to call that list, like perhaps in pf
> table <ip> persist file "/etc/iplist.txt" ?

Not to my knowledge. I don't think that design is as robust. iptables 
works entirely in the kernel memory. You can actually crash the OS, but 
the netfilter code will continue passing packets.

> or i should use some bash scripting ?

Yes:
#OPTIONS and TARGET must be set
while read IP ; do
    iptables $OPTIONS $IP $TARGET
done < /etc/iplist.txt

> thank you for your assistance :-)

np
-- 
    mail to this address is discarded unless "/dev/rob0"
    or "not-spam" is in Subject: header


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

* Fwd: macro & iptables
       [not found]     ` <65aa6af905083107354ca663e0@mail.gmail.com>
@ 2005-08-31 14:35       ` Edmundo Carmona
  2005-09-01  3:13         ` Agung
  0 siblings, 1 reply; 7+ messages in thread
From: Edmundo Carmona @ 2005-08-31 14:35 UTC (permalink / raw)
  To: netfilter

you have a list of IPs? say, for example, you want to accept those IPs
for input (one IP per line). I guess this will work:

cat /etc/iplist.txt | while read anIP; do
    iptables -A INPUT -s $anIP -j ACCEPT
done;

On 8/31/05, Agung <duppeh@yahoo.com> wrote:
> let say... i have lists of ip in /etc/iplist.txt
> is it possible to call that list, like perhaps in pf
> table <ip> persist file "/etc/iplist.txt" ?
> or i should use some bash scripting ?
> thank you for your assistance :-)
>
>
>
> ____________________________________________________
> Start your day with Yahoo! - make it your home page
> http://www.yahoo.com/r/hs
>
>
>


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

* Re: Fwd: macro & iptables
  2005-08-31 14:35       ` Fwd: " Edmundo Carmona
@ 2005-09-01  3:13         ` Agung
  0 siblings, 0 replies; 7+ messages in thread
From: Agung @ 2005-09-01  3:13 UTC (permalink / raw)
  To: netfilter



thank you for your help mr edmoundo & mr rob, it's
help me so much :-) 

__________________________________________________
Do You Yahoo!?
Tired of spam?  Yahoo! Mail has the best spam protection around 
http://mail.yahoo.com 


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

* Re: macro & iptables
  2005-08-31  3:55 macro & iptables Agung
  2005-08-31 11:29 ` /dev/rob0
@ 2005-09-08 21:08 ` Kenneth Kalmer
  1 sibling, 0 replies; 7+ messages in thread
From: Kenneth Kalmer @ 2005-09-08 21:08 UTC (permalink / raw)
  To: Agung; +Cc: netfilter

Agung, Edmundo & Rob

I know the question has been answered but I've got the urge to add my
2c as well.

As a quick background, I've used iptables for several months now and
am quite comfortable in my abilities. This list has helped me a lot,
even just by reading the majority of the posts every day.

I'm learning pf now, been using it for a couple of days only. The
differences between iptables and pf are quite significant. In the past
couple of days if really learned to love pf, over iptables, exactly
for reasons like it's macros and ease of configuration.

For an experiment I tried replacing a very reliable iptables firewall
on a DSL connection with a pf one, and man did I have troubles.

So where pf is easier to configure, with gimmicks like macros and
lists, iptables has unbelievable flexibility even though it is only
executed command by command.

I must admit that I have my own shell scripts that make configuring an
iptables firewall 10 times easier and quicker than a pf one, but yet I
know iptables way better than pf.

Stick to what you know and are comfortable with. Never risk security
for nice features. Both applications are world class, and netfilter
has excellent support!

HTH to clear the air a bit...

Enjoy the weekend

On 8/31/05, Agung <duppeh@yahoo.com> wrote:
> hi there,
> 
> is it possible using macro *like pf did* with iptables
> ?? while i'm googling i found nothing about this, any
> suggestion ?? :-)
> 
> 
> regards,
> Agung
> 
> __________________________________________________
> Do You Yahoo!?
> Tired of spam?  Yahoo! Mail has the best spam protection around
> http://mail.yahoo.com
> 
> 


-- 

Kenneth Kalmer
kenneth.kalmer@gmail.com

Folding@home stats
http://vspx27.stanford.edu/cgi-bin/main.py?qtype=userpage&username=kenneth%2Ekalmer


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

end of thread, other threads:[~2005-09-08 21:08 UTC | newest]

Thread overview: 7+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-08-31  3:55 macro & iptables Agung
2005-08-31 11:29 ` /dev/rob0
2005-08-31 14:13   ` Agung
2005-08-31 14:23     ` /dev/rob0
     [not found]     ` <65aa6af905083107354ca663e0@mail.gmail.com>
2005-08-31 14:35       ` Fwd: " Edmundo Carmona
2005-09-01  3:13         ` Agung
2005-09-08 21:08 ` Kenneth Kalmer

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.