Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.server -> Re: Help: How is password hashed in Oracle?

Re: Help: How is password hashed in Oracle?

From: Brian Peasland <oracle_dba_at_nospam.peasland.net>
Date: Thu, 4 May 2006 20:49:21 GMT
Message-ID: <IyrDuK.9At@igsrsparc2.er.usgs.gov>


Evan wrote:

> gazzag wrote:

>>> Why not do this:
>>>
>>> spool test_password.sql
>>> SELECT 'CONNECT '||username||'/'||username FROM dba_users;
>>> spool off
>>> spool test_password.out
>>> @test_password
>>> spool off
>>>
>>> This will attempt to connect to every user with the password as their
>>> username. Review the test_password.out file to see if you were able to
>>> connect.
>>
>>
>> This is a good example of how we can sometimes try to over-complicate
>> things; the simplest solutions are invariably the best :-)
>>
> 
> I add a "select 'USER='||username from user_users;".
> This lets me grep for 'USER=' to clearly show the lines.

Alternatively, you could just do 'set echo on' in SQL*Plus to see the commands as they are being executed.

One problem with the SELECT as you have written it, and as it pertains to this specific problem...if you do not have the correct password, then you will not be connect to Oracle and you will not be able to return any results, which means the query will receive the SP2-0640 error as follows:

SQL> connect foo/bar
ERROR:
ORA-01017: invalid username/password; logon denied

Warning: You are no longer connected to ORACLE. SQL> select 'user='||username from user_users; SP2-0640: Not connected

Cheers,
Brian

-- 
===================================================================

Brian Peasland
oracle_dba_at_nospam.peasland.net
http://www.peasland.net

Remove the "nospam." from the email address to email me.


"I can give it to you cheap, quick, and good.
Now pick two out of the three" - Unknown
Received on Thu May 04 2006 - 15:49:21 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US