From: Amir Goldstein <amir73il@gmail.com>
To: Aaron Goidel <acgoide@tycho.nsa.gov>
Cc: Paul Moore <paul@paul-moore.com>,
selinux@vger.kernel.org,
LSM List <linux-security-module@vger.kernel.org>,
linux-fsdevel <linux-fsdevel@vger.kernel.org>,
David Howells <dhowells@redhat.com>, Jan Kara <jack@suse.cz>,
James Morris <jmorris@namei.org>,
Stephen Smalley <sds@tycho.nsa.gov>,
linux-kernel <linux-kernel@vger.kernel.org>
Subject: Re: [Non-DoD Source] Re: [PATCH] fanotify, inotify, dnotify, security: add security hook for fs notifications
Date: Fri, 9 Aug 2019 19:29:57 +0300 [thread overview]
Message-ID: <CAOQ4uxjfwhg4LaPhaDoSQqTviLbXT_-g+WNfQ5AahTK9d+h-Zw@mail.gmail.com> (raw)
In-Reply-To: <03ad3773-bea7-77de-0a1f-4bd6f41d3211@tycho.nsa.gov>
...
> >> First a suggestion, take it or leave it.
> >> The name of the hook _notify() seems misleading to me.
> >> naming the hook security_path_watch() seems much more
> >> appropriate and matching the name of the constants FILE__WATCH
> >> used by selinux.
> >
> > I guess I'm not too bothered by either name, Aaron? FWIW, if I was
> > writing this hook, I would probably name it
> > security_fsnotify_path(...).
> >
Or even just security_fsnotify()
>
> While I'm not necessarily attached to the name, I feel as though
> "misleading" is too strong a word here.
Agree. It is not misleading, but I should note that you yourself
named the security class "watch", so why the inconsistency?
> Notify seems to be an
> appropriate enough term to me as every call to the hook, and thus all
> the logic to which the hook adds security, lives in the notify/ subtree.
>
Well, if nobody cares about the name, it's fine by me.
I wanted to point your attention to this proposal by David Howells:
https://lore.kernel.org/linux-fsdevel/155991706847.15579.4702772917586301113.stgit@warthog.procyon.org.uk/
His proposal adds new types of watches, for keyring changes,
mount changes, etc and he proposed security hooks for setting
new watches named "watch_XXX" and for posting notifications
called "post_notification". The latter was later rejected by
Stephen Smalley:
https://lore.kernel.org/linux-fsdevel/cd657aab-e11c-c0b1-2e36-dd796ca75b75@tycho.nsa.gov/
https://lore.kernel.org/linux-fsdevel/541e5cb3-142b-fe87-dff6-260b46d34f2d@tycho.nsa.gov/
Just to have a perspective why the hook name "notify_path" may end up
being a bit ambiguous down the road.
Thanks,
Amir.
next prev parent reply other threads:[~2019-08-09 16:30 UTC|newest]
Thread overview: 17+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-31 15:34 [PATCH] fanotify, inotify, dnotify, security: add security hook for fs notifications Aaron Goidel
2019-07-31 17:26 ` Casey Schaufler
2019-08-01 0:27 ` Paul Moore
2019-08-01 11:31 ` Stephen Smalley
2019-08-01 12:47 ` Paul Moore
2019-08-08 18:33 ` Paul Moore
2019-08-09 9:06 ` Amir Goldstein
2019-08-09 12:55 ` Paul Moore
2019-08-09 15:44 ` [Non-DoD Source] " Aaron Goidel
2019-08-09 16:29 ` Amir Goldstein [this message]
2019-08-10 10:05 ` Amir Goldstein
2019-08-10 15:01 ` Paul Moore
2019-08-12 13:41 ` Jan Kara
2019-08-12 13:49 ` [Non-DoD Source] " Aaron Goidel
2019-08-12 14:45 ` Paul Moore
2019-08-09 16:25 ` [Non-DoD Source] " Aaron Goidel
2019-08-09 16:43 ` Amir Goldstein
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=CAOQ4uxjfwhg4LaPhaDoSQqTviLbXT_-g+WNfQ5AahTK9d+h-Zw@mail.gmail.com \
--to=amir73il@gmail.com \
--cc=acgoide@tycho.nsa.gov \
--cc=dhowells@redhat.com \
--cc=jack@suse.cz \
--cc=jmorris@namei.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-security-module@vger.kernel.org \
--cc=paul@paul-moore.com \
--cc=sds@tycho.nsa.gov \
--cc=selinux@vger.kernel.org \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).