I recently rewrote my CV in LaTeX using Overleaf.com. Once I finished writing my CV in LaTeX, I downloaded it as a PDF. I'm now trying to upload my CV on brassring (careers website) and every time I select the PDF file I get the following error: 'The system does not allow files with active contents.' However if I try and upload my original CV that was written in Word it successfully uploads.
-
1you could find some useful info here: https://tex.stackexchange.com/questions/26529/how-can-i-generate-pdf-metadata-from-latex?rq=1, and (but not limited to) https://tex.stackexchange.com/questions/151241/remove-metadata-of-pdf-generated-by-latex – Raaja_is_at_topanswers.xyz Jan 11 '19 at 13:16
-
You could also try this: https://tex.stackexchange.com/questions/133303/how-to-remove-bookmarks-from-you-pdf-latex-file – Felix Phl Jan 11 '19 at 13:16
-
Any java in the pdf will be seen as a threat so simply use windows to REprint the pdf to DUMB pdf same as you did for word to pdf – Jan 11 '19 at 14:34
-
@KJO java in a PDF? Do you mean javascript? Two very different things – daleif Jan 11 '19 at 14:46
-
@daleif agreed java comes in many forms and variants but simply labelled as one umbrella "type" of attack see https://www.av-test.org/fileadmin/News/Pictures/2013/2013_12_rangliste_sw_nach_exploits_en.jpg – Jan 11 '19 at 15:03
-
@KJO yes, but how is java related to PDF in this sense? I'm just pointing out that the java you refer to in your comment is probably meant to be refering to 'javascript' and not java! And yes, javascript in PDF files is an attack vector. – daleif Jan 11 '19 at 15:34
-
@daleif I have no Idea what "active contents" the OP reject is based on. It could be anything imbedded in the pdf most likely one of the three common vectors 1. Active X Controls 2. Scripting (including JavaScript) 3. Java Applets so perhaps a better term would be "active scripting" but that does not cover all of Adobes own PDF Activity controls. In the words of the bard "A thorn by any name smells just as sharp". If someone shouts "virus" I don't first worry if its airborne or not. – Jan 11 '19 at 15:48
-
@Raaja Thanks but that didn't work – Spov Jan 11 '19 at 16:36
-
@KJO Is there a way to check for the common vectors? The only thing I see in my LaTeX file is LaTeX so there definitely isn't any JS. – Spov Jan 11 '19 at 16:37
-
@KJO I just tried to reprint the pdf again and it worked now ! Thank you so much, if you post it as an answer I can mark it as solved, so please do that and thanks once again! – Spov Jan 11 '19 at 16:57
-
I can't believe this question only has 1 upvote. I had this problem with SAP SucessFactors and many companies here in Germany use it for their application process. – user134593 May 21 '20 at 15:33
4 Answers
There are many embedded objects that can be flagged in a pdf with active content that may be seen by others as a threat in a pdf.
The simplest way to restructure to a dumbed down pdf is to use "windows print to pdf" to "reprint" as a simplified pdf much the same as you did for outputting word to pdf.
-
3This should work with most PDF readers on most platforms, not just Windows – user134593 May 21 '20 at 14:57
-
1While not specific to LaTeX, using Print to File (PDF) (and save as PDF also) did not work for me on Fedora32 using LibreOffice – Kelly Bang Jun 11 '20 at 18:21
-
1This solution allows for any malicious code to run when you open the PDF in a viewer. This might remove the warning but in the process you might infect your computer. Use a sandbox PC for this or better, use the Ghostscript solution. – TFuto Jan 08 '21 at 20:36
-
1Hm, after printing to PDF, the PDF looks really bad and I can't select any text anymore. The "save to PDF" version using Chrome (below) worked better. – stefanbschneider Sep 23 '21 at 10:56
In pretty much the same situation you described, I was able to "clean up" the PDF using GhostScript (edited according to comments):
gs -dNOPAUSE -sDEVICE=pdfwrite -sOUTPUTFILE=clean.pdf -dBATCH dirty.pdf
The company website accepted clean.pdf without complaints.
- 4,624
- 191
- 1
- 2
-
11Your script generated a corrupt PDF. This script worked for me "gs -dNOPAUSE -sDEVICE=pdfwrite -sOUTPUTFILE=NEW_FILE.pdf -dBATCH OLD_FILE.pdf" – Imam Bux Jun 15 '19 at 16:03
-
1@ImamBux your solution worked for me as well, I also got a corrupt file from LMB's script. Thanks! – teerav42 Feb 25 '20 at 04:28
-
-
We can also now do
gs -sDEVICE=pdfwrite -o clean.pdf dirty.pdf. Works great, thanks! – Erlkoenig Dec 13 '23 at 11:57
A quick and easy solution can be
- Simply open your pdf file in any modern web browser, say Google Chrome.
- Select 'Print' option to bring up the print menu.
- Change the Destination as 'Save as pdf' (in Google Chrome)
- Save the pdf in a new location on your system.
This uses Chrome's pdf wrapper which kind of repacks the pdf without any hyperlinks or Macros or perhaps any other active content.
- 151
-
1This solution allows for any malicious code to run when you open the PDF in a viewer. This might remove the warning but in the process you might infect your computer. Use a sandbox PC for this or better, use the Ghostscript solution. – TFuto Jan 08 '21 at 20:36
-
2True, Glad you pointed this out mate. I would only recommend this method if you've created the pdf yourself. If for example, you are trying to upload your resume to company's portal, chances are even hyperlinks not allowed. So there you can use this method. – simarmannsingh Jan 12 '21 at 15:23
My solution: Open the PDF in macOS Preview.app and save it with the option "Create PDF/A". I suppose many other PDF readers can do the same.
- 497