9fans - fans of the OS Plan 9 from Bell Labs
 help / color / mirror / Atom feed
* [9fans] remove files in /srv
@ 2005-02-01  1:11 YAMANASHI Takeshi
  2005-02-01  3:21 ` arisawa
  2005-02-01  3:56 ` Russ Cox
  0 siblings, 2 replies; 11+ messages in thread
From: YAMANASHI Takeshi @ 2005-02-01  1:11 UTC (permalink / raw)
  To: 9fans

Hi,

Anyone can replace files in /srv.  Bad things won't
happen if /srv/boot has been replaced by a malicious user?

Therefore, how about changing '#s' so that only file owner
or host owner can remove the file?
-- 




^ permalink raw reply	[flat|nested] 11+ messages in thread
* Re: [9fans] remove files in /srv
@ 2005-02-01  3:48 YAMANASHI Takeshi
  2005-02-01  4:06 ` arisawa
  0 siblings, 1 reply; 11+ messages in thread
From: YAMANASHI Takeshi @ 2005-02-01  3:48 UTC (permalink / raw)
  To: 9fans

On Tue Feb  1 12:21:37 JST 2005, arisawa@ar.aichi-u.ac.jp wrote:
> >Anyone can replace files in /srv.  Bad things won't
> >happen if /srv/boot has been replaced by a malicious user?
 :
> su# rm boot
> rm: boot: permission denied

oops.  you can surely remove /srv/dns though.
what's the difference between boot and dns...?

I got it: #s is doing a special treatment for boot in
/sys/src/9/port/devsrv.c:/^srvremove .
	if(strcmp(sp->name, "boot") == 0)
		error(Eperm);

I'd rather have #s only removable by hostowner/file owner instead.
Would this change break something?
-- 




^ permalink raw reply	[flat|nested] 11+ messages in thread
* Re: [9fans] remove files in /srv
@ 2005-02-01  4:05 YAMANASHI Takeshi
  2005-02-01  4:44 ` geoff
  0 siblings, 1 reply; 11+ messages in thread
From: YAMANASHI Takeshi @ 2005-02-01  4:05 UTC (permalink / raw)
  To: 9fans

> This won't work well.  9fs alice creates /srv/alice as the user
> who runs it, but if the connection is lost and someone else
> runs 9fs alice, then they need permission to remove it and
> replace it. 

They can post a new connection under another name like
/srv/alice.username, can't they?

There are many other important services now in /srv to trust users.
I'm concerned for /srv/^(fossil fscons cs dns factotum) especially.
# boot is excluded because of the special treatment
-- 




^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2005-02-02 23:57 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-02-01  1:11 [9fans] remove files in /srv YAMANASHI Takeshi
2005-02-01  3:21 ` arisawa
2005-02-01  3:56 ` Russ Cox
2005-02-01  3:48 YAMANASHI Takeshi
2005-02-01  4:06 ` arisawa
2005-02-01  4:33   ` Russ Cox
2005-02-01 20:31     ` rog
2005-02-02 23:22       ` Bruce Ellis
2005-02-02 23:57         ` Charles Forsyth
2005-02-01  4:05 YAMANASHI Takeshi
2005-02-01  4:44 ` geoff

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).