mirror of
https://github.com/veracrypt/VeraCrypt.git
synced 2025-11-11 11:08:02 -06:00
Windows Bootloader: pass correct compressed data size to decompressor. Because the ds segment register is modified when setting up the decompressor segment, loader length should be read from the cs segment. (#666)
This commit is contained in:
@@ -139,7 +139,7 @@ checksum_ok:
|
|||||||
push dx
|
push dx
|
||||||
|
|
||||||
; Decompress boot loader
|
; Decompress boot loader
|
||||||
mov cx, word ptr [start + TC_BOOT_SECTOR_LOADER_LENGTH_OFFSET]
|
mov cx, word ptr cs:[start + TC_BOOT_SECTOR_LOADER_LENGTH_OFFSET]
|
||||||
sub cx, TC_GZIP_HEADER_SIZE
|
sub cx, TC_GZIP_HEADER_SIZE
|
||||||
push cx ; Compressed data size
|
push cx ; Compressed data size
|
||||||
push TC_BOOT_LOADER_COMPRESSED_BUFFER_OFFSET + TC_GZIP_HEADER_SIZE ; Compressed data
|
push TC_BOOT_LOADER_COMPRESSED_BUFFER_OFFSET + TC_GZIP_HEADER_SIZE ; Compressed data
|
||||||
|
|||||||
Reference in New Issue
Block a user