Skip to main content
Press slash or control plus K to focus the search. Use the arrow keys to navigate results and press enter to open a threat.
Reconnecting to live updates…
EPSS 0.2%top 90%

libgphoto2 is a camera access and control library.

0
Medium
Published: 04/18/2026 (04/18/2026, 00:16:00 UTC)
Source: GCVE Database
Product: libgphoto2

Description

libgphoto2 is a camera access and control library. Versions up to and including 2.5.33 have an out-of-bounds read in `ptp_unpack_DPV()` in `camlibs/ptp2/ptp-pack.c` (lines 622–629). The UINT128 and INT128 cases advance `*offset += 16` without verifying that 16 bytes remain in the buffer. The entry check at line 609 only guarantees `*offset < total` (at least 1 byte available), leaving up to 15 bytes unvalidated. Commit 433bde9888d70aa726e32744cd751d7dbe94379a patches the issue.

CVSS v3.1

Score 5.2medium

Attack Vector
Physical
Attack Complexity
Low
Privileges Required
None
User Interaction
None
Scope
Unchanged
Confidentiality
High
Integrity
None
Availability
Low
CVSS:3.1/AV:P/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:L

Affected software

Ubuntu:14.04:LTSmore threats →ghsa
libgphoto2
pkg:deb/ubuntu/[email protected]?arch=source&distro=trusty
Affected versions
=2.5.2-0ubuntu5=2.5.2-0ubuntu6=2.5.3.1-0ubuntu1=2.5.3.1-1ubuntu2=2.5.3.1-1ubuntu2.2
Ubuntu:16.04:LTSmore threats →ghsa
libgphoto2
pkg:deb/ubuntu/[email protected]?arch=source&distro=xenial
Affected versions
=2.5.8-1=2.5.8-2=2.5.8-3=2.5.9-2=2.5.9-3
Ubuntu:18.04:LTSmore threats →ghsa
libgphoto2
pkg:deb/ubuntu/[email protected]?arch=source&distro=bionic
Affected versions
=2.5.14-1=2.5.16-2
Ubuntu:20.04:LTSmore threats →ghsa
libgphoto2
pkg:deb/ubuntu/[email protected]?arch=source&distro=focal
Affected versions
=2.5.23-2=2.5.24-1=2.5.25-0ubuntu0.1
Ubuntu:22.04:LTSmore threats →ghsa
libgphoto2
pkg:deb/ubuntu/[email protected]?arch=source&distro=jammy
Affected versions
=2.5.27-1=2.5.27-1build1=2.5.27-1build2
Ubuntu:24.04:LTSmore threats →ghsa
libgphoto2
pkg:deb/ubuntu/[email protected]?arch=source&distro=noble
Affected versions
=2.5.30-1=2.5.31-1=2.5.31-2=2.5.31-2.1build1=2.5.31-2.1build2=2.5.31-2.1ubuntu1
Ubuntu:25.10more threats →ghsa
libgphoto2
pkg:deb/ubuntu/[email protected]?arch=source&distro=questing
Affected versions
=2.5.31-4=2.5.31-4build1=2.5.31-4ubuntu1
Ubuntu:26.04:LTSmore threats →ghsa
libgphoto2
pkg:deb/ubuntu/[email protected]?arch=source&distro=resolute
Affected versions
=2.5.31-4build1=2.5.32-1=2.5.33-1=2.5.33-1ubuntu1

Run on your own infrastructure? Check whether these packages are installed with threat-finder — our free open-source scanner.

AI-Powered Analysis

Machine-generated threat intelligence

AILast updated: 07/16/2026, 13:20:09 UTC

Technical Analysis

The libgphoto2 camera access and control library versions up to 2.5.33 have an out-of-bounds read vulnerability in the ptp_unpack_DPV() function located in camlibs/ptp2/ptp-pack.c. Specifically, the UINT128 and INT128 cases increment the offset by 16 bytes without ensuring that 16 bytes are available, as the initial check only guarantees at least one byte is available. This can lead to reading up to 15 bytes beyond the buffer boundary. The vulnerability is fixed by commit 433bde9888d70aa726e32744cd751d7dbe94379a.

Potential Impact

An out-of-bounds read can lead to information disclosure by reading memory beyond the intended buffer. According to the CVSS vector, the vulnerability requires physical access (AV:P), has low complexity (AC:L), no privileges required (PR:N), no user interaction (UI:N), and impacts confidentiality with high severity (C:H), but does not affect integrity (I:N) and only has low impact on availability (A:L). No known exploits are reported in the wild.

Mitigation Recommendations

A fix is available via commit 433bde9888d70aa726e32744cd751d7dbe94379a. Users should upgrade libgphoto2 to a version later than 2.5.33 where this issue is patched. The affected versions include multiple Ubuntu package versions up to 2.5.33-1ubuntu1. Applying the official patch or upgrading to a fixed version is recommended to remediate this vulnerability.

Pro Console: star threats, build custom feeds, automate alerts via Slack, email & webhooks.Upgrade to Pro

Technical Details

Gcve Source
db.gcve.eu
Osv Id
UBUNTU-CVE-2026-40335
Osv Schema Version
1.7.0
Aliases
[]
Ecosystems
["Ubuntu:14.04:LTS","Ubuntu:16.04:LTS","Ubuntu:18.04:LTS","Ubuntu:20.04:LTS","Ubuntu:22.04:LTS","Ubuntu:24.04:LTS","Ubuntu:25.10","Ubuntu:26.04:LTS"]
Database Specific Severity
null
Cvss Version
3.1

Threat ID: 6a58b4c668715ace43daac44

Added to database: 07/16/2026, 10:39:02 UTC

Last enriched: 07/16/2026, 13:20:09 UTC

Last updated: 07/31/2026, 19:22:58 UTC

Views: 21

Community Reviews

0 reviews

Crowdsource mitigation strategies, share intel context, and vote on the most helpful responses. Sign in to add your voice and help keep defenders ahead.

Sort by
Loading community insights…

Want to contribute mitigation steps or threat intel context? Sign in or create an account to join the community discussion.

Actions

PRO

Updates to AI analysis require Pro Console access. Upgrade inside Console → Billing.

Please log in to the Console to use AI analysis features.

Need more coverage?

Upgrade to Pro Console for AI refresh and higher limits.

For incident response and remediation, OffSeq services can help resolve threats faster.

Latest Threats

Breach by OffSeqOFFSEQFRIENDS — 25% OFF

Check if your credentials are on the dark web

Instant breach scanning across billions of leaked records. Free tier available.

Scan now
OffSeq TrainingCredly Certified

Lead Pen Test Professional

Technical5-day eLearningPECB Accredited
View courses