Sunday, October 21, 2007

password value in dba_users

[CONCLUSION]
Same encrypted password string (PASSWORD column) in dba_users doesn't mean the actual password are the same. USERNAME looks the key to encrypt the password.
Below is the experiment.

SQL> select password, username from dba_users where username in ('LIQY');

PASSWORD USERNAME
------------------------------ ------------------------------
B68901BE8B75A6BA LIQY

SQL> create user liqy1 identified by values 'B68901BE8B75A6BA';

User created.

SQL> grant create session to liqy1;

Grant succeeded.

SQL> sers where username in ('LIQY','LIQY1'); <> connect liqy1/liqyliqy;
ERROR:
ORA-01017: invalid username/password; logon denied


Warning: You are no longer connected to ORACLE.
SQL> connect liqy/liqyliqy;
Connected.


SQL> connect /
Connected.
SQL> alter user liqy identified by liqyliqy;

User altered.

SQL> s where username in ('LIQY','LIQY1'); <> connect /
Connected.
SQL> alter user liqy1 identified by liqyliqy;

User altered.

SQL> select password, username from dba_users where username in ('LIQY','LIQY>

PASSWORD USERNAME
------------------------------ ------------------------------
B68901BE8B75A6BA LIQY
56775B8ACC3F0E97 LIQY1