From: Florian Westphal <fw@strlen.de>
To: Chen Gang <gang.chen@asianux.com>
Cc: Xue Ying <ying.xue0@gmail.com>,
David Miller <davem@davemloft.net>,
Shan Wei <shanwei88@gmail.com>,
Eric Dumazet <eric.dumazet@gmail.com>,
netdev <netdev@vger.kernel.org>
Subject: Re: [Suggestion] net/netfilter: strcpy for timeout->name
Date: Wed, 21 Nov 2012 12:39:01 +0100 [thread overview]
Message-ID: <20121121113901.GA25102@breakpoint.cc> (raw)
In-Reply-To: <50AB4386.3080603@asianux.com>
Chen Gang <gang.chen@asianux.com> wrote:
> Please help checking net/netfilter/nfnetlink_cttimeout.c:
> I suggest, we use strncpy instead of strcpy at line 143.
> just like we have already used strncmp at line 94.
[..]
> after checking the calling work flow:
> the length of nla_data(cda[CTA_TIMEOUT_NAME]) is not limited in server side.
Good catch, classic buffer overflow.
I've sent a patch to add the missing "len" policy. Thanks for reporting
this bug.
next prev parent reply other threads:[~2012-11-21 11:39 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2012-11-20 4:08 [Suggestion] net/tipc: can delete checking: (if_local_len > TIPC_MAX_IF_NAME) || (if_peer_len > TIPC_MAX_IF_NAME) Chen Gang
2012-11-20 5:19 ` Xue Ying
2012-11-20 5:25 ` Chen Gang
2012-11-20 8:47 ` [Suggestion] net/netfilter: strcpy for timeout->name Chen Gang
2012-11-21 11:39 ` Florian Westphal [this message]
2012-11-21 12:17 ` Chen Gang
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=20121121113901.GA25102@breakpoint.cc \
--to=fw@strlen.de \
--cc=davem@davemloft.net \
--cc=eric.dumazet@gmail.com \
--cc=gang.chen@asianux.com \
--cc=netdev@vger.kernel.org \
--cc=shanwei88@gmail.com \
--cc=ying.xue0@gmail.com \
/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;
as well as URLs for NNTP newsgroup(s).