?
Solved

Userid Passwd from a plsql code to shell script

Posted on 2011-03-17
4
Medium Priority
?
522 Views
Last Modified: 2012-05-11
I submit a job using dbms_scheduler which invokes a shell script that connects to database.
I pass the userid and password to shell script as arguments via the job.
But when I do ps - ef ... I can see the username and password being displayed on screen...

I have two questions:
1. What should I do to avoid the display of password by executing ps -ef .
2. As I am already connected to the database, can I directly send the user id and password to shell without specifying it manually.. i.e. Currently I send the user id and password hardcoded in my job arguments... If the password changes in future, I need to change my code too.. Is there a way where I do not have to send the hard coded user id and password from plsql.
0
Comment
Question by:sanpradeep
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
  • 2
4 Comments
 
LVL 7

Expert Comment

by:MrNed
ID: 35163021
I usually have a config file stored somewhere securely on the server with username/password/database combinations to be used for scripts. I can have a common function to extract it in your profile script and every other script can retrieve them as needed - nothing shows up on the command lines.

Of course if you dont/cant secure the file properly, there's not much point.
0
 

Author Comment

by:sanpradeep
ID: 35163814
You mean to say that there is no way we can find out the password of the current connected session by querying any dictionary view..
0
 
LVL 7

Accepted Solution

by:
MrNed earned 2000 total points
ID: 35163937
No, definitely not. You can get a hashed version of it (http://www.lifeaftercoffee.com/2005/08/23/oracle-password-hacks/), but that is not enough to re-connect with.
0
 

Author Comment

by:sanpradeep
ID: 35173906
Thanks for clarifying...
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Truncate is a DDL Command where as Delete is a DML Command. Both will delete data from table, but what is the difference between these below statements truncate table <table_name> ?? delete from <table_name> ?? The first command cannot be …
This post first appeared at Oracleinaction  (http://oracleinaction.com/undo-and-redo-in-oracle/)by Anju Garg (Myself). I  will demonstrate that undo for DML’s is stored both in undo tablespace and online redo logs. Then, we will analyze the reaso…
This video shows how to Export data from an Oracle database using the Datapump Export Utility.  The corresponding Datapump Import utility is also discussed and demonstrated.
This video shows how to Export data from an Oracle database using the Original Export Utility.  The corresponding Import utility, which works the same way is referenced, but not demonstrated.
Suggested Courses

770 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question