Description
The (1) otrl_base64_otr_decode function in src/b64.c; (2) otrl_proto_data_read_flags and (3) otrl_proto_accept_data functions in src/proto.c; and (4) decode function in toolkit/parse.c in libotr before 3.2.1 allocates a zero-length buffer when decoding a base64 string, which allows remote attackers to cause a denial of service (application crash) via a message with the value "?OTR:===.", which triggers a heap-based buffer overflow.
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | libotr | 3.2.1-1 | — |
| Debian 13 | libotr | 3.2.1-1 | — |
| Debian 12 | libotr | 3.2.1-1 | — |
| Debian 6.0 | libotr | 3.2.0-2+squeeze1 | DSA-2526-1 |
Advisories 1
- DSA-2526-1 libotr - buffer overflow Debian Security (DSA / DLA) · Mar 9, 2026
References
- DSA-2526 vendor-advisory
- SUSE-SU-2012:1578 vendor-advisory
- libotr-base64-bo(77528) vdb-entry
- https://bugzilla.redhat.com/show_bug.cgi?id=846377
- MDVSA-2013:097 vendor-advisory
- MDVSA-2012:131 vendor-advisory
- http://otr.git.sourceforge.net/git/gitweb.cgi?p=otr/libotr%3Ba=commitdiff%3Bh=b17232f86f8e60d0d22caf9a2400494d3c77da58
- [OTR-dev] 20120727 otrl_base64_otr_decode() function... mailing-list
- [OTR-dev] 20120727 Re: otrl_base64_otr_decode() function... mailing-list
- http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=684121
- USN-1541-1 vendor-advisory
- openSUSE-SU-2012:1525 vendor-advisory
- http://otr.git.sourceforge.net/git/gitweb.cgi?p=otr/libotr%3Ba=commitdiff%3Bh=1902baee5d4b056850274ed0fa8c2409f1187435
- openSUSE-SU-2013:0155 vendor-advisory
- http://otr.git.sourceforge.net/git/gitweb.cgi?p=otr/libotr%3Ba=commitdiff%3Bh=6d4ca89cf1d3c9a8aff696c3a846ac5a51f762c1
- 54907 vdb-entry