Stop further socket() or connect() calls.

Peter Jeremy peterjeremy at optushome.com.au
Mon Jul 3 19:04:54 UTC 2006


On Mon, 2006-Jul-03 18:09:27 +0100, mal content wrote:
>Was it my imagination or did I see a function in libc that
>allowed a process to prevent further network access?

The closest is shutdown(2) which can stop further access in one
direction on an existing socket - not what you want.

>I was looking for a way to write a small wrapper program
>that disables network access and then exec()'s a given
>program.

For dynamic executables, you could LD_PRELOAD a .so that replaces
all the socket-related syscalls.

-- 
Peter Jeremy
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 187 bytes
Desc: not available
Url : http://lists.freebsd.org/pipermail/freebsd-hackers/attachments/20060703/d25987bc/attachment.pgp


More information about the freebsd-hackers mailing list