Skip to content

Commit

Permalink
Add exceptions for Write below root
Browse files Browse the repository at this point in the history
Add lists of files/directories that are acceptable to write.
  • Loading branch information
mstemm committed Oct 25, 2017
1 parent b08ea96 commit 71a386f
Showing 1 changed file with 10 additions and 1 deletion.
11 changes: 10 additions & 1 deletion rules/falco_rules.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -617,9 +617,18 @@
priority: ERROR
tags: [filesystem]

- list: known_root_files
items: [/root/.monit.state]

- list: known_root_directories
items: [/root/.oracle_jre_usage]

- rule: Write below root
desc: an attempt to write to any file directly below / or /root
condition: root_dir and evt.dir = < and open_write
condition: >
root_dir and evt.dir = < and open_write
and not fd.name in (known_root_files)
and not fd.directory in (known_root_directories)
output: "File below / or /root opened for writing (user=%user.name command=%proc.cmdline parent=%proc.pname file=%fd.name name=%proc.name)"
priority: ERROR
tags: [filesystem]
Expand Down

0 comments on commit 71a386f

Please sign in to comment.