public inbox for linux-xfs@vger.kernel.org
 help / color / mirror / Atom feed
From: Cong Wang <amwang@redhat.com>
To: Jan Kara <jack@suse.cz>
Cc: Andrew Morton <akpm@linux-foundation.org>,
	linux-kernel@vger.kernel.org, xfs@oss.sgi.com
Subject: Re: [Patch] quota: do not leak info to user-space
Date: Tue, 14 May 2013 13:33:29 +0800	[thread overview]
Message-ID: <1368509609.2507.8.camel@cr0> (raw)
In-Reply-To: <20130513101839.GE400@quack.suse.cz>

On Mon, 2013-05-13 at 12:18 +0200, Jan Kara wrote:
> On Mon 13-05-13 12:04:23, Jan Kara wrote:
> > On Fri 10-05-13 17:24:33, Cong Wang wrote:
> > > From: Cong Wang <amwang@redhat.com>
> > > 
> > > There is a hole in struct fs_quota_stat, so we have to
> > > zero the struct on stack before copying it to user-space.
> > > 
> > > Cc: Jan Kara <jack@suse.cz>
> > > Signed-off-by: Cong Wang <amwang@redhat.com>
> >   Good point. I've merged the patch.
>   Ah, now I've noticed that XFS (the only user of the callback you are
> fixing) is zeroing the structure on its own (xfs_qm_scall_getqstat). So
> there's no real problem. I'm somewhat wondering whether clearing the field
> in the place where you did it isn't more future-proof but usually we don't
> pass in prezeroed buffers so I've decided to leave things as they are.
> 

You are right. Thanks for looking into this!


_______________________________________________
xfs mailing list
xfs@oss.sgi.com
http://oss.sgi.com/mailman/listinfo/xfs

      reply	other threads:[~2013-05-14  5:33 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
     [not found] <1368177873-4819-1-git-send-email-amwang@redhat.com>
2013-05-13 10:04 ` [Patch] quota: do not leak info to user-space Jan Kara
2013-05-13 10:18   ` Jan Kara
2013-05-14  5:33     ` Cong Wang [this message]

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=1368509609.2507.8.camel@cr0 \
    --to=amwang@redhat.com \
    --cc=akpm@linux-foundation.org \
    --cc=jack@suse.cz \
    --cc=linux-kernel@vger.kernel.org \
    --cc=xfs@oss.sgi.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