From: Eric Dumazet <eric.dumazet@gmail.com>
To: Jeffrey Merkey <jeffmerkey@gmail.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: Question about SIOCGIFCONF
Date: Fri, 28 May 2010 22:06:13 +0200 [thread overview]
Message-ID: <1275077173.2472.3.camel@edumazet-laptop> (raw)
In-Reply-To: <AANLkTin5RRIrSwenr1wCuJlEvydVD9_d3U2ZLitSXigs@mail.gmail.com>
Le vendredi 28 mai 2010 à 13:05 -0600, Jeffrey Merkey a écrit :
> The code in question is net-tools/lib/interface.c function
> if_readproc() and associated routines. Looks like a hole.
>
> Jeff
>
> On Fri, May 28, 2010 at 1:02 PM, Jeffrey Merkey <jeffmerkey@gmail.com> wrote:
> > Review of the net-tools source code for IFCONFIG indicates that when
> > /proc is not loaded and/or /proc/net/dev is not available, IFCONFIG
> > will attempt to use this ioctl to determine which interfaces are
> > present in the system. Since the ioctl will not report unbound
> > interfaces which are active, IFCONFIG will not properly report or
> > detect network adapters which are unbound. This seems to be a hole,
> > although most of the time I assume /proc will always be mounted.
> > Someone should review this and make a decision as to whether or not
> > this could be a problem. At any rate, it does not work as advertised.
> >
Maybe you could forget about a 20 years old legacy program and use the
real thing : ip
ip link
ip addr
...
Alternatively, you could rewrite ifconfig to use modern API.
(Not depending on /proc , at all)
next prev parent reply other threads:[~2010-05-28 20:06 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-05-28 3:02 Jeffrey Merkey
2010-05-28 4:57 ` Eric Dumazet
2010-05-28 9:22 ` Steven Whitehouse
2010-05-28 18:31 ` Jeffrey Merkey
2010-05-28 19:02 ` Jeffrey Merkey
2010-05-28 19:05 ` Jeffrey Merkey
2010-05-28 20:06 ` Eric Dumazet [this message]
[not found] ` <AANLkTimg3iNFVcV7AWSc0MPoW7UwunwSdH4NNIxl_w-P@mail.gmail.com>
2010-05-28 22:00 ` Fwd: " Jeffrey Merkey
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=1275077173.2472.3.camel@edumazet-laptop \
--to=eric.dumazet@gmail.com \
--cc=jeffmerkey@gmail.com \
--cc=linux-kernel@vger.kernel.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®