VeraCrypt
aboutsummaryrefslogtreecommitdiff
path: root/src/Boot
diff options
context:
space:
mode:
authorMounir IDRASSI <mounir.idrassi@idrix.fr>2014-06-10 16:08:11 (GMT)
committerMounir IDRASSI <mounir.idrassi@idrix.fr>2014-11-08 22:19:44 (GMT)
commitf34d894f6e53a033678fe2f9faba0c85e7cb0728 (patch)
tree9845c3038ca7e411798bc7810de19961a3acbc9d /src/Boot
parent7875d3ec3fb130e7db586d977c8f4f21f736963d (diff)
downloadVeraCrypt-f34d894f6e53a033678fe2f9faba0c85e7cb0728.zip
VeraCrypt-f34d894f6e53a033678fe2f9faba0c85e7cb0728.tar.gz
Detect correctly VeraCrypt rescue disk by looking for the little-endian encoding of "Vera" instead of "True".
Diffstat (limited to 'src/Boot')
-rw-r--r--src/Boot/Windows/BootMain.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/Boot/Windows/BootMain.cpp b/src/Boot/Windows/BootMain.cpp
index f1df2e9..6df82bd 100644
--- a/src/Boot/Windows/BootMain.cpp
+++ b/src/Boot/Windows/BootMain.cpp
@@ -1081,7 +1081,7 @@ void main ()
// Check whether the user is not using the Rescue Disk to create a hidden system
if (ReadWriteMBR (false, BootDrive, true) == BiosResultSuccess
- && *(uint32 *) (SectorBuffer + 6) == 0x65757254
+ && *(uint32 *) (SectorBuffer + 6) == 0x61726556
&& *(uint32 *) (SectorBuffer + 10) == 0x70797243
&& (SectorBuffer[TC_BOOT_SECTOR_CONFIG_OFFSET] & TC_BOOT_CFG_MASK_HIDDEN_OS_CREATION_PHASE) != TC_HIDDEN_OS_CREATION_PHASE_NONE)
{