usb: gadget: configfs: fix out-of-bounds read of qw_sign
- Published
- Last modified
- Where the record stands: published, rejected by its publisher, or superseded by another id.What do these mean? →
- published
- Whether CISA lists it in its Known Exploited Vulnerabilities catalog: proof that attackers are using it.What do these mean? →
- Not listed in CISA KEV
- Fix
- Fixed in 5.10.270, 5.15.221, 6.1.188, 6.6.157, 6.12.110, and 2 more
- Whether working attack code is public (Exploit-DB, Metasploit, Nuclei or GitHub). Public code makes attacks easier.What do these mean? →
- None on Exploit-DB, Metasploit or GitHub
Summary
In the Linux kernel, the following vulnerability has been resolved: usb: gadget: configfs: fix out-of-bounds read of qw_sign os_desc_qw_sign_show() passes OS_STRING_QW_SIGN_LEN as the input length to utf16s_to_utf8s(), but that argument counts UTF-16 code units while OS_STRING_QW_SIGN_LEN (14) is the byte size of qw_sign[]. The array holds only OS_STRING_QW_SIGN_LEN / 2 (7) code units, so the conversion reads up to 7 units (14 bytes) past the end of qw_sign[] into the following members of struct gadget_info when the stored signature fills the array without a NUL terminator, exposing those bytes through the configfs attribute. The store path halves the count for its input bound but passes the full byte count as the utf8s_to_utf16s() output limit; use the destination code-unit count in both directions.
Timeline
- CVE published
- Record last updated
Affected versions
- Linux Linux
From 76180d716f91f035d9c8639497cf5459b44e1a51 · fixed in b895dbed8ac9e12a5ffa1a2165575a8469f8340d; From 76180d716f91f035d9c8639497cf5459b44e1a51 · fixed in 9b45125501aad2dff7730970461b455b0e0658ee; From 76180d716f91f035d9c8639497cf5459b44e1a51 · fixed in f6da500b0f8106882598b6dec87fe37d653946cf; From 76180d716f91f035d9c8639497cf5459b44e1a51 · fixed in a28c486434634f6d1e120711d2b09f3eddea6c98; From 76180d716f91f035d9c8639497cf5459b44e1a51 · fixed in 7e94cb967778e074411940db4db97f22ed77560c; From 76180d716f91f035d9c8639497cf5459b44e1a51 · fixed in afbf39c0f2297c6abef6d670a82a2079b0836191; From 76180d716f91f035d9c8639497cf5459b44e1a51 · fixed in 36315a330e067f7773196940552feacb1debbef1; From 76180d716f91f035d9c8639497cf5459b44e1a51 · fixed in f63edb54d8f738f9c21e2068c777ae1c097df6b7
- Linux Linux
4.13
- KernelLinux
From 4.13.0 · fixed in 5.10.270; From 5.11.0 · fixed in 5.15.221; From 5.16.0 · fixed in 6.1.188; From 6.2.0 · fixed in 6.6.157; From 6.7.0 · fixed in 6.12.110; From 6.13.0 · fixed in 6.18.52; From 6.19.0 · fixed in 7.2.6
References 8
git.kernel.org
- stable/c/b895dbed8ac9e12a5ffa1a2165575a8469f8340d
- stable/c/9b45125501aad2dff7730970461b455b0e0658ee
- stable/c/f6da500b0f8106882598b6dec87fe37d653946cf
- stable/c/a28c486434634f6d1e120711d2b09f3eddea6c98
- stable/c/7e94cb967778e074411940db4db97f22ed77560c
- stable/c/afbf39c0f2297c6abef6d670a82a2079b0836191
- stable/c/36315a330e067f7773196940552feacb1debbef1
- stable/c/f63edb54d8f738f9c21e2068c777ae1c097df6b7