develooper Front page | perl.beginners | Postings from March 2002

RE: changing $0 on solaris?

Thread Previous | Thread Next
March 28, 2002 08:29
RE: changing $0 on solaris?
Message ID:

I believe that changing $0 is a security breach on some systems. The only
UNIX virus/worm that I have seen, set the argv[0] to a null string and the
process would not show in the "ps" output list. UNIX ps displays the value
of argv[0], and if this string is changed the program can fake being a
different process.


> -----Original Message-----
> From: Ross Simpson []
> Sent: Wednesday, March 27, 2002 6:04 PM
> To: Perl Beginners
> Subject: changing $0 on solaris?
> I'm trying to change the value of $0 in a perl script (so 
> that it shows as
> something I define in ps).
> Directly modifying $0 works in linux, but on solaris it has no effect.
> Is there another way to do this, or does solaris not allow it?
> thanks
> Ross
> -- 
> To unsubscribe, e-mail:
> For additional commands, e-mail:

Thread Previous | Thread Next Perl Programming lists via nntp and http.
Comments to Ask Bjørn Hansen at | Group listing | About