You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
UAF: PCWSTR built from temporary HSTRING in DeviceEnumerator::get_device #59
Two call sites build a PCWSTR from a temporary HSTRING. The temporary drops at the ;, so the PCWSTR points at freed heap memory before the Win32 call reads it.
src/api.rs:370 in DeviceEnumerator::get_device:
let w_id = PCWSTR::from_raw(HSTRING::from(device_id).as_ptr());let immdevice = unsafe{self.enumerator.GetDevice(w_id)? };
src/api.rs:1903 in set_echo_cancellation_render_endpoint:
Activity
HEnquist commentedon May 4, 2026
Thanks for reporting! No need for a PR, it's such a small fix. I'll make a new release as soon as I have a little time.