Issue
AccessControlException in groovy script task types
Explanation
In order to bypass the AccessControlException in groovy script task types, you need to add the following lines in the script.policy file. Instructions on how this can be achieved is explained as follows:
When a Groovy Script task becomes active, the script is executed in a sandbox environment on the XL Release server. This means that the script has very restricted permissions. By default, access to the file system, network, and non-API-related classes is not allowed.
Solution
- To remove these restrictions, add a script.policy file to the XL_RELEASE_SERVER_HOME/conf directory. This is a standard Java Security Policy file that contains the permissions that a script should have.
- To enable the use of additional Java packages or classes in the script, use the following XL Release- specific RuntimePermission:
permission java.lang.RuntimePermission accessClassInPackage.sun.net.www.protocol.https";
- - You must restart the XL Release server after creating or changing the XL_RELEASE_SERVER_HOME/conf/script.policy file.
Comments
Please sign in to leave a comment.