{"id":"CVE-2026-12633","summary":"Out-of-bounds write in IPv6 6LoWPAN Context Option handling via unauthenticated Router Advertisement","details":"The IPv6 neighbor-discovery code in subsys/net/ip/ipv6_nbr.c processes the 6LoWPAN Context Option (6CO, RFC 6775) carried inside ICMPv6 Router Advertisements. In handle_ra_6co() the 8-bit context_len field is taken directly from the packet and was never bounded to the RFC maximum of 128. The function computes context-\u003econtext_len / 8 and then performs memset(context-\u003eprefix + context_len, 0, sizeof(context-\u003eprefix) - context_len), where context-\u003eprefix is a fixed 16-byte array.\n\nWith context_len between 136 and 255 (and the option length field set to 3, which the pre-fix validation accepts), context_len / 8 evaluates to 17..31, so the memset length 16 - context_len/8 underflows the unsigned size_t argument to roughly SIZE_MAX. This produces an unbounded out-of-bounds memset that zeroes kernel memory well past the 6lo context structure.\n\nThe defect is reachable from unauthenticated, link-local input: any host on the same link can send a crafted Router Advertisement with a 6CO option. The RA handler validates only the option length field before calling handle_ra_6co(), so a single packet triggers the wild write. The code is compiled when CONFIG_NET_6LO_CONTEXT is enabled.\n\nThe impact is a reliable remote (adjacent) denial of service via memory corruption, with collateral integrity loss as the memset zeroes contiguous memory before the system faults. Router Advertisements are link-scoped and not forwarded, so the attacker must be on the same link (AV:A). The fix rejects any context_len greater than 128 before the length computation.","aliases":["GHSA-h5m5-hm6j-cgpf"],"modified":"2026-08-22T09:15:48.277590Z","published":"2026-08-19T20:37:34.532Z","database_specific":{"cna_assigner":"zephyr","cwe_ids":["CWE-787"],"osv_generated_from":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/12xxx/CVE-2026-12633.json"},"references":[{"type":"ADVISORY","url":"https://github.com/CVEProject/cvelistV5/tree/main/cves/2026/12xxx/CVE-2026-12633.json"},{"type":"ADVISORY","url":"https://github.com/zephyrproject-rtos/zephyr/security/advisories/GHSA-h5m5-hm6j-cgpf"},{"type":"ADVISORY","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-12633"},{"type":"FIX","url":"https://github.com/zephyrproject-rtos/zephyr/commit/15e838c739be637bf23fd56a5c26f2b32079551b"},{"type":"PACKAGE","url":"https://github.com/zephyrproject-rtos/zephyr"}],"affected":[{"ranges":[{"type":"GIT","repo":"https://github.com/zephyrproject-rtos/zephyr","events":[{"introduced":"fcb9144dca68f98d24caf39532595555355c3c1d"},{"fixed":"15e838c739be637bf23fd56a5c26f2b32079551b"}],"database_specific":{"source":["AFFECTED_FIELD","REFERENCES"],"extracted_events":[{"introduced":"1.8.0"},{"fixed":"4.4.2"}]}}],"database_specific":{"source":"https://storage.googleapis.com/cve-osv-conversion/osv-output/CVE-2026-12633.json","vanir_signatures_modified":"2026-08-22T09:15:48Z","vanir_signatures":[{"target":{"file":"subsys/net/ip/ipv6_nbr.c","function":"handle_ra_6co"},"deprecated":false,"digest":{"function_hash":"267539371696623121120350077775344467726","length":604},"id":"CVE-2026-12633-3b7fcb39","signature_type":"Function","signature_version":"v1","source":"https://github.com/zephyrproject-rtos/zephyr/commit/15e838c739be637bf23fd56a5c26f2b32079551b"},{"source":"https://github.com/zephyrproject-rtos/zephyr/commit/15e838c739be637bf23fd56a5c26f2b32079551b","target":{"file":"subsys/net/ip/ipv6_nbr.c"},"deprecated":false,"digest":{"line_hashes":["204206096444958091730372478603137950800","338615262403669516417959998986501470228","85139857402039309434835499307801015552","271653168381252246532307486393129816758","20062006815393758460042036162702769065"],"threshold":0.9},"id":"CVE-2026-12633-8142ab50","signature_type":"Line","signature_version":"v1"}]}}],"schema_version":"1.9.0","severity":[{"type":"CVSS_V3","score":"CVSS:3.1/AV:A/AC:L/PR:N/UI:N/S:U/C:N/I:H/A:H"}]}