Skip to content
GitLab
Projects Groups Topics Snippets
  • /
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Register
  • Sign in
  • L linux
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributor statistics
    • Graph
    • Compare revisions
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 0
    • Merge requests 0
  • Deployments
    • Deployments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • Kirill Smelkov
  • linux
  • Repository
  • linux
  • kernel
  • auditfilter.c
Find file BlameHistoryPermalink
  • Richard Guy Briggs's avatar
    audit: filter PATH records keyed on filesystem magic · 42d5e376
    Richard Guy Briggs authored Aug 23, 2017
    Tracefs or debugfs were causing hundreds to thousands of PATH records to
    be associated with the init_module and finit_module SYSCALL records on a
    few modules when the following rule was in place for startup:
    	-a always,exit -F arch=x86_64 -S init_module -F key=mod-load
    
    Provide a method to ignore these large number of PATH records from
    overwhelming the logs if they are not of interest.  Introduce a new
    filter list "AUDIT_FILTER_FS", with a new field type AUDIT_FSTYPE,
    which keys off the filesystem 4-octet hexadecimal magic identifier to
    filter specific filesystem PATH records.
    
    An example rule would look like:
    	-a never,filesystem -F fstype=0x74726163 -F key=ignore_tracefs
    	-a never,filesystem -F fstype=0x64626720 -F key=ignore_debugfs
    
    Arguably the better way to address this issue is to disable tracefs and
    debugfs on boot from production systems.
    
    See: https://github.com/linux-audit/audit-kernel/issues/16
    See: https://github.com/linux-audit/audit-userspace/issues/8
    Test case: https://github.com/linux-audit/audit-testsuite/issues/42
    
    
    
    Signed-off-by: default avatarRichard Guy Briggs <rgb@redhat.com>
    [PM: fixed the whitespace damage in kernel/auditsc.c]
    Signed-off-by: default avatarPaul Moore <paul@paul-moore.com>
    42d5e376
GitLab Nexedi Edition | About GitLab | About Nexedi | 沪ICP备2021021310号-2 | 沪ICP备2021021310号-7