summaryrefslogtreecommitdiffstats
path: root/fs/ceph/xattr.c
diff options
context:
space:
mode:
authorJeff Layton <jlayton@kernel.org>2020-09-08 15:47:40 +0200
committerIlya Dryomov <idryomov@gmail.com>2023-08-22 09:01:48 +0200
commit6b5717bd30ab7f35792d20b71211055bdb43e6de (patch)
treec6463f5f7545dbe23fcd03b0ab497d5d5e27308b /fs/ceph/xattr.c
parentceph: fscrypt_auth handling for ceph (diff)
downloadlinux-6b5717bd30ab7f35792d20b71211055bdb43e6de.tar.xz
linux-6b5717bd30ab7f35792d20b71211055bdb43e6de.zip
ceph: implement -o test_dummy_encryption mount option
Add support for the test_dummy_encryption mount option. This allows us to test the encrypted codepaths in ceph without having to manually set keys, etc. [ lhenriques: fix potential fsc->fsc_dummy_enc_policy memory leak in ceph_real_mount() ] Signed-off-by: Jeff Layton <jlayton@kernel.org> Reviewed-by: Xiubo Li <xiubli@redhat.com> Reviewed-and-tested-by: Luís Henriques <lhenriques@suse.de> Reviewed-by: Milind Changire <mchangir@redhat.com> Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Diffstat (limited to '')
-rw-r--r--fs/ceph/xattr.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/fs/ceph/xattr.c b/fs/ceph/xattr.c
index 806183959c47..ddc9090a1465 100644
--- a/fs/ceph/xattr.c
+++ b/fs/ceph/xattr.c
@@ -1408,6 +1408,9 @@ void ceph_release_acl_sec_ctx(struct ceph_acl_sec_ctx *as_ctx)
#ifdef CONFIG_CEPH_FS_SECURITY_LABEL
security_release_secctx(as_ctx->sec_ctx, as_ctx->sec_ctxlen);
#endif
+#ifdef CONFIG_FS_ENCRYPTION
+ kfree(as_ctx->fscrypt_auth);
+#endif
if (as_ctx->pagelist)
ceph_pagelist_release(as_ctx->pagelist);
}