[root@vm chkrootkit]# mkdir .commands# 拷贝依赖的系统命令文件到.commands
[root@vm chkrootkit]# cp `which --skip-alias awk cut echo find egrep id head ls netstat ps strings sed uname` .commands/
[root@vm chkrootkit]# ls .commands/
awk cutecho egrep find headidls netstat ps sed strings uname# 打包系统文件,备份到安全的地方
[root@vm chkrootkit]# tar zcvf commands.tar.gz .commands/
.commands/
.commands/awk
.commands/cut
.commands/echo
.commands/find
.commands/egrep
.commands/id
.commands/head
.commands/ls
.commands/netstat
.commands/ps
.commands/strings
.commands/sed
.commands/uname
# 使用备份命令检测
[root@vm chkrootkit]# ./chkrootkit -p ./.commands/
RKHunter
简介
RKHunter是专业检测系统rootkit的工具
MD5校验测试
检测rootkit使用的二进制核系统工具文件
检测特洛伊木马程序的特征码
检测常用程序的文件属性是否异常
检测系统相关的测试
检测隐藏文件
检测可疑的核心模块LKM
检测系统已启用的监听端口
安装
# 下载安装包
[root@vm ~] wget https://jaist.dl.sourceforge.net/project/rkhunter/rkhunter/1.4.6/rkhunter-1.4.6.tar.gz
# 解压
[root@vm ~] tar xvf rkhunter-1.4.6.tar.gz
# 安装
[root@vm rkhunter-1.4.6] cd rkhunter-1.4.6/
[root@vm rkhunter-1.4.6] ./installer.sh --install
Checking system for:
Rootkit Hunter installer files: found
A web file download command: wget found
Starting installation:
Checking installation directory "/usr/local": it exists and is writable.
Checking installation directories:
Directory /usr/local/share/doc/rkhunter-1.4.6: creating: OK
Directory /usr/local/share/man/man8: exists and is writable.
Directory /etc: exists and is writable.
Directory /usr/local/bin: exists and is writable.
Directory /usr/local/lib64: exists and is writable.
Directory /var/lib: exists and is writable.
Directory /usr/local/lib64/rkhunter/scripts: creating: OK
Directory /var/lib/rkhunter/db: creating: OK
Directory /var/lib/rkhunter/tmp: creating: OK
Directory /var/lib/rkhunter/db/i18n: creating: OK
Directory /var/lib/rkhunter/db/signatures: creating: OK
Installing check_modules.pl: OK
Installing filehashsha.pl: OK
Installing stat.pl: OK
Installing readlink.sh: OK
Installing backdoorports.dat: OK
Installing mirrors.dat: OK
Installing programs_bad.dat: OK
Installing suspscan.dat: OK
Installing rkhunter.8: OK
Installing ACKNOWLEDGMENTS: OK
Installing CHANGELOG: OK
Installing FAQ: OK
Installing LICENSE: OK
Installing README: OK
Installing language support files: OK
Installing ClamAV signatures: OK
Installing rkhunter: OK
Installing rkhunter.conf: OK
Installation complete
# 默认安装到/usr/local/bin下
[root@vm ~]# which rkhunter
/usr/local/bin/rkhunter
【推荐】国内首个AI IDE,深度理解中文开发场景,立即下载体验Trae
【推荐】编程新体验,更懂你的AI,立即体验豆包MarsCode编程助手
【推荐】抖音旗下AI助手豆包,你的智能百科全书,全免费不限次数
【推荐】轻量又高性能的 SSH 工具 IShell:AI 加持,快人一步
· 无需6万激活码!GitHub神秘组织3小时极速复刻Manus,手把手教你使用OpenManus搭建本
· Manus爆火,是硬核还是营销?
· 终于写完轮子一部分:tcp代理 了,记录一下
· 别再用vector<bool>了!Google高级工程师:这可能是STL最大的设计失误
· 单元测试从入门到精通