mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Andreas Dilger <adilger@turbolinux.com>
To: Sean Hunter <sean@dev.sportingbet.com>
Cc: linux-kernel@vger.kernel.org
Subject: Re: CAP_LINUX_IMMUTABLE question
Date: Tue, 7 Aug 2001 10:50:09 -0600 (MDT)	[thread overview]
Message-ID: <200108071650.f77Go9Qj015650@webber.adilger.int> (raw)
In-Reply-To: <20010807120850.A18750@dev.sportingbet.com> "from Sean Hunter at Aug 7, 2001 12:08:50 pm"

Sean Hunter writes:
> I now want to drop CAP_LINUX_IMMUTABLE, and have (I think) done that.
> However, it seems to make no difference to my ability to set or clear
> the immutable attribute.  I tried this on ext2 and ext3 filesystems
> just to be on the safe side.
> 
> [root@henry /boot]# lcap CAP_LINUX_IMMUTABLE
> [root@henry /boot]# lsattr ./vmlinux-2.4.2-2smp
> ---i--------- ./vmlinux-2.4.2-2smp
> [root@henry /boot]# chattr -i ./vmlinux-2.4.2-2smp
> [root@henry /boot]# lsattr ./vmlinux-2.4.2-2smp
> ------------- ./vmlinux-2.4.2-2smp
> [root@henry /boot]# chattr +i ./vmlinux-2.4.2-2smp
> [root@henry /boot]# lsattr ./vmlinux-2.4.2-2smp
> ---i--------- ./vmlinux-2.4.2-2smp

The code that _should_ check this is fs/ext[23]/ioctl.c:EXT[23]_IOC_SETFLAGS,
so you may want to add some debugging there, to see:
1) if you really have dropped CAP_LINUX_IMMUTABLE
2) the logic of the checking is correct

Cheers, Andreas
-- 
Andreas Dilger  \ "If a man ate a pound of pasta and a pound of antipasto,
                 \  would they cancel out, leaving him still hungry?"
http://www-mddsp.enel.ucalgary.ca/People/adilger/               -- Dogbert


  reply	other threads:[~2001-08-07 16:50 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-08-07 11:08 Sean Hunter
2001-08-07 16:50 ` Andreas Dilger [this message]
2006-12-28 21:52 Aaron Cohen

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=200108071650.f77Go9Qj015650@webber.adilger.int \
    --to=adilger@turbolinux.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=sean@dev.sportingbet.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

all inboxes | Powered by JetHome®