SELinux Security Module development
 help / color / mirror / Atom feed
From: Johannes Segitz <jsegitz@suse.de>
To: Stephen Smalley <stephen.smalley.work@gmail.com>
Cc: Petr Lautrbach <lautrbach@redhat.com>,
	Ondrej Mosnacek <omosnace@redhat.com>,
	Jason Zaman <jason@perfinion.com>,
	James Carter <jwcart2@gmail.com>,
	selinux@vger.kernel.org
Subject: Re: [PATCH] selinux_restorecon: Do not exit on directory cycles
Date: Thu, 23 Jul 2026 17:42:45 +0200	[thread overview]
Message-ID: <amI2denYr02e5TKA@suse.com> (raw)
In-Reply-To: <CAEjxPJ6oS-W+5e6G-KqSr60CP+GTU3G_A6d0nLpFHQMPnqccGg@mail.gmail.com>

[-- Attachment #1: Type: text/plain, Size: 2588 bytes --]

On Thu, Jul 23, 2026 at 11:38:24AM -0400, Stephen Smalley wrote:
> On Thu, Jul 23, 2026 at 11:21 AM Johannes Segitz <jsegitz@suse.de> wrote:
> >
> > On Thu, Jul 23, 2026 at 10:55:48AM -0400, Stephen Smalley wrote:
> > > On Thu, Jul 23, 2026 at 4:56 AM Johannes Segitz <jsegitz@suse.de> wrote:
> > > >
> > > > All other failures are handled gracefully. Directory cycles can e.g.
> > > > happen on BTRFS filesystems with subvolumes. Skip them and continue
> > > > instead of exiting
> > >
> > > This is a user-visible behavior change so we should note it; restorecon -R
> > > on a tree with a bind mount of an ancestor will now complete with rc 0 and
> > > only a WARNING rather than aborting with ELOOP.
> >
> > Okay, I can write something up. But in general you would be fine with the
> > behavior change?
> 
> I am (although other maintainers are free to disagree).

okay, I'll prepare an updated version with wording that addresses this and
...

> > > Missing Signed-off-by line and the patch still doesn't apply for me
> > > (did you send it using git send-email and against current selinux/main?)
> > > but also see comment below on the code.
> >
> > I start feel like an idiot. The first time I used this old repo with the
> > wrong branch, but this time I made sure it applies, but didn't use
> > git send-mail.
> >
> > I did
> > # git format-patch -1 HEAD
> > 0001-selinux_restorecon-Do-not-exit-on-directory-cycles.patch
> >
> > which for me then applies:
> > # git checkout main
> > Already on 'main'
> > Your branch is up to date with 'origin/main'.
> > # git rev-parse --short HEAD
> > 84d424b8
> > # git am 0001-selinux_restorecon-Do-not-exit-on-directory-cycles.patch
> > Applying: selinux_restorecon: Do not exit on directory cycles
> >
> > Maybe my manual inclusion in the mail breaks it? I attach it now to the
> > mail
> 
> Yes, unfortunately mail clients are unforgiving of inline patches
> these days so we recommend
> using git send-email,
> https://github.com/SELinuxProject/selinux/wiki/Contributing#contributing-code

... will set this up. My mail setup is bit unusual, because of this I
avoided it until now, but I agree that it makes reviewing easier

Johannes
-- 
GPG Key                EE16 6BCE AD56 E034 BFB3  3ADD 7BF7 29D5 E7C8 1FA0
Subkey fingerprint:    250F 43F5 F7CE 6F1E 9C59  4F95 BC27 DD9D 2CC4 FD66
SUSE Software Solutions Germany GmbH, Frankenstr. 146, 90461 Nürnberg, Germany
www.suse.com, Geschäftsführer: Jochen Jaser, Andrew McDonald, Abhinav Puri, (HRB 36809, AG Nürnberg)


[-- Attachment #2: Digital signature --]
[-- Type: application/pgp-signature, Size: 870 bytes --]

  reply	other threads:[~2026-07-23 15:42 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2026-07-23  8:55 [PATCH] selinux_restorecon: Do not exit on directory cycles Johannes Segitz
2026-07-23 14:55 ` Stephen Smalley
2026-07-23 15:21   ` Johannes Segitz
2026-07-23 15:38     ` Stephen Smalley
2026-07-23 15:42       ` Johannes Segitz [this message]
2026-07-24 15:29         ` Stephen Smalley
  -- strict thread matches above, loose matches on Subject: below --
2026-07-21  7:17 Johannes Segitz
2026-07-21 13:54 ` Stephen Smalley
2026-07-21 15:15   ` Johannes Segitz

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=amI2denYr02e5TKA@suse.com \
    --to=jsegitz@suse.de \
    --cc=jason@perfinion.com \
    --cc=jwcart2@gmail.com \
    --cc=lautrbach@redhat.com \
    --cc=omosnace@redhat.com \
    --cc=selinux@vger.kernel.org \
    --cc=stephen.smalley.work@gmail.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