selinux.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Stephen Smalley <stephen.smalley.work@gmail.com>
To: Dominick Grift <dominick.grift@defensec.nl>
Cc: SElinux list <selinux@vger.kernel.org>
Subject: Re: [PATCH] policycoreutils: fix inaccurate description in sestatus
Date: Tue, 21 Jul 2020 09:08:27 -0400	[thread overview]
Message-ID: <CAEjxPJ6swWoPG_55QT8=GsoXkgiQD29=F1BhjHo2xLo6w-agXQ@mail.gmail.com> (raw)
In-Reply-To: <20200721112512.1906547-1-dominick.grift@defensec.nl>

On Tue, Jul 21, 2020 at 7:27 AM Dominick Grift
<dominick.grift@defensec.nl> wrote:
>
> strdup(selinux_policy_root()) does not return a path that can be used to derive "Loaded policy name"
> instead if returns a path that can be used to derive "Policy name from config file".
>
> Signed-off-by: Dominick Grift <dominick.grift@defensec.nl>

My only concern with this is whether it might break scripts that
extract bits of information from sestatus output by matching on the
existing prefix, especially since it has been this way for a long time
(approaching 9 years?).  OTOH, it looks like it was labeled "Policy
from config file" prior to that commit.  No strong feelings either way
except that we don't want to break things for users unnecessarily.

> ---
>  policycoreutils/sestatus/sestatus.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/policycoreutils/sestatus/sestatus.c b/policycoreutils/sestatus/sestatus.c
> index b37f0353..8b03b028 100644
> --- a/policycoreutils/sestatus/sestatus.c
> +++ b/policycoreutils/sestatus/sestatus.c
> @@ -268,7 +268,7 @@ int main(int argc, char **argv)
>         free(root_path);
>
>         /* Dump all the path information */
> -       printf_tab("Loaded policy name:");
> +       printf_tab("Policy name from config file:");
>         pol_path = strdup(selinux_policy_root());
>         if (pol_path) {
>                 pol_name = basename(pol_path);
> --
> 2.27.0
>

  parent reply	other threads:[~2020-07-21 13:08 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-07-21 11:25 [PATCH] policycoreutils: fix inaccurate description in sestatus Dominick Grift
2020-07-21 11:38 ` Dominick Grift
2020-07-21 13:08 ` Stephen Smalley [this message]
2020-07-21 13:34   ` Dominick Grift

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='CAEjxPJ6swWoPG_55QT8=GsoXkgiQD29=F1BhjHo2xLo6w-agXQ@mail.gmail.com' \
    --to=stephen.smalley.work@gmail.com \
    --cc=dominick.grift@defensec.nl \
    --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).