[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <AANLkTimZgiYi3KE7DC8DMWEzgSx7+cUaOurEHSo864AP@mail.gmail.com>
Date: Thu, 2 Dec 2010 19:29:53 +0800
From: Changli Gao <xiaosuo@...il.com>
To: Eric Dumazet <eric.dumazet@...il.com>
Cc: David Miller <davem@...emloft.net>, hagen@...u.net,
wirelesser@...il.com, netdev@...r.kernel.org,
Dan Rosenberg <drosenberg@...curity.com>
Subject: Re: [PATCH net-next-2.6] filter: add a security check at install time
On Thu, Dec 2, 2010 at 7:15 PM, Eric Dumazet <eric.dumazet@...il.com> wrote:
>
> Their scratch memory is not on stack but part of the filter, so no
> security problem (You can only read previous values of scratch registers
> written by your own filter on handling a previous packet.)
>
The code I checked is the newest in SVN. The scratch memory is really on stack.
/*
* Execute the filter program starting at pc on the packet p
* wirelen is the length of the original packet
* buflen is the amount of data present
*/
u_int
bpf_filter(const struct bpf_insn *pc, u_char *p, u_int wirelen, u_int buflen)
{
u_int32_t A = 0, X = 0;
bpf_u_int32 k;
u_int32_t mem[BPF_MEMWORDS];
--
Regards,
Changli Gao(xiaosuo@...il.com)
--
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Powered by blists - more mailing lists