Home » RDBMS Server » Security » Regarding oracle VPD
Regarding oracle VPD [message #669079] Sun, 01 April 2018 05:33 Go to next message
shipon_97
Messages: 16
Registered: March 2008
Junior Member
I am using Oracle 12c with VPD object level policies using user SCOTT. Like below:

BEGIN
  SYS.DBMS_RLS.ADD_POLICY     (
    object_schema          => 'SCOTT'
    ,object_name           => 'CARDS'
    ,policy_name           => 'STRICT'
    ,function_schema       => 'TCTDBS'
    ,policy_function       => 'SV_DB_POLICIES.STRICT_POLICY'
    ,statement_types       => 'SELECT,INSERT,UPDATE,DELETE'
    ,policy_type           => dbms_rls.shared_context_sensitive
    ,long_predicate        => FALSE
    ,update_check          => TRUE
    ,static_policy         => FALSE
    ,enable                => TRUE );
END;
/

-- Here only Scott user can select,insert,update and delete on cards table under scott schema . Now from another user 'test' , I cannot select this CARDS table , although I give the select permission .

grant select on scott.cards to test ;

SQL > conn test/test
SQL> select count(*) from scott.cards;

  COUNT(*)
----------
         0

My question , How can I able to select scott.cards table from the 'test' user using VPD policies ??
Is there any way to use this policy by a specific user ?
Re: Regarding oracle VPD [message #669081 is a reply to message #669079] Sun, 01 April 2018 07:02 Go to previous message
shipon_97
Messages: 16
Registered: March 2008
Junior Member
Got the answer!!!

grant EXEMPT ACCESS POLICY to TEST;
Previous Topic: Give "select on all tables from a user" to another user
Next Topic: What encryption algorithm Oracle 12
Goto Forum:
  


Current Time: Wed Dec 11 16:29:12 CST 2019