select * from Dba_users;--Query all users in the database
ALTER user Scott account lock;--Lock users
alter user Scott account unlock;--Unlocking the user
Create user username identified by password;
Grant connect to user name;--Authorized user permission to allow login
Grant create tablespace to username;--Authorization to create TABLE space permissions
Grant Select on the authorized table name to user name;--Authorize the user to query permissions for a table
grant update on authorized table name to user name;--Authorize the user to update permissions for a table
grant insert on authorized table name to user name;--Authorize the user to insert a table's permissions
Grant execute on stored procedure to user name;--Authorize the user to have stored procedure permissions
grant update on authorized table name to user name with GRANT option;--(continuous authorization) Authorized Update permission to transfer to the next user, allow the user to continue to authorize;
--Revoke permissions
Revoke select on the authorized table name from the user name;--Recover the permissions of the query select Table ;
revoke insert on authorized table name from user name;--Revoke permissions of xujin1 role;
revoke all on the authorized table name from the user name;--Recover all permissions of the user
Grant connect to user name;--Authorized user permission to allow login
revoke connect from user name;--Reclaim the user's logon rights
SELECT * from Dba_tab_privs where grantee= ' user name ';--Query the permissions of a user-owned object
SELECT * from Dba_sys_privs where grantee= ' username ';--query for system permissions owned by a user
select * from Session_privs;--system permissions that are valid for the current session
--Character
create role name;--Establish ' role name ' role
Grant role name to user name;--Authorizes the role's permissions to the user;
alter USER role name default user name 1, user name 2;
drop role role name;--Remove roles 1;
SELECT * from Role_sys_privs where role= role name;---See what system permissions are available under a role ;
SELECT * from Role_role_privs where role= role name;---See what role permissions are under a role
SELECT * from Role_tab_privs where role= ' role name ';---See what table permissions are available under a role
SELECT * from Dba_role_privs where grantee= ' username ';--see how many roles there are under the user;
Oracle basic rights authorization or reclaim permissions, unlock and other permissions configuration