According to the VeraCrypt FAQ, regarding whether or not TPMs are supported:

No. Those programs use TPM to protect against attacks that require the attacker to have administrator privileges, or physical access to the computer, and the attacker needs you to use the computer after such an access. However, if any of these conditions is met, it is actually impossible to secure the computer (see below) and, therefore, you must stop using it (instead of relying on TPM).

If the attacker has administrator privileges, he can, for example, reset the TPM, capture the content of RAM (containing master keys) or content of files stored on mounted VeraCrypt volumes (decrypted on the fly), which can then be sent to the attacker over the Internet or saved to an unencrypted local drive (from which the attacker might be able to read it later, when he gains physical access to the computer).

Maybe I'm wrong, but the content of the RAM will never contains the master keys right? The TPM will be used like an HSM, thus cryptographic operations will be made inside the TPM, and nothing about keys will be stored in the RAM. Can you confirm me that?

If the attacker can physically access the computer hardware (and you use it after such an access), he can, for example, attach a malicious component to it (such as a hardware keystroke logger) that will capture the password, the content of RAM (containing master keys) or content of files stored on mounted VeraCrypt volumes (decrypted on the fly), which can then be sent to the attacker over the Internet or saved to an unencrypted local drive (from which the attacker might be able to read it later, when he gains physical access to the computer again).

I'm not sure about what they call "hardware keystroke logger". Is it a sort of electromagnetic analyses (DEMA)? If so, TPM is by default protected against it.

  • 1
    While TPMs have benefits, there's always a risk that the manufacturer has put a back-door in. The decision of whether to use a TPM reflects the software's priorities. VeraCrypt wants to put you in charge and avoids the TPM back-door risk.
    – paj28
    Feb 12, 2017 at 11:36
  • A hardware keylogger is just a device you plug between the keyboard and the PC. Also you have a duplicate paragraph, the last of which mysteriously contains "again" in its last sentence
    – J.A.K.
    Feb 12, 2017 at 13:45
  • The purpose of a TPM is to provide integrity and mitigate evil maid attacks. The VeraCrypt developers seem to not understand the TCG threat model very well and refuse to use the TPM out of ignorance (though according to one answer here, newer versions of UEFI VeraCrypt do use a TPM).
    – forest
    May 25, 2018 at 5:48

2 Answers 2


VeraCrypt encrypts every sector with a different key. Those different keys are derived from one master key. The master key itself is stored in the volume, protected by the volume password (and/or key files). The discussion you quote is about whether the master key should be stored inside the TPM instead of being encrypted by a password or key files on the disk. In either case, VeraCrypt needs the master key in RAM to derive the sector keys.

Having the TPM calculate the sector keys is indeed an option that improves security against RAM dumps, but I can't judge the practicality (for example, I don't know whether the TPM supports deriving subkeys in a suitable way or the latency introduced by that). Nevertheless, an attacker having administrative rights could start to ask the TPM for one sector key after the other (just as truecrypt does) and record them.

Your second question: A hardware keylogger is a standalone USB proxy that is installed between your USB controller on the mainboard and the keyboard (it might even be inside the case, especially if the keyboard is connected to a front-facing port being cable-connected to the main board.

My oppinion about using a TPM is that it could indeed work if certain conditions are met. And that applies even to the case in which the TPM only protects the master key: The TPM is supposed to hand out the master key if your computer is not tampered with (like a software keylogger in the BIOS or an unauthorized operating system change). So the TPM should make offline attacks on retrieving the master key impossible. Still the TPM does not protect the master key after having it given out to VeraCrypt. The idea is that the there are no security holes in the operating system (which has been verified by secure boot), and the key is stored in kernel memory. The operating system furthermore should prevent user-mode processes to read kernel mode memory, so there is no chance to get the VeraCrypt master key. Note the very bold assumption of an "operating system without security holes", which is very unlikely to be true with current operating systems, so the whole argument breaks down. And as if this is not bad enough, even an operating system without security holes needs to rely on the hardware working properly. If the hardware (like the processor or the memory) exposes memory contents to a user space process without the operating system having allowed such a thing, the system is compromised. And exactly that can be achieved by the recent RowHammer attack on a large portion of computers.

  • Thank you for your answer. This sentence is still with no answer : "Having the TPM calculate the sector keys is indeed that improves security against RAM dumps...". However, I think this is another question (does a TPM make cryptographic operations by itself...)
    – Duke Nukem
    Feb 13, 2017 at 8:06
  • A TPM can do cryptographic operations, like signing with a key that never leaves the TPM. But I don't know whether the properties of the hardware crypto in a TPM makes it suitable for deriving sector keys. Feb 13, 2017 at 8:12
  • -1 this is not at all what a TPM is ever used for, and not the reason why it would be used in the first place (it would be used for integrity or storing a per-machine key, nothing else).
    – forest
    May 25, 2018 at 5:11

I did preview of TPM 1.2 support for VeraCrypt UEFI.

Main idea is to set secret in TPM NVRAM under PCRs protection. It locks boot chain. So modification of BIOS and other components causes authorization deny.

  • It looks like they added it in 1.20.
    – forest
    Jun 19, 2018 at 3:41

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .