RUSTSEC-2026-0183
Not scored
Potential undefined behavior when calling Remote::list()
- Severity
- Not scored
- Published
- Last changed
Description
When calling Remote::list() for a remote of a git repository, when that remote does not advertise any references, git2 passes a null pointer to the unsafe function slice::from_raw_parts(). Based on the safety section documentation of function, data must be non-null even for slices of length zero. Thus, the use of a null pointer leads to undefined behavior.
Affected
| Product or package | Versions | Reported by |
|---|---|---|
| git2 (crates.io) | from 0.0.0-0 before 0.21.0 | RustSec Advisory Database |
References
Sources
| Source | Record | Licence |
|---|---|---|
| RustSec Advisory Database | RUSTSEC-2026-0183 changed 2026-06-17 | CC0-1.0 |