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

File watchers are deprecated #124

Open
n9 opened this issue Jan 4, 2024 · 4 comments
Open

File watchers are deprecated #124

n9 opened this issue Jan 4, 2024 · 4 comments

Comments

@n9
Copy link

n9 commented Jan 4, 2024

(Just to track from man auditctl.8.)

The -w form of writing watches is for backwards compatibility and is deprecated due to poor system performance. Convert watches of this form to the syscall based form.

Examples:

To watch a file for changes (2 ways to express):

auditctl -w /etc/shadow -p wa # Note this slows the system
auditctl -a always,exit -F arch=b64 -F path=/etc/shadow -F perm=wa

To recursively watch a directory for changes (2 ways to express):

auditctl -w /etc/ -p wa # Note this slows the system
auditctl -a always,exit -F arch=b64 -F dir=/etc/ -F perm=wa
@kovacs-andras
Copy link
Contributor

wow you are right, I haven't seen this change yet (Sep 24, 2023) linux-audit/audit-userspace@dd846b5#diff-ad7bcc936952a07512b62979369a29707578fabc81ec7da725aebf3598375b1cR276

@Pierre-Gronau-ndaal
Copy link
Contributor

Pierre-Gronau-ndaal commented Feb 13, 2024

have anyone an idea how we can prevent double the lines cause of the arch option like:

-a always,exit -F arch=b32 -F dir=/etc/ -F perm=wa
-a always,exit -F arch=b64 -F dir=/etc/ -F perm=wa

to cover 32 bit systems as well

@kovacs-andras
Copy link
Contributor

With a different config file. https://github.com/Neo23x0/auditd/blob/master/audit.rules#L793-L798

@Neo23x0
Copy link
Owner

Neo23x0 commented Apr 21, 2024

For me the biggest problem with this is backwards compatibility.
Cause I want this config to be usable on Linux OSs that are 10 years old. (the things you find in customer environments)
Maybe the best solution would be to create two configs. A "standard" one and a "legacy" one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants