Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mortenbra/bfdacd9c790522e7e7962b566ffd9152 to your computer and use it in GitHub Desktop.
Save mortenbra/bfdacd9c790522e7e7962b566ffd9152 to your computer and use it in GitHub Desktop.
-- run as SYS or a user with APEX_ADMINISTRATOR_ROLE
begin
-- note: this does not work, as the REMOTE_ADDR variable will be 127.0.0.1 when using Apache as proxy
--apex_instance_admin.set_parameter ('RESTRICT_IP_RANGE', '1.2.3.4');
-- this solution requires this header to be set in Apache VirtualHost, based on whether the client IP is trusted or not
apex_instance_admin.set_parameter ('RESTRICT_DEV_HEADER', 'X-MyCompany-Public-Client');
commit;
end;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment