CIS Ceph Benchmark

Security configuration benchmark for Ceph distributed storage

v1.0.0 03-2025

Overview

▶

This benchmark provides prescriptive guidance for establishing a secure configuration posture for Ceph distributed storage. It covers CephX authentication, keyring management, messenger v2 encryption, RGW TLS, network separation, dashboard security, pool hardening, OSD encryption at rest, CRUSH rules, and maintenance scheduling.

14Recommendations
7Sections
2Profile Levels
SectionAreaFocus
1Installation & IdentityVersion management, daemon user
2Authentication & Key ManagementCephX, keyring permissions
3Encryption & TLSMessenger v2, RGW TLS
4Logging & MonitoringCentralized logging, audit trails
5Network & Dashboard SecurityNetwork separation, dashboard TLS
6Storage & Data SecurityPool config, OSD encryption
7Maintenance & ResilienceCRUSH rules, scrub scheduling

Profile Definitions

▶
ProfileDescriptionIntended Use
L1Level 1 — StandardEssential security for all Ceph deployments; minimal performance impact.
L2Level 2 — HardenedAdvanced hardening for PCI-DSS, HIPAA, or high-security environments.

1 — Installation & Identity

▶

1.1 Version & Process Security

▶
1.1.1 Ensure Ceph is running the latest stable version (Manual)
L1 Manual
Description

This recommendation verifies that Ceph is running the latest stable version on the Ceph distributed storage system. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Ceph distributed storage system vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Verify Ceph version
ceph --version
ceph health detail
Remediation
# Update Ceph to latest stable
apt-get update && apt-get install --only-upgrade ceph ceph-common
# Or use cephadm:
ceph orch upgrade start --ceph-version 18.2.x
ceph orch upgrade status
1.1.2 Ensure Ceph daemons run as a dedicated non-root user (Automated)
L1 Auto
Description

This recommendation verifies that Ceph daemons run as a dedicated non-root user on the Ceph distributed storage system. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Ceph distributed storage system vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check Ceph daemon users
ps -eo user,pid,comm | grep ceph
grep 'setuser' /etc/ceph/ceph.conf
Remediation
# Ensure daemons run as ceph user
# In ceph.conf [global]:
# setuser match path = /var/lib/ceph/$type/$cluster-$id
useradd -r -s /usr/sbin/nologin ceph 2>/dev/null
chown -R ceph:ceph /var/lib/ceph /var/log/ceph /etc/ceph

2 — Authentication & Key Management

▶

2.1 CephX & Keyrings

▶
2.1.1 Ensure CephX authentication is required for all connections (Automated)
L1 Auto
Description

This recommendation ensures that CephX authentication is required for all connections on the Ceph distributed storage system. Enforcing this requirement establishes a minimum security standard and prevents insecure configurations.

Rationale

Without this enforcement, the Ceph distributed storage system may accept insecure configurations that weaken overall security posture. Mandating this control ensures consistent protection against common attack vectors.

Audit
# Check CephX authentication
ceph config get mon auth_cluster_required
ceph config get mon auth_service_required
ceph config get mon auth_client_required
Remediation
# Enable CephX authentication
# In ceph.conf [global]:
# auth_cluster_required = cephx
# auth_service_required = cephx
# auth_client_required = cephx
ceph config set global auth_cluster_required cephx
ceph config set global auth_service_required cephx
ceph config set global auth_client_required cephx
2.1.2 Ensure keyring files have restricted permissions (Automated)
L1 Auto
Description

This setting ensures that keyring files have restricted permissions on the Ceph distributed storage system. Restricting this capability limits potential abuse and enforces the principle of least privilege across the environment.

Rationale

Unrestricted access to this capability could allow unauthorized users or processes to perform actions beyond their intended scope. Applying least-privilege principles to the Ceph distributed storage system is essential for defense in depth.

