My app creates an PDF file and uses an user entered info. How can I avoid all attacks with PDF vector?
Will htmlspecialchars be enough?
I don't want to enable JavaScript in PDF.
|
My app creates an PDF file and uses an user entered info. How can I avoid all attacks with PDF vector? Will htmlspecialchars be enough? I don't want to enable JavaScript in PDF. |
|||||
|
|
How are you generating your PDFs? Unless you are creating HTML markup and using a tool to convert that to PDF, If you are using the PHP PDFlib functions like I'm not sure what attacks you're trying to avoid; the most common problem with PDF is embedded scripting malware, but unless you're deliberately putting script in (using eg There was a global-XSS vulnerability in the browser PDF plugin once that affected any site hosting a PDF; if you want to ensure protection from that for users with old plugins you can serve all your PDFs with |
|||
|
|