Ferramentas de Usuário

Ferramentas de Site


Action disabled: source
pt:lenny:security:rootkit_detection:rkhunter

Página desactualizada Esta página contém uma versão anterior deste guia que pode estar desatualizada. Para a consultar a versão mais recente clique aqui.

7.2.1 Rootkit Hunter

Objectivo

Instalar o pacote rkhunter, um sistema de detecção de rootkits que avisa por email o administrador do sistema se detectar alterações no sistema que indiciem a presença de um rootkit.

Instalação

server:~# aptitude install rkhunter

Configuração

A configuração por omissão do pacote rkhunter é normalmente suficiente: o ficheiro /etc/default/rkhunter define que a actualização da base de dados é feita semanalmente, a verificação da existência de rootkits é feita diariamente, e os resultados são enviados por email para o administrador de sistema (root).

Deverá, no entanto ser feita a actualização da base de dados de propriedades de ficheiros do rkhunter:

server:~# rkhunter --propupd
[ Rootkit Hunter version 1.3.2 ]
File updated: searched for 154 files, found 123

Utilização

O rkhunter pode ser executado na linha de comandos:

server:~# rkhunter --check
[ Rootkit Hunter version 1.3.2 ]

Checking system commands...

  Performing 'strings' command checks
    Checking 'strings' command                               [ OK ]

  Performing 'shared libraries' checks
    Checking for preloading variables                        [ None found ]
    Checking for preload file                                [ Not found ]
    Checking LD_LIBRARY_PATH variable                        [ Not found ]

  Performing file properties checks
    Checking for prerequisites                               [ OK ]
    /bin/bash                                                [ OK ]
    /bin/cat                                                 [ OK ]
    /bin/chmod                                               [ OK ]
    /bin/chown                                               [ OK ]
    /bin/cp                                                  [ OK ]
    /bin/date                                                [ OK ]
    /bin/df                                                  [ OK ]
    /bin/dmesg                                               [ OK ]
    /bin/echo                                                [ OK ]

# [...]

Checking application versions...

    Checking version of GnuPG                                [ OK ]
    Checking version of Bind DNS                             [ OK ]
    Checking version of OpenSSL                              [ OK ]
    Checking version of PHP                                  [ OK ]
    Checking version of Procmail MTA                         [ OK ]
    Checking version of ProFTPd                              [ OK ]
    Checking version of OpenSSH                              [ OK ]


System checks summary
=====================

File properties checks...
    Files checked: 123
    Suspect files: 0

Rootkit checks...
    Rootkits checked : 108
    Possible rootkits: 0

Applications checks...
    Applications checked: 7
    Suspect applications: 0

The system checks took: 2 minutes and 4 seconds

All results have been written to the logfile (/var/log/rkhunter.log)

One or more warnings have been found while checking the system.
Please check the log file (/var/log/rkhunter.log)

Actualização da base de dados

A base de dados do rkhunter é actualizada semanal e automaticamente. No entanto, é possível proceder à sua actualização sempre que se quiser:

server:~# rkhunter --update
[ Rootkit Hunter version 1.3.2 ]

Checking rkhunter data files...
  Checking file mirrors.dat                                  [ No update ]
  Checking file programs_bad.dat                             [ No update ]
  Checking file backdoorports.dat                            [ No update ]
  Checking file suspscan.dat                                 [ No update ]
  Checking file i18n/cn                                      [ No update ]
  Checking file i18n/en                                      [ No update ]
  Checking file i18n/zh                                      [ No update ]
  Checking file i18n/zh.utf8                                 [ No update ]

Referências

pt/lenny/security/rootkit_detection/rkhunter.txt · Última modificação em: 2024-02-15 01:05 por 127.0.0.1