Article

  • 5 months

    5 months

    YetiShare / Plugins / Document Viewer

    472

Uncaught ImagickException: attempt to perform an operation not allowed by the security policy `PDF'

Issue:


When attempting to view a PDF thumbnail, it fails with the error below in the logs:
Uncaught ImagickException: attempt to perform an operation not allowed by the security policy `PDF'

Fix:


Edit:

nano /etc/ImageMagick-6/policy.xml

Find:

<policy domain="coder" rights="none" pattern="PDF" />

Remove or comment out that line:

<!--<policy domain="coder" rights="none" pattern="PDF" />-->

Restart PHP FPM/Apache.