Edinburgh-Genome-Foundry / pdf_reports

:closed_book: Python library and CSS theme to generate PDF reports from HTML/Pug
https://edinburgh-genome-foundry.github.io/pdf_reports/
MIT License
223 stars 39 forks source link

Encrypt PDF files #19

Open DTHerrera opened 2 years ago

DTHerrera commented 2 years ago

Hello, I just want to know if there is any option to encrypt and decrypt the generated PDF documents.

Thanks a lot.

veghp commented 2 years ago

Hi, no not at the moment.

If you mean file encryption, that's outside the scope of the package, if you mean password-protection then the following applies: the document is generated based on a HTML template and exported to PDF; if there is a functionality in the weasyprint package that can perform password protection then there may be a way to implement this in pdf_reports. Alternatives are (batch-)protecting with another tool such as ghostscript.