Summary of DBMS_CLOUD_ADMIN_SEC Subprograms

This section covers the DBMS_CLOUD_ADMIN_SEC subprograms provided with Autonomous AI Database.

Subprogram Description

CLONE_ADMIN_PRIVILEGES Procedure

This procedure copies the all Oracle maintained privileges and permissions from the ADMIN user to a specified database account.

CLONE_ADMIN_PRIVILEGES Procedure

This procedure clones all Oracle maintained privileges and permissions from the ADMIN user to an existing individual database account.

The DBMS_CLOUD_ADMIN_SEC.CLONE_ADMIN_PRIVILEGES procedure creates a user with the same privileges as the ADMIN user. It allows administrators to assign the same administrative privileges to specific users, providing an alternative to using the ADMIN account for administrative tasks. You can run the procedure again to update cloned users if the ADMIN user’s privileges change.

Syntax

DBMS_CLOUD_ADMIN_SEC.CLONE_ADMIN_PRIVILEGES (
    username  IN VARCHAR2
);

Parameters

Parameter Description

username

Specifies the name of an existing user account. This is the target account that will receive all privileges currently held by the ADMIN user.

This parameter is mandatory.

Examples

  1. Clone the ADMIN privileges to an individual user DBA1.
    BEGIN
       DBMS_CLOUD_ADMIN_SEC.CLONE_ADMIN_PRIVILEGES (
           username => 'DBA1'
       );
    END;
    /
  2. Synchronize privileges after a patch or feature change:

    You can run the procedure again to synchronize privileges if the ADMIN account’s privileges change.

    BEGIN
       DBMS_CLOUD_ADMIN_SEC.CLONE_ADMIN_PRIVILEGES (
           username => 'DBA1'
       );
    END;
    /

Example

Usage Note

  • Only the ADMIN user or an existing cloned admin user can run this procedure.

  • The procedure copies the privileges and permissions of the ADMIN account to the specified user. It does not revoke any privileges that the user already has.

  • This procedure allows administrators to use their own credentials while maintaining the same level of access as the ADMIN account. This provides an alternative to sharing the ADMIN account.

  • After you clone the required users, you can lock the ADMIN account to reduce the risk of shared access.