• Miklos Szeredi's avatar
    ovl: fix race in private xattr checks · 52148463
    Miklos Szeredi authored
    Xattr operations can race with copy up.  This does not matter as long as
    we consistently fiter out "trunsted.overlay.opaque" attribute on upper
    directories.
    
    Previously we checked parent against OVL_PATH_MERGE.  This is too general,
    and prone to race with copy-up.  I.e. we found the parent to be on the
    lower layer but ovl_dentry_real() would return the copied-up dentry,
    possibly with the "opaque" attribute.
    
    So instead use ovl_path_real() and decide to filter the attributes based on
    the actual type of the dentry we'll use.
    Signed-off-by: default avatarMiklos Szeredi <mszeredi@suse.cz>
    52148463
inode.c 8.92 KB