- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Suppress ps -ef command line args
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Forums
Discussions
Discussions
Discussions
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-23-2006 10:38 PM
04-23-2006 10:38 PM
Suppress ps -ef command line args
Guys I have been coming back to you after a long gap.
The issue I am currently facing is as follows:
Process A is talking to Process B. A invokes B(executable) by providing some arguments. Process A is a unix script. Now, if I do "ps -ef" during communication between 2 processes, I can see the command line arguments being passed by A to B.
I need to hide these arguments from the user. Let me know if there is a workaround to suppress these arguments from appearing in the output of ps -ef or any command.
Thanks & Regards,
Pankaj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-23-2006 10:41 PM
04-23-2006 10:41 PM
Re: Suppress ps -ef command line args
Pete
Pete
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-23-2006 10:44 PM
04-23-2006 10:44 PM
Re: Suppress ps -ef command line args
use a file for process A to wtite the parameters, then let process B read that file.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-23-2006 10:47 PM
04-23-2006 10:47 PM
Re: Suppress ps -ef command line args
Thanks for your response.
That seems to be a good option, however I have some constraints regarding executable B. It is presently reading the parameters from command line and I can't change its design.
Waiting for something more on this...
Thanks and regards,
Pankaj
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-23-2006 11:09 PM
04-23-2006 11:09 PM
Re: Suppress ps -ef command line args
Bill Hassell, sysadmin
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-24-2006 01:50 AM
04-24-2006 01:50 AM
Re: Suppress ps -ef command line args
Create a new user, named for example ps.
Create a new group for this user, called for example ps.
Now you get a user named ps in a group named ps.
Change the owner and permissions of the ps command:
chmod 550 /bin/ps
chown ps:ps /bin/ps
Add the users that you want to normally use ps in the "ps" group.
Install sudo.
Create a script that runs the ps command with the output filtered/modified. Call this script /bin/secps
Configure your sudoers file to allow the execution of the secps command as user "ps". Using sudo, disallow the use of parameters for that command, like this:
USERLIST ALL = (ps) NOPASSWD: /bin/secps
Then the users only can run the command with sudo.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
04-24-2006 04:55 AM
04-24-2006 04:55 AM
Re: Suppress ps -ef command line args
You'll have to rename your "B" to "B.hide", compile the C program, and name the new program "B".
The original purpose of the program was to hide passwords passed on the command-line when calling Oracle sqplus commands, but it should work with any program.