linux poison RSS
linux poison Email

Merge or Encrypt / Decrypt PDF files using pdftk

Pdftk is a simple command line tool for doing everyday things with PDF documents. Use it to merge PDF documents, split PDF pages into a new document, decrypt input as necessary (password required), encrypt output as desired, fill PDF forms with FDF data and/or flatten forms, apply a background watermark, report on PDF metrics, update PDF metadata, attach files to PDF pages or the PDF document, unpack PDF attachments, burst a PDF document into single pages, decompress and re-compress page streams, and repair corrupted PDF files (where possible).

Ubuntu user can install pdftk using following command: sudo apt-get install pdftk

Using pdftk:
Once installed, we can merge pdf files using following command:
pdftk 1.pdf  2.pdf  3.pdf cat output 123.pdf
Encrypt a PDF using 128-Bit Strength (the Default) and Withhold All Permissions (the Default)
pdftk mydoc.pdf output mydoc.128.pdf owner_pw foopass
Decrypt a PDF
pdftk secured.pdf input_pw foopass output unsecured.pdf


Copy Protection Software said...

Hi all,

Nice blog! You can use PDF encryption to lock a file's content behind a password, but more often it is used to enforce lighter restrictions imposed by the author. When using pdftk on encrypted PDF documents, the owner password must be supplied. Thank you....

Post a Comment

Related Posts with Thumbnails