Oracle 11g ORA-24247: network access denied by access control list (ACL)

10.3k views Asked by At

I am using soap_api as in the link http://www.oracle-base.com/articles/9i/ConsumingWebServices9i.php. I was able to call a web service in

Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - Prod
PL/SQL Release 10.2.0.1.0 - Production
"CORE   10.2.0.1.0  Production"
TNS for 32-bit Windows: Version 10.2.0.1.0 - Production
NLSRTL Version 10.2.0.1.0 - Production

But When i use the same in

Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
PL/SQL Release 11.2.0.1.0 - Production
"CORE   11.2.0.1.0  Production"
TNS for 64-bit Windows: Version 11.2.0.1.0 - Production
NLSRTL Version 11.2.0.1.0 - Production

Its giving

"ORA-29273: HTTP request failed
 ORA-06512: at "SYS.UTL_HTTP", line 1130
 ORA-24247: network access denied by access control list (ACL)"

Please help

1

There are 1 answers

2
Asraful On BEST ANSWER

Oracle allows access to external network services using several PL/SQL APIs (UTL_TCP, UTL_SMTP, UTL_MAIL, UTL_HTTP and UTL_INADDR), all of which are implemented using the TCP protocol. You need to create one ACL (access control list ) for this. Bellow scripts may be useful in this case as worked for me . In my case : i am using SYS.UTL_HTTP to call one SOAP based web service from pl/sql level .

begin
  dbms_network_acl_admin.create_acl (
  acl          => 'networkacl.xml',
  description  => 'Allow Network Connectivity',
  principal    => 'PUBLIC',
  is_grant     => TRUE,
  privilege    => 'connect',
  start_date   => SYSTIMESTAMP,
  end_date     => NULL);
 dbms_network_acl_admin.assign_acl (
  acl         => 'networkacl.xml',
  host        => 'AS NEEDED*',
  lower_port  => AS NEEDED*,
  upper_port  => AS NEEDED*);
  commit;
end;

You may take a look : here

  • AS NEEDED = define yourself based on your requirement