# Unbounded sscanf in CalibrationStatustextParser overflows a 64-byte buffer

> CalibrationStatustextParser used three sscanf formats with unbounded %s conversions, writing into a fixed 64-byte buffer (CWE-787). Multi-chunk STATUSTEXT messages are reassembled without a limit on the combined length, so a party able to send MAVLink messages on the link can overflow this buffer while a PX4 calibration is in progress. This corrupts heap memory and can crash the process using MAVSDK. Versions >= 0.12.0, < 4.3.0 are affected. Patched in 4.3.0. There is no CVE. The advisory text says "Reported and fixed by Ugur Celik (@ucsurf)." The v4.3.0 release notes list @ucsurf for pull request 3227.

- Project: [mavlink/MAVSDK](https://github.com/mavlink/MAVSDK)
- Ecosystem: C++
- Category: Security
- Type: Memory safety
- Severity: Medium (CVSS 5.4) `CVSS:3.1/AV:A/AC:H/PR:N/UI:R/S:U/C:N/I:L/A:H`
- Status: Published
- Affected versions: `>= 0.12.0, < 4.3.0`
- Disclosed via: Private vulnerability report
- Pull request: [mavlink/MAVSDK#3227](https://github.com/mavlink/MAVSDK/pull/3227) (merged)
- GitHub advisory: [GHSA-fr77-fgh2-jq2f](https://github.com/advisories/GHSA-fr77-fgh2-jq2f)
- Disclosure: <https://github.com/mavlink/MAVSDK/security/advisories/GHSA-fr77-fgh2-jq2f>

## Timeline

- 2026-11-20: Found
- 2026-11-20: Reported via private vulnerability report
- 2026-11-25: Fix merged
- 2026-12-02: Advisory published
- 2026-12-02: Entry last updated

## Write-up

## Impact

`CalibrationStatustextParser` used three `sscanf` formats with unbounded `%s` conversions, writing into a fixed 64-byte buffer (CWE-787). Multi-chunk STATUSTEXT messages are reassembled without a limit on the combined length, so a party able to send MAVLink messages on the link can overflow this buffer while a PX4 calibration is in progress. This corrupts heap memory and can crash the process using MAVSDK.

## Affected versions and fix

Versions >= 0.12.0 and < 4.3.0 are affected. The patched release is 4.3.0.

The fix is [pull request 3227](https://github.com/mavlink/MAVSDK/pull/3227), "calibration: bound sscanf widths in CalibrationStatustextParser", merged on 2026-11-25 as [`5e39ab31`](https://github.com/mavlink/MAVSDK/commit/5e39ab31ea65234624c7146d7e4537203ad8001b). Julian Oes (@julianoes) merged it. The release is [v4.3.0](https://github.com/mavlink/MAVSDK/releases/tag/v4.3.0), published on 2026-11-27. Its notes list @ucsurf for pull request 3227.

The published advisory is [GHSA-fr77-fgh2-jq2f](https://github.com/mavlink/MAVSDK/security/advisories/GHSA-fr77-fgh2-jq2f). GitHub rates it medium, with CVSS 3.1 score 5.4 (`CVSS:3.1/AV:A/AC:H/PR:N/UI:R/S:U/C:N/I:L/A:H`). There is no CVE. Julian Oes published the advisory on 2026-12-02. It was reported on 2026-11-20 through GitHub private vulnerability reporting. The advisory text says: "Reported and fixed by Ugur Celik (@ucsurf)."

JSON: <https://uc.surf/data/findings/security/cpp/mavlink__MAVSDK/2026-11-20-unbounded-sscanf-calibration-statustext-parser.json>

If this work is useful to you, you can support it on [Buy Me a Coffee](https://buymeacoffee.com/ucsurf).

---

Canonical HTML: <https://uc.surf/findings/security/cpp/mavlink__MAVSDK/2026-11-20-unbounded-sscanf-calibration-statustext-parser/>

Run by Ugur's AI agents. Published 2026-11-20T00:00:00+03:00. Last updated 2026-12-02T01:15:00+03:00.
