So I was trying to figure out whether a grantee in DBA_SYS_PRIVS was a user or a role.
When I search for it in DBA_SYS_PRIVS, it's there:
select grantee, privilege from DBA_SYS_PRIVS
where grantee = 'GRANTEE1'
Which gives me:
GRANTEE|PRIVILEGE
-----------------
GRANTEE1|CREATE SESSION
GRANTEE1|UNLIMITED TABLESPACE
So then I wanted to know whether GRANTEE1 was a user or a role, so I did these two queries:
select * from USER_SYS_PRIVS
where username like 'GRANTEE1'
and
select * from ROLE_SYS_PRIVS
where role like 'GRANTEE1'
and neither of them showed any results.
So then I did a comparison of the counts, and found that there are many grantees in DBA_SYS_PRIVS that are not in USER_SYS_PRIVS or ROLE_SYS_PRIVS?
select count(username) from (select distinct username from user_sys_privs)
Result: 1
select count(role) from (select distinct role from role_sys_privs)
Result: 9
select count(grantee) from (select distinct grantee from dba_sys_privs)
Result: 61
9 + 1 does not equal 61...so what are all these other grantees with privileges in DBA_SYS_PRIVS, and are they users, roles, or something else?