Linux RAID subsystem development
 help / color / mirror / Atom feed
From: Ian Dall <ian@beware.dropbear.id.au>
To: mschwarz@multitool.net
Cc: linux-raid@vger.kernel.org
Subject: Re: Behavior of mdadm depending on user
Date: Tue, 03 Jul 2007 22:10:29 +0930	[thread overview]
Message-ID: <1183466429.395.44.camel@sibyl.beware.dropbear.id.au> (raw)
In-Reply-To: <4168.72.21.237.163.1183428604.squirrel@www.multitool.net>

On Mon, 2007-07-02 at 21:10 -0500, Michael Schwarz wrote:
> This ia just a couple of quick questions.
> 
> I'm charged with developing a prototype application that will assemble and
> mount a hot-swapped drive array, mount it, transfer files to it, unmount it,
> and stop the array. And it is an application delivered by a local webserver
> (don't ask).
> 
> I don't want to do any of the incredibly stupid acts of making madadm and
> mount/umount setuid root, nor do I want to run the webserver as root.
> 
> Instead, I took the slightly less stupid approach of invoking madadm and
> mount/umount with a hardcoded C application that is setuid root. (We can
> debate the stupidity of this -- I know it isn't best, but it is fast and less
> stupid than the alternatives presented above).

This isn't really an answer to your question, but isn't this an ideal
application for sudo? Make a shell script with the mdadm command(s) you
want. And set it up so apache or whatever your web server runs as able
to run your shell script as root without authentication. 

Ian
-- 
Ian Dall <ian@beware.dropbear.id.au>

  reply	other threads:[~2007-07-03 12:40 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-07-03  2:10 Behavior of mdadm depending on user Michael Schwarz
2007-07-03 12:40 ` Ian Dall [this message]
2007-07-03 16:53   ` Michael Schwarz
2007-07-03 17:28     ` Michael

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=1183466429.395.44.camel@sibyl.beware.dropbear.id.au \
    --to=ian@beware.dropbear.id.au \
    --cc=linux-raid@vger.kernel.org \
    --cc=mschwarz@multitool.net \
    /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