PDF passwords explained: what they protect and what they do not

A PDF can carry two very different kinds of password. One genuinely locks the document; the other mostly asks politely. Knowing which is which decides how far you can rely on it.

By NoUploadPDF ยท Published

Two kinds of protection

The PDF format allows a document to have an opening password, a set of restrictions, or both. They are often described together, as if they were two strengths of the same lock. They are not.

An opening password
Also called a user password or document open password. Without it, the file cannot be read at all. Every reader asks for it before showing a single page.
Restrictions
Also called permissions, and controlled by an owner or permissions password. Anyone can open and read the file, but the reader is asked not to allow printing, copying text, or editing.

What an opening password really does

When a PDF has an opening password, its contents are encrypted: the text, the images and the structure of every page are scrambled using a key derived from the password, and only that key turns them back into a readable document. There is no hidden copy of the pages to fall back on. A reader that does not have the password does not have the document, only noise.

That is why a forgotten opening password is a real problem. A properly encrypted file has no back door, and no reputable tool can simply remove the password. The only way in without it is to guess, and against a strong password and modern encryption, guessing does not finish in any useful amount of time.

Why restrictions alone are weak

Restrictions are different. A file with restrictions but no opening password has to be readable by anyone, so any reader can display it, which means any program can also read every word of it. The restriction is a flag in the file saying, in effect, "please do not let the reader print this". Readers that follow the rules respect it; programs that ignore it are common, and removing the flag takes moments.

So treat restrictions as a statement of intent, not as security. They stop casual copying by people using ordinary software. They do not stop anyone determined, and they do not keep the content private, because the content was never hidden. If a document must not be read by the wrong people, it needs an opening password.

How strong is the encryption?

The format has gained stronger encryption over the years, and the version used matters:

MethodWhere you meet itStrength today
RC4, 40-bitVery old files and old softwareWeak. Can be broken regardless of the password
RC4 or AES, 128-bitFiles from the mid-2000s onwardAcceptable, but no longer recommended
AES, 256-bitCurrent software; the strongest the format definesStrong. The password is the weak point, not the cipher

Inside the file, AES-256 is recorded as AESV3, and the most recent form of the format's password handling as revision 6. Protect PDF uses exactly that, and does not take the file's own word for it: before offering the locked document, it reads those two markers back out of the saved file, and has a second, independent PDF reader confirm that the file refuses to open without the password and opens with it. A file that fails either test is not offered.

One cost of strong encryption is that PDF readers many years old may not open a document locked with AES-256. Anything current will.

Choosing the password

With AES-256, an attacker cannot attack the encryption; they can only guess the password. So the password is the whole of the protection:

  • Length beats cleverness. Four or five unrelated words are far harder to guess than a short word with a number and a symbol added.
  • Use it only here. A password used elsewhere may already be in a list of leaked passwords, which is the first thing anyone tries.
  • Avoid what is printed in the document. A date of birth or an account number on page 1 is a poor password for page 1.

Many banks and payroll services lock statements with a predictable password, such as part of a date of birth. That protects against a message reaching the wrong inbox, not against someone who knows you.

Sending a locked file

A password sent in the same email as the file protects almost nothing: anyone who gets the email gets both. Send it another way, such as a text message, a phone call or a message in a different app, and agree it in advance if you send files to the same person often.

Remember too what encryption cannot do. Once the recipient opens the document, they can save, print or forward an unlocked copy. A password controls who can open a file, not what happens after it is opened.

What the tools here do

Locking a document

Protect PDF sets one password, which both opens the document and governs what it permits; a separate password for changing the permissions is not offered. With the password, the document can be read, printed at full quality and copied from; editing it is not permitted. Bookmarks, form fields and attachments are encrypted along with the pages.

The password is used on your device and is never sent anywhere or kept. That has a consequence worth stating plainly: if you lose it, nobody can recover it, including this site.

Removing a password you know

Unlock PDF saves a copy with no encryption and no restrictions, once you type the password. A file that opens freely but blocks printing or copying needs no password at all, for the reason explained above. The unlocked copy is written as a fresh document rather than resaved, so no trace of the encryption carries over, and a second reader confirms that it opens without any password. Every page comes across with its comments and links; bookmarks, attached files and fillable form fields do not.

It does not guess. A wrong password is refused once, with a message saying so, and the tool stops; there is no retry, no list of common passwords and no attempt to break the encryption. That is a deliberate limit, and it is also why it cannot help with a forgotten password. It is for documents you are entitled to open, such as your own statements, or a file shared with you along with its password.

Changing a password

Unlock the file with the old password, then protect the unlocked copy with the new one. Delete the unlocked copy afterwards if it should not be kept.

A quick way to tell what a file has

If you are not sure whether a document is encrypted or only restricted, Inspect PDF reports whether it is encrypted. A file that asks for a password before showing anything has an opening password. A file that opens straight away, but greys out printing or copying, has restrictions only.

The tools for this

More on privacy and security