All of lore.kernel.org
 help / color / mirror / Atom feed
From: Phil Sutter <phil@nwl.cc>
To: Steve Grubb <sgrubb@redhat.com>
Cc: Richard Guy Briggs <rgb@redhat.com>,
	Linux-Audit Mailing List <linux-audit@redhat.com>,
	LKML <linux-kernel@vger.kernel.org>,
	netfilter-devel@vger.kernel.org, Paul Moore <paul@paul-moore.com>,
	Ondrej Mosnacek <omosnace@redhat.com>,
	fw@strlen.de, twoerner@redhat.com,
	Eric Paris <eparis@parisplace.org>,
	tgraf@infradead.org
Subject: Re: [PATCH ghak124 v3] audit: log nftables configuration change events
Date: Fri, 12 Feb 2021 13:11:12 +0100	[thread overview]
Message-ID: <20210212121112.GA3158@orbyte.nwl.cc> (raw)
In-Reply-To: <4087569.ejJDZkT8p0@x2>

Hi,

On Thu, Feb 11, 2021 at 04:02:55PM -0500, Steve Grubb wrote:
> On Thursday, February 11, 2021 11:29:34 AM EST Paul Moore wrote:
> > > If I'm not mistaken, iptables emits a single audit log per table, ipset
> > > doesn't support audit at all. So I wonder how much audit logging is
> > > required at all (for certification or whatever reason). How much
> > > granularity is desired?
>  
>   <snip> 
> 
> > I believe the netfilter auditing was mostly a nice-to-have bit of
> > functionality to help add to the completeness of the audit logs, but I
> > could very easily be mistaken.  Richard put together those patches, he
> > can probably provide the background/motivation for the effort.
> 
> There are certifications which levy requirements on information flow control. 
> The firewall can decide if information should flow or be blocked. Information 
> flow decisions need to be auditable - which we have with the audit target. 

In nftables, this is realized via 'log level audit' statement.
Functionality should by all means be identical to that of xtables' AUDIT
target.

> That then swings in requirements on the configuration of the information flow 
> policy.
> 
> The requirements state a need to audit any management activity - meaning the 
> creation, modification, and/or deletion of a "firewall ruleset". Because it 
> talks constantly about a ruleset and then individual rules, I suspect only 1 
> summary event is needed to say something happened, who did it, and the 
> outcome. This would be in line with how selinux is treated: we have 1 summary 
> event for loading/modifying/unloading selinux policy.

So the central element are firewall rules for audit purposes and
NETFILTER_CFG notifications merely serve asserting changes to those
rules are noticed by the auditing system. Looking at xtables again, this
seems coherent: Any change causes the whole table blob to be replaced
(while others stay in place). So table replace/create is the most common
place for a change notification. In nftables, the most common one is
generation dump - all tables are treated as elements of the same
ruleset, not individually like in xtables.

Richard, assuming the above is correct, are you fine with reducing
nftables auditing to a single notification per transaction then? I guess
Florian sufficiently illustrated how this would be implemented.

> Hope this helps...

It does, thanks a lot for the information!

Thanks, Phil

  reply	other threads:[~2021-02-12 12:12 UTC|newest]

Thread overview: 51+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-06-04 13:20 [PATCH ghak124 v3] audit: log nftables configuration change events Richard Guy Briggs
2020-06-04 13:20 ` Richard Guy Briggs
2020-06-04 17:03 ` Steve Grubb
2020-06-04 17:03   ` Steve Grubb
2020-06-04 17:57   ` Richard Guy Briggs
2020-06-04 17:57     ` Richard Guy Briggs
2020-06-04 18:51     ` Steve Grubb
2020-06-04 18:51       ` Steve Grubb
2020-06-24  0:34 ` Paul Moore
2020-06-24  0:34   ` Paul Moore
2020-06-24 10:03 ` Pablo Neira Ayuso
2020-06-24 10:03   ` Pablo Neira Ayuso
2020-06-24 12:34   ` Richard Guy Briggs
2020-06-24 12:34     ` Richard Guy Briggs
2020-06-24 13:03     ` Pablo Neira Ayuso
2020-06-24 13:03       ` Pablo Neira Ayuso
2020-06-24 13:26       ` Richard Guy Briggs
2020-06-24 13:26         ` Richard Guy Briggs
2021-02-11 15:16 ` Phil Sutter
2021-02-11 16:29   ` Paul Moore
2021-02-11 16:29     ` Paul Moore
2021-02-11 20:26     ` Richard Guy Briggs
2021-02-11 20:26       ` Richard Guy Briggs
2021-02-11 22:09       ` Florian Westphal
2021-02-17 23:41         ` Richard Guy Briggs
2021-02-17 23:41           ` Richard Guy Briggs
2021-02-18  8:22           ` Florian Westphal
2021-02-18  8:22             ` Florian Westphal
2021-02-18 12:42             ` Richard Guy Briggs
2021-02-18 12:42               ` Richard Guy Briggs
2021-02-18 12:52               ` Florian Westphal
2021-02-18 12:52                 ` Florian Westphal
2021-02-18 13:28                 ` Richard Guy Briggs
2021-02-18 13:28                   ` Richard Guy Briggs
2021-02-18 13:41                   ` Florian Westphal
2021-02-18 13:41                     ` Florian Westphal
2021-02-18 21:20                 ` Richard Guy Briggs
2021-02-18 21:20                   ` Richard Guy Briggs
2021-02-18 22:42                   ` Florian Westphal
2021-02-18 22:42                     ` Florian Westphal
2021-02-19  6:26                     ` Richard Guy Briggs
2021-02-19  6:26                       ` Richard Guy Briggs
2021-02-19 19:25                       ` Richard Guy Briggs
2021-02-19 19:25                         ` Richard Guy Briggs
2021-02-12 20:48       ` Richard Guy Briggs
2021-02-12 20:48         ` Richard Guy Briggs
2021-02-11 21:02     ` Steve Grubb
2021-02-11 21:02       ` Steve Grubb
2021-02-12 12:11       ` Phil Sutter [this message]
2021-02-12 20:54         ` Richard Guy Briggs
2021-02-12 20:54           ` Richard Guy Briggs

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20210212121112.GA3158@orbyte.nwl.cc \
    --to=phil@nwl.cc \
    --cc=eparis@parisplace.org \
    --cc=fw@strlen.de \
    --cc=linux-audit@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=netfilter-devel@vger.kernel.org \
    --cc=omosnace@redhat.com \
    --cc=paul@paul-moore.com \
    --cc=rgb@redhat.com \
    --cc=sgrubb@redhat.com \
    --cc=tgraf@infradead.org \
    --cc=twoerner@redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.