Home Man
Search
Today's Posts
Register

Discuss UNIX and Linux computer and network security, cyber security, cyber attacks, IT security, and more.

Security of Environment Variables

Tags
environment variables, password hide, secure, security

Login to Reply

 
Thread Tools Search this Thread
# 1  
Old 05-11-2016
Security of Environment Variables

Hello,

I'm trying to help a client with passing decrypted passwords into child processes. I just want to ask how secure (or not) it is to pass those decrypted passwords via environment variables?

Thanks,
denden
# 2  
Old 05-11-2016
maybe if you gave an example or be more clear in of what you are trying to do, we could give our comments...
The Following User Says Thank You to vbe For This Useful Post:
denden (05-11-2016)
# 3  
Old 05-11-2016
The Oracle Import process can be a good example of this. If you put the password
in the command, then you can see it when you use the "ps -ef | grep impdp".

Code:
impdp system/change_on_install ...

But if you use the echo command and pipe to the impdp command, then you won't
see the password when you do "ps -ef | grep impdp"

Code:
echo "system/change_on_install" | impdp  ...

Another option would be to put a delimited text file under the ~/.ssh directory.
You can then grep for the line that you want and use the cut command to grab
the password.

~/.ssh/pw
Code:
user:this_pwd
user1:this_pwd
user2:this_pwd
user3:this_pwd

You script that needs a password would have the following. Including the carrot
and colon will make sure that the line starts with the username and does not
accidentally pick up more than one line if you have similar usernames. You do
need to make sure that each username is unique in the file.
Code:
THIS_PWD=`grep "^user1:" | cut -d":" -f2`

The Following User Says Thank You to gandolf989 For This Useful Post:
denden (05-11-2016)
Login to Reply

« Previous Thread | Next Thread »
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
Environment Variables sai_2507 HP-UX 1 05-29-2012 03:43 AM
Reg. Environment variables ecearund Shell Programming and Scripting 0 05-23-2012 05:35 AM
Environment variables rwa25 Shell Programming and Scripting 5 04-28-2012 02:57 AM
Need to SET Environment variables shyamu544 Shell Programming and Scripting 1 07-01-2011 02:20 AM
environment variables radhika03 Shell Programming and Scripting 3 01-22-2007 12:58 PM
Environment variables in 'rsh' cherryven AIX 2 08-09-2006 12:24 AM
environment variables sumsin Programming 6 03-13-2006 10:17 AM
help..Environment variables... sekar sundaram UNIX for Dummies Questions & Answers 3 08-30-2005 03:35 AM
environment variables spavlov UNIX for Dummies Questions & Answers 3 08-20-2003 09:49 AM
environment variables Esaia Programming 2 02-20-2003 07:19 PM


All times are GMT -4. The time now is 05:37 AM.

Unix & Linux Forums Content Copyrightę1993-2018. All Rights Reserved.
UNIX.COM Login
Username:
Password:  
Show Password