CVE-2026-136905: libyang through 6.4.13 Incomplete Cleanup in ly_out_reset()
CESNET libyang through 6.4.13 contains an incomplete cleanup vulnerability in lyoutreset() in src/out.c that tests a stale errno ESPIPE value after a successful seek. Applications reusing one output handler for different clients rewind but do not truncate the file, leaking leftover bytes of a previous client's output.
Affected Software
Event History
Frequently Asked Questions
Which deployments are exposed to data leakage?
Applications using libyang through 6.4.13 are exposed when they reuse a single output handler for different clients and rewind its file-backed output between responses. Leftover bytes from a prior client's output can then remain in the file and be returned to another client.
What must occur for an attacker to obtain prior output?
The affected application must produce output for multiple clients through the same reused output handler, rewind the output, and fail to truncate it. The prior output must be longer than the subsequent output for leftover bytes to be disclosed.
How can operators check whether they may be affected?
Review application use of libyang output handlers for reuse across client requests or sessions. In particular, check whether rewinding output files is followed by truncation before generating a new, potentially shorter response.
What can be done if updating libyang is not immediately possible?
Avoid reusing an output handler or its backing file across different clients. If reuse is necessary, ensure the output is truncated after rewind and before writing the next client's output.