I think the differences are

  • You connect to the server by providing the file path instead of the destination IP/port
  • There is no such thing as a source port.. Also, the source IP would only be localhost.

I think that each open UNIX Domain socket still has the same two streams,, input stream and output stream.

Is this all correct?

Also, is the file required to be known when connecting to a UNIX Domain socket? Can a non root user find UNIX domain sockets and connect to them?

link|improve this question

feedback

1 Answer

up vote 0 down vote accepted

On Linux netstat -x reveals.

link|improve this answer
Is the rest of my question correct? – George Bailey Jan 31 '11 at 18:31
man 7 unix: «… In the Linux implementation, sockets which are visible in the file system honor the permissions of the directory they are in. Their owner, group and their permissions can be changed. Creation of a new socket will fail if the process does not have write and search (execute) permission on the directory the socket is created in. Connecting to the socket object requires read/write permission. This behavior differs from many BSD-derived systems which ignore permissions for UNIX domain sockets. Portable programs should not rely on this feature for security. …» – poige Jan 31 '11 at 18:41
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.