]> git-server-git.apps.pok.os.sepia.ceph.com Git - ceph-client.git/commit
ceph: create symlinks with encrypted and base64-encoded targets
authorJeff Layton <jlayton@kernel.org>
Thu, 3 Sep 2020 17:31:10 +0000 (13:31 -0400)
committerJeff Layton <jlayton@kernel.org>
Tue, 31 May 2022 15:50:00 +0000 (11:50 -0400)
commit15af65d8034f3a8d6fb2deabc3c21f76236a10fd
tree245e54279c0fde9c4c5d88dfd0ee12736e9f452a
parent61c19fe07472d7f22336e9659f92b3e16c0a1b56
ceph: create symlinks with encrypted and base64-encoded targets

When creating symlinks in encrypted directories, encrypt and
base64-encode the target with the new inode's key before sending to the
MDS.

When filling a symlinked inode, base64-decode it into a buffer that
we'll keep in ci->i_symlink. When get_link is called, decrypt the buffer
into a new one that will hang off i_link.

Reviewed-by: Xiubo Li <xiubli@redhat.com>
Signed-off-by: Jeff Layton <jlayton@kernel.org>
fs/ceph/crypto.c
fs/ceph/dir.c
fs/ceph/inode.c