linux-integrity.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Al Viro <viro@zeniv.linux.org.uk>
To: Mimi Zohar <zohar@linux.ibm.com>
Cc: Linus Torvalds <torvalds@linux-foundation.org>,
	linux-integrity@vger.kernel.org,
	James Morris James Morris <jmorris@namei.org>,
	Linux List Kernel Mailing <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] ima: cleanup the match_token policy code
Date: Tue, 18 Dec 2018 04:06:29 +0000	[thread overview]
Message-ID: <20181218040629.GT2217@ZenIV.linux.org.uk> (raw)
In-Reply-To: <1545102007.4206.15.camel@linux.ibm.com>

On Mon, Dec 17, 2018 at 10:00:07PM -0500, Mimi Zohar wrote:

> Could you expand on commit 5b2ea6199614 ("selinux: switch away from
> match_token()") patch description.  All that it says is "It's not a
> good fit, unfortunately, and the next step will make it even less so.
> Open-code what we need here."  And there's even less for the
> equivalent Smack patch, which just says "same issue as with
> selinux...".

match_token() would require messing around with strsep() or something
equivalent.  It's not a regex; foo=%s has no idea that comma is in any
way special, etc.

As for the next commit...  Killing the Cthulhu-awful mess in
selinux_sb_eat_lsm_opts() (allocating two temproraries, concatenating
(comma-separated) non-LSM options into one, concatenating (pipe-separated)
dequoted LSM options into another, then splitting that another by '|'
instances and figuring out which option each piece is, etc.)
is a Good Thing(tm).  And having to dance around the needs of
match_token() adds extra headache, for no good reason.

  reply	other threads:[~2018-12-18  4:06 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-12-18  0:14 [PATCH] ima: cleanup the match_token policy code Mimi Zohar
2018-12-18  0:36 ` Linus Torvalds
2018-12-18  1:33   ` Al Viro
2018-12-18  1:40     ` Al Viro
2018-12-18  3:00     ` Mimi Zohar
2018-12-18  4:06       ` Al Viro [this message]
2018-12-18  5:04         ` Mimi Zohar

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=20181218040629.GT2217@ZenIV.linux.org.uk \
    --to=viro@zeniv.linux.org.uk \
    --cc=jmorris@namei.org \
    --cc=linux-integrity@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    --cc=zohar@linux.ibm.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 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).