TMAegisBeta
Thêm quy tắc cho cockroachdb

CockroachDB

TMA-COCKROACHDB-6.6

Ensure SQL Session Idle Timeouts Are Configured for SQL Roles

Trung bìnhCấp 1Xem xét thủ côngcockroachdb

Mô tả

CockroachDB allows administrators to define role-level SQL session idle timeouts using the idle_in_session_timeout session variable. This setting ensures that any session authenticated under a given SQL role is automatically terminated after a defined period of inactivity. Configuring idle session timeouts for SQL roles provides a more granular control model than cluster-wide settings.

Cách kiểm tra

Phương pháp kiểm tra: Xem xét thủ công

Khuyến nghị này không thể kiểm tra tự động. Lần quét sẽ liệt kê mục này kèm hướng dẫn khi bạn truyền cờ --include-manual.

For every SQL role run SHOW DEFAULT SESSION VARIABLES FOR ROLE <role_name>; idle_in_session_timeout must appear with a non-zero value aligned with policy (e.g. 10m-30m for administrative roles, up to 1h for application roles with documented justification). Roles without it are a finding.

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

1. Set idle timeout for a SQL role: Set a reasonable timeout for idle connections: ALTER ROLE <role_name> SET idle_in_session_timeout = '<duration>'; -- Example - set 30-minute idle timeout for a read-only role: ALTER ROLE table_reader SET idle_in_session_timeout = '30m';

Thuộc tính

Hệ điều hành
Bất kỳ
Thẻ
cockroachdbsession
Tham chiếu
CIS CockroachDB v25.x Benchmark v1.0.0 - 6.6 Ensure SQL Session Idle Timeouts Are Configured for SQL Roles