public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Cyrill Gorcunov <gorcunov@gmail.com>
To: David Wagner <daw-news@cs.berkeley.edu>, linux-kernel@vger.kernel.org
Subject: Re: buffer overflow in /proc/sys/sunrpc/transports
Date: Sun, 31 Aug 2008 14:37:33 +0400	[thread overview]
Message-ID: <20080831103733.GG7391@lenovo> (raw)
In-Reply-To: <20080831103026.GF7391@lenovo>

[Cyrill Gorcunov - Sun, Aug 31, 2008 at 02:30:26PM +0400]
...
| 
| | 
| | 2. Is it OK to dereference *lenp directly?  Is lenp a pointer into user
| | memory or kernel memory?  If it points to user memory, why is it safe to
| | dereference it directly?  (What about TOCTTOU bugs?)  Should there be
| | some sparse annotations here to ensure the code is not dereferencing
| | user pointers directly?  Later on, proc_do_xprt() also dereferences
| | *lenp and *ppos directly.

on second view: will check for TOCTTOU bug (iirc vfs layer does
latch file descriptor for these kind of operations)

| 
| Not only proc_do_xprt do that so I think it's safe (check for NULL
| on highr level I suspect).
| 
...

		- Cyrill -

  reply	other threads:[~2008-08-31 10:37 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-08-30 18:44 buffer overflow in /proc/sys/sunrpc/transports Vegard Nossum
2008-08-30 19:06 ` Cyrill Gorcunov
2008-08-30 19:15   ` Vegard Nossum
2008-08-30 19:21     ` Cyrill Gorcunov
2008-08-30 19:23       ` Cyrill Gorcunov
2008-08-30 19:34       ` Vegard Nossum
2008-08-30 19:44         ` Cyrill Gorcunov
2008-08-30 19:42   ` Vegard Nossum
2008-08-30 19:45     ` Cyrill Gorcunov
2008-08-30 19:56     ` Cyrill Gorcunov
2008-08-30 19:59       ` Vegard Nossum
2008-08-30 20:04         ` Cyrill Gorcunov
2008-08-30 20:13           ` Vegard Nossum
2008-08-30 20:15             ` Cyrill Gorcunov
2008-08-30 20:29             ` Cyrill Gorcunov
2008-08-30 22:55   ` David Wagner
2008-08-31  8:37     ` Cyrill Gorcunov
2008-08-31 10:30     ` Cyrill Gorcunov
2008-08-31 10:37       ` Cyrill Gorcunov [this message]
2008-08-30 20:20 ` David Wagner

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=20080831103733.GG7391@lenovo \
    --to=gorcunov@gmail.com \
    --cc=daw-news@cs.berkeley.edu \
    --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