Audit
# Check keyring permissions
find /etc/ceph -name '*.keyring' -exec stat -c '%a %U %G %n' {} \;
ceph auth ls | head -30
Remediation
# Restrict keyring permissions
chmod 600 /etc/ceph/*.keyring
chown ceph:ceph /etc/ceph/*.keyring
# Remove unnecessary auth keys:
ceph auth rm client.unused_key
# Rotate admin key:
ceph auth get-or-create client.admin mon 'allow *' osd 'allow *' mgr 'allow *' mds 'allow *'

3 — Encryption & TLS

▶

3.1 Messenger & RGW TLS

▶
3.1.1 Ensure messenger v2 encryption is enabled for all traffic (Automated)
L1 Auto
Description

This recommendation verifies that messenger v2 encryption is enabled for all traffic on the Ceph distributed storage system. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Ceph distributed storage system vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check messenger v2 encryption
ceph config get global ms_cluster_mode
ceph config get global ms_service_mode
ceph config get global ms_client_mode
Remediation
# Enable messenger v2 encryption
ceph config set global ms_cluster_mode 'secure crc'
ceph config set global ms_service_mode 'secure crc'
ceph config set global ms_client_mode 'secure crc'
# For strict encryption:
ceph config set global ms_cluster_mode secure
ceph config set global ms_service_mode secure
ceph config set global ms_client_mode secure
3.1.2 Ensure RADOS Gateway uses TLS with valid certificates (Automated)
L1 Auto
Description

This recommendation verifies that RADOS Gateway uses TLS with valid certificates on the Ceph distributed storage system. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Ceph distributed storage system vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check RGW TLS configuration
ceph config get client.rgw rgw_frontends
grep 'rgw_frontends\|ssl' /etc/ceph/ceph.conf
Remediation
# Configure RGW with TLS
# In ceph.conf [client.rgw.<name>]:
# rgw_frontends = beast ssl_port=443 ssl_certificate=/etc/ceph/rgw-cert.pem ssl_private_key=/etc/ceph/rgw-key.pem
ceph config set client.rgw rgw_frontends 'beast ssl_port=443 ssl_certificate=/etc/ceph/rgw-cert.pem ssl_private_key=/etc/ceph/rgw-key.pem'
chmod 600 /etc/ceph/rgw-*.pem

4 — Logging & Monitoring

▶

4.1 Log Configuration & Audit

▶
4.1.1 Ensure centralized logging with syslog forwarding is configured (Automated)
L1 Auto
Description

This recommendation verifies that centralized logging with syslog forwarding is configured on the Ceph distributed storage system. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Ceph distributed storage system vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check Ceph logging configuration
ceph config get global log_to_file
ceph config get global log_file
ceph config get global mon_cluster_log_file
Remediation
# Configure centralized logging
ceph config set global log_to_file true
ceph config set global log_file /var/log/ceph/$cluster-$name.log
ceph config set global mon_cluster_log_file /var/log/ceph/$cluster.log
ceph config set global log_to_syslog true
ceph config set global err_to_syslog true
4.1.2 Ensure audit logging with log rotation is enabled (Automated)
L1 Auto
Description

This recommendation verifies that audit logging with log rotation is enabled on the Ceph distributed storage system. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Ceph distributed storage system vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check debug and audit logging
ceph config get global debug_mon
ceph config get global debug_osd
ceph config get mgr mgr/cephadm/log_to_cluster
Remediation
# Configure audit logging (low debug for production)
ceph config set global debug_mon 1/5
ceph config set global debug_osd 1/5
ceph config set global debug_auth 2/5
# Enable manager audit logging:
ceph config set mgr mgr/cephadm/log_to_cluster true
# Log rotation:
cat > /etc/logrotate.d/ceph << 'EOF'
/var/log/ceph/*.log {
    daily
    rotate 14
    compress
    missingok
    notifempty
    sharedscripts
    postrotate
        killall -q -1 ceph-mon ceph-osd ceph-mds ceph-mgr
    endscript
}
EOF

5 — Network & Dashboard Security

▶

5.1 Network Separation & Dashboard TLS

▶
5.1.1 Ensure public and cluster networks are separated (Automated)
L1 Auto
Description

This recommendation verifies that public and cluster networks are separated on the Ceph distributed storage system. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Ceph distributed storage system vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check network separation
grep -E 'public_network|cluster_network' /etc/ceph/ceph.conf
ceph config get global public_network
ceph config get global cluster_network
Remediation
# Separate public and cluster networks
# In ceph.conf [global]:
# public_network = 10.0.1.0/24
# cluster_network = 10.0.2.0/24
ceph config set global public_network 10.0.1.0/24
ceph config set global cluster_network 10.0.2.0/24
# Firewall rules:
ufw allow from 10.0.1.0/24 to any port 6789,3300
ufw allow from 10.0.2.0/24 to any port 6800:7300
5.1.2 Ensure management dashboard uses TLS with authentication (Automated)
L1 Auto
Description

This recommendation verifies that management dashboard uses TLS with authentication on the Ceph distributed storage system. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Ceph distributed storage system vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check mgr dashboard TLS
ceph mgr module ls | grep -A3 dashboard
ceph config get mgr mgr/dashboard/ssl
Remediation
# Enable dashboard with TLS
ceph mgr module enable dashboard
ceph dashboard create-self-signed-cert
# Or use proper certs:
ceph dashboard set-ssl-certificate -i /etc/ceph/dashboard-cert.pem
ceph dashboard set-ssl-certificate-key -i /etc/ceph/dashboard-key.pem
ceph config set mgr mgr/dashboard/ssl true
ceph dashboard ac-user-create admin -i /tmp/pw.txt administrator

6 — Storage & Data Security

▶

6.1 Pool & OSD Hardening

▶
6.1.1 Ensure pools have appropriate replication and application tags (Automated)
L1 Auto
Description

This recommendation verifies that pools have appropriate replication and application tags on the Ceph distributed storage system. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Ceph distributed storage system vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check pool configuration
ceph osd pool ls detail | head -30
ceph osd pool get <pool_name> size
ceph osd pool get <pool_name> min_size
Remediation
# Harden pool settings
# Set replication factor:
ceph osd pool set <pool_name> size 3
ceph osd pool set <pool_name> min_size 2
# Enable application tags:
ceph osd pool application enable <pool_name> rbd
# Set PG autoscale:
ceph osd pool set <pool_name> pg_autoscale_mode on
6.1.2 Ensure OSD encryption at rest is enabled (Automated)
L1 Auto
Description

This recommendation verifies that OSD encryption at rest is enabled on the Ceph distributed storage system. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Ceph distributed storage system vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check OSD encryption
ceph osd tree
lsblk -o NAME,FSTYPE,MOUNTPOINT | grep ceph
dmsetup ls --target crypt 2>/dev/null
Remediation
# Enable OSD encryption at rest
# For new OSDs with cephadm:
ceph config set global osd_dmcrypt_type luks2
# Deploy encrypted OSD:
ceph orch daemon add osd <host>:<device> --encrypted=true
# Verify:
ceph osd metadata <osd_id> | grep dmcrypt

7 — Maintenance & Resilience

▶

7.1 CRUSH Rules & Scrub Settings

▶
7.1.1 Ensure CRUSH rules use appropriate failure domains (Automated)
L1 Auto
Description

This recommendation verifies that CRUSH rules use appropriate failure domains on the Ceph distributed storage system. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Ceph distributed storage system vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check CRUSH map and erasure coding
ceph osd crush rule ls
ceph osd erasure-code-profile ls
ceph osd crush dump | head -20
Remediation
# Configure CRUSH rules for failure domains
ceph osd crush rule create-replicated replicated_rack default rack
ceph osd pool set <pool_name> crush_rule replicated_rack
# Create erasure coding profile:
ceph osd erasure-code-profile set ec-4-2 k=4 m=2 crush-failure-domain=rack
ceph osd pool create ec-pool 32 erasure ec-4-2
7.1.2 Ensure balancer and scrub maintenance windows are configured (Automated)
L1 Auto
Description

This recommendation verifies that balancer and scrub maintenance windows are configured on the Ceph distributed storage system. Implementing this control strengthens the overall security configuration and reduces exposure to potential threats.

Rationale

Failure to implement this control may leave the Ceph distributed storage system vulnerable to attack or non-compliant with organizational security policies. This control helps establish a consistent, hardened configuration baseline.

Audit
# Check balancer and scrub settings
ceph balancer status
ceph config get osd osd_scrub_auto_repair
ceph config get global osd_max_scrubs
Remediation
# Configure balancer and maintenance
ceph balancer mode upmap
ceph balancer on
# Configure scrub settings:
ceph config set global osd_max_scrubs 1
ceph config set osd osd_scrub_auto_repair true
ceph config set osd osd_deep_scrub_interval 604800
# Set maintenance window:
ceph config set osd osd_scrub_begin_hour 2
ceph config set osd osd_scrub_end_hour 6