Change process name in python (POSIX only, using dl module)

>>> import dl
>>> libc = dl.open(‘/lib/libc.so.6’)
0
>>> libc.call(‘prctl’, 15, ‘CRAP’, 0, 0, 0)
0
now our process is called CRAP

Advertisements

8 thoughts on “Change process name in python (POSIX only, using dl module)

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s