Re: [PATCH RFC v3] vfs: make fstatat retry once on ESTALE errors from getattr call

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Jeff Layton <jlayton@xxxxxxxxxx> writes:

>> And an audit would still not ensure safety against future additions of
>> ESTALE.
>> 
>
> Well, nothing is safe from the future. It's incumbent upon us to review
> patches and such before such breakage goes in.

Good interfaces are safe against stupidity, and that very much applies
to the kernel too.  Review is not an excuse for bad interfaces.

> But, let's say for the purposes of argument that we do have a fs (FUSE
> or otherwise) that is persistently returning ESTALE on a lookup. Why
> was Peter's check that we were making forward progress not enough to
> guard against this problem?
>
> In particular, I'm talking about the code he added to link_path_walk in
> this patch to check that the value of nd->path.dentry was changing:
>
>     https://lkml.org/lkml/2008/3/10/266
>
> It seems like that ought to be enough to alleviate your fears on this.
> We could also check for fatal signals on each pass and that would allow
> users to break out of the loop even when the underlying fs doesn't
> handle signals properly.

AFAICS that doesn't ensure progress, only change.  It helps those cases
which persistently return ESTALE, but not cases where there is change
but no progress.  E.g. it doesn't prevent DoS by a client doing renames
over a directory in a tight loop.

Thanks,
Miklos
--
To unsubscribe from this list: send the line "unsubscribe linux-fsdevel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html


[Index of Archives]     [Linux Ext4 Filesystem]     [Union Filesystem]     [Filesystem Testing]     [Ceph Users]     [Ecryptfs]     [AutoFS]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux Cachefs]     [Reiser Filesystem]     [Linux RAID]     [Samba]     [Device Mapper]     [CEPH Development]
  Powered by Linux