Linux command
rkhunter 命令
安全
权限或系统影响较大,执行前请核对目标。
常用示例
Check
sudo rkhunter --check
Check
sudo rkhunter --check --sk
Update
sudo rkhunter --update
Update
sudo rkhunter --propupd
List
sudo rkhunter --list tests
Example
sudo rkhunter --versioncheck
Example
sudo rkhunter --cronjob --report-warnings-only
说明
rkhunter (Rootkit Hunter) scans Linux systems for rootkits, backdoors, and local exploits. It checks for hidden files, suspicious kernel modules, modified binaries, and other signs of compromise. The tool maintains a database of known malware signatures and file checksums, comparing current system state against known-good values.
参数
- -c, --check
- Perform system check for rootkits, backdoors, and exploits.
- --update
- Update data files and malware signatures.
- --propupd
- Update file properties database with current values (run after legitimate system changes).
- --list _tests|rootkits|lang|perl|propfiles_
- List supported capabilities.
- --versioncheck
- Check for a newer rkhunter version.
- -C, --config-check
- Validate configuration file(s).
- --sk, --skip-keypress
- Don't wait for a keypress between test groups.
- --rwo, --report-warnings-only
- Only display warnings.
- --cronjob
- Optimize output for cron execution (no colors, no keypress).
- --configfile _file_
- Use an alternate configuration file.
- -l, --logfile _file_
- Write log output to a specific file.
- --appendlog
- Append to an existing log file instead of overwriting.
- --disable _tests_
- Disable specific tests (comma-separated list).
- --enable _tests_
- Enable only the specified tests.
- --pkgmgr _type_
- Use package manager verification (RPM, DPKG, BSD, SOLARIS, NONE).
- -q, --quiet
- Suppress all output.
- --nocolors
- Disable colored output.
- -V, --version
- Display version information.
- -h, --help
- Display help information.
FAQ
What is the rkhunter command used for?
rkhunter (Rootkit Hunter) scans Linux systems for rootkits, backdoors, and local exploits. It checks for hidden files, suspicious kernel modules, modified binaries, and other signs of compromise. The tool maintains a database of known malware signatures and file checksums, comparing current system state against known-good values.
How do I run a basic rkhunter example?
Run `sudo rkhunter --check` in a terminal, then adjust file names, paths, flags, or remote targets for your system.
What does -c, --check do in rkhunter?
Perform system check for rootkits, backdoors, and exploits.