[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: Looking for a mentor for 'arno-iptables-firewall' package



Joost van Baal wrote on 14/09/2005 10:56:
> On Thu, Aug 25, 2005 at 05:11:03PM +0200, Michael Hanke wrote:
> 
>>I would like someone to have a look at it:
>>http://apsy.gse.uni-magdeburg.de/~hanke/mentors
> 
> debian-mentors readers: I am looking at it know.  The package is marked
> as such on http://sponsors.debian.net/ .
> 
>>There is one open issue. To actually setup the firewall one has to set
>>the name of the external interface. Therefore it would be nice if a
>>list of interfaces could be generated and displayed through debconf,
>>but I don't know how to do it.
> 
> The only thing I can come up with is: parse the
> 
>  ip -o link show
> 
> output.  You'd have to depend upon iproute for this, of course.

Why not use "ifconfig -a"? On all my systems, it seems to work OK:

ifconfig -a | grep Link\ encap \
| sed -e 's/[       ][      ]*Link.*//;s/:[0-9]*//' \
| sort -u

The sed line removes the "Link encap" and hwaddr stuff and subsequently
removes :[0-9]* tails from alias interfaces. Since that could list
interfaces which have aliases more than once, the sort -u is used.

I'm assuming here that you wouldn't want to use an alias interface as
the name of the external interface...

cu,
sven



Reply to: