Problem solve Get help with specific problems with your technologies, process and projects.

Acquiring knowledge of Oracle database users and their IDs

I need a script that shows me all of the database users and their passwords in my Oracle database. How would I...

acquire such a script? Passwords for Oracle database users are not encrypted, they are hashed. Therefore, it is not possible to retrieve the password for a user given the password string. When you login to the database, the password you supply is hashed in the same manner it was when the user was created. If the computed hash (at login time) and the stored hash (from create or alter time) match, you are authenticated. It is statistically unlikely that you can create two passwords that produce the same hash value. A similar method is used for the passwords for Unix accounts. That's why the system or database administrator can only reset your password, they cannot retrieve the current password.

select username,password from dba_users;

That query will show you all the hashed passwords for each user account, but you cannot use that string to login.

This was last published in April 2005

Dig Deeper on Oracle database security



Find more PRO+ content and other member only offers, here.

Have a question for an expert?

Please add a title for your question

Get answers from a TechTarget expert on whatever's puzzling you.

You will be able to add details on the next page.

Start the conversation

Send me notifications when other members comment.

By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Please create a username to comment.