Where
-Infinity
0
Severity
7.5
Integer Underflow
AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H

In MIT Kerberos 5 (aka krb5) before 1.22.3, there is an integer underflow and resultant out-of-bounds read if an application calls gssacceptseccontext() on a system with a NegoEx mechanism registered in /etc/gss/mech. An unauthenticated remote attacker can trigger this, possibly causing the process to terminate in parsemessage.

1 / 2
Source: MITRE
First published (updated )
Severity
7.1
Integer Overflow
AV:N/AC:H/PR:L/UI:N/S:C/C:N/I:L/A:H

In MIT Kerberos 5 (aka krb5) before 1.22 (with incremental propagation), there is an integer overflow for a large update size to resize() in kdblog.c. An authenticated attacker can cause an out-of-bounds write and kadmind daemon crash.

1 / 4
Source: MITRE
First published (updated )
Severity
5
Integer Underflow
AV:N/AC:H/PR:H/UI:N/S:U/C:L/I:N/A:H

An integer underflow vulnerability was found in MIT krb5 in the berval2tldata() function in plugins/kdb/ldap/libkdbldap/ldapprincipal2.c. The function performs an unsigned subtraction (bvlen - 2) without a prior bounds check. When bvlen is 0 or 1, the subtraction wraps to a large value which is then truncated to uint16t, yielding 0xFFFE (65534) or 0xFFFF (65535). The subsequent malloc succeeds and memcpy reads up to 65534 bytes from a 0-1 byte buffer, resulting in a heap out-of-bounds read.

The attack vector involves a malicious or compromised LDAP KDB backend returning a krbExtraData attribute with bvlen < 2, triggering the underflow when the KDC or kadmind reads principal data.

Upstream fix: https://github.com/krb5/krb5/commit/2a5fd83 MIT ticket: https://krbdev.mit.edu/rt/Ticket/Display.html?id=9206

1 / 4
Source: Red Hat
First published (updated )
Severity
4

An integer underflow vulnerability was found in MIT krb5 in the berval2tldata() function in plugins/kdb/ldap/libkdbldap/ldapprincipal2.c. The function performs an unsigned subtraction (bvlen - 2) without a prior bounds check. When bvlen is 0 or 1, the subtraction wraps to a large value which is then truncated to uint16t, yielding 0xFFFE (65534) or 0xFFFF (65535). The subsequent malloc succeeds and memcpy reads up to 65534 bytes from a 0-1 byte buffer, resulting in a heap out-of-bounds read.

The attack vector involves a malicious or compromised LDAP KDB backend returning a krbExtraData attribute with bvlen < 2, triggering the underflow when the KDC or kadmind reads principal data.

Upstream fix: https://github.com/krb5/krb5/commit/2a5fd83 MIT ticket: https://krbdev.mit.edu/rt/Ticket/Display.html?id=9206

First published (updated )
Severity
1

A flaw was found in MIT krb5 1.6 or later, an authenticated kadmin user with permission to add principals to an LDAP Kerberos database can circumvent a DN containership check by supplying both a "linkdn" and "containerdn" database argument, or by supplying a DN string which is a left extension of a container DN string but is not hierarchically within the container DN.

Reference: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=891869

Upstream patch: https://github.com/krb5/krb5/commit/e1caf6fb74981da62039846931ebdffed71309d1

First published (updated )
Severity
1

A flaw was found in MIT krb5 1.6 or later, an authenticated kadmin user with permission to add principals to an LDAP Kerberos database can cause a null dereference in kadmind, or circumvent a DN container check, by supplying tagged data intended to be internal to the database module.

Reference: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=891869

Upstream patch: https://github.com/krb5/krb5/commit/e1caf6fb74981da62039846931ebdffed71309d1

First published (updated )

Hi,

just a quick note that MIT krb5 has fixed two unauthenticated network NegoEx parsing vulnerabilities.

Affected versions:

MIT krb5 1.18 and later, when an application calls gssacceptseccontext() on a system with a NegoEx mechanism registered in /etc/gss/mech

Description:

CVE-2026-40355 is a null pointer dereference in parsenegomessage(). The result of the second vectorbase() call was not checked before being dereferenced. An unauthenticated remote attacker can trigger this issue and crash the process.

CVE-2026-40356 is a read overrun of up to 52 bytes in parsemessage(). A short headerlen could cause an integer underflow while calculating the remaining message length. An unauthenticated remote attacker can trigger this issue and possibly crash the proces. Exfiltration of the bytes read appears unlikely.

MIT krb5 security confirmed the following CVSS v3.1 vectors:

CVE-2026-40355: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H Base score: 7.5

CVE-2026-40356: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:N/I:N/A:H Base score: 5.9

Users are recommended to apply the upstream patch or update to a version containing the fix.

Credit: Cem Onat Karagun

References: https://github.com/krb5/krb5/commit/2e75f0d9362fb979f5fc92829431a590a130929f https://cems.fun/2026/04/27/krb5-two-unauthenticated-network-vulnerabilities.html https://www.youtube.com/watch?v=zpBrriAJxCQ

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203