ceph: supply snapshot context in ceph_zero_partial_object()
Linux
Affected versions
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
Linux
| Product | Affected | Fixed in |
|---|---|---|
| Linux Linux |
|
≥ ad7a60de882aca31afb58721db166f7e77afcd92 · < 69e59a87bab0ea31ab2a584fc65e12dafacf8953| No fix yet |
| Linux Linux |
|
|
In the Linux kernel, the following vulnerability has been resolved:
ceph: supply snapshot context in ceph_zero_partial_object()
The ceph_zero_partial_object function was missing proper snapshot context for its OSD write operations, which could lead to data inconsistencies in snapshots.
Reproducer: ../src/vstart.sh --new -x --localhost --bluestore ./bin/ceph auth caps client.fs_a mds 'allow rwps fsname=a' mon 'allow r fsname=a' osd 'allow rw tag cephfs data=a' mount -t ceph fs_a@.a=/ /mnt/mycephfs/ -o conf=./ceph.conf dd if=/dev/urandom of=/mnt/mycephfs/foo bs=64K count=1 mkdir /mnt/mycephfs/.snap/snap1 md5sum /mnt/mycephfs/.snap/snap1/foo fallocate -p -o 0 -l 4096 /mnt/mycephfs/foo echo 3 > /proc/sys/vm/drop/caches md5sum /mnt/mycephfs/.snap/snap1/foo # get different md5sum!!
From the CVE record · Linux
The Linux kernel’s CephFS ceph_zero_partial_object() function can issue OSD writes without the proper snapshot context. Partially zeroing a file after taking a snapshot can change the data observed in that snapshot. The input does not establish whether an attacker can trigger this remotely or what access they would need.
Engineers running Linux kernels with CephFS should check whether their kernels include the fix; affected versions were not provided.