lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  PHC 
Open Source and information security mailing list archives
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Date:	Tue, 13 Mar 2012 02:15:29 -0400
From:	Bill Fink <>
To:	Stephen Hemminger <>
Cc:	Diego Woitasen <>,
Subject: Re: ip route show shows the routes in the inverse order?

On Mon, 12 Mar 2012, Stephen Hemminger wrote:

> On Mon, 12 Mar 2012 22:18:48 -0300
> Diego Woitasen <> wrote:
> > Hi,
> >  I've noticed that iproute and the old route command show the routes
> > in the inverse order. This new behavior looks related to the removal
> > of fib_hash (replaceed by fib_trie). I think that the old behavior
> > should be recovered. More specific routes in the first place looks
> > more natural for me and it's been the behavior for years. It doesn't
> > make any sense to change it.
> > 
> >  Sorry if this was already discussed, I couldn't find anything in the archives.
> > 
> > Regards,
> >  Diego
> > 
> The kerne never guaranteed any order in returned values. If you want a given
> order than you need to sort them your self.

I understand the kernel doesn't guarantee any order to the routes.
But it does make sense for the userspace tools like ip to do this
for the user since the kernel is no longer doing this.  And having
more specific routes first also makes sense.  Some scripts may depend
on this plus its much more efficent that way if trying to find a
matching route since you can quit on the first match instead of
having to scan the entire routing table.

To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to
More majordomo info at

Powered by blists - more mailing lists