Skip to content

Instantly share code, notes, and snippets.

@koheyamada
Last active May 8, 2017 06:54
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save koheyamada/253bec73c0657162f6ce7771a7ad9f3d to your computer and use it in GitHub Desktop.
Save koheyamada/253bec73c0657162f6ce7771a7ad9f3d to your computer and use it in GitHub Desktop.
AIDEを使ってファイルの改竄検知を行う。 ref: http://qiita.com/kooohei/items/bcf34fd82c2f98b0b559
$ sudo yum install aide
$ sudo cp /var/lib/aide/aide.db.new.gz /var/lib/aide/aide.db.gz
$ sudo cp /var/lib/aide/aide.db.new.gz /var/lib/aide/aide.db.gz
$ sudo touch /root/aide-test.txt
$ sudo aide -i
AIDE, version 0.14
### AIDE database at /var/lib/aide/aide.db.new.gz initialized.
$ sudo aide --check
AIDE found differences between database and filesystem!!
Start timestamp: 2017-04-28 17:36:55
Summary:
Total number of files: 60760
Added files: 1
Removed files: 0
Changed files: 1
---------------------------------------------------
Added files:
---------------------------------------------------
added: /root/aide-test.txt
---------------------------------------------------
Changed files:
---------------------------------------------------
changed: /root
--------------------------------------------------
Detailed information about changes:
---------------------------------------------------
Directory: /root
Mtime : 2017-04-28 17:28:16 , 2017-04-28 17:36:47
Ctime : 2017-04-28 17:28:16 , 2017-04-28 17:36:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment