Ubuntu · Boot & system hardening

Disable core dumps of setuid programs

When it fails: Privileged programs can write their memory to core dump files. A crashing setuid program can leave secrets such as password hashes in a core file.

CB-UBU-BOOT-005mediumactiveautomatedautomated fixprofile core

As released in v0.1.2 (beta). Current state.

Description

The fs.suid_dumpable sysctl decides whether a process that changed privileges (setuid or setgid programs, or programs that dropped privileges) can produce a core dump when it crashes. With 0, such processes never dump core.

1 dumps them like any process and 2 dumps them readable by root only. Both are unsafe on production systems. Core dumps of regular processes are a separate topic.

On Ubuntu, apport writes 2 to fs.suid_dumpable when it starts, after /etc/sysctl.d/ has been applied, and 0 when it stops. The value set by this fix only survives a reboot when apport is disabled (CB-UBU-BOOT-015).

Rationale

Setuid programs such as passwd or su handle secrets while running with root privileges. A core dump of their memory can expose password hashes, keys or tokens, and an attacker who can make one crash may be able to read the dump.

Impact

Crashes of setuid programs cannot be analysed from a core dump. Debug them on a test system.

Setting

Locationsysctl `fs.suid_dumpable`, persisted in `/etc/sysctl.d/`
Default2 while apport runs, 0 otherwise
Recommended0

Audit

Run sysctl fs.suid_dumpable. The value must be 0. Then check that no sysctl configuration file sets another value.

Automated: every check must pass. Scanners report each check by its id.

running

Running value of fs.suid_dumpable.

key: fs.suid_dumpable
value: 0

Remediation

Create /etc/sysctl.d/60-cirsec.conf containing fs.suid_dumpable = 0, remove any other assignment of this key, then run sysctl --system.

Restartnone
Disruptionnone

Rollback

Remove the line from /etc/sysctl.d/60-cirsec.conf and run sysctl --system.

set

Generated from check running: the engine writes the fix for every output, it sets the expected value and the check runs again after.

Each release turns these fixes into remediate.sh and an Ansible role per profile: dry run by default, a fix runs only when its check fails.

References

Mappings

FrameworkIDRelationNote
ANSSI-BP-028 - Recommandations de configuration d'un système GNU/Linux2.0R14partialR14 lists several filesystem settings; this control covers fs.suid_dumpable.
NIST SP 800-53 Rev. 55.1.1SI-11related

How this control relates to the other framework's: equivalent, stricter, looser, partial or related.

Threats mitigated

People and lifecycle

Authors
Verified2026-10-19 by Sn0wAlice on 20.04, Proxmox VM, Ubuntu 20.04 cloud image, kernel 5.4.0-216-generic, BIOS boot. Fails on a fresh install (2, set by apport); passes once CB-UBU-BOOT-015 stops apport; 0 kept after reboot.
Verified2026-10-19 by Sn0wAlice on 22.04, Proxmox VM, Ubuntu 22.04 cloud image, kernel 5.15.0-198-generic, BIOS boot. Fails on a fresh install (2, set by apport); passes once CB-UBU-BOOT-015 stops apport; 0 kept after reboot.
Verified2026-10-19 by Sn0wAlice on 24.04, Proxmox VM, Ubuntu 24.04 cloud image, kernel 6.8.0-147-generic, BIOS boot. Fails on a fresh install (2, set by apport); passes once CB-UBU-BOOT-015 stops apport; 0 kept after reboot.
Verified2026-10-19 by Sn0wAlice on 26.04, Proxmox VM, Ubuntu 26.04 cloud image, kernel 7.0.0-38-generic, BIOS boot. Fails on a fresh install (2, set by apport); passes once CB-UBU-BOOT-015 stops apport; 0 kept after reboot.
Introduced inv0.1.0
Created, updated2026-10-19, 2026-10-19
Translationsfr