Skip to Main Content

Oracle Database Express Edition (XE)

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Can't Display New ACL's

PhilMan2Feb 28 2017 — edited Mar 1 2017

Hello,

I'm using Oracle XE 11.g and Apex 4.02.  I can't seem to display new ACL's that I created.  Here the code I'm using in SQL Developer:

If it existed in some form (due to testing), delete the ACL:

BEGIN

  DBMS_NETWORK_ACL_ADMIN.drop_acl (

    acl         => 'http_isbndb_com.xml');

  COMMIT;

END;

/

Create the ACL and assign a second privilege

PROMPT About to restore Privileges to User (Schema) APEX_040200 for the ACL http_isbndb_com.xml.;

BEGIN

  DBMS_NETWORK_ACL_ADMIN.CREATE_ACL   (acl        => 'http_isbndb_com.xml',

                                       description => 'http_isbndb_com.xml',

                                       principal  => 'APEX_040200',

                                       is_grant   => true,

                                       start_date => systimestamp,

                                       end_date   => null,

                                       privilege  => 'connect');

  DBMS_NETWORK_ACL_ADMIN.ADD_PRIVILEGE(acl        => 'http_isbndb_com.xml',

                                       principal  => 'APEX_040200',

                                       is_grant   => true,

                                       start_date => systimestamp,

                                       end_date   => null,

                                       privilege  => 'resolve');

COMMIT;

END;

/

PROMPT   Privileges are restored for principal APEX_040200 with ACL http_isbndb_com.xml.;

I get the prompts and the "Anonymous Block Completed" lines in SQL developer.

Display the ACL

SELECT acl,

       principal,

       privilege,

       is_grant,

       TO_CHAR(start_date, 'DD-MON-YYYY') AS start_date,

       TO_CHAR(end_date, 'DD-MON-YYYY') AS end_date

FROM   dba_network_acl_privileges;

This does NOT display the ACL: http_isbndb_com

If I re-run the CREATE_ACL / ADD_PRIVILEGE statements I get the following error message:

Error report -

ORA-31003: Parent /sys/acls/ already contains child entry http_isbndb_com.xml

ORA-06512: at "SYS.DBMS_NETWORK_ACL_ADMIN", line 252

ORA-06512: at line 2

31003. 00000 -  "Parent %s already contains child entry %s"

*Cause:    An attempt was made to insert a duplicate child into

           the XDB hierarchical resolver.

*Action:   Insert a unique name into the container.

That leads me to believe that I actually added something, but I just can't see it in the Select.

What am I doing wrong?

Thanks for looking at this.

This post has been answered by Gaz in Oz on Feb 28 2017
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 29 2017
Added on Feb 28 2017
3 comments
1,562 views