CVE-2025-21646: afs: Fix the maximum cell name length

Published Jan 19, 2025
·
Updated

In the Linux kernel, the following vulnerability has been resolved:

afs: Fix the maximum cell name length

The kafs filesystem limits the maximum length of a cell to 256 bytes, but a problem occurs if someone actually does that: kafs tries to create a directory under /proc/net/afs/ with the name of the cell, but that fails with a warning:

WARNING: CPU: 0 PID: 9 at fs/proc/generic.c:405

because procfs limits the maximum filename length to 255.

However, the DNS limits the maximum lookup length and, by extension, the maximum cell name, to 255 less two (length count and trailing NUL).

Fix this by limiting the maximum acceptable cellname length to 253. This also allows us to be sure we can create the "/afs/.<cell>/" mountpoint too.

Further, split the YFS VL record cell name maximum to be the 256 allowed by the protocol and ignore the record retrieved by YFSVL.GetCellName if it exceeds 253.

Other sources

In the Linux kernel, the following vulnerability has been resolved:

afs: Fix the maximum cell name length

The kafs filesystem limits the maximum length of a cell to 256 bytes, but a problem occurs if someone actually does that: kafs tries to create a directory under /proc/net/afs/ with the name of the cell, but that fails with a warning:

WARNING: CPU: 0 PID: 9 at fs/proc/generic.c:405

because procfs limits the maximum filename length to 255.

However, the DNS limits the maximum lookup length and, by extension, the maximum cell name, to 255 less two (length count and trailing NUL).

Fix this by limiting the maximum acceptable cellname length to 253. This also allows us to be sure we can create the "/afs/.<cell>/" mountpoint too.

Further, split the YFS VL record cell name maximum to be the 256 allowed by the protocol and ignore the record retrieved by YFSVL.GetCellName if it exceeds 253.

NVD

This CVE was automatically created from a reference found in an email or other text. If you are reading this, then this CVE entry is probably erroneous, since this text should be replaced by the official CVE description automatically.

Launchpad

Affected Software

14 affected componentsFixes available
Linux Kernel
debian/linux<=5.10.223-1
5.10.234-16.1.129-16.1.135-16.12.27-1
debian/linux-6.1
6.1.129-1~deb11u1
Linux Linux kernel>=5.8<5.10.234
Linux Linux kernel>=5.11<5.15.177
Linux Linux kernel>=5.16<6.1.125
Linux Linux kernel>=6.2<6.6.72
Linux Linux kernel>=6.7<6.12.10
Linux Linux kernel=6.13-rc1
Linux Linux kernel=6.13-rc2
Linux Linux kernel=6.13-rc3
Linux Linux kernel=6.13-rc4
Linux Linux kernel=6.13-rc5
Linux Linux kernel=6.13-rc6

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Upgrade

    Upgrade debian/linux to a version that resolves this vulnerability.

    Fixed in 5.10.234-1Fixed in 6.1.129-1Fixed in 6.1.135-1Fixed in 6.12.27-1
  2. Upgrade

    Upgrade debian/linux-6.1 to a version that resolves this vulnerability.

    Fixed in 6.1.129-1~deb11u1
  3. Configuration

    Limit the maximum acceptable AFS cell name length to 253 (to avoid procfs filename limit issues).

    kafs filesystem (cell name handling) maximum acceptable cellname length = 253
  4. Configuration

    Set the YFS VL record cell name maximum to the 256 allowed by the protocol; when reading via YFSVL.GetCellName, ignore the retrieved record if the cell name exceeds 253.

    kafs filesystem (YFS VL record parsing) YFS VL record cell name maximum = 256 (protocol limit)
  5. Compensating control

    Ensure any created /proc/net/afs/ directory entries use cell names that do not exceed the procfs maximum filename length of 255 (255 less two for length count and trailing NUL), which implies enforcing the 253 byte limit for cell names.

Event History

Jan 19, 2025
CVE Published
via MITRE·10:18 AM
Data Sourced
via MITRE·10:18 AM
DescriptionSeverity
Data Sourced
via Red Hat·11:02 AM
DescriptionSeverityAffected Software
Data Sourced
via NVD·11:15 AM
Description
Data Sourced
via NVD·11:15 AM
RemedySeverityAffected Software
Mar 27, 2025
Data Sourced
via Launchpad·06:49 PM
Description
Apr 28, 2025
Data Sourced
via Ubuntu·06:56 PM
RemedyDescriptionSeverityAffected Software

Frequently Asked Questions

1

What is the severity of CVE-2025-21646?

The severity of CVE-2025-21646 is classified as moderate due to potential denial-of-service impacts.

2

How do I fix CVE-2025-21646?

To fix CVE-2025-21646, you should update to the latest version of the Linux kernel where the vulnerability has been patched.

3

What systems are affected by CVE-2025-21646?

CVE-2025-21646 affects all versions of the Linux kernel that utilize the kafs filesystem.

4

What are the potential impacts of CVE-2025-21646?

The potential impacts of CVE-2025-21646 include system instability and denial of service when exceeding the maximum cell name length.

5

When was CVE-2025-21646 reported?

CVE-2025-21646 was reported in early 2025, highlighting an issue with the kafs filesystem in the Linux kernel.

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