Created
June 11, 2019 11:23
-
-
Save riddla/2e8d5785801a79289cb4ee2b3ddba7dd to your computer and use it in GitHub Desktop.
remove password from pdf file using ghostscript
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Ghostscript command to remove the password from an encrypted pdf document. | |
# Replace ENCRYPTED.pdf with the path to your password protected pdf file. | |
# The unencrypted file is created as OUTPUT.pdf in the same directory. | |
# Install Ghostscript on the Mac with brew install gs | |
gs -q -dNOPAUSE -dBATCH -sDEVICE=pdfwrite -sOutputFile=OUTPUT.pdf -c .setpdfwrite -f ENCRYPTED.pdf |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment