linux – 审计设置的建议

我正在尝试学习如何保护 Linux机箱(我正在使用Ubuntu).建议使用Auditd监视节点上的活动.我已设法安装它,但我找不到有关正确设置以保护我的节点的更多信息.

我应该如何设置auditd以使我的节点更安全?我应该监控什么?为什么?我正在寻找有经验的管理员的设置示例和建议.

谢谢!

解决方法

需要明确的是,auditd是一个非常宝贵的工具,但它不会使您的系统更安全.它会做什么,为您提供更详细的某些活动记录.有人仍需要查看生成的日志.就像树一样,如果监视一个活动,但没有人在看,那么日志是否重要?

最简单的是,我在/etc/audit/audit.rules中使用了以下内容.每当setrlimit或stime系统调用exit时,以及每当删除目录时,它都会抛出一个日志.

# This file contains the auditctl rules that are loaded
# whenever the audit daemon is started via the initscripts.
# The rules are simply the parameters that would be passed
# to auditctl.

# First rule - delete all
-D

-e 1

# Increase the buffers to survive stress events.
# Make this bigger for busy systems
-b 1024

# Feel free to add below this line. See auditctl man page
-a exit,always -S unlink -S rmdir
-a exit,always -S stime.*
-a exit,always -S setrlimit.*

对于一些更深入的例子,请查看RHEL 5.1-5.2的CIS基准测试.不幸的是,Ubuntu没有一个,Debian的一个已经有几年了.但是,该部分中不应该有任何特定于分发的内容.

相关文章

insmod和modprobe加-f参数导致Invalid module format错误 这...
将ArchLinux安装到U盘 几个月前入门Arch的时候上网搜了不少安...
1、安装Apache。 1)执行如下命令,安装Apache服务及其扩展包...
一、先说一下用ansible批量采集机器信息的实现办法: 1、先把...
安装配置 1. 安装vsftpd 检查是否安装了vsftpd # rpm -qa | ...
如何抑制stable_secret读取关键的“net.ipv6.conf.all.stabl...