linux下安裝及使用rootkit hunter(rootkit檢測掃描工具)

來源:互聯網
上載者:User

在官方的資料當中,rootkit hunter可以作的事情包括:偵測rootkit 程式、偵測後門程式、以及主機端的套件檢查問題。

官方下載:

Project: http://www.rootkit.nl/projects/rootkit_hunter.html
download: http://downloads.sourceforge.net/rkhunter/rkhunter-1.4.2.tar.gz?use_mirror=jaist

解壓安裝:

解壓
#tar -zxvf rkhunter-1.3.4.tar.gz
安裝
#cd rkhunter-1.3.4
#./installer.sh -h
Usage: ./installer.sh <parameters>
Ordered valid parameters:
--help (-h)      : 顯示協助
--examples       : 顯示安裝執行個體
--layout <value> : 選擇安裝模板(安裝必選參數).
                   模板選擇:
                    - default: (FHS compliant),
                    - /usr,
                    - /usr/local,
                    - oldschool: 之前版本安裝路徑,
                    - custom: 自訂安裝路徑,
                    - RPM: for building RPM's. Requires $RPM_BUILD_ROOT.
                    - DEB: for building DEB's. Requires $DEB_BUILD_ROOT.
--striproot      : Strip path from custom layout (for package maintainers).
--install        : 根據選擇目錄安裝
--show           : 顯示安裝路徑
--remove         : 卸載rkhunter
--version        : 顯示安裝版本

我使用的安裝指令:

#./installer.sh --layout default --install

rkhunter操作:

#/usr/local/bin/rkhunter --propupd
#/usr/local/bin/rkhunter -c --sk -rwo

結果就是“中招”,基本上就是重新安裝系統的命了。不過從檢查的結果來看,可以判斷所中的rootkit的類型和被替換的系統檔案。同時對一些程式版本進行檢測,提供的資訊比較多。

指令參數說明:


/usr/local/bin/rkhunter
Usage: rkhunter {--check | --update | --versioncheck |
                 --propupd [{filename | directory | package name},...] |
                 --list [{tests | {lang | languages} | rootkits},...] |
                 --version | --help} [options]
Current options are:
         --append-log                  在記錄檔後追加日誌,而不覆蓋原有日誌
         --bindir <directory>...       Use the specified command directories
     -c, --check                       檢測當前系統
  --cs2, --color-set2                  Use the second color set for output
         --configfile <file>           使用特定的設定檔
         --cronjob                     作為cron定期運行
                                       (包含參數 -c, --sk , --nocolors )
         --dbdir <directory>           Use the specified database directory
         --debug                       Debug模式(不要使用除非要求使用)
         --disable <test>[,<test>...]  跳過指定檢查對象(預設為無)
         --display-logfile             在最後顯示記錄檔內容
         --enable  <test>[,<test>...]  對指定檢測對象進行檢查
                                       (預設檢測所有對象)
         --hash {MD5 | SHA1 | NONE |   使用指定的檔案雜湊函數
                 <command>}            (Default is SHA1)
     -h, --help                        顯示協助菜單
 --lang, --language <language>         指定使用的語言
                                       (Default is English)
         --list [tests | languages |   羅列測試對象明朝,使用語言,可檢測的木馬程式
                 rootkits]            
     -l, --logfile [file]              寫到指定的記錄檔名
                                       (Default is /var/log/rkhunter.log)
         --noappend-log                不追加日誌,直接覆蓋記錄檔
         --nocolors                    輸出只顯示黑白兩色
         --nolog                       不寫入記錄檔
--nomow, --no-mail-on-warning          如果有警告資訊,不發送郵件
   --ns, --nosummary                   不顯示檢查結果的統計資料
 --novl, --no-verbose-logging          不顯示詳細記錄
         --pkgmgr {RPM | DPKG | BSD |  使用特定的包管理用於檔案的雜湊值驗證
                   NONE}               (Default is NONE)
         --propupd [file | directory | 更新整個檔案屬性資料庫或僅僅更新指定條目
                    package]...       
     -q, --quiet                       安靜模式(no output at all)
  --rwo, --report-warnings-only        只顯示警告資訊
     -r, --rootdir <directory>         使用指定的root目錄
   --sk, --skip-keypress               自動完成所有檢測,跳過鍵盤輸入
         --summary                     顯示檢測結果的統計資訊
                                       (This is the default)
         --syslog [facility.priority]  記錄檢測啟動和結束時間到系統日誌中
                                       (Default level is authpriv.notice)
         --tmpdir <directory>          使用指定的臨時目錄
         --update                      檢測更新內容
   --vl, --verbose-logging             使用詳細日誌記錄 (on by default)
     -V, --version                     顯示版本資訊
         --versioncheck                檢測最新版本
     -x, --autox                       當X在使用時,自動啟動檢測
     -X, --no-autox                    當X在使用時,不自啟檢測

有了rootkit hunter,偵測 rootkit 程式、偵測後門程式、以及主機端的套件檢查問題就變得簡單了,很多時候,rootkit hunter可以自動幫我們完成這些複雜的工作。

聯繫我們

該頁面正文內容均來源於網絡整理,並不代表阿里雲官方的觀點,該頁面所提到的產品和服務也與阿里云無關,如果該頁面內容對您造成了困擾,歡迎寫郵件給我們,收到郵件我們將在5個工作日內處理。

如果您發現本社區中有涉嫌抄襲的內容,歡迎發送郵件至: info-contact@alibabacloud.com 進行舉報並提供相關證據,工作人員會在 5 個工作天內聯絡您,一經查實,本站將立刻刪除涉嫌侵權內容。

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.