{"answers":{"affected":"It affects 1 product.","exploited":"It is not confirmed as exploited in the wild, but public exploit code for CVE-2025-21756 exists.","fix":"Apply the vendor's patch.","what":"CVE-2025-21756 is a high-severity use after free vulnerability in Linux kernel, published on 27 Feb 2025. It can only be exploited from the same machine or local network, with no action from the victim."},"fix_prompt":"Check this codebase for CVE-2025-21756 and fix it if it is affected.\n\nWhat it is: CVE-2025-21756 is a high-severity use after free vulnerability in Linux kernel, published on 27 Feb 2025. It can only be exploited from the same machine or local network, with no action from the victim.\nExploitation: It is not confirmed as exploited in the wild, but public exploit code for CVE-2025-21756 exists.\n\nAffected product: Linux kernel. 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-2025-21756/ (Markdown: https://insights.sbomify.com/CVE-2025-21756/index.md)","id":"CVE-2025-21756","markdown":"https://insights.sbomify.com/CVE-2025-21756/index.md","name":"CVE-2025-21756","record":{"aliases":["A-396331793","ASB-A-396331793","AZL-58995","AZL-59037","BELL-CVE-2025-21756","DEBIAN-CVE-2025-21756","GHSA-5828-2c94-235c","RHSA-2025:8058","UBUNTU-CVE-2025-21756"],"analysis":{"component_type":"kernel","fix_type":"patch","impacts":["code_execution","privilege_escalation"],"network_reachable":"adjacent_or_local","non_default_config":false,"product_category":"Linux kernel","requires_auth":"low_privilege","summary":"A use-after-free vulnerability in the Linux kernel vsock subsystem allows local attackers to execute arbitrary code or escalate privileges.","user_interaction":"not_required","vuln_class":"use_after_free"},"analysis_generated_by":"qwen3.8-flash-next","assigner":"Linux","cpe":[{"product":"linux_kernel","vendor":"linux"}],"cvss":{"score":7.8,"severity":"high","source":"cna","vector":"CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H","version":"3.1"},"cwes":[{"id":"CWE-416","name":"Use After Free"}],"description":"In the Linux kernel, the following vulnerability has been resolved:\n\nvsock: Keep the binding until socket destruction\n\nPreserve sockets bindings; this includes both resulting from an explicit\nbind() and those implicitly bound through autobind during connect().\n\nPrevents socket unbinding during a transport reassignment, which fixes a\nuse-after-free:\n\n    1. vsock_create() (refcnt=1) calls vsock_insert_unbound() (refcnt=2)\n    2. transport-\u003erelease() calls vsock_remove_bound() without checking if\n       sk was bound and moved to bound list (refcnt=1)\n    3. vsock_bind() assumes sk is in unbound list and before\n       __vsock_insert_bound(vsock_bound_sockets()) calls\n       __vsock_remove_bound() which does:\n           list_del_init(\u0026vsk-\u003ebound_table); // nop\n           sock_put(\u0026vsk-\u003esk);               // refcnt=0\n\nBUG: KASAN: slab-use-after-free in __vsock_bind+0x62e/0x730\nRead of size 4 at addr ffff88816b46a74c by task a.out/2057\n dump_stack_lvl+0x68/0x90\n print_report+0x174/0x4f6\n kasan_report+0xb9/0x190\n __vsock_bind+0x62e/0x730\n vsock_bind+0x97/0xe0\n __sys_bind+0x154/0x1f0\n __x64_sys_bind+0x6e/0xb0\n do_syscall_64+0x93/0x1b0\n entry_SYSCALL_64_after_hwframe+0x76/0x7e\n\nAllocated by task 2057:\n kasan_save_stack+0x1e/0x40\n kasan_save_track+0x10/0x30\n __kasan_slab_alloc+0x85/0x90\n kmem_cache_alloc_noprof+0x131/0x450\n sk_prot_alloc+0x5b/0x220\n sk_alloc+0x2c/0x870\n __vsock_create.constprop.0+0x2e/0xb60\n vsock_create+0xe4/0x420\n __sock_create+0x241/0x650\n __sys_socket+0xf2/0x1a0\n __x64_sys_socket+0x6e/0xb0\n do_syscall_64+0x93/0x1b0\n entry_SYSCALL_64_after_hwframe+0x76/0x7e\n\nFreed by task 2057:\n kasan_save_stack+0x1e/0x40\n kasan_save_track+0x10/0x30\n kasan_save_free_info+0x37/0x60\n __kasan_slab_free+0x4b/0x70\n kmem_cache_free+0x1a1/0x590\n __sk_destruct+0x388/0x5a0\n __vsock_bind+0x5e1/0x730\n vsock_bind+0x97/0xe0\n __sys_bind+0x154/0x1f0\n __x64_sys_bind+0x6e/0xb0\n do_syscall_64+0x93/0x1b0\n entry_SYSCALL_64_after_hwframe+0x76/0x7e\n\nrefcount_t: addition on 0; use-after-free.\nWARNING: CPU: 7 PID: 2057 at lib/refcount.c:25 refcount_warn_saturate+0xce/0x150\nRIP: 0010:refcount_warn_saturate+0xce/0x150\n __vsock_bind+0x66d/0x730\n vsock_bind+0x97/0xe0\n __sys_bind+0x154/0x1f0\n __x64_sys_bind+0x6e/0xb0\n do_syscall_64+0x93/0x1b0\n entry_SYSCALL_64_after_hwframe+0x76/0x7e\n\nrefcount_t: underflow; use-after-free.\nWARNING: CPU: 7 PID: 2057 at lib/refcount.c:28 refcount_warn_saturate+0xee/0x150\nRIP: 0010:refcount_warn_saturate+0xee/0x150\n vsock_remove_bound+0x187/0x1e0\n __vsock_release+0x383/0x4a0\n vsock_release+0x90/0x120\n __sock_release+0xa3/0x250\n sock_close+0x14/0x20\n __fput+0x359/0xa80\n task_work_run+0x107/0x1d0\n do_exit+0x847/0x2560\n do_group_exit+0xb8/0x250\n __x64_sys_exit_group+0x3a/0x50\n x64_sys_call+0xfec/0x14f0\n do_syscall_64+0x93/0x1b0\n entry_SYSCALL_64_after_hwframe+0x76/0x7e","ecosystems":["Red Hat:rhel_eus:9.4::appstream","Red Hat:rhel_eus:9.4::baseos","Red Hat:rhel_eus:9.4::crb","Red Hat:rhel_eus:9.4::nfv","Red Hat:rhel_eus:9.4::realtime"],"exploits":{"exploitdb":0,"first_seen":"2025-04-18","github_poc":4,"max_poc_stars":158,"metasploit":0,"nuclei":0,"refs":[{"date":"2025-04-18T14:22:15Z","kind":"github_poc","ref":"https://github.com/hoefler02/CVE-2025-21756","stars":158,"title":"Exploit for CVE-2025-21756 for Linux kernel 6.6.75. My first linux kernel exploit!"},{"date":"2025-06-26T02:47:49Z","kind":"github_poc","ref":"https://github.com/khoatran107/cve-2025-21756","stars":9,"title":null},{"date":"2026-03-22T23:14:47Z","kind":"github_poc","ref":"https://github.com/h3raklez/CVE-2025-21756","stars":1,"title":"CVE-2025-21756: Attack of the Vsock"},{"date":"2025-06-19T02:20:31Z","kind":"github_poc","ref":"https://github.com/KuanKuanQAQ/cve-testing","stars":0,"title":"Reproduce CVE-2022-32250 and CVE-2025-21756 by tampering with modprobe_path and hijacking control flow, respectively."}],"tier":"weaponised"},"has_fix":true,"headline":"vsock: Keep the binding until socket destruction","id":"CVE-2025-21756","indexable":true,"kev":null,"kind":"cve","links":{"ecosystem":null,"product":"linux:linux_kernel","products":["linux:linux_kernel"],"type":"use_after_free","year":"2025"},"n_packages":142,"n_references":7,"next":{"headline":"This CVE ID has been rejected or withdrawn by its CVE Numbering Authority.","id":"CVE-2025-21757"},"packages":[{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:7.3.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"bpftool-debuginfo","purl":"pkg:rpm/redhat/bpftool-debuginfo","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-64k-debug-debuginfo","purl":"pkg:rpm/redhat/kernel-64k-debug-debuginfo","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-64k-debug-devel","purl":"pkg:rpm/redhat/kernel-64k-debug-devel","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-64k-debug-devel-matched","purl":"pkg:rpm/redhat/kernel-64k-debug-devel-matched","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-64k-debuginfo","purl":"pkg:rpm/redhat/kernel-64k-debuginfo","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-64k-devel","purl":"pkg:rpm/redhat/kernel-64k-devel","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-64k-devel-matched","purl":"pkg:rpm/redhat/kernel-64k-devel-matched","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-debug-debuginfo","purl":"pkg:rpm/redhat/kernel-debug-debuginfo","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-debug-devel","purl":"pkg:rpm/redhat/kernel-debug-devel","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-debug-devel-matched","purl":"pkg:rpm/redhat/kernel-debug-devel-matched","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-debuginfo","purl":"pkg:rpm/redhat/kernel-debuginfo","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-debuginfo-common-aarch64","purl":"pkg:rpm/redhat/kernel-debuginfo-common-aarch64","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-debuginfo-common-ppc64le","purl":"pkg:rpm/redhat/kernel-debuginfo-common-ppc64le","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-debuginfo-common-s390x","purl":"pkg:rpm/redhat/kernel-debuginfo-common-s390x","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-debuginfo-common-x86_64","purl":"pkg:rpm/redhat/kernel-debuginfo-common-x86_64","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-devel","purl":"pkg:rpm/redhat/kernel-devel","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-devel-matched","purl":"pkg:rpm/redhat/kernel-devel-matched","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-doc","purl":"pkg:rpm/redhat/kernel-doc","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-rt-debug-debuginfo","purl":"pkg:rpm/redhat/kernel-rt-debug-debuginfo","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-rt-debuginfo","purl":"pkg:rpm/redhat/kernel-rt-debuginfo","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-tools-debuginfo","purl":"pkg:rpm/redhat/kernel-tools-debuginfo","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-zfcpdump-debuginfo","purl":"pkg:rpm/redhat/kernel-zfcpdump-debuginfo","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-zfcpdump-devel","purl":"pkg:rpm/redhat/kernel-zfcpdump-devel","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-zfcpdump-devel-matched","purl":"pkg:rpm/redhat/kernel-zfcpdump-devel-matched","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"libperf-debuginfo","purl":"pkg:rpm/redhat/libperf-debuginfo","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"perf","purl":"pkg:rpm/redhat/perf","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"perf-debuginfo","purl":"pkg:rpm/redhat/perf-debuginfo","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"python3-perf-debuginfo","purl":"pkg:rpm/redhat/python3-perf-debuginfo","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"rtla","purl":"pkg:rpm/redhat/rtla","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::appstream","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"rv","purl":"pkg:rpm/redhat/rv","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::baseos","fixed":["0:7.3.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"bpftool","purl":"pkg:rpm/redhat/bpftool","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::baseos","fixed":["0:7.3.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"bpftool-debuginfo","purl":"pkg:rpm/redhat/bpftool-debuginfo","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::baseos","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel","purl":"pkg:rpm/redhat/kernel","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::baseos","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-64k","purl":"pkg:rpm/redhat/kernel-64k","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::baseos","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-64k-core","purl":"pkg:rpm/redhat/kernel-64k-core","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::baseos","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-64k-debug","purl":"pkg:rpm/redhat/kernel-64k-debug","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::baseos","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-64k-debug-core","purl":"pkg:rpm/redhat/kernel-64k-debug-core","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::baseos","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-64k-debug-debuginfo","purl":"pkg:rpm/redhat/kernel-64k-debug-debuginfo","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::baseos","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-64k-debug-modules","purl":"pkg:rpm/redhat/kernel-64k-debug-modules","source":"RHSA-2025:8058"},{"ecosystem":"Red Hat:rhel_eus:9.4::baseos","fixed":["0:5.14.0-427.68.2.el9_4"],"introduced":["0"],"last_affected":[],"package":"kernel-64k-debug-modules-core","purl":"pkg:rpm/redhat/kernel-64k-debug-modules-core","source":"RHSA-2025:8058"}],"prev":{"headline":"This CVE ID has been rejected or withdrawn by its CVE Numbering Authority.","id":"CVE-2025-21755"},"products":["Linux"],"published":"2025-02-27","related":[{"cvss_score":8.8,"headline":"Linux Kernel Out-of-Bounds Write","id":"CVE-2026-53266","kev_date_added":"2026-09-18","published":"2026-06-25"},{"cvss_score":8.8,"headline":"Linux Kernel Improper Input Validation","id":"CVE-2013-6282","kev_date_added":"2022-09-15","published":"2013-11-19"},{"cvss_score":8.4,"headline":"Linux Kernel Heap-Based Buffer Overflow","id":"CVE-2022-0185","kev_date_added":"2024-08-21","published":"2022-02-11"},{"cvss_score":8.4,"headline":"Linux Kernel Privilege Escalation","id":"CVE-2013-2094","kev_date_added":"2022-09-15","published":"2013-05-14"},{"cvss_score":7.8,"headline":"Linux Kernel Unspecified","id":"CVE-2026-53362","kev_date_added":"2026-08-27","published":"2026-07-04"},{"cvss_score":7.8,"headline":"Linux Kernel Missing Initialization of a Variable","id":"CVE-2026-46300","kev_date_added":"2026-10-28","published":"2026-05-23"},{"cvss_score":7.8,"headline":"Linux Kernel Race Condition","id":"CVE-2025-39964","kev_date_added":"2026-09-18","published":"2025-10-13"}],"sources":[{"class":"attribution","licence":"CVE Terms of Use (MITRE)","name":"CVE List","prefix":"CVE"},{"class":"attribution","licence":"CC BY 4.0","name":"Red Hat","prefix":"RHSA"},{"class":"attribution","licence":"US public information, NVD API terms","name":"NVD"},{"class":"attribution","licence":"CWE Terms of Use","name":"CWE (MITRE)"},{"class":"attribution","licence":"FIRST CVSS licence","name":"CVSS (FIRST)"},{"class":"open","licence":"CC0","name":"PoC-in-GitHub"}],"ssvc":{"automatable":"no","exploitation":"poc","technical_impact":"total"},"state":"PUBLISHED","updated":"2026-10-15","vendors":["Linux"]},"summary":"A use-after-free vulnerability in the Linux kernel vsock subsystem allows local attackers to execute arbitrary code or escalate privileges.","url":"https://insights.sbomify.com/CVE-2025-21756/"}