在 rhel6 系统上,我使用本指南启用了 fips:
重新启动系统后,sudo 条目不再起作用。
进入 sudoers:
example ALL=(ALL) ALL
使用 sudo 运行的命令示例:
sudo ls -l /root
[sudo] password for example:
/var/cache/.security.db: unable to flush: Permission denied
sudo: PERM_ROOT: setresuid(0, -1, -1): Operation not permitted
sudo: unable to open /var/db/sudo/example/2: Operation not permitted
sudo: unable to send audit message: Operation not permitted
sudo: unable to set supplementary group IDs: Operation not permitted
sudo: unable to execute /bin/ls: Operation not permitted
使用 sudo 运行脚本时的另一个错误,在 sudoers 中使用此条目:
example ALL=/usr/local/bin/example_script.sh
结果:
sudo /usr/local/bin/example_script.sh
[sudo] password for example:
sudo: PERM_ROOT: setresuid(0, -1, -1): Operation not permitted
sudo: unable to open /var/db/sudo/example/1: Operation not permitted
sudo: unable to send audit message: Operation not permitted
sudo: unable to set supplementary group IDs: Operation not permitted
sudo: unable to execute /usr/local/bin/example_script.sh: Operation not
可能相关的日志条目:
examplehost sudo: pam_krb5[30799]: authentication succeeds for 'example' (example@exampledomain)
examplehost sudo: example : unable to open /var/db/sudo/example/2 : Permission denied ; TTY=pts/2 ; PWD=/home/example ; USER=root ; COMMAND=/bin/ls -l /root
examplehost example : TTY=pts/2 ; PWD=/home/example ; USER=root ; COMMAND=/bin/ls -l /root
examplehost sudo: pam_keyinit(sudo:session): Unable to change GID to 0 temporarily examplehost su: pam_unix(su-l:session): session closed for user example
examplehost su: pam_unix(su-l:session): session closed for user example
请注意,系统正在使用活动目录身份验证。
我尝试将 /var/db/sudo 和 /var/cache/.security.db 移开,但没有任何效果。
sudoers 中的现有条目以及新创建的条目都会受到影响。我环顾四周,但还没有找到任何解决方案。否则系统工作正常,它接受 ssh 登录,网络服务器也在运行。
限制似乎很好:
ulimit -u
31353
cat /etc/security/limits.d/90-nproc.conf
* soft nproc 1024
root soft nproc unlimited