Summary

Cakephp twig-view unserialize Twig filter allows arbitrary object deserialization

Advisory details

Impact

The unserialize filter has no restriction on which classes are allowed. This can be used as a deserialization remote-code-execution gadget.

Patches

1.3.3 and 2.1.2 contain a fix for this issue. The fix may impact backwards compatibility if you are relying on deserializing PHP objects in your templates.

Workarounds

Don't use the unserialize filter.

References