Re: File sharing with Nautilus



Hi Bill -

You are correct we don't need root access if:

1) The webserver is already installed.
2) The webserver is not binding to a reserved port.

There are some problems though with what you're suggesting. First,
firewalls. I know I tell my firewall to reject the hell out of any
packet coming in on a port that I haven't specifically told it that it
was okay to listen to. Root access would be required to punch a hole.
But then what port would you use? You wouldn't want 80 on the off chance
that another webserver was running. You wouldn't want it random,
otherwise you couldn't publicize the existence of the server to others.
It could indeed run with the permissions of the user on a high enough
port, but when does it run? *nix machines are multi-user. So I wouldn't
want stuff only shared when I'm logged in; if I'm out sick and a
co-worker wants to access one of my public files, they couldn't. And if
more than one user was logged on at a time? Would each of them have
their own webserver on their own port? Or if they used the same server,
under whose permissions would the server run as?

To me, the only way around all of these is if the server runs as root.
It's the only way to have a fixed port, to have multiple users able to
share files at the same time, and to have the server able to access
multiple users' files.

But we still have the problem of collisions with Apache or other
servers. And the firewall. And some of the others I mentioned.

-jag

On Sun, 2003-08-17 at 15:14, Bill Garrett wrote:
> > Well, which web servers do you want to support? Only Apache?
> > 
> > Okay... first off, you're talking root access required on everything...
> 
> This is not necessarily the case for Web servers, but the alternative may not
> be any more pleasant.  Assuming that "Share This File" in the context of
> Nautilus means you wish to share only the file's content (as opposed to expose
> the file as a CGI program), you can very easily include one of the MANY GPLed
> "low-rent" mini-HTTP-servers out there.  Are any files being shared?  Start up
> our mini-server, on some high port number, register its existence in GConf and
> elsewhere, and inform it of the file(s) it should share.  Any others should be
> automatically rejected, if requested by a client.
> 
> It can run with the permissions of the user, and either shut down when his
> session ends, or keep running until he tells it to stop.  Ideally it
> would watch when files move or are removed, and of course there'd be an
> option to shut it down entirely, whether or not files were still being shared.
> 
> Obviously, this does not address SMB, NFS, and many other file-sharing
> mechanisms.  It also raises the question of "is it the business of Nautilus to
> be doing this?"




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]