Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove old snapshot files for FIM #872

Merged
merged 8 commits into from
Jul 3, 2018
Merged

Conversation

Cerv1
Copy link
Contributor

@Cerv1 Cerv1 commented Jun 29, 2018

Now syscheck deletes the folders from queue/diff/local that are not currently being monitorized or have the report_changes attribute disabled.

To enable this feature, the option <remove_old_diff> must be yes in the ossec.conf.

Example of use.

<remove_old_diff>yes</remove_old_diff>
<directories check_all="yes" report_changes="yes" realtime="yes">/dir</directories>

The above configuration generates the following structure:

├── diff
│   ├── local
│       └── dir
│           ├── first
│           │   └── level 2
│           │       └── file
│           │           └── last-entry
│           └── second
│               └── third
│                   └── fourth
│                       └── low_file
│                           └── last-entry

If we changed the previous configuration to:

<remove_old_diff>yes</remove_old_diff>
<directories check_all="yes" report_changes="no" realtime="yes">/dir</directories>

The files that were saved and now are no longer being monitorized, will be deleted. Therefore, our local file structure will be the next one:

├── diff
│   ├── local

@vikman90 vikman90 added the module/fim File Integrity Monitoring label Jul 1, 2018
@Cerv1 Cerv1 force-pushed the dev-syscheck-remove-local branch from e397ab9 to bbd5b2f Compare July 2, 2018 12:49
@chemamartinez chemamartinez merged commit 31f2b03 into 3.4-dev Jul 3, 2018
@chemamartinez chemamartinez deleted the dev-syscheck-remove-local branch July 3, 2018 13:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
module/fim File Integrity Monitoring
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants