Skip to content

Commit 209ad12

Browse files
idryomovsmb49
authored andcommitted
libceph: bump CephXAuthenticate encoding version
BugLink: https://bugs.launchpad.net/bugs/1928857 commit 7807daf upstream. A dummy v3 encoding (exactly the same as v2) was introduced so that the monitors can distinguish broken clients that may not include their auth ticket in CEPHX_GET_AUTH_SESSION_KEY request on reconnects, thus failing to prove previous possession of their global_id (one part of CVE-2021-20288). The kernel client has always included its auth ticket, so it is compatible with enforcing mode as is. However we want to bump the encoding version to avoid having to authenticate twice on the initial connect -- all legacy (CephXAuthenticate < v3) are now forced do so in order to expose insecure global_id reclaim. Marking for stable since at least for 5.11 and 5.12 it is trivial (v2 -> v3). Cc: stable@vger.kernel.org # 5.11+ URL: https://tracker.ceph.com/issues/50452 Signed-off-by: Ilya Dryomov <idryomov@gmail.com> Reviewed-by: Sage Weil <sage@redhat.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Kamal Mostafa <kamal@canonical.com> Signed-off-by: Stefan Bader <stefan.bader@canonical.com>
1 parent 536f4b8 commit 209ad12

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

net/ceph/auth_x.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -526,7 +526,7 @@ static int ceph_x_build_request(struct ceph_auth_client *ac,
526526
if (ret < 0)
527527
return ret;
528528

529-
auth->struct_v = 2; /* nautilus+ */
529+
auth->struct_v = 3; /* nautilus+ */
530530
auth->key = 0;
531531
for (u = (u64 *)enc_buf; u + 1 <= (u64 *)(enc_buf + ret); u++)
532532
auth->key ^= *(__le64 *)u;

0 commit comments

Comments
 (0)