HOW TO ALTER PROFILE

Only common users who have been commonly granted the ALTER PROFILE system privilege can alter or drop the mandatory profile,

and only from the CDB root.

We cannot remove a limit from the DEFAULT profile.

Making a Password Unavailable:


The following statement makes the password of the new_profile profile unavailable for reuse for 90 days:

    ALTER PROFILE new_profile 

   LIMIT PASSWORD_REUSE_TIME 90 

   PASSWORD_REUSE_MAX UNLIMITED;

   

Setting Default Password Values: 


The following statement defaults the PASSWORD_REUSE_TIME value of the app_user profile to its defined value in the DEFAULT profile:


   ALTER PROFILE app_user 

   LIMIT PASSWORD_REUSE_TIME DEFAULT

   PASSWORD_REUSE_MAX UNLIMITED;

   

Limiting Login Attempts and Password Lock Time: 


The following statement alters profile app_user with FAILED_LOGIN_ATTEMPTS set to 5 and PASSWORD_LOCK_TIME set to 1:


  ALTER PROFILE app_user LIMIT

   FAILED_LOGIN_ATTEMPTS 5

   PASSWORD_LOCK_TIME 1;

This statement causes any user account to which the app_user profile is assigned to become locked for 

one day after five consecutive unsuccessful login attempts.


Changing Password Lifetime and Grace Period: 


The following statement modifies the profile app_user2 PASSWORD_LIFE_TIME to 90 days and PASSWORD_GRACE_TIME to 5 days:


ALTER PROFILE app_user2 LIMIT

   PASSWORD_LIFE_TIME 90

   PASSWORD_GRACE_TIME 5;

   

Limiting Account Inactivity: 


The following statement modifies the profile app_user2 INACTIVE_ACCOUNT_TIME to 30 consecutive days:


ALTER PROFILE app_user2 LIMIT

  INACTIVE_ACCOUNT_TIME 30;

  

If the account has already been inactive for a certain number of days, then those days count toward the new 30 day limit.


Limiting Concurrent Sessions:


This statement defines a new limit of 5 concurrent sessions for the app_user profile:


ALTER PROFILE app_user LIMIT SESSIONS_PER_USER 5; 


If the app_user profile does not currently define a limit for SESSIONS_PER_USER, then the preceding statement adds the limit of 5 to the profile. 

If the profile already defines a limit, then the preceding statement redefines it to 5. 

Any user assigned the app_user profile is subsequently limited to 5 concurrent sessions.


Removing Profile Limits: 


This statement removes the IDLE_TIME limit from the app_user profile:


ALTER PROFILE app_user LIMIT IDLE_TIME DEFAULT;


Any user assigned the app_user profile is subject in their subsequent sessions to the IDLE_TIME limit defined in the DEFAULT profile.


Limiting Profile Idle Time: 


This statement defines a limit of 2 minutes of idle time for the DEFAULT profile:


ALTER PROFILE default LIMIT IDLE_TIME  2; 

This IDLE_TIME limit applies to these users:


Users who are not explicitly assigned any profile


Users who are explicitly assigned a profile that does not define an IDLE_TIME limit


This statement defines unlimited idle time for the app_user2 profile:


ALTER PROFILE app_user2 LIMIT IDLE_TIME UNLIMITED; 

Any user assigned the app_user2 profile is subsequently permitted unlimited idle time.


Enable Gradual Password Rollover: 


This statement sets the password rollover time to 2 days in the profile usr_prof:


ALTER PROFILE usr_prof LIMIT PASSWORD_ROLLOVER_TIME 2 ;

Comments

Popular posts from this blog

How to fix Oracle SQL Developer connection issue "Got minus one from a read call"

How to troubleshoot Long Running Concurrent Request in EBS 12.2

Few Important steps of Oracle Database Clone