즐기며 살자

ORA-01031: insufficient privileges 본문

Oracle/ORA

ORA-01031: insufficient privileges

Milden 2016. 10. 29. 23:14

Toad 11.6에서 Oracle 12c에 접속시 ORA-01031: Insufficient privileges

An issue  faced is that when we try to connect from TOAD (version: 11.6 ) to a newly upgraded Oracle database 12c we faced the error:

ORA-01031: insufficient privileges

TOAD Error Message ORA-01031

The reason we are facing this problem, is the newly security implementation by Oracle in 12c for the system privilege SELECT ANY DICTIONARY. They have stripped this system privilege from accessing the following tables:USER$, ENC$,DEFAULT_PWD$, LINK$, USER_HISTORY$, CDB_LOCAL_ADMINAUTH$, XS$VERIFIERS

The current TOAD version checks the old (SELECT ANY DICTIONARY) which already has this table SYS.USER$ part of its permissionwhen it can’t access this table, it throws the error message:  ORA-01031

The reason in 12c they stripped those tables from “SELECT ANY DICTIONARY” is to protect the passwords in case this privilege is granted to non-DBA account , so the hashed passwords are not exposed (ONLY SYS account can query those tables).

So, to let the current version of TOAD works for 12c execute the following sql query:

SQL> grant select on sys.user$ to database_account;

https://geodatamaster.wordpress.com/2015/03/08/toad-ora-01031-insufficient-privileges-when-connecting-to-oracle-12c/