Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re: How best to hide command-line arguments from ps command?

by tadman (Prior)
on Nov 18, 2003 at 21:36 UTC ( [id://308137]=note: print w/replies, xml ) Need Help??


in reply to How best to hide command-line arguments from ps command?

While it's not 100% secure, you can always reassign the value of $0 first thing in your script. That's the variable that ends up controlling how your process shows up in the process listing.

The MySQL shell client, for example, is careful to "x" out your password so that it doesn't show up in a process listing. What you see is something like mysql --username=foo --password=xxxxx instead of your actual password.
  • Comment on Re: How best to hide command-line arguments from ps command?

Replies are listed 'Best First'.
Re: Re: How best to hide command-line arguments from ps command?
by sauoq (Abbot) on Nov 18, 2003 at 22:19 UTC

    This won't work on all platforms.

    -sauoq
    "My two cents aren't worth a dime.";
    
    A reply falls below the community's threshold of quality. You may see it by logging in.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://308137]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others chanting in the Monastery: (7)
As of 2024-04-19 10:38 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found