When Hyland plugged MNT-21638, a remote-code-execution hole in the Activiti script task, the patch shipped in ACS 7.3.0 quietly changed the execution sandbox. Workflows deployed from inside the repository (via Share, Admin > Workflow Console or a simple file upload) lost direct access to Java and now throw the exception:
ScriptException ... ReferenceError: "java" is not defined
Later versions (from 7.3.1 to 23.4.x) even blocked some task-listener scripts because of a follow-on bug tracked in MNT-24913
Below is the fastest way to decide whether you’re affected and the resolution path that works for every known cause.
Affected versions: 7.3 to 23.4.x
Deployment methods affected:
Database flag:
SELECT category FROM act_re_deployment
returns Null/empty (it must return http://alfresco.org/workflows/fullAccess)
Why the DB check? The MNT-24913 fix simply falls back to that category flag when the Activiti execution context isn’t yet available. So if the flag is missing, your script will stay locked down even after upgrading.
Package every workflow as a class-path deployment and give it the fullAccess category.
Do not waste time poking Rhino or reverting patches, this is the only approach blessed by Engineering and it keeps you secure from the original RCE.
Here’s the minimal setup:
1. Place files on the classpath
$CATALINA_BASE/shared/classes/alfresco/extension/
├── myProcess.bpmn20.xml
└── myProcess-context.xml
2. Skeleton Spring context
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE beans PUBLIC "-//SPRING//DTD BEAN//EN"
"http://www.springframework.org/dtd/spring-beans.dtd">
<beans>
<bean id="my.workflowBootstrap" parent="workflowDeployer">
<property name="workflowDefinitions">
<list>
<props>
<prop key="engineId">activiti</prop>
<prop key="location">alfresco/extension/myProcess.bpmn20.xml</prop>
<prop key="mimetype">text/xml</prop>
<prop key="redeploy">false</prop>
</props>
</list>
</property>
</bean>
</beans>
Mounting or copying these two files into the container gives the process full Java access again.
3. Verify
SELECT category
FROM act_re_deployment
WHERE name_ = 'myProcess.bpmn20.xml';
It should return http://alfresco.org/workflows/fullAccess
If the row is missing, restart ACS; the bootstrapper sets it on startup.
1. Bundle BPMN + context in your build pipeline; treat workflows like code, not content.
2. Smoke-test upgrades with a script task that calls a harmless Java class, you’ll catch sandbox regressions instantly.
3. Monitor "act_re_deployment.category", a missing flag means someone bypassed the standard deploy path.
4. Stay current: the patch cadence is steady, and Hyland no longer back-ports most script-engine fixes beyond the current LTS.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.