{"id":"DEBIAN-CVE-2023-53846","details":"In the Linux kernel, the following vulnerability has been resolved:  f2fs: fix to do sanity check on direct node in truncate_dnode()  syzbot reports below bug:  BUG: KASAN: slab-use-after-free in f2fs_truncate_data_blocks_range+0x122a/0x14c0 fs/f2fs/file.c:574 Read of size 4 at addr ffff88802a25c000 by task syz-executor148/5000  CPU: 1 PID: 5000 Comm: syz-executor148 Not tainted 6.4.0-rc7-syzkaller-00041-ge660abd551f1 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/27/2023 Call Trace:  \u003cTASK\u003e  __dump_stack lib/dump_stack.c:88 [inline]  dump_stack_lvl+0xd9/0x150 lib/dump_stack.c:106  print_address_description.constprop.0+0x2c/0x3c0 mm/kasan/report.c:351  print_report mm/kasan/report.c:462 [inline]  kasan_report+0x11c/0x130 mm/kasan/report.c:572  f2fs_truncate_data_blocks_range+0x122a/0x14c0 fs/f2fs/file.c:574  truncate_dnode+0x229/0x2e0 fs/f2fs/node.c:944  f2fs_truncate_inode_blocks+0x64b/0xde0 fs/f2fs/node.c:1154  f2fs_do_truncate_blocks+0x4ac/0xf30 fs/f2fs/file.c:721  f2fs_truncate_blocks+0x7b/0x300 fs/f2fs/file.c:749  f2fs_truncate.part.0+0x4a5/0x630 fs/f2fs/file.c:799  f2fs_truncate include/linux/fs.h:825 [inline]  f2fs_setattr+0x1738/0x2090 fs/f2fs/file.c:1006  notify_change+0xb2c/0x1180 fs/attr.c:483  do_truncate+0x143/0x200 fs/open.c:66  handle_truncate fs/namei.c:3295 [inline]  do_open fs/namei.c:3640 [inline]  path_openat+0x2083/0x2750 fs/namei.c:3791  do_filp_open+0x1ba/0x410 fs/namei.c:3818  do_sys_openat2+0x16d/0x4c0 fs/open.c:1356  do_sys_open fs/open.c:1372 [inline]  __do_sys_creat fs/open.c:1448 [inline]  __se_sys_creat fs/open.c:1442 [inline]  __x64_sys_creat+0xcd/0x120 fs/open.c:1442  do_syscall_x64 arch/x86/entry/common.c:50 [inline]  do_syscall_64+0x39/0xb0 arch/x86/entry/common.c:80  entry_SYSCALL_64_after_hwframe+0x63/0xcd  The root cause is, inodeA references inodeB via inodeB's ino, once inodeA is truncated, it calls truncate_dnode() to truncate data blocks in inodeB's node page, it traverse mapping data from node-\u003ei.i_addr[0] to node-\u003ei.i_addr[ADDRS_PER_BLOCK() - 1], result in out-of-boundary access.  This patch fixes to add sanity check on dnode page in truncate_dnode(), so that, it can help to avoid triggering such issue, and once it encounters such issue, it will record newly introduced ERROR_INVALID_NODE_REFERENCE error into superblock, later fsck can detect such issue and try repairing.  Also, it removes f2fs_truncate_data_blocks() for cleanup due to the function has only one caller, and uses f2fs_truncate_data_blocks_range() instead.","modified":"2026-11-15T18:00:13.772683212Z","published":"2025-12-09T16:17:25.003Z","upstream":["CVE-2023-53846"],"references":[{"type":"ADVISORY","url":"https://security-tracker.debian.org/tracker/CVE-2023-53846"}],"affected":[{"package":{"name":"linux","ecosystem":"Debian:12","purl":"pkg:deb/debian/linux?arch=source&distro=bookworm"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"6.1.192-1"}]}],"versions":["6.1.106-1","6.1.106-2","6.1.106-3","6.1.112-1","6.1.115-1","6.1.119-1","6.1.123-1","6.1.124-1","6.1.128-1","6.1.129-1","6.1.133-1","6.1.135-1","6.1.137-1","6.1.139-1","6.1.140-1","6.1.147-1","6.1.148-1","6.1.153-1","6.1.158-1","6.1.159-1","6.1.162-1","6.1.164-1","6.1.170-1","6.1.170-2","6.1.170-3","6.1.172-1","6.1.174-1","6.1.176-1","6.1.177-1","6.1.180-1","6.1.187-1","6.1.190-1","6.1.27-1","6.1.37-1","6.1.38-1","6.1.38-2","6.1.38-2~bpo11+1","6.1.38-3","6.1.38-4","6.1.38-4~bpo11+1","6.1.52-1","6.1.55-1","6.1.55-1~bpo11+1","6.1.64-1","6.1.66-1","6.1.67-1","6.1.69-1","6.1.69-1~bpo11+1","6.1.76-1","6.1.76-1~bpo11+1","6.1.82-1","6.1.85-1","6.1.90-1","6.1.90-1~bpo11+1","6.1.94-1","6.1.94-1~bpo11+1","6.1.98-1","6.1.99-1"],"ecosystem_specific":{"urgency":"not yet assigned"},"database_specific":{"source":"https://storage.googleapis.com/osv-test-debian-osv/debian-cve-osv/DEBIAN-CVE-2023-53846.json"}},{"package":{"name":"linux","ecosystem":"Debian:13","purl":"pkg:deb/debian/linux?arch=source&distro=trixie"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"6.4.11-1"}]}],"ecosystem_specific":{"urgency":"not yet assigned"},"database_specific":{"source":"https://storage.googleapis.com/osv-test-debian-osv/debian-cve-osv/DEBIAN-CVE-2023-53846.json"}},{"package":{"name":"linux","ecosystem":"Debian:14","purl":"pkg:deb/debian/linux?arch=source&distro=forky"},"ranges":[{"type":"ECOSYSTEM","events":[{"introduced":"0"},{"fixed":"6.4.11-1"}]}],"ecosystem_specific":{"urgency":"not yet assigned"},"database_specific":{"source":"https://storage.googleapis.com/osv-test-debian-osv/debian-cve-osv/DEBIAN-CVE-2023-53846.json"}}],"schema_version":"1.9.2","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H"}]}