Database Security Products (MOSC)

MOSC Banner

how to control the label of one user automatically

edited Nov 27, 2011 12:48AM in Database Security Products (MOSC) 4 commentsAnswered
  As we know , we can use SA_USER_ADMIN.SET_USER_LABELS to control the label of one specific user manually.   However, can we use a trigger to revoke the privilege of the user after the user logoff the database or re-logon the database.
 
  I have try to do this.
create or replace trigger label_security_reset_privilege               
after logon on database
declare
v_username varchar2(100);
Begin
  v_username :=SYS_CONTEXT('USERENV', 'SESSION_USER');
     if  v_username  in ('username1','username2','username3')
 Then
 SA_USER_ADMIN.SET_USER_LABELS('ssaccess_policy',v_username,'L1:c1:all');
    end if;

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center