libceph: implement CEPHX_V2 calculation mode
authorIlya Dryomov <idryomov@gmail.com>
Fri, 27 Jul 2018 17:25:32 +0000 (19:25 +0200)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 8 Dec 2018 12:05:10 +0000 (13:05 +0100)
commit18a23fb2632030888fc56a7df73a80f57445718f
treeb676c1112ac9fe861db0b12b3c6dcb209d389d80
parent06e925920d4de3da2114876bc607447e929604af
libceph: implement CEPHX_V2 calculation mode

commit cc255c76c70f7a87d97939621eae04b600d9f4a1 upstream.

Derive the signature from the entire buffer (both AES cipher blocks)
instead of using just the first half of the first block, leaving out
data_crc entirely.

This addresses CVE-2018-1129.

Link: http://tracker.ceph.com/issues/24837
Signed-off-by: Ilya Dryomov <idryomov@gmail.com>
Reviewed-by: Sage Weil <sage@redhat.com>
[bwh: Backported to 4.9:
 - Define and test the feature bit in the old way
 - Don't change any other feature bits in ceph_features.h]
Signed-off-by: Ben Hutchings <ben.hutchings@codethink.co.uk>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
include/linux/ceph/ceph_features.h
net/ceph/auth_x.c