Article

  • 2 years

    1 year

    YetiShare / Plugins / Document Viewer

    2768

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 & Nginx/Apache.