Skip to main content

Gammu EUVDEUVD-2026-137549

| CVE-2026-138164 MEDIUM
Stack-based Buffer Overflow (CWE-121)
2026-11-28 VulnCheck GHSA-qvrw-322v-v5fc
4.8
CVSS 4.0 · Vendor: VulnCheck
View

Attack ChainAIDerived

Hypothetical attack flow derived from CVE metadata – not a confirmed exploit chain

  1. Access
    Supply crafted backup file with long text field
  2. Exploit
    Victim runs gammu convertbackup locally
  3. Execution
    SaveBackupText hex-encodes field past 10,000-byte stack buffer
  4. Impact
    Out-of-bounds write of attacker-influenced hex bytes

Vulnerability Assessment

Weakness
CWE
ASVS 5.0
V15 - Secure Coding and Architecture Stack buffer bounds checking
MITRE ATT&CK

1 technique across 1 tactic: Execution

The technique list with ATT&CK links and the kill-chain view is part of the Basic plan and up.

Exploitation Conditions

Exploitation requires a victim to locally run 'gammu convertbackup' on an attacker-supplied Gammu text backup containing a calendar or note Text field of at least 2,500 characters (the exact overflow threshold; 2,499 is clean). A second, source-review-only route is 'gammu backup' against a phone holding a note longer than 2,500 characters (Gammu's 4,096-character note limit exceeds the threshold), but the advisory states this phone-to-backup path was not executed. Limiting factors that reduce realistic risk: the vector is local (AV:L) with required passive user interaction (UI:P) - no remote or unauthenticated trigger; impact is confined to an out-of-bounds integrity write (VI:L) with no confidentiality or availability effect; and every optimized build tested, including hardened builds with -D_FORTIFY_SOURCE=3 and -fstack-protector-strong, completed without crashing, so default distribution builds are unlikely to exhibit a crash or demonstrated higher impact.

Impact

This is a genuine but low-urgency memory-safety defect, not a high-CVSS/low-real-risk case and not a false alarm. The signals are internally consistent and point to modest real-world risk. The CVSS 4.0 vector (AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:L/VA:N, 4.8 Medium) shows a local-only, user-interaction-dependent flaw with no confidentiality or availability impact and only low integrity impact - the attacker-controlled hex bytes written past the buffer. The GHSA advisory's own 'demonstrated' CVSS:3.1 vector (AV:L/AC:L/PR:N/UI:R/C:N/I:L/A:N = 3.3) agrees. Critically, the researchers explicitly state the out-of-bounds write was confirmed only under AddressSanitizer; every optimized build they tested (including hardened builds with FORTIFY_SOURCE and stack-protector, and even unhardened optimized builds) completed without crashing, so no availability consequence and no code execution were demonstrated. The advisory also lists a 'potential' ceiling of CVSS:3.1 7.0 (High) for code execution, but marks it AC:H and explicitly not demonstrated - do not treat that ceiling as confirmed impact. No EPSS score and no CISA KEV entry are provided in the input, and the product is a niche utility, so widespread opportunistic exploitation is unlikely. The vuln.today decision label is 'this_month' (routine patch cadence), not act_now or emergency. Net: patch on a normal cycle; this is not a drop-everything issue.

Exploit ScenarioDerived

An attacker crafts a Gammu text backup file whose calendar or note Text field is 2,500 or more characters; when a victim runs 'gammu convertbackup' on that file, SaveBackupText() hex-encodes the field at four output bytes per input character into a fixed 10,000-byte stack buffer with no bounds check, writing past its end. The GHSA advisory includes a complete, confirmed-reproducing proof of concept (a Python generator plus build/run steps) that triggers the out-of-bounds write under AddressSanitizer at 2,500/2,600/4,090 characters, but it demonstrates only the memory-corruption write - optimized builds survived and no code execution was shown. Because AV:L/UI:P, the victim must locally process an attacker-supplied backup.

This Month Plan within 30 days. Why: MEDIUM severity (CVSS 4.0-6.9).
Patch available 0.2% exploitation probability (EPSS)

Get an e-mail when this CVE is exploited, patched or re-scored. Free account.

Alert me

AnalysisAIv1 – Nov 28, 2026

Gammu's backup writer overflows a fixed 10,000-byte stack buffer when hex-encoding a text field of 2,500 characters or more, and the overflow is reachable by running 'gammu convertbackup' on an attacker-supplied text backup whose calendar or note Text field is long enough. All versions before 1.45.2 are affected per the wildcard CPE; the issue is local (AV:L) and requires the victim to convert a crafted backup (UI:P), and the demonstrated consequence is a limited integrity write with no observed crash on optimized builds, so confidentiality and availability impact are unproven. A reproduction with sanitizer output is published in the upstream advisory, but it is a proof-of-concept rather than working exploit code, and there is no CISA KEV entry indicating active exploitation. Vendor-released patch: 1.45.2.

RemediationAI

Upgrade to Gammu 1.45.2 (https://github.com/gammu/gammu/releases/tag/1.45.2), which replaces the fixed stack buffer with a heap allocation sized at four bytes per character plus a terminator, adds an overflow guard on the length computation, and adds a regression test exercising 2,400, 2,499, 2,500, 2,600 and 4,090 character fields; the upstream fix is commit 6ea5148f35995aa8ca02b0c5e4654a125405e799 and the advisory is https://github.com/gammu/gammu/security/advisories/GHSA-f954-jx97-g68w. If upgrading is deferred, the practical compensating control is to treat backup files as untrusted input: do not run 'gammu convertbackup' on backups from third parties or unknown sources, and where conversion is required, pre-screen or rewrite the backup so calendar and note Text fields stay below 2,500 characters (2,499 is clean; Gammu's 4,096-character note limit is above the overflow threshold, so legitimate long notes cannot simply be assumed safe), or perform the conversion inside a disposable container or sandbox so an out-of-bounds write cannot reach persistent state. Do not rely on -D_FORTIFY_SOURCE or -fstack-protector-strong as the fix: the tested hardened builds survived the input, but the out-of-bounds write still occurs and the mitigation only masks the symptom. Note that applying this month's cycle is appropriate given the local vector, required user interaction and absence of demonstrated crash or code execution on default builds.

Affected VersionsENISA

Gammu 0 <1.45.2

Affected Packages

euvd gammu fix: 1.45.2

Source: OSV (Open Source Vulnerabilities)

Affects your stack

Affects 1 package in euvd

Checking this CVE against your own stacks and servers is part of the Basic plan and up.

Technical ContextAI · show details

The defect sits in libgammu's backup serializer. SaveBackupText() at libgammu/service/backup/backtext.c:165 declares 'char buffer[10000]' and at line 189 passes it with a length of UnicodeLength(myvalue)*2 to EncodeHexBin(), which emits four output bytes per input character (two hex digits per byte, two bytes per UCS-2 character). The encoded length is derived purely from field content and is never compared against sizeof(buffer), so any text of 2,500 characters or more writes past the stack object; the overflowing store is the hex-digit write in coding.c:565 and, at exactly 2,500 characters, the first byte past the buffer is the terminator at coding.c:568. The executed route is SaveBackup() (backtext.c:1681) -> SaveCalendarEntry() (backtext.c:789) -> SaveBackupText() via 'gammu convertbackup'; source review indicates 'gammu backup' against a phone holding a note over 2,500 characters would reach the same sink, since Gammu's 4,096-character note limit exceeds the threshold, though that phone-to-backup path was not executed. The flaw is classified CWE-121 (stack-based buffer overflow) in the CVE record and CWE-787 (out-of-bounds write) in the upstream advisory; the CPE cpe:2.3:a:gammu:gammu:*:*:*:*:*:*:*:* covers all releases below 1.45.2. Sanitizer builds (ASan at -O1) reported the out-of-bounds write at 2,500, 2,600 and 4,090 characters with a clean 2,400-character control, while -O2 builds with -D_FORTIFY_SOURCE=3 and -fstack-protector-strong and uninstrumented -O2 builds all completed without crashing, so the mechanism is confirmed but a crash or code-execution consequence is not.

Know when Gammu gets its next vulnerability

  • Watch products and get an email when something new is published
  • Check this CVE against your own stack and servers
  • Exploit and PoC references, threat intelligence from 22 sources

No credit card · 7-day full trial

Severity by source

Vendor (VulnCheck) PRIMARY 4.8 MEDIUM
CVSS:4.0/AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N
vuln.today AI 3.3 LOW

Local backup conversion requires the victim to process an attacker-supplied file (AV:L/UI:R), needs no privileges (PR:N); only attacker-influenced bytes written out of bounds (I:L), with no demonstrated C or A impact.

3.1 AV:L/AC:L/PR:N/UI:R/S:U/C:N/I:L/A:N
4.0 AV:L/AC:L/AT:N/PR:N/UI:P/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N

Primary rating from Vendor (VulnCheck).

CVSS VectorVendor: VulnCheck

Attack Vector
Local
Attack Complexity
Low
Attack Requirements
None
Privileges Required
None
User Interaction
Passive
Vulnerable system: Confidentiality
None
Vulnerable system: Integrity
Low
Vulnerable system: Availability
None
Subsequent system: Confidentiality
None
Subsequent system: Integrity
None
Subsequent system: Availability
None

DescriptionCVE.org

Gammu before 1.45.2 contains a stack-based buffer overflow vulnerability in SaveBackupText() in backtext.c that allows attackers to corrupt stack memory by supplying long text fields. Attackers can craft a backup with long calendar or note fields that, when converted with gammu convertbackup, writes hex digits past the 10,000-byte stack buffer.

Threat Intelligence Overview

EPSS Score
0.2%
Top 94% exploitable
Prevalence
Low
niche open-source mobile-phone management utility, limited production footprint
Social Media
2
Sightings
Data Quality
6 sources
Confidence: High

How this decision was reached

The engine reads each signal below and applies a fixed list of rules from top to bottom. The first rule that matches sets the recommended action – like a statement, every line is shown.

SignalValue
Severity MEDIUM
CISA KEV No
Public POC No
EPSS 0.2%
Patch available Yes
Active threat No
Deciding rule
MEDIUM severity (CVSS 4.0-6.9)
What every action level means
Emergency Immediate action required. Criteria: CRITICAL + in CISA KEV (actively exploited) without patch, OR CRITICAL + EPSS > 30% without patch, OR CRITICAL + active threat signals without patch.
Act Now Prioritize within 24-48h. Criteria: in KEV with patch available, OR CRITICAL + public POC, OR HIGH + EPSS > 10%, OR CRITICAL + active threat, OR any CRITICAL severity.
This Week Schedule remediation this week. Criteria: HIGH severity (CVSS 7.0-8.9). Patch within normal change window.
This Month Plan within 30 days. Criteria: MEDIUM severity (CVSS 4.0-6.9), lower exploitation probability. Include in regular patch cycle.
Monitor Track and reassess. Criteria: LOW severity (CVSS 0.1-3.9), minimal exploitation risk. No immediate action needed.

SSVC AssessmentENISA

SSVC Decision· derived
Defer
Exploitation· derived
None
System Exposure· derived
Small
Automatable· derived
No
Human Impact· derived
Medium

Priority Score

24
Low Medium High Critical
KEV: 0
EPSS: 0
CVSS: +24
PoC: 0
Weaponized: 0
Threat intel: 0
Gov advisory: 0

Attack Technique

A buffer overflow occurs when a program writes more data to a memory buffer than it was allocated to hold, causing the excess data to spill into adjacent memory regions.

A stack-based buffer overflow occurs when a program writes more data to a buffer located on the stack than it was allocated to hold.

Vendor StatusVendor

Debian

gammu
Release Status Fixed Version Urgency
bookworm vulnerable 1.42.0-8 -
trixie vulnerable 1.42.0-10 -
forky vulnerable 1.45.0-2 -
sid fixed 1.45.2-1 -
(unstable) fixed 1.45.2-1 -

This site uses cookies essential for authentication and security. No tracking or analytics cookies are used. Privacy Policy