Access Control List in Oracle Database 11g

We had a request at one of our clients to open access from Apex to LDAP.  Here’s an example of creating the ACL and adding privileges.

begin  
dbms_network_acl_admin.create_acl (
    acl         => ‘ldap_web.xml’,
    description => ‘Allow Apex to LDAP Service’,
    principal   => ‘MYSCHEMA’,
    is_grant    => TRUE,
    privilege   => ‘connect’
    );
    commit;
end;
/


begin
  dbms_network_acl_admin.add_privilege (
  acl       => ‘ldap_web.xml’,
  principal => ‘MYSCHEMA’,
  is_grant  => TRUE,
  privilege => ‘resolve’
  );
  commit;
end;
/

begin
  dbms_network_acl_admin.add_privilege (
  acl       => ‘ldap_web.xml’,
  principal => ‘APEX_040100‘,
  is_grant  => TRUE,
  privilege => ‘resolve’
  );
  commit;
end;
/

begin
  dbms_network_acl_admin.assign_acl(
  acl  => ‘ldap_web.xml’,
  host => ‘ldap.visctech.com.ad
  );
  commit;
end;
/
 

Comments are closed.