{"answers":{"affected":"","exploited":"There is no known exploitation of CVE-2026-139012 in the wild and no public exploit code.","exposure":"","fix":"Upgrade to a fixed version.","what":"CVE-2026-139012 is a vulnerability in Linux, published on 30 Nov 2026."},"fix_prompt":"Check this codebase for CVE-2026-139012 and fix it if it is affected.\n\nWhat it is: CVE-2026-139012 is a vulnerability in Linux, published on 30 Nov 2026. \nExploitation: There is no known exploitation of CVE-2026-139012 in the wild and no public exploit code.\n\nAffected product: Linux. No package-level version data is available, so check the vendor advisory linked from the reference page.\n\nTask:\n1. Search the dependency manifests and lockfiles (for example package.json, package-lock.json, requirements.txt, poetry.lock, uv.lock, pom.xml, build.gradle, go.mod, Cargo.lock, Gemfile.lock) and any Dockerfiles for the affected packages, including transitive dependencies.\n2. If an affected version is in use, upgrade it to the fixed version for its release line with the project's package manager, so the lockfile is regenerated. Prefer the smallest upgrade that fixes it.\n3. If there is no fix, or the upgrade would break the build, do not guess: explain the risk and the safest workaround instead.\n4. Run the tests and summarise what changed and why.\n5. If nothing in the project is affected, say so and change nothing.\n\nReference: https://insights.sbomify.com/CVE-2026-139012/ (Markdown: https://insights.sbomify.com/CVE-2026-139012/index.md)","id":"CVE-2026-139012","markdown":"https://insights.sbomify.com/CVE-2026-139012/index.md","name":"CVE-2026-139012","record":{"aliases":["BELL-CVE-2026-139012","DEBIAN-CVE-2026-139012","GHSA-ch5h-x4jc-6qmq","UBUNTU-CVE-2026-139012"],"analysis":null,"analysis_generated_by":null,"assigner":"Linux","component":null,"cpe":[],"cvss":{"score":null,"severity":null,"source":null,"vector":null,"version":null},"cwes":[],"description":"In the Linux kernel, the following vulnerability has been resolved:\n\nf2fs: compress: fix to handle race between truncate and writeback\n\nfsstress reports a kernel BUG in f2fs_truncate_partial_cluster():\n\nkernel BUG at fs/f2fs/compress.c:1238!\nRIP: 0010:f2fs_truncate_partial_cluster+0x292/0x2a0\nCall Trace:\n \u003cTASK\u003e\n f2fs_truncate+0xf6/0x210\n f2fs_setattr+0x6b7/0x770\n notify_change+0x33b/0x520\n do_truncate+0xc2/0xf0\n vfs_truncate+0x153/0x1d0\n ksys_truncate+0x78/0xd0\n __x64_sys_truncate+0x16/0x20\n do_syscall_64+0xbe/0x540\n\nThe root cause is that Thread A (truncate) and Thread B (background\nwriteback or fsync) can race as follows:\n\nThread A                             Thread B\n- f2fs_setattr\n - f2fs_truncate\n  - f2fs_truncate_blocks\n   - f2fs_truncate_partial_cluster\n    - f2fs_is_compressed_cluster\n      return 1\n                                     - f2fs_write_cache_pages\n                                      - f2fs_write_multi_pages\n                                       - f2fs_write_raw_pages\n                                        - f2fs_write_single_data_page\n                                          dn.data_blkaddr != COMPRESS_ADDR\n                                          (cluster converted to normal)\n    - f2fs_prepare_compress_overwrite\n     - f2fs_is_compressed_cluster\n       return 0\n     - return 0\n    - f2fs_bug_on(sbi, err == 0): BUG!\n\nWriteback path does not acquire i_gc_rwsem or filemap_invalidate_lock.\nWhen a compressed cluster fails compression during writeback, it is\noverwritten with raw data blocks. If Thread A checked\nf2fs_is_compressed_cluster() before the conversion, but calls\nf2fs_prepare_compress_overwrite() after the conversion,\nf2fs_prepare_compress_overwrite() returns 0 because the cluster is no\nlonger a compressed cluster.\n\nTo fix this, remove the f2fs_bug_on() and retry checking the cluster status\nwhen f2fs_prepare_compress_overwrite() returns 0, so that it can fall back\nto f2fs_do_truncate_blocks() to handle it as a normal cluster.","ecosystems":[],"exploits":{"exploitdb":0,"first_seen":null,"github_poc":0,"max_poc_stars":null,"metasploit":0,"nuclei":0,"refs":[],"tier":"none_known"},"has_fix":true,"headline":"f2fs: compress: fix to handle race between truncate and writeback","id":"CVE-2026-139012","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":null,"product":null,"products":[],"type":null,"year":"2026"},"main_cpe":null,"main_fixed":[],"main_package":null,"n_packages":0,"n_references":8,"n_vendor_status":0,"next":{"headline":"f2fs: force out-place update for all writes on compressed file","id":"CVE-2026-139013"},"nickname":null,"packages":[],"prev":{"headline":"ata: libata: Do not leave ata_host_stop() registered when activation fails","id":"CVE-2026-139011"},"products":["Linux"],"published":"2026-11-30","related":[],"sources":[{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"}],"ssvc":{"automatable":null,"exploitation":null,"technical_impact":null},"state":"PUBLISHED","text_fixes":[],"updated":"2026-11-30","vendor_status":[],"vendors":["Linux"]},"summary":null,"url":"https://insights.sbomify.com/CVE-2026-139012/"}