[Y-devel] comment: security

Rupert Mazzucco maz at ap.univie.ac.at
Thu Feb 26 17:57:21 GMT 2004


> > - Security:  Here's a simple solution: Disallow tcp connections
> > altogether, ie only PF_LOCAL sockets, and use the "unix credentials"
> > feature of this socket type to accept only connections by processes
> > that have the same UID as the Y server.
>
> Maybe a bit too simplistic, as network connections are higly useful
> now and then. Then again, for the time being it'll do.

Network connections are still easy.  The remote application would
realise that the Y server is not local, but instead of creating and
connecting a socket itself, it would launch eg
'/usr/bin/ssh -fN -L<somelocalport>:localhost:8900' and make a local
connection to <somelocalport>.  ssh does the rest.

If you initiate the connection from the machine the server is running
on, an analog to "ssh -X" can be used similarly.

> >  Applications need to find a
> > means to connect to the machine before they can connect to the Y server.
>
> This'll complicate the actual use of remote connections. Which may or may
> not be a good thing. I kinda like the idea of a redirecting application

I'm not sure I understand that point.  By "find a means" I meant
something like "use an app-defined function if given and fall back
on ssh, for which you look in the path, if not."

In terms of implementation that wouldn't be longer or more
complicated than the socket-connect routine, probably even simpler.

> > Disadvantage: Portability problems.  The mechanism exists only for Linux
> > (see man 7 unix, example in Secure-Programs-HOWTO 3.4.)  But the manpage
> > says a similar mechanism exists in "BSD derivates" [...]
>
> FreeBSD 5.* promises funky acls on almost everything, I heard. ICBW of
> course. As to the checking, [...]

I checked, and FreeBSD has indeed nearly identical mechanisms in 4.x

So, that could be a way to go.

Regards,
Rupert




More information about the Y-devel mailing list









2026 © www.Y-Windows.Org - All Rights Reserved