How to find the privileges that have been granted to a user by querying data dictionary views.
DEMO

DEMO: HOW TO FIND SYSTEM, ROLES AND OBJECTS PRIVILEGES THAT HAVE BEEN GRANTED TO A USER

RELATED

HOW TO RETRIEVE AN OBJECT DDL OR A USER DDL USING PL/SQL
HOW TO FIND ALL OBJECTS PRIVILEGES GRANTED TO A USER IN AN ORACLE DATABASE

QUERY

The DBT_UPRIVSI queries data dictionary views to retrieve DIRECTLY and INDIRECTLY granted privileges to a user or a role.
The DBT_UPRIVSD queries data dictionary views to retrieve DIRECTLY granted privileges to a user or a role.

SQL> @DBT_UPRIVSD.sql

USERNAME or ROLE: demo

*************************
** Account details
*************************


Database                  TST19C
Systimestamp              11-SEP-2022 15:49
Account Name              DEMO
Account Type              USER
Created                   11-SEP-2022 15:42
Expiry Date               10-MAR-2023 15:42
Account Status            OPEN
User Profile              DEFAULT
Default Tablespace        USERS
Temporary Tablespace      TEMP


*************************
** System privileges
*************************

GRANTEE                   PRIVILEGE
------------------------- ----------------------------------------
DEMO                      UNLIMITED TABLESPACE
DEMO                      CREATE ANY DIRECTORY


*************************
** Granted Roles
*************************

GRANTEE                   GRANTED_ROLE                   SET_AS_DEFAULT  ROLE_CREATED      ROLE_TYPE
------------------------- ------------------------------ --------------- ----------------- ------------
DEMO                      CONNECT                        YES             17-APR-2019 00:56 ORACLE ROLE
DEMO                      RESOURCE                       YES             17-APR-2019 00:56 ORACLE ROLE


*************************
** Object privileges
*************************

GRANTEE                   PRIVILEGE  OBJECT_NAME
------------------------- ---------- ----------------------------------------
DEMO                      SELECT     SYS.V_$SESSION
DEMO                      SELECT     SYS.V_$SESSION_EVENT

Written At
18 NOV 202122:30
OEL Release
7.9 x64
Database Release
19.13.0.0.0