Whamcloud - gitweb
LU-4883 lmv: disable sub-stripe access from .lustre/fid
[fs/lustre-release.git] / lustre / lmv / lmv_obd.c
index 659d3de..c18a68b 100644 (file)
@@ -2832,6 +2832,9 @@ int lmv_unpack_md(struct obd_export *exp, struct lmv_stripe_md **lsmp,
                RETURN(0);
        }
 
+       if (le32_to_cpu(lmm->lmv_magic) == LMV_MAGIC_STRIPE)
+               RETURN(-EPERM);
+
        /* Unpack memmd */
        if (le32_to_cpu(lmm->lmv_magic) != LMV_MAGIC_V1 &&
            le32_to_cpu(lmm->lmv_magic) != LMV_USER_MAGIC) {