CST-7031 Velocity/FreeMarker templates do not properly restrict variable usage

Description

In Liferay Portal 7.0 CE GA3, Velocity and FreeMarker templates does not properly restrict the use of some variables, which allow any user with permission to create a template to insert arbitrary code in any page, prevent access to the portal or access private information stored in the portal.

Workaround:

  1. Navigate to Control Panel > Configuration > System Settings > Foundation > Velocity Engine
  2. Add "staticFieldGetter" (without the quotes) to the list of Restricted variables
  3. Navigate to Control Panel > Configuration > System Settings > Foundation > FreeMarker Engine
  4. Add "staticFieldGetter" (without the quotes) to the list of Restricted variables

Severity

Severity 1

Fixed Version(s)

Acknowledgments

This issue was reported by Sergej Michel

Publication Date: 

augusti 7, 2017

Found a Bug?

If you have found, or think you have found a bug, help us to help you by letting us know!

Found a Security Vulnerability?

There's a different process available if you have a security issue to report...

Hall of Fame!

Raise your profile - report security vulnerabilities and enter the Hall of Fame!