Skip to content
OpenAdvisories
Medium · 4.8 CVE-2026-118767 EUVD-2026-113276

Botan: Python binding bcrypt APIs truncate passwords containing embedded NULs

Published Oct 29, 2026 · Updated Oct 30, 2026 · Assigned by GitHub_M

Description

Botan is a C++ cryptography library. From 1.11.22 until 3.13.0, Botan's Python binding converted Python strings containing U+0000 to const char* values without consistently rejecting the embedded NUL, causing bcrypt and check_bcrypt to process only the prefix before the NUL. Applications could validate a longer password but hash a shorter effective value, allowing application password-policy bypass; scrypt and argon2 are unaffected. This issue is fixed in version 3.13.0.

Affected products

VendorProductAffectedFixed
randombit botan >= 1.11.22, < 3.13.0 —

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.

ReleasePackageFixed inAdvisory
Debian 14 botan3 3.13.0+dfsg-2 —
Debian 13 botan +1 No fix yet —
Debian 12 botan No fix yet —
ReleasePackageFixed inAdvisory
Ubuntu 20.04 LTS botan No fix yet —
Ubuntu 18.04 LTS botan No fix yet —
Show 2 more (older releases, extended support, other products)
ReleasePackageFixed inAdvisory
Ubuntu Pro 24.04 LTS botan No fix yet —
Ubuntu Pro 22.04 LTS botan No fix yet —

Azure Linux

ReleasePackageFixed inAdvisory
Azure Linux 3 botan2 No fix yet —

References