[Pythonmac-SIG] Python solution to monitor your internet
connection?
Jack Jansen
Jack.Jansen at cwi.nl
Tue Jan 20 07:34:22 EST 2004
On 18-jan-04, at 18:21, Bob Ippolito wrote:
>
> On Jan 18, 2004, at 11:25 AM, W.T. Bridgman wrote:
>
>> I know of a few commercial/shareware packages that can monitor your
>> machine for apps that try to 'phone home' when you're online, but
>> does anyone know of any open source (preferably Python) solutions for
>> this?
>>
>> If not, can anyone point me to somewhere that I might find out what I
>> need to write such an app that can monitor my internet connection?
>> I'm specifically interested in monitoring OS X applications. Do the
>> python internet modules have sufficient access to the internet API to
>> do this?
>
> You pretty much have to write the bulk of such a thing in C, since you
> have to intercept calls to C functions from other processes.
I don't think you have to be *that* gross. The ipfirewall device (see
man 4 firewall) can probably be used to make all packets be given to
your code for inspection. But still I don't think I'd want to do this
in Python because of the overhead.
--
Jack Jansen, <Jack.Jansen at cwi.nl>, http://www.cwi.nl/~jack
If I can't dance I don't want to be part of your revolution -- Emma
Goldman
More information about the Pythonmac-SIG
mailing list