lists.openwall.net   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  linux-hardening  linux-cve-announce  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, 14 Nov 2017 10:24:30 +0100
From:   Jan Kara <jack@...e.cz>
To:     Chao Yu <yuchao0@...wei.com>
Cc:     Jan Kara <jack@...e.cz>, jack@...e.com,
        linux-kernel@...r.kernel.org, chao@...nel.org
Subject: Re: [PATCH] quota: be aware of error from dquot_initialize

On Tue 14-11-17 11:43:49, Chao Yu wrote:
> On 2017/11/13 17:18, Jan Kara wrote:
> > On Mon 13-11-17 11:31:48, Chao Yu wrote:
> >> Commit 6184fc0b8dd7 ("quota: Propagate error from ->acquire_dquot()")
> >> missed to handle error from dquot_initialize in dquot_file_open, fix it.
> >>
> >> Signed-off-by: Chao Yu <yuchao0@...wei.com>
> > 
> > Good spotting. I've added the patch to my tree.
> 
> Thanks for queuing the patch. :)
> 
> BTW, I notice in add_dquot_ref we also didn't handle error of
> __dquot_initialize, should we handle it too?

It is questionable what we should do with an error in add_dquot_ref(). User
asked us to turn quotas on - that succeeded just fine but then we walked
over already active inodes in add_dquot_ref(), wanted to initialize
accounting information, and that failed for some inode. We can just leave
quota on, the accounting will work for other inodes - that's what we do
now. We could also propagate the failure up and refuse to turn quotas off.
I guess that's a somewhat better approach so if you want to implement that,
go ahead.

								Honza
-- 
Jan Kara <jack@...e.com>
SUSE Labs, CR

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