public inbox for linux-scsi@vger.kernel.org
 help / color / mirror / Atom feed
From: Douglas Gilbert <dougg@torque.net>
To: Patrick Mochel <mochel@osdl.org>
Cc: linux-kernel@vger.kernel.org, linux-scsi@vger.kernel.org
Subject: Re: sysfs mount point permissions in 2.5.64
Date: Fri, 07 Mar 2003 09:22:04 +1100	[thread overview]
Message-ID: <3E67CA0C.4070108@torque.net> (raw)
In-Reply-To: Pine.LNX.4.33.0303051706020.998-100000@localhost.localdomain

Patrick,

Thanks. That patch fixed the problem I reported.

Doug Gilbert


Patrick Mochel wrote:
> On Thu, 6 Mar 2003, Douglas Gilbert wrote:
> 
> 
>>In lk 2.5.64 on my i386 box the sysfs mount point
>>( "/sys") changes permission from:
>>   drwxr-xr-x
>>to
>>   drw-r--r--
>>during the boot process. I didn't notice this feature
>>in lk 2.5.63 . Chmodding the directory back to its former
>>permissions get overridden by subsequent boot sequences.
>>
>>This change in permissions inhibits non-root users from using
>>utilities that scan sysfs for information (e.g. lsscsi).
>>
>>Is this a feature or otherwise?
> 
> 
> This is certainly not intended, and is entirely my fault. The patch below 
> should fix it.
> 
> 	-pat
> 
> ===== fs/sysfs/mount.c 1.5 vs edited =====
> --- 1.5/fs/sysfs/mount.c	Tue Mar  4 12:17:14 2003
> +++ edited/fs/sysfs/mount.c	Wed Mar  5 17:06:25 2003
> @@ -33,7 +33,7 @@
>  	sb->s_op = &sysfs_ops;
>  	sysfs_sb = sb;
>  
> -	inode = sysfs_new_inode(S_IFDIR | S_IRUGO | S_IWUSR);
> +	inode = sysfs_new_inode(S_IFDIR | S_IRWXU | S_IRUGO | S_IXUGO);
>  	if (inode) {
>  		inode->i_op = &simple_dir_inode_operations;
>  		inode->i_fop = &simple_dir_operations;
> 




      reply	other threads:[~2003-03-06 22:22 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2003-03-05 21:47 sysfs mount point permissions in 2.5.64 Douglas Gilbert
2003-03-05 23:08 ` Patrick Mochel
2003-03-06 22:22   ` Douglas Gilbert [this message]

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=3E67CA0C.4070108@torque.net \
    --to=dougg@torque.net \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-scsi@vger.kernel.org \
    --cc=mochel@osdl.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