CVE-2026-138158gphoto libgphoto2 Stack-based Buffer Overflow
NVD
Vulnerability Summary
libgphoto2 through 2.5.34 contains a stack buffer overflow in sierra_get_string_register() that lets a malicious sierra-protocol camera or USB device overwrite stack memory. When files are listed, the device can answer the file-name register with an oversized packet, writing up to 32 KB past small stack buffers to cause crashes or possible code execution.
CVSS v4.0 Base Metrics — Score 7.0 (HIGH)
CVSS:4.0/AV:P/AC:L/AT:N/PR:N/UI:P/VC:H/VI:H/VA:H/SC:N/SI:N/SA:NAttack VectorPhysical
Attack ComplexityLow
Attack RequirementsNone
Privileges RequiredNone
User InteractionPassive
Confidentiality (Vulnerable System)High
Integrity (Vulnerable System)High
Availability (Vulnerable System)High
Confidentiality (Subsequent System)None
Integrity (Subsequent System)None
Availability (Subsequent System)None
Show CVSS v3.x metrics (score 6.6)
CVSS v3.1 Base Metrics — Score 6.6 (MEDIUM)
CVSS:3.1/AV:P/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:HAttack VectorPhysical
Attack ComplexityLow
Privileges RequiredNone
User InteractionRequired
ScopeUnchanged
ConfidentialityHigh
IntegrityHigh
AvailabilityHigh
Affected & Patched Versions
- gphoto libgphoto2 <= 2.5.34
- gphoto libgphoto2 2.5.34
What to do
Plan remediation soon. No exploitation is confirmed yet, but the severity is high.
- Check whether you run gphoto libgphoto2 and which version.
- Update to a patched version listed above, then confirm the new version.
Timeline
- Nov 28, 2026Published
- Nov 28, 2026Record last modified
Score, severity and exploitation changes are tracked from the day Watchtower started logging them.
Get notified about new gphoto libgphoto2 CVEsYou are reading CVE-2026-138158. Get an email when KEV listings, exploits or new CVEs match your stack.
Set up CVE alertsExternal References
- Vendor Advisoryhttps://github.com/gphoto/libgphoto2/security/advisories/GHSA-4f44-frcc-8824
- Patchhttps://github.com/gphoto/libgphoto2/commit/c4cd525d7461c26b89b4705dc74fc4b84d57ff3a
- Referencehttps://github.com/gphoto/libgphoto2/blob/v2.5.34/camlibs/sierra/library.c#L1285-L1289
- Referencehttps://github.com/gphoto/libgphoto2
- Referencehttps://www.vulncheck.com/advisories/libgphoto2-through-2.5.34-stack-buffer-overflow-via-sierra-get-string-register
Data last checked: Nov 28, 2026 03:30 UTC