CentOS 系统RPM 安全检查

运行下面的命令可以检查rpm包安装后发生了什么改变


# rpm -Va
S.5....T.  c /etc/watchdog.conf
S.5....T.  c /etc/xinetd.d/tftp
S.5....T.  c /etc/rc.d/rc.local
S.5....T.  c /etc/sysctl.conf
S.5....T.  c /etc/bashrc
S.5....T.  c /etc/dhcp/dhcpd.conf
....L....  c /etc/pam.d/fingerprint-auth
....L....  c /etc/pam.d/password-auth
....L....  c /etc/pam.d/smartcard-auth
....L....  c /etc/pam.d/system-auth
S.5....T.  c /etc/security/limits.conf
S.5....T.  c /etc/postfix/main.cf
S.5....T.  c /etc/ssh/sshd_config
S.5....T.  c /etc/nanorc
S.5....T.  c /etc/httpd/conf/httpd.conf


代码的意思是

S file Size differs
M Mode differs (includes permissions and file type)
5 digest (formerly MD5 sum) differs
D Device major/minor number mismatch
L readLink(2) path mismatch
U User ownership differs
G Group ownership differs
T mTime differs
P caPabilities differ


以 /etc/watchdog.conf为例

S.5....T. c /etc/watchdog.conf


第一个字母S,是文件size发生了变化

第二个是数字5,是文件的md5值发生了变化

第三个字母T,是mtime发生了变化

第四个字母c,是change的缩写。


可以看出,这个文件在watchdog软件包安装后,发生了编辑行为。由于是配置文件发生修改,基本可以视作正常的,如果是二进制文件被修改,就值得注意了。

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值