TMA-MARIADB-7.4
Ensure Password Complexity Policies are in Place
설명
Passwords should be configured with a minimum length of 14 characters and should be checked against dictionaries of common, known, and expected passwords. Requires simple_password_check and cracklib_password_check ACTIVE with FORCE_PLUS_PERMANENT, simple_password_check_minimal_length >= 14 and strict_password_validation ON (the dictionary contents are not checked). Runs mariadb -NBe with the client defaults: as root on the server the unix_socket plugin usually authenticates; otherwise put an administrative account in ~/.my.cnf (mode 0600), not MYSQL_PWD (see 1.4/1.6).
점검 방법
감사 방식: SQL 쿼리
out=$(mariadb -NBe "SELECT IF((SELECT COUNT(*) FROM information_schema.PLUGINS WHERE LOWER(PLUGIN_NAME) IN ('simple_password_check', 'cracklib_password_check') AND PLUGIN_STATUS = 'ACTIVE' AND LOAD_OPTION = 'FORCE_PLUS_PERMANENT') = 2 AND (SELECT VARIABLE_VALUE FROM information_schema.GLOBAL_VARIABLES WHERE LOWER(VARIABLE_NAME) = 'simple_password_check_minimal_length') >= 14 AND @@global.strict_password_validation = 1, 'compliant', 'noncompliant')" 2>/dev/null) || exit 1; printf '%s\n' "$out"- 예상 출력
compliant
조치 방법
조치 방식: 가이드 또는 인프라 패치
Install the plugins (INSTALL SONAME 'simple_password_check'; INSTALL SONAME 'cracklib_password_check'; the cracklib plugin may need an OS package) and add under [mariadbd]: plugin_load_add = simple_password_check, simple_password_check = FORCE_PLUS_PERMANENT, simple_password_check_minimal_length = 14, plugin_load_add = cracklib_password_check, cracklib_password_check = FORCE_PLUS_PERMANENT, strict_password_validation = ON; restart.
속성
- 운영 체제
- 모두
- 태그
- mariadbdatabaseauthenticationpassword
- 참고 자료
- CIS MariaDB 10.11 Benchmark v1.0.0 - 7.4 Ensure Password Complexity Policies are in Place
이 호스트 점검하기
감사 권한이 있는 시스템에서 실행하세요. 스캔은 읽기 전용입니다.
tmaegis scan --target mariadb