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

Rule deletion #128

Open
wants to merge 4 commits into
base: main
Choose a base branch
from
Open

Rule deletion #128

wants to merge 4 commits into from

Commits on Sep 8, 2023

  1. rule: Report missing rules during deletion

    Although the implementation for AuditClient.Delete is only used to back
    AuditClient.DeleteAll, we'd like to be able to delete individual rules.
    This commit adds checking of the netlink error field and reports when
    the deletion has failed.  When DeleteAll is called, we ignore the ENOENT
    return since it could've raced somewhere and we don't actually care
    since we're deleting all of the rules.
    jeffmahoney committed Sep 8, 2023
    Configuration menu
    Copy the full SHA
    d7bead3 View commit details
    Browse the repository at this point in the history
  2. rule.Rule.Build: Don't assume that no syscalls means all syscalls

    Rule.Build assumes that if no syscalls are specified they all are set.
    This is really only the case when the exit list is used since the
    syscall numbers aren't available in the other lists.  When we assume
    that all of the syscalls are enabled, we end up generating wireformat
    rules for e.g. 'task,never' that have all of the syscall bits set.  That
    doesn't match what is already used when 'auditctl -a task,never' is
    used.  It may be ignored by the kernel when such a rule is added, but
    it would cause problems when that rule is deleted.
    jeffmahoney committed Sep 8, 2023
    Configuration menu
    Copy the full SHA
    95acdd8 View commit details
    Browse the repository at this point in the history

Commits on Sep 9, 2023

  1. rule: Add support for removing individual rules

    We currently don't handle the '-d' or '-W' options that would remove
    list rules or file watches.  This commit adds support to handle those
    properly.  rule.ToCommandLine still returns the expected result, but
    I've added a rule.ToCommandLineAddRemove that takes a bool indicating
    whether the rule would be added or removed.  This was required to do
    testing of deletion rules.
    jeffmahoney committed Sep 9, 2023
    Configuration menu
    Copy the full SHA
    b0c2227 View commit details
    Browse the repository at this point in the history

Commits on Jul 23, 2024

  1. Configuration menu
    Copy the full SHA
    4961b27 View commit details
    Browse the repository at this point in the history