TMAegisBeta
Thêm quy tắc cho cockroachdb

CockroachDB

TMA-COCKROACHDB-6.5

Ensure OCSP Certificate Revocation Checking Is Enabled

Trung bìnhCấp 1Tự độngcockroachdb

Mô tả

Online Certificate Status Protocol (OCSP) is a mechanism for checking whether a certificate has been revoked by its Certificate Authority (CA) before it expires. CockroachDB supports OCSP checking through the security.ocsp.mode cluster setting, which can be configured to verify certificate revocation status when validating client and node certificates. Runs cockroach sql with --certs-dir ${COCKROACH_CERTS_DIR:-/var/lib/cockroach/certs} (a root or admin client certificate must be in it); the target node comes from COCKROACH_HOST (default localhost:26257) or COCKROACH_URL. The benchmark rates this recommendation Manual; the automated check covers its objective pass criterion. Passes when security.ocsp.mode is strict or lax (default off); strict is recommended where the OCSP responder is reliable.

Cách kiểm tra

Phương pháp kiểm tra: Truy vấn SQL

sql_query
out=$(cockroach sql --certs-dir="${COCKROACH_CERTS_DIR:-/var/lib/cockroach/certs}" --format=csv --execute "SHOW CLUSTER SETTING security.ocsp.mode;" 2>/dev/null) || exit 1; printf '%s\n' "$out" | awk 'NR == 2 {v = tolower($0)} END {print (v == "strict" || v == "lax") ? "compliant" : "mode " v}'
Đầu ra mong đợi
compliant

Cách khắc phục

Phương pháp khắc phục: Hướng dẫn hoặc bản vá hạ tầng

SET CLUSTER SETTING security.ocsp.mode = 'strict'; (or 'lax' if OCSP availability cannot be guaranteed) and tune security.ocsp.timeout.

Thuộc tính

Hệ điều hành
Bất kỳ
Thẻ
cockroachdbtls
Tham chiếu
CIS CockroachDB v25.x Benchmark v1.0.0 - 6.5 Ensure OCSP Certificate Revocation Checking Is Enabled

Kiểm tra máy này

Chạy lệnh này trên máy bạn được phép kiểm tra. Lần quét chỉ ở chế độ đọc.

shell
tmaegis scan --target cockroachdb