PDFbrute is a shell script in which you can pass a wordlist and brute force an encrypted PDF file and get the password in plaintext.
PDFbrute requires qpdf to work.
Install the dependencies, give executable permission to the script and then run the shell script.
$ git clone https://github.com/1337w0rm/pdfbrute.git
$ cd pdfbrute
$ chmod +x pdfbrute.sh
$ ./pdfbrute wordlist.txt encrypted-pdf-file.pdf