Merge remote-tracking branch 'upstream/master' into zh-HK-update

This commit is contained in:
harryytm 2024-11-26 00:43:38 +00:00
commit b01af9e926
222 changed files with 4452 additions and 18788 deletions

1
.gitignore vendored
View File

@ -16,6 +16,7 @@
src/Main/veracrypt
*.osse41
*.ossse3
*.oshani
# VC macOS build artifacts
src/Main/VeraCrypt

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="ar" name="العربية" en-name="Arabic" version="0.2.0" translators="Ahmad Gharbeia, Khaled Hosny, Ali Khojah" />
<font lang="ar" class="normal" size="11" face="default" />
<font lang="ar" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="be" name="Беларуская" en-name="Belarusian" version="0.1.0" translators="Aleg Azarousky" />
<font lang="be" class="normal" size="11" face="default" />
<font lang="be" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="bg" name="Български" en-name="Bulgarian" version="0.1.0" translators="Lachezar Gorchev" />
<font lang="bg" class="normal" size="11" face="default" />
<font lang="bg" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="ca" name="Català" en-name="Catalan" version="0.1.0" translators="CESICAT, Centre de Seguretat de la Informació de Catalunya" />
<font lang="ca" class="normal" size="11" face="default" />
<font lang="ca" class="bold" size="13" face="Arial" />

View File

@ -7,7 +7,7 @@ Information about Corsican localization:
2. History of Corsican translation for VeraCrypt:
- Updated in 2024 by Patriccollu di Santa Maria è Sichè: Aug. 2nd (1.26.15), Aug. 10th (1.26.15)
- Updated in 2024 by Patriccollu di Santa Maria è Sichè: Aug. 2nd (1.26.17), Aug. 10th (1.26.17)
- Updated in 2023 by Patriccollu di Santa Maria è Sichè: May 29th (1.26), May 30th (1.26), June 1st (1.26),
June 2nd (1.26), June 5th (1.26.2), June 21st (1.26.2), June 23rd (1.26.2), June 25th (1.26.2),
June 29th (1.26.2), July 1st (1.26.3), July 30th (1.26.4), Aug. 14th (1.26.5), Sep. 8th (1.26.5),
@ -19,7 +19,7 @@ Information about Corsican localization:
https://github.com/Patriccollu/Lingua_Corsa-Infurmatica/blob/ceppu/Prughjetti/VeraCrypt/Traduzzione.md
-->
<VeraCrypt>
<localization prog-version="1.26.15">
<localization prog-version="1.26.17">
<language langid="co" name="Corsu" en-name="Corsican" version="1.4.6" translators="Patriccollu di Santa Maria è Sichè"/>
<font lang="co" class="normal" size="11" face="default"/>
<font lang="co" class="bold" size="13" face="Arial"/>

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="cs" name="Čeština" en-name="Czech" version="1.3.0" translators="Vítek Moser, Lagardere" />
<font lang="cs" class="normal" size="11" face="default" />
<font lang="cs" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="da" name="Dansk" en-name="Danish" version="0.1.0" translators="Lasse Bond" />
<font lang="da" class="normal" size="11" face="default" />
<font lang="da" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<!-- Sprachen -->
<language langid="de" name="Deutsch" en-name="German" version="1.1.8" translators="Harry Haller, Alexander Schorg, Simon Frankenberger, David Arndt, H. Sauer, Dulla, Ettore Atalan, Matthias Kolja Miehl, Felix Reichmann" />
<!-- Schriftarten -->

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="el" name="Ελληνικά" en-name="Greek" version="0.1.0" translators="Βασίλης Κοσμίδης" />
<font lang="el" class="normal" size="11" face="default" />
<font lang="el" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="es" name="Español" en-name="Spanish" version="1.0.0" translators="Juan Antonio Auñón Ochando" />
<font lang="es" class="normal" size="11" face="default" />
<font lang="es" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="et" name="Eesti" en-name="Estonian" version="0.1.0" translators="Maiko Mõtsar" />
<font lang="et" class="normal" size="11" face="vaikimisi" />
<font lang="et" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="eu" name="Euskara" en-name="Basque" version="1.0.0" translators="Ander Genua" />
<font lang="eu" class="normal" size="11" face="default" />
<font lang="eu" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="fa" name="فارسي" en-name="Persian" version="0.1.0" translators="Ali Bitazar, Rodabeh Sarmadi" />
<font lang="fa" class="normal" size="11" face="default" />
<font lang="fa" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="fi" name="Suomi" en-name="Finnish" version="0.4.0" translators="Matti Ruhanen, Jertzukka" />
<font lang="fi" class="normal" size="11" face="default" />
<font lang="fi" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="fr" name="Français" en-name="French" version="0.3.0" translators="Stéphane S., Olivier M., Thierry T" />
<font lang="fr" class="normal" size="11" face="default" />
<font lang="fr" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt xmlns:xs="http://www.w3.org/2001/XMLSchema">
<localization prog-version="1.26.15">
<localization prog-version="1.26.17">
<language langid="he" name="עברית" en-name="Hebrew" version="0.1.0" translators="thewh1teagle" />
<font lang="he" class="normal" size="11" face="default" />
<font lang="he" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="hu" name="Magyar" en-name="Hungarian" version="1.0.0" translators="Nyul Balazs > Szaki, Zityi's Translator Te@m" />
<font lang="hu" class="normal" size="11" face="default" />
<font lang="hu" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="id" name="Bahasa Indonesia" en-name="Indonesian" version="1.0.0" translators="Tajuddin N. F.; Transifex contributors" />
<font lang="id" class="normal" size="11" face="default" />
<font lang="id" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="it" name="Italiano" en-name="Italian" version="1.0.1" translators="Maurizio Ballo, Consiglio Gaetano" />
<font lang="it" class="normal" size="11" face="default" />
<font lang="it" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="ja" name="日本語" en-name="Japanese" version="1.1.0" translators="OGOSHI Masayuki, Transifex contributors" />
<font lang="ja" class="normal" size="12" face="MS UI Gothic" />
<font lang="ja" class="bold" size="16" face="MS UI Gothic" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="ka" name="ქართული" en-name="Georgian" version="0.1.0" translators="Kakha Lomiashvili" />
<font lang="ka" class="normal" size="12" face="Arial" />
<font lang="ka" class="bold" size="12" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="ko" name="한국어" en-name="Korean" version="0.2.0" translators="Kieaer, Herbert Shin, BaekMu" />
<font lang="ko" class="normal" size="11" face="돋움" />
<font lang="ko" class="bold" size="13" face="맑은 고딕" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="lv" name="Latviešu" en-name="Latvian" version="0.1.0" translators="Edmunds Melkers" />
<font lang="lv" class="normal" size="11" face="default" />
<font lang="lv" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="my" name="မြန်မာ" en-name="Burmese" version="2.0.0" translators="Zaw Myo Htet; Transifex contributors" />
<font lang="my" class="normal" size="11" face="Myanmar3" />
<font lang="my" class="bold" size="13" face="Myanmar3" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="nb" name="Norsk Bokmål" en-name="Norwegian (Bokmål)" version="0.1.0" translators="Marius Kjærstad" />
<font lang="nb" class="normal" size="11" face="default" />
<font lang="nb" class="bold" size="13" face="Arial " />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="nl" name="Nederlands" en-name="Dutch" version="0.0.0" translators="Jan van der Wal, Peter Tak, Thomas De Rocker"/>
<font lang="nl" class="normal" size="11" face="default"/>
<font lang="nl" class="bold" size="13" face="Arial"/>

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="nn" name="Norsk Nynorsk" en-name="Norwegian (Nynorsk)" version="0.1.0" translators="Kjell Rune Helland" />
<font lang="nn" class="normal" size="11" face="default" />
<font lang="nn" class="bold" size="13" face="Arial " />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="pl" name="Polski" en-name="Polish" version="1.0.0" translators="Mirek Druchowicz, Janusz Zamecki, Sobiesław Antolak, Begina Felicysym" />
<font lang="pl" class="normal" size="11" face="default" />
<font lang="pl" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="pt-br" name="Português-Brasil" en-name="Portuguese (Brazil)" version="0.2.0" translators="Thiago C. L. Mendes, Lecidio S. Alencar , Lucas C. Ferreira, Daniel Dias Rodrigues, Transifex contributors" />
<font lang="pt-br" class="normal" size="11" face="padrão" />
<font lang="pt-br" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="ro" name="Română" en-name="Romanian" version="2.0.0" translators="Barna Cosmin Marian" />
<font lang="ro" class="normal" size="11" face="default" />
<font lang="ro" class="bold" size="13" face="Arial" />
@ -1636,11 +1636,11 @@
<entry lang="ro" key="IDC_DISABLE_MEMORY_PROTECTION">Dezactivare protecție memorie pentru compatibilitate unelte de accesibilitate</entry>
<entry lang="ro" key="DISABLE_MEMORY_PROTECTION_WARNING">AVERTIZARE: dezactivarea protecției memoriei reduce significant securitatea. Activați această opțiune NUMAI dacă aveți de nevoie de uneltele de accesibilitate, cum ar fi naratoarele, pentru a interacționa cu interfața VeraCrypt.</entry>
<entry lang="ro" key="LINUX_LANGUAGE">Limba</entry>
<entry lang="en" key="LINUX_SELECT_SYS_DEFAULT_LANG">Select system's default language</entry>
<entry lang="en" key="LINUX_RESTART_FOR_LANGUAGE_CHANGE">For the language change to come into effect, VeraCrypt needs to be restarted.</entry>
<entry lang="en" key="ERR_XTS_MASTERKEY_VULNERABLE">WARNING: The volume's master key is vulnerable to an attack that compromises data security.\n\nPlease create a new volume and transfer the data to it.</entry>
<entry lang="en" key="ERR_SYSENC_XTS_MASTERKEY_VULNERABLE">WARNING: The encrypted system's master key is vulnerable to an attack that compromises data security.\nPlease decrypt the system partition/drive and then re-encrypt it.</entry>
<entry lang="en" key="ERR_XTS_MASTERKEY_VULNERABLE_SHORT">WARNING: The volume's master key has a security vulnerability.</entry>
<entry lang="ro" key="LINUX_SELECT_SYS_DEFAULT_LANG">Selectați limba implicită a sistemului</entry>
<entry lang="ro" key="LINUX_RESTART_FOR_LANGUAGE_CHANGE">Pentru a se aplica modificarea limbii, VeraCrypt trebuie repornit.</entry>
<entry lang="ro" key="ERR_XTS_MASTERKEY_VULNERABLE">AVERTIZARE: Cheia principală a volumului este vulnerabilă la un atac care compromite securitatea datelor.\n\nTrebuie să creați un volum nou și să transferați datele pe acesta.</entry>
<entry lang="ro" key="ERR_SYSENC_XTS_MASTERKEY_VULNERABLE">AVERTIZARE: Cheia principală a sistemului criptat este vulnerabilă la un atac care compromite securitatea datelor.\nDecriptați partiția/unitatea de sistem și apoi recriptați-o.</entry>
<entry lang="ro" key="ERR_XTS_MASTERKEY_VULNERABLE_SHORT">AVERTIZARE: Cheia principală a volumului are o vulnerabilitate de securitate.</entry>
</localization>
<xs:schema attributeFormDefault="unqualified" elementFormDefault="qualified" xmlns:xs="http://www.w3.org/2001/XMLSchema">
<xs:element name="VeraCrypt">

View File

@ -1,7 +1,7 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<language langid="ru" name="Русский" en-name="Russian" version="1.26.15" translators="Dmitry Yerokhin [erodim@mail.ru] (240826)" />
<localization prog-version= "1.26.17">
<language langid="ru" name="Русский" en-name="Russian" version="1.26.17" translators="Dmitry Yerokhin [erodim@mail.ru] (240826)" />
<font lang="ru" class="normal" size="11" face="default" />
<font lang="ru" class="bold" size="13" face="Arial" />
<font lang="ru" class="fixed" size="12" face="Lucida Console" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="sk" name="Slovenčina" en-name="Slovak" version="0.1.0" translators="Kamil David" />
<font lang="sk" class="normal" size="11" face="default" />
<font lang="sk" class="bold" size="13" face="Arial" />

File diff suppressed because it is too large Load Diff

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="sv" name="Svenska" en-name="Swedish" version="1.0.0" translators="Peter Runesson" />
<font lang="sv" class="normal" size="11" face="default" />
<font lang="sv" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="th" name="ภาษาไทย" en-name="Thai" version="0.0.0" translators=""/>
<font lang="th" class="normal" size="11" face="default" />
<font lang="th" class="bold" size="13" face="Arial" />

View File

@ -1,7 +1,7 @@
<?xml version='1.0' encoding='UTF-8' standalone='no'?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<language langid="tr" name="Türkçe" en-name="Turkish" version="1.26.15" translators="FabSec; By Fabriel, Ali İskender Turan, Zeynel Abidin Öztürk, Mehmet Keçeci, Kaya Zeren" />
<localization prog-version= "1.26.17">
<language langid="tr" name="Türkçe" en-name="Turkish" version="1.26.17" translators="FabSec; By Fabriel, Ali İskender Turan, Zeynel Abidin Öztürk, Mehmet Keçeci, Kaya Zeren" />
<font lang="tr" class="normal" size="11" face="default" />
<font lang="tr" class="bold" size="13" face="Arial" />
<font lang="tr" class="fixed" size="12" face="Lucida Console" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="uk" name="Українська" en-name="Ukrainian" version="1.1.0" translators="Kravchuk Olexandr, Babchuk Volodymyr" />
<font lang="uk" class="normal" size="11" face="default" />
<font lang="uk" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="uz" name="Ўзбекча" en-name="Uzbek (Cyrillic)" version="0.1.0" translators="Abdurauf Azizov, Dmitry Yerokhin" />
<font lang="uz" class="normal" size="11" face="default" />
<font lang="uz" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="vi" name="Tiếng Việt" en-name="Vietnamese" version="0.1.0" translators="Nguyễn Kim Huy" />
<font lang="vi" class="normal" size="11" face="default" />
<font lang="vi" class="bold" size="13" face="Arial" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="zh-cn" name="简体中文" en-name="Chinese (Simplified)" version="1.0.3" translators="Barney Li, Zhangjintao, Nkh0472, 风之暇想" />
<font lang="zh-cn" class="normal" size="12" face="Microsoft YaHei" />
<font lang="zh-cn" class="bold" size="14" face="Microsoft YaHei" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="zh-hk" name="繁體中文(香港)" en-name="Chinese (Hong Kong)" version="0.1.0" translators="PUN Chi Ho, Yeung Tim Ming" />
<font lang="zh-hk" class="normal" size="12" face="Microsoft JhengHei UI" />
<font lang="zh-hk" class="bold" size="13" face="Microsoft JhengHei UI Bold" />

View File

@ -1,6 +1,6 @@
<?xml version="1.0" encoding="utf-8"?>
<VeraCrypt>
<localization prog-version= "1.26.15">
<localization prog-version= "1.26.17">
<language langid="zh-tw" name="繁體中文" en-name="Chinese (Taiwan)" version="0.1.0" translators="Barney Li, Simon Ma, ChangMing Hsu" />
<font lang="zh-tw" class="normal" size="12" face="MingLiU" />
<font lang="zh-tw" class="bold" size="15" face="MingLiU" />

Binary file not shown.

View File

@ -40,6 +40,37 @@ <h1>Release Notes</h1>
<span style="color:#ff0000;">To avoid hinting whether your volumes contain a hidden volume or not, or if you depend on plausible deniability when using hidden volumes/OS, then you must recreate both the outer and hidden volumes including system encryption and hidden OS, discarding existing volumes created prior to 1.18a version of VeraCrypt.</span></li>
</p>
<p><strong style="text-align:left">1.26.17</strong> (November 19<sup>th</sup>, 2024):</p>
<ul>
<li><strong>All OSes:</strong>
<ul>
<li>Added support for SHA-256 x86 intrinsic to enhance the performance of PBKDF2-HMAC-SHA256.</li>
<li>Updated translations</li>
</ul>
</li>
<li><strong>Windows:</strong>
<ul>
<li>Dropped support for Windows 32-bit.</li>
<li>Set Windows 10 May 2020 Update (version 2004) as the minimum supported version.</li>
<li>Fixed driver deadlock under low-memory scenarios caused by re-entrant IRP completions.</li>
<li>Fixed failed EFI detection on some PCs where the BootOrder variable is not defined (proposed by @kriegste, GH #360).</li>
<li>Fixed various issues affecting the EFI system encryption configuration editor.</li>
<li>Replaced the deprecated CryptGenRandom with BCryptGenRandom for generating secure random bytes.</li>
</ul>
</li>
<li><strong>Linux:</strong>
<ul>
<li>Fixed an assertion issue with the wxWidgets library included in Ubuntu.</li>
<li>Improved directory-opening logic by prioritizing xdg-open and adding fallback mechanisms.</li>
</ul>
</li>
<li><strong>macOS:</strong>
<ul>
<li>Disabled screen capture by default. Added the --allow-screencapture CLI switch to enable it if needed.</li>
</ul>
</li>
</ul>
<p><strong style="text-align:left">1.26.15</strong> (September 2<sup>nd</sup>, 2024):</p>
<ul>
<li><strong>Windows:</strong>

View File

@ -43,7 +43,38 @@ <h1>История версий</h1>
VeraCrypt старее, чем 1.18a.</span></li>
</p>
<p><strong style="text-align:left">1.26.15</strong> (2 сентября 2024 года):</p>
<p><strong style="text-align:left">1.26.17</strong> (19 ноября 2024 года):</p>
<ul>
<li><strong>Все ОС:</strong>
<ul>
<li>Добавлена поддержка SHA-256 x86 intrinsic для повышения производительности PBKDF2-HMAC-SHA256.</li>
<li>Обновлены переводы.</li>
</ul>
</li>
<li><strong>Windows:</strong>
<ul>
<li>Прекращена поддержка 32-битных версий Windows.</li>
<li>Установлено, что минимально поддерживаемая версия Windows — Windows 10 May 2020 Update (версия 2004).</li>
<li>Исправлена блокировка драйвера при низком уровне памяти, вызванная повторяющимися завершениями IRP.</li>
<li>Исправлено определение EFI на некоторых ПК, где переменная BootOrder не определена (предложено @kriegste, GH #360).</li>
<li>Исправлены различные проблемы, связанные с редактором конфигурации шифрования EFI системы.</li>
<li>Заменён устаревший CryptGenRandom на BCryptGenRandom для генерации безопасных случайных данных.</li>
</ul>
</li>
<li><strong>Linux:</strong>
<ul>
<li>Исправлена ошибка утверждения в библиотеке wxWidgets, включённой в Ubuntu.</li>
<li>Улучшена логика открытия каталогов: теперь в первую очередь используется xdg-open с добавлением резервных механизмов.</li>
</ul>
</li>
<li><strong>macOS:</strong>
<ul>
<li>Отключён захват экрана по умолчанию. Добавлен параметр командной строки --allow-screencapture для включения этой функции при необходимости.</li>
</ul>
</li>
</ul>
<p><strong style="text-align:left">1.26.17</strong> (2 сентября 2024 года):</p>
<ul>
<li><strong>Windows:</strong>
<ul>

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

Binary file not shown.

View File

@ -1,250 +0,0 @@
<?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="9.00"
Name="Boot"
ProjectGUID="{8B7F059F-E4C7-4E11-88F5-EE8B8433072E}"
RootNamespace="Boot"
Keyword="MakeFileProj"
TargetFrameworkVersion="131072"
>
<Platforms>
<Platform
Name="Win32"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Release|Win32"
OutputDirectory="$(ConfigurationName)"
IntermediateDirectory="$(ConfigurationName)"
ConfigurationType="0"
>
<Tool
Name="VCNMakeTool"
BuildCommandLine="md Release 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1&#x0D;&#x0A;&#x0D;&#x0A;md Release_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;md Release_AES 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=AES&#x0D;&#x0A;&#x0D;&#x0A;md Release_AES_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=AES SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;md Release_Serpent 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=SERPENT&#x0D;&#x0A;&#x0D;&#x0A;md Release_Serpent_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=SERPENT SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;md Release_Twofish 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=TWOFISH&#x0D;&#x0A;&#x0D;&#x0A;md Release_Twofish_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=TWOFISH SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;md Release_Camellia 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=CAMELLIA&#x0D;&#x0A;&#x0D;&#x0A;md Release_Camellia_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=CAMELLIA SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;md Rescue 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 RESCUE_DISK=1&#x0D;&#x0A;&#x0D;&#x0A;md Rescue_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 RESCUE_DISK=1 SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;md Rescue_AES 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=AES RESCUE_DISK=1&#x0D;&#x0A;&#x0D;&#x0A;md Rescue_AES_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=AES RESCUE_DISK=1 SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;md Rescue_Serpent 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=SERPENT RESCUE_DISK=1&#x0D;&#x0A;&#x0D;&#x0A;md Rescue_Serpent_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=SERPENT RESCUE_DISK=1 SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;md Rescue_Twofish 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=TWOFISH RESCUE_DISK=1&#x0D;&#x0A;&#x0D;&#x0A;md Rescue_Twofish_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=TWOFISH RESCUE_DISK=1 SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;md Rescue_Camellia 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=CAMELLIA RESCUE_DISK=1&#x0D;&#x0A;&#x0D;&#x0A;md Rescue_Camellia_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=CAMELLIA RESCUE_DISK=1 SINGLE_PRF=SHA2"
ReBuildCommandLine="del /q /s Release &gt;NUL:&#x0D;&#x0A;md Release 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Release_SHA2 &gt;NUL:&#x0D;&#x0A;md Release_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Release_AES &gt;NUL:&#x0D;&#x0A;md Release_AES 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=AES&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Release_AES_SHA2 &gt;NUL:&#x0D;&#x0A;md Release_AES_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=AES SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Release_Serpent &gt;NUL:&#x0D;&#x0A;md Release_Serpent 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=SERPENT&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Release_Serpent_SHA2 &gt;NUL:&#x0D;&#x0A;md Release_Serpent_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=SERPENT SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Release_Twofish &gt;NUL:&#x0D;&#x0A;md Release_Twofish 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=TWOFISH&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Release_Twofish_SHA2 &gt;NUL:&#x0D;&#x0A;md Release_Twofish_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=TWOFISH SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Release_Camellia &gt;NUL:&#x0D;&#x0A;md Release_Camellia 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=CAMELLIA&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Release_Camellia_SHA2 &gt;NUL:&#x0D;&#x0A;md Release_Camellia_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=CAMELLIA SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Rescue &gt;NUL:&#x0D;&#x0A;md Rescue 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 RESCUE_DISK=1&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Rescue_SHA2 &gt;NUL:&#x0D;&#x0A;md Rescue_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 RESCUE_DISK=1 SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Rescue_AES &gt;NUL:&#x0D;&#x0A;md Rescue_AES 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=AES RESCUE_DISK=1&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Rescue_AES_SHA2 &gt;NUL:&#x0D;&#x0A;md Rescue_AES_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=AES RESCUE_DISK=1 SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Rescue_Serpent &gt;NUL:&#x0D;&#x0A;md Rescue_Serpent 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=SERPENT RESCUE_DISK=1&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Rescue_Serpent_SHA2 &gt;NUL:&#x0D;&#x0A;md Rescue_Serpent_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=SERPENT RESCUE_DISK=1 SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Rescue_Twofish &gt;NUL:&#x0D;&#x0A;md Rescue_Twofish 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=TWOFISH RESCUE_DISK=1&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Rescue_Twofish_SHA2 &gt;NUL:&#x0D;&#x0A;md Rescue_Twofish_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=TWOFISH RESCUE_DISK=1 SINGLE_PRF=SHA2&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Rescue_Camellia &gt;NUL:&#x0D;&#x0A;md Rescue_Camellia 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=CAMELLIA RESCUE_DISK=1&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Rescue_Camellia_SHA2 &gt;NUL:&#x0D;&#x0A;md Rescue_Camellia_SHA2 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=CAMELLIA RESCUE_DISK=1 SINGLE_PRF=SHA2"
CleanCommandLine="del /q /s Release Release_AES Release_Serpent Release_Twofish Release_Camellia Rescue Rescue_AES Rescue_Serpent Rescue_Twofish Rescue_Camellia &gt;NUL:&#x0D;&#x0A;del /q /s Release_SHA2 Release_AES_SHA2 Release_Serpent_SHA2 Release_Twofish_SHA2 Release_Camellia_SHA2 Rescue_SHA2 Rescue_AES_SHA2 Rescue_Serpent_SHA2 Rescue_Twofish_SHA2 Rescue_Camellia_SHA2 &gt;NUL:&#x0D;&#x0A;"
Output="Release\BootLoader.com"
PreprocessorDefinitions="WIN32;NDEBUG"
IncludeSearchPath="&quot;$(SolutionDir)&quot;;&quot;$(SolutionDir)\Common&quot;;&quot;$(SolutionDir)\Crypto&quot;;&quot;$(MSVC16_ROOT)\Include&quot;"
ForcedIncludes=""
AssemblySearchPath=""
ForcedUsingAssemblies=""
CompileAsManaged=""
/>
</Configuration>
<Configuration
Name="Release Loader|Win32"
OutputDirectory="$(ConfigurationName)"
IntermediateDirectory="$(ConfigurationName)"
ConfigurationType="0"
>
<Tool
Name="VCNMakeTool"
BuildCommandLine="md Release 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1&#x0D;&#x0A;&#x0D;&#x0A;md Release_AES 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=AES&#x0D;&#x0A;&#x0D;&#x0A;md Release_Serpent 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=SERPENT&#x0D;&#x0A;&#x0D;&#x0A;md Release_Twofish 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=TWOFISH"
ReBuildCommandLine="del /q /s Release &gt;NUL:&#x0D;&#x0A;md Release 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Release_AES &gt;NUL:&#x0D;&#x0A;md Release_AES 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=AES&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Release_Serpent &gt;NUL:&#x0D;&#x0A;md Release_Serpent 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=SERPENT&#x0D;&#x0A;&#x0D;&#x0A;del /q /s Release_Twofish &gt;NUL:&#x0D;&#x0A;md Release_Twofish 2&gt;NUL:&#x0D;&#x0A;nmake.exe /nologo RELEASE=1 SINGLE_CIPHER=TWOFISH"
CleanCommandLine="del /q /s Release Release_AES Release_Serpent Release_Twofish &gt;NUL:"
Output="Release\BootLoader.com"
PreprocessorDefinitions="WIN32;NDEBUG"
IncludeSearchPath="&quot;$(SolutionDir)&quot;;&quot;$(SolutionDir)\Common&quot;;&quot;$(SolutionDir)\Crypto&quot;;&quot;$(MSVC16_ROOT)\Include&quot;"
ForcedIncludes=""
AssemblySearchPath=""
ForcedUsingAssemblies=""
CompileAsManaged=""
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Source Files"
Filter="cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx"
UniqueIdentifier="{4FC737F1-C7A5-4376-A066-2A32D752A2FF}"
>
<File
RelativePath=".\BootConfig.cpp"
>
</File>
<File
RelativePath=".\BootConsoleIo.cpp"
>
</File>
<File
RelativePath=".\BootCrt.asm"
>
</File>
<File
RelativePath=".\BootDebug.cpp"
>
</File>
<File
RelativePath=".\BootDiskIo.cpp"
>
</File>
<File
RelativePath=".\BootEncryptedIo.cpp"
>
</File>
<File
RelativePath=".\BootMain.cpp"
>
</File>
<File
RelativePath=".\BootMemory.cpp"
>
</File>
<File
RelativePath=".\BootSector.asm"
>
</File>
<File
RelativePath=".\Decompressor.c"
>
</File>
<File
RelativePath=".\IntFilter.cpp"
>
</File>
<File
RelativePath=".\Platform.cpp"
>
</File>
<Filter
Name="Common"
>
<File
RelativePath="..\..\Common\Crc.c"
>
</File>
<File
RelativePath="..\..\Common\Crypto.c"
>
</File>
<File
RelativePath="..\..\Common\Endian.c"
>
</File>
<File
RelativePath="..\..\Common\Pkcs5.c"
>
</File>
<File
RelativePath="..\..\Common\Volumes.c"
>
</File>
<File
RelativePath="..\..\Common\Xts.c"
>
</File>
</Filter>
<Filter
Name="Crypto"
>
<File
RelativePath="..\..\Crypto\Aes_hw_cpu.asm"
>
</File>
<File
RelativePath="..\..\Crypto\AesSmall.c"
>
</File>
<File
RelativePath="..\..\Crypto\AesSmall_x86.asm"
>
</File>
<File
RelativePath="..\..\Crypto\CamelliaSmall.c"
>
</File>
<File
RelativePath="..\..\Crypto\Rmd160.c"
>
</File>
<File
RelativePath="..\..\Crypto\Serpent.c"
>
</File>
<File
RelativePath="..\..\Crypto\Sha2Small.c"
>
</File>
<File
RelativePath="..\..\Crypto\Twofish.c"
>
</File>
</Filter>
</Filter>
<Filter
Name="Header Files"
Filter="h;hpp;hxx;hm;inl;inc;xsd"
UniqueIdentifier="{93995380-89BD-4b04-88EB-625FBE52EBFB}"
>
<File
RelativePath=".\Bios.h"
>
</File>
<File
RelativePath=".\BootCommon.h"
>
</File>
<File
RelativePath=".\BootConfig.h"
>
</File>
<File
RelativePath=".\BootConsoleIo.h"
>
</File>
<File
RelativePath=".\BootDebug.h"
>
</File>
<File
RelativePath=".\BootDefs.h"
>
</File>
<File
RelativePath=".\BootDiskIo.h"
>
</File>
<File
RelativePath=".\BootEncryptedIo.h"
>
</File>
<File
RelativePath=".\BootMain.h"
>
</File>
<File
RelativePath=".\BootMemory.h"
>
</File>
<File
RelativePath=".\BootStrings.h"
>
</File>
<File
RelativePath=".\IntFilter.h"
>
</File>
<File
RelativePath=".\Platform.h"
>
</File>
</Filter>
<Filter
Name="Build Files"
>
<File
RelativePath=".\Makefile"
>
</File>
</Filter>
</Files>
<Globals>
</Globals>
</VisualStudioProject>

View File

@ -369,7 +369,7 @@ static bool OpenVolume (uint8 drive, Password &password, int pim, CRYPTO_INFO **
if (ReadSectors (SectorBuffer, drive, headerSec, 1) != BiosResultSuccess)
continue;
if (ReadVolumeHeader (!hiddenVolume, (char *) SectorBuffer, &password, pim, cryptoInfo, nullptr) == ERR_SUCCESS)
if (ReadVolumeHeader (!hiddenVolume, SectorBuffer, &password, pim, cryptoInfo, nullptr) == ERR_SUCCESS)
{
// Prevent opening a non-system hidden volume
if (hiddenVolume && !((*cryptoInfo)->HeaderFlags & TC_HEADER_FLAG_ENCRYPTED_SYSTEM))
@ -917,7 +917,7 @@ static void DecryptDrive (uint8 drive)
CRYPTO_INFO *headerCryptoInfo = crypto_open();
while (ReadSectors (SectorBuffer, drive, headerSector, 1) != BiosResultSuccess);
if (ReadVolumeHeader (TRUE, (char *) SectorBuffer, &bootArguments->BootPassword, (int) (bootArguments->Flags >> 16), NULL, headerCryptoInfo) == 0)
if (ReadVolumeHeader (TRUE, SectorBuffer, &bootArguments->BootPassword, (int) (bootArguments->Flags >> 16), NULL, headerCryptoInfo) == 0)
{
DecryptBuffer (SectorBuffer + HEADER_ENCRYPTED_DATA_OFFSET, HEADER_ENCRYPTED_DATA_SIZE, headerCryptoInfo);
@ -1094,7 +1094,7 @@ static void RepairMenu ()
AcquireSectorBuffer();
CopyMemory (TC_BOOT_LOADER_BUFFER_SEGMENT, 0, SectorBuffer, TC_LB_SIZE);
if (ReadVolumeHeader (TRUE, (char *) SectorBuffer, &password, pim, &cryptoInfo, nullptr) == 0)
if (ReadVolumeHeader (TRUE, SectorBuffer, &password, pim, &cryptoInfo, nullptr) == 0)
{
if (validHeaderPresent)
{

View File

@ -11,8 +11,8 @@ elseif ( NOT DEFINED NOGUI )
endif()
# - Set version of the package
set( FULL_VERSION "1.26.15" )
set( VERSION "1.26.15" )
set( FULL_VERSION "1.26.17" )
set( VERSION "1.26.17" )
set( RELEASE "1" )
# - Set PROJECT_NAME and CONFLICT_PACKAGE values

View File

@ -14,7 +14,7 @@ $(NAME): $(NAME).a
clean:
@echo Cleaning $(NAME)
rm -f $(APPNAME) $(NAME).a $(OBJS) $(OBJSEX) $(OBJSNOOPT) $(OBJSSSE41) $(OBJSSSSE3) $(OBJS:.o=.d) $(OBJSEX:.oo=.d) $(OBJSNOOPT:.o0=.d) $(OBJSSSE41:.osse41=.d) $(OBJSSSSE3:.ossse3=.d) *.gch
rm -f $(APPNAME) $(NAME).a $(OBJS) $(OBJSEX) $(OBJSNOOPT) $(OBJSHANI) $(OBJSSSE41) $(OBJSSSSE3) $(OBJS:.o=.d) $(OBJSEX:.oo=.d) $(OBJSNOOPT:.o0=.d) $(OBJSHANI:.oshani=.d) $(OBJSSSE41:.osse41=.d) $(OBJSSSSE3:.ossse3=.d) *.gch
%.o: %.c
@echo Compiling $(<F)
@ -27,6 +27,10 @@ clean:
%.osse41: %.c
@echo Compiling $(<F)
$(CC) $(CFLAGS) -mssse3 -msse4.1 -c $< -o $@
%.oshani: %.c
@echo Compiling $(<F)
$(CC) $(CFLAGS) -mssse3 -msse4.1 -msha -c $< -o $@
%.ossse3: %.c
@echo Compiling $(<F)
@ -39,6 +43,10 @@ clean:
%.osse41: %.cpp
@echo Compiling $(<F)
$(CXX) $(CXXFLAGS) -mssse3 -msse4.1 -c $< -o $@
%.oshani: %.cpp
@echo Compiling $(<F)
$(CXX) $(CXXFLAGS) -mssse3 -msse4.1 -msha -c $< -o $@
%.ossse3: %.cpp
@echo Compiling $(<F)
@ -88,10 +96,10 @@ TR_SED_BIN := tr '\n' ' ' | tr -s ' ' ',' | sed -e 's/^,//g' -e 's/,$$/n/' | tr
# Dependencies
-include $(OBJS:.o=.d) $(OBJSEX:.oo=.d) $(OBJSNOOPT:.o0=.d) $(OBJSSSE41:.osse41=.d) $(OBJSSSSE3:.ossse3=.d)
-include $(OBJS:.o=.d) $(OBJSEX:.oo=.d) $(OBJSNOOPT:.o0=.d) $(OBJSHANI:.oshani=.d) $(OBJSSSE41:.osse41=.d) $(OBJSSSSE3:.ossse3=.d)
$(NAME).a: $(OBJS) $(OBJSEX) $(OBJSNOOPT) $(OBJSSSE41) $(OBJSSSSE3)
$(NAME).a: $(OBJS) $(OBJSEX) $(OBJSNOOPT) $(OBJSHANI) $(OBJSSSE41) $(OBJSSSSE3)
@echo Updating library $@
$(AR) $(AFLAGS) -rcu $@ $(OBJS) $(OBJSEX) $(OBJSNOOPT) $(OBJSSSE41) $(OBJSSSSE3)
$(AR) $(AFLAGS) -rcu $@ $(OBJS) $(OBJSEX) $(OBJSNOOPT) $(OBJSHANI) $(OBJSSSE41) $(OBJSSSSE3)
$(RANLIB) $@

View File

@ -27,8 +27,8 @@ LANGUAGE LANG_ENGLISH, SUBLANG_ENGLISH_US
//
VS_VERSION_INFO VERSIONINFO
FILEVERSION 1,26,15,0
PRODUCTVERSION 1,26,15,0
FILEVERSION 1,26,17,0
PRODUCTVERSION 1,26,17,0
FILEFLAGSMASK 0x17L
#ifdef _DEBUG
FILEFLAGS 0x1L
@ -45,11 +45,11 @@ BEGIN
BEGIN
VALUE "CompanyName", "IDRIX"
VALUE "FileDescription", "VeraCrypt COMReg"
VALUE "FileVersion", "1.26.15"
VALUE "FileVersion", "1.26.17"
VALUE "LegalTrademarks", "VeraCrypt"
VALUE "OriginalFilename", "VeraCrypt COMReg.exe"
VALUE "ProductName", "VeraCrypt"
VALUE "ProductVersion", "1.26.15"
VALUE "ProductVersion", "1.26.17"
END
END
BLOCK "VarFileInfo"

View File

@ -14,18 +14,22 @@
<ProjectGuid>{C8914211-32AC-4F48-ACD9-8212E8DE53F3}</ProjectGuid>
<Keyword>Win32Proj</Keyword>
<RootNamespace>COMReg</RootNamespace>
<ProjectName>COMReg</ProjectName>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v143</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v143</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
@ -40,14 +44,14 @@
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<LinkIncremental>true</LinkIncremental>
<TargetName>VeraCryptCOMRegBase</TargetName>
<OutDir>Debug\</OutDir>
<IntDir>Debug\</IntDir>
<OutDir>$(ProjectDir)$(Configuration)\</OutDir>
<IntDir>$(ProjectDir)$(Configuration)\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>false</LinkIncremental>
<TargetName>VeraCryptCOMRegBase</TargetName>
<OutDir>Release\</OutDir>
<IntDir>Release\</IntDir>
<OutDir>$(ProjectDir)$(Configuration)\</OutDir>
<IntDir>$(ProjectDir)$(Configuration)\</IntDir>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
@ -77,13 +81,15 @@
<PreprocessorDefinitions>WIN32;VC_COMREG;NDEBUG;_WINDOWS;HAVE_CONFIG_H;ZIP_STATIC;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<AdditionalIncludeDirectories>..\Setup;..\Common;..\Crypto;..\;..\PKCS11;..\Common\zlib;..\Common\libzip;..\Common\lzma;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<ControlFlowGuard>Guard</ControlFlowGuard>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>false</GenerateDebugInformation>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<AdditionalDependencies>..\Common\Release\Zip.lib;..\Crypto\Release\crypto.lib;..\Common\Release\lzma.lib;%(AdditionalDependencies)</AdditionalDependencies>
<GenerateMapFile>true</GenerateMapFile>
</Link>
<PostBuildEvent>
<Command>copy Release\VeraCryptCOMRegBase.exe "..\Release\Setup Files\VeraCryptCOMRegBase.exe"</Command>
@ -108,11 +114,6 @@
<ClInclude Include="..\Common\Dlgcode.h" />
<ClInclude Include="..\Setup\SelfExtract.h" />
</ItemGroup>
<ItemGroup>
<ProjectReference Include="..\Common\Lzma.vcxproj">
<Project>{b896fe1f-6bf3-4f75-9148-f841829073d9}</Project>
</ProjectReference>
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>

View File

@ -1,120 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectGuid>{C8914211-32AC-4F48-ACD9-8212E8DE53F3}</ProjectGuid>
<Keyword>Win32Proj</Keyword>
<RootNamespace>COMReg</RootNamespace>
<ProjectName>COMReg</ProjectName>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>Application</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>true</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<LinkIncremental>true</LinkIncremental>
<TargetName>VeraCryptCOMRegBase</TargetName>
<OutDir>$(ProjectDir)$(ConfigurationName)\</OutDir>
<IntDir>$(ProjectDir)$(ConfigurationName)\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<LinkIncremental>false</LinkIncremental>
<TargetName>VeraCryptCOMRegBase</TargetName>
<OutDir>$(ProjectDir)$(ConfigurationName)\</OutDir>
<IntDir>$(ProjectDir)$(ConfigurationName)\</IntDir>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;VC_COMREG;_DEBUG;_WINDOWS;HAVE_CONFIG_H;ZIP_STATIC;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
<AdditionalIncludeDirectories>..\Setup;..\Common;..\Crypto;..\;..\PKCS11;..\Common\zlib;..\Common\libzip;..\Common\lzma;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<AdditionalDependencies>..\Common\Debug\Zip.lib;..\Crypto\Debug\crypto.lib;..\Common\Debug\lzma.lib;%(AdditionalDependencies)</AdditionalDependencies>
</Link>
<PostBuildEvent>
<Command>copy Debug\VeraCryptCOMRegBase.exe "..\Debug\Setup Files\VeraCryptCOMRegBase.exe"</Command>
</PostBuildEvent>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>NotUsing</PrecompiledHeader>
<Optimization>MaxSpeed</Optimization>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;VC_COMREG;NDEBUG;_WINDOWS;HAVE_CONFIG_H;ZIP_STATIC;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<AdditionalIncludeDirectories>..\Setup;..\Common;..\Crypto;..\;..\PKCS11;..\Common\zlib;..\Common\libzip;..\Common\lzma;%(AdditionalIncludeDirectories)</AdditionalIncludeDirectories>
<ControlFlowGuard>Guard</ControlFlowGuard>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
<AdditionalDependencies>..\Common\Release\Zip.lib;..\Crypto\Release\crypto.lib;..\Common\Release\lzma.lib;%(AdditionalDependencies)</AdditionalDependencies>
<GenerateMapFile>true</GenerateMapFile>
</Link>
<PostBuildEvent>
<Command>copy Release\VeraCryptCOMRegBase.exe "..\Release\Setup Files\VeraCryptCOMRegBase.exe"</Command>
</PostBuildEvent>
</ItemDefinitionGroup>
<ItemGroup>
<ClCompile Include="..\Common\Crc.c" />
<ClCompile Include="..\Common\Dlgcode.c">
<CompileAs Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">CompileAsCpp</CompileAs>
<CompileAs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">CompileAsCpp</CompileAs>
</ClCompile>
<ClCompile Include="..\Setup\SelfExtract.c">
<CompileAs Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">Default</CompileAs>
</ClCompile>
<ClCompile Include="COMReg.cpp" />
</ItemGroup>
<ItemGroup>
<ResourceCompile Include="COMReg.rc" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\Common\Crc.h" />
<ClInclude Include="..\Common\Dlgcode.h" />
<ClInclude Include="..\Setup\SelfExtract.h" />
</ItemGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>

View File

@ -1,49 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="Source Files">
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
</Filter>
<Filter Include="Resource Files">
<UniqueIdentifier>{67DA6AB6-F800-4c08-8B7A-83BB121AAD01}</UniqueIdentifier>
<Extensions>rc;ico;cur;bmp;dlg;rc2;rct;bin;rgs;gif;jpg;jpeg;jpe;resx;tiff;tif;png;wav;mfcribbon-ms</Extensions>
</Filter>
<Filter Include="Header Files">
<UniqueIdentifier>{453a6bf1-2afd-4016-8b8f-e3821a6c8ab5}</UniqueIdentifier>
</Filter>
<Filter Include="Source Files\Common">
<UniqueIdentifier>{efcd999c-3973-4bd6-af14-0583669e6722}</UniqueIdentifier>
</Filter>
</ItemGroup>
<ItemGroup>
<ClCompile Include="COMReg.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="..\Setup\SelfExtract.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="..\Common\Dlgcode.c">
<Filter>Source Files\Common</Filter>
</ClCompile>
<ClCompile Include="..\Common\Crc.c">
<Filter>Source Files\Common</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ResourceCompile Include="COMReg.rc">
<Filter>Resource Files</Filter>
</ResourceCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\Setup\SelfExtract.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="..\Common\Dlgcode.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="..\Common\Crc.h">
<Filter>Header Files</Filter>
</ClInclude>
</ItemGroup>
</Project>

View File

@ -1,7 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<LocalDebuggerCommand>$(TargetPath)</LocalDebuggerCommand>
<DebuggerFlavor>WindowsLocalDebugger</DebuggerFlavor>
</PropertyGroup>
</Project>

View File

@ -396,6 +396,7 @@ typedef struct
int EncryptionIoRequestCount;
int EncryptionItemCount;
int EncryptionFragmentSize;
int EncryptionMaxWorkItems;
} EncryptionQueueParameters;
#pragma pack (pop)
@ -418,6 +419,7 @@ typedef struct
#define VC_ENCRYPTION_IO_REQUEST_COUNT DRIVER_STR("VeraCryptEncryptionIoRequestCount")
#define VC_ENCRYPTION_ITEM_COUNT DRIVER_STR("VeraCryptEncryptionItemCount")
#define VC_ENCRYPTION_FRAGMENT_SIZE DRIVER_STR("VeraCryptEncryptionFragmentSize")
#define VC_ENCRYPTION_MAX_WORK_ITEMS DRIVER_STR("VeraCryptEncryptionMaxWorkItems")
#define VC_ERASE_KEYS_SHUTDOWN DRIVER_STR("VeraCryptEraseKeysShutdown")

View File

@ -773,11 +773,13 @@ namespace VeraCrypt
else
{
LastError = GetLastError();
#ifndef SETUP
if (LastError == ERROR_ACCESS_DENIED && IsUacSupported())
{
Elevated = true;
FileOpen = true;
}
#endif
}
FilePointerPosition = 0;
@ -806,12 +808,14 @@ namespace VeraCrypt
throw SystemException (SRC_POS);
}
#ifndef SETUP
if (Elevated)
{
Elevator::ReadWriteFile (false, IsDevice, Path, buffer, FilePointerPosition, size, &bytesRead);
FilePointerPosition += bytesRead;
return bytesRead;
}
#endif
if (!ReadFile (Handle, buffer, size, &bytesRead, NULL))
{
@ -913,6 +917,7 @@ namespace VeraCrypt
try
{
#ifndef SETUP
if (Elevated)
{
Elevator::ReadWriteFile (true, IsDevice, Path, buffer, FilePointerPosition, size, &bytesWritten);
@ -920,6 +925,7 @@ namespace VeraCrypt
throw_sys_if (bytesWritten != size);
}
else
#endif
{
if (!WriteFile (Handle, buffer, size, &bytesWritten, NULL))
{
@ -1046,11 +1052,13 @@ namespace VeraCrypt
else
{
LastError = GetLastError ();
#ifndef SETUP
if (LastError == ERROR_ACCESS_DENIED && IsUacSupported())
{
Elevated = true;
FileOpen = true;
}
#endif
}
FilePointerPosition = 0;
@ -1141,7 +1149,7 @@ namespace VeraCrypt
// throw ParameterIncorrect (SRC_POS); // It is assumed that CheckRequirements() had been called
// Find the first active partition on the system drive
foreach (const Partition &partition, config.Partitions)
for (const Partition& partition : config.Partitions)
{
if (partition.Info.BootIndicator)
{
@ -1154,13 +1162,13 @@ namespace VeraCrypt
Partition bootPartition = partition;
Partition partitionBehindBoot;
foreach (const Partition &partition, config.Partitions)
for (const Partition &otherPartition : config.Partitions)
{
if (partition.Info.StartingOffset.QuadPart > bootPartition.Info.StartingOffset.QuadPart
&& partition.Info.StartingOffset.QuadPart < minOffsetFound)
if (otherPartition.Info.StartingOffset.QuadPart > bootPartition.Info.StartingOffset.QuadPart
&& otherPartition.Info.StartingOffset.QuadPart < minOffsetFound)
{
minOffsetFound = partition.Info.StartingOffset.QuadPart;
partitionBehindBoot = partition;
minOffsetFound = otherPartition.Info.StartingOffset.QuadPart;
partitionBehindBoot = otherPartition;
}
}
@ -1351,11 +1359,11 @@ namespace VeraCrypt
part.IsGPT = diskPartInfo.IsGPT;
// Mount point
int driveNumber = GetDiskDeviceDriveLetter ((wchar_t *) partPath.str().c_str());
int driveLetter = GetDiskDeviceDriveLetter ((wchar_t *) partPath.str().c_str());
if (driveNumber >= 0)
if (driveLetter >= 0)
{
part.MountPoint += (wchar_t) (driveNumber + L'A');
part.MountPoint += (wchar_t) (driveLetter + L'A');
part.MountPoint += L":";
}
@ -2441,7 +2449,8 @@ namespace VeraCrypt
if (!fieldValue.empty() && strlen (fieldValue.c_str()))
{
string copieValue = fieldValue;
std::transform(copieValue.begin(), copieValue.end(), copieValue.begin(), ::tolower);
std::transform(copieValue.begin(), copieValue.end(), copieValue.begin(),
[](unsigned char c) { return static_cast<char>(std::tolower(c)); });
if (strstr (copieValue.c_str(), "postexec") && strstr (copieValue.c_str(), "file("))
{
@ -3323,53 +3332,29 @@ namespace VeraCrypt
}
}
DWORD sizeDcsBoot;
#ifdef _WIN64
uint8 *dcsBootImg = MapResource(L"BIN", IDR_EFI_DCSBOOT, &sizeDcsBoot);
#else
uint8 *dcsBootImg = MapResource(L"BIN", Is64BitOs()? IDR_EFI_DCSBOOT : IDR_EFI_DCSBOOT32, &sizeDcsBoot);
#endif
if (!dcsBootImg)
throw ErrorException(L"Out of resource DcsBoot", SRC_POS);
DWORD sizeDcsInt;
#ifdef _WIN64
uint8 *dcsIntImg = MapResource(L"BIN", IDR_EFI_DCSINT, &sizeDcsInt);
#else
uint8 *dcsIntImg = MapResource(L"BIN", Is64BitOs()? IDR_EFI_DCSINT: IDR_EFI_DCSINT32, &sizeDcsInt);
#endif
if (!dcsIntImg)
throw ErrorException(L"Out of resource DcsInt", SRC_POS);
DWORD sizeDcsCfg;
#ifdef _WIN64
uint8 *dcsCfgImg = MapResource(L"BIN", IDR_EFI_DCSCFG, &sizeDcsCfg);
#else
uint8 *dcsCfgImg = MapResource(L"BIN", Is64BitOs()? IDR_EFI_DCSCFG: IDR_EFI_DCSCFG32, &sizeDcsCfg);
#endif
if (!dcsCfgImg)
throw ErrorException(L"Out of resource DcsCfg", SRC_POS);
DWORD sizeLegacySpeaker;
#ifdef _WIN64
uint8 *LegacySpeakerImg = MapResource(L"BIN", IDR_EFI_LEGACYSPEAKER, &sizeLegacySpeaker);
#else
uint8 *LegacySpeakerImg = MapResource(L"BIN", Is64BitOs()? IDR_EFI_LEGACYSPEAKER: IDR_EFI_LEGACYSPEAKER32, &sizeLegacySpeaker);
#endif
if (!LegacySpeakerImg)
throw ErrorException(L"Out of resource LegacySpeaker", SRC_POS);
#ifdef VC_EFI_CUSTOM_MODE
DWORD sizeBootMenuLocker;
#ifdef _WIN64
uint8 *BootMenuLockerImg = MapResource(L"BIN", IDR_EFI_DCSBML, &sizeBootMenuLocker);
#else
uint8 *BootMenuLockerImg = MapResource(L"BIN", Is64BitOs()? IDR_EFI_DCSBML: IDR_EFI_DCSBML32, &sizeBootMenuLocker);
#endif
if (!BootMenuLockerImg)
throw ErrorException(L"Out of resource DcsBml", SRC_POS);
#endif
DWORD sizeDcsInfo;
#ifdef _WIN64
uint8 *DcsInfoImg = MapResource(L"BIN", IDR_EFI_DCSINFO, &sizeDcsInfo);
#else
uint8 *DcsInfoImg = MapResource(L"BIN", Is64BitOs()? IDR_EFI_DCSINFO: IDR_EFI_DCSINFO32, &sizeDcsInfo);
#endif
if (!DcsInfoImg)
throw ErrorException(L"Out of resource DcsInfo", SRC_POS);
@ -3381,8 +3366,8 @@ namespace VeraCrypt
bool bAlreadyExist;
const char* g_szMsBootString = "bootmgfw.pdb";
unsigned __int64 loaderSize = 0;
const wchar_t * szStdEfiBootloader = Is64BitOs()? L"\\EFI\\Boot\\bootx64.efi": L"\\EFI\\Boot\\bootia32.efi";
const wchar_t * szBackupEfiBootloader = Is64BitOs()? L"\\EFI\\Boot\\original_bootx64.vc_backup": L"\\EFI\\Boot\\original_bootia32.vc_backup";
const wchar_t * szStdEfiBootloader = L"\\EFI\\Boot\\bootx64.efi";
const wchar_t * szBackupEfiBootloader = L"\\EFI\\Boot\\original_bootx64.vc_backup";
if (preserveUserConfig)
{
@ -3538,10 +3523,7 @@ namespace VeraCrypt
// move the original bootloader backup from old location (if it exists) to new location
// we don't force the move operation if the new location already exists
if (Is64BitOs())
EfiBootInst.RenameFile (L"\\EFI\\Boot\\original_bootx64_vc_backup.efi", L"\\EFI\\Boot\\original_bootx64.vc_backup", FALSE);
else
EfiBootInst.RenameFile (L"\\EFI\\Boot\\original_bootia32_vc_backup.efi", L"\\EFI\\Boot\\original_bootia32.vc_backup", FALSE);
EfiBootInst.RenameFile (L"\\EFI\\Boot\\original_bootx64_vc_backup.efi", L"\\EFI\\Boot\\original_bootx64.vc_backup", FALSE);
// Clean beta9
EfiBootInst.DelFile(L"\\DcsBoot.efi");
@ -3720,61 +3702,33 @@ namespace VeraCrypt
{
// create EFI disk structure
DWORD sizeDcsBoot;
#ifdef _WIN64
uint8 *dcsBootImg = MapResource(L"BIN", IDR_EFI_DCSBOOT, &sizeDcsBoot);
#else
uint8 *dcsBootImg = MapResource(L"BIN", Is64BitOs()? IDR_EFI_DCSBOOT : IDR_EFI_DCSBOOT32, &sizeDcsBoot);
#endif
if (!dcsBootImg)
throw ParameterIncorrect (SRC_POS);
DWORD sizeDcsInt;
#ifdef _WIN64
uint8 *dcsIntImg = MapResource(L"BIN", IDR_EFI_DCSINT, &sizeDcsInt);
#else
uint8 *dcsIntImg = MapResource(L"BIN", Is64BitOs()? IDR_EFI_DCSINT: IDR_EFI_DCSINT32, &sizeDcsInt);
#endif
if (!dcsIntImg)
throw ParameterIncorrect (SRC_POS);
DWORD sizeDcsCfg;
#ifdef _WIN64
uint8 *dcsCfgImg = MapResource(L"BIN", IDR_EFI_DCSCFG, &sizeDcsCfg);
#else
uint8 *dcsCfgImg = MapResource(L"BIN", Is64BitOs()? IDR_EFI_DCSCFG: IDR_EFI_DCSCFG32, &sizeDcsCfg);
#endif
if (!dcsCfgImg)
throw ParameterIncorrect (SRC_POS);
DWORD sizeLegacySpeaker;
#ifdef _WIN64
uint8 *LegacySpeakerImg = MapResource(L"BIN", IDR_EFI_LEGACYSPEAKER, &sizeLegacySpeaker);
#else
uint8 *LegacySpeakerImg = MapResource(L"BIN", Is64BitOs()? IDR_EFI_LEGACYSPEAKER: IDR_EFI_LEGACYSPEAKER32, &sizeLegacySpeaker);
#endif
if (!LegacySpeakerImg)
throw ParameterIncorrect (SRC_POS);
#ifdef VC_EFI_CUSTOM_MODE
DWORD sizeBootMenuLocker;
#ifdef _WIN64
uint8 *BootMenuLockerImg = MapResource(L"BIN", IDR_EFI_DCSBML, &sizeBootMenuLocker);
#else
uint8 *BootMenuLockerImg = MapResource(L"BIN", Is64BitOs()? IDR_EFI_DCSBML: IDR_EFI_DCSBML32, &sizeBootMenuLocker);
#endif
if (!BootMenuLockerImg)
throw ParameterIncorrect (SRC_POS);
#endif
DWORD sizeDcsRescue;
#ifdef _WIN64
uint8 *DcsRescueImg = MapResource(L"BIN", IDR_EFI_DCSRE, &sizeDcsRescue);
#else
uint8 *DcsRescueImg = MapResource(L"BIN", Is64BitOs()? IDR_EFI_DCSRE: IDR_EFI_DCSRE32, &sizeDcsRescue);
#endif
if (!DcsRescueImg)
throw ParameterIncorrect (SRC_POS);
DWORD sizeDcsInfo;
#ifdef _WIN64
uint8 *DcsInfoImg = MapResource(L"BIN", IDR_EFI_DCSINFO, &sizeDcsInfo);
#else
uint8 *DcsInfoImg = MapResource(L"BIN", Is64BitOs()? IDR_EFI_DCSINFO: IDR_EFI_DCSINFO32, &sizeDcsInfo);
#endif
if (!DcsInfoImg)
throw ParameterIncorrect (SRC_POS);
@ -3800,7 +3754,7 @@ namespace VeraCrypt
finally_do_arg (zip_t**, &z, { if (*finally_arg) zip_discard (*finally_arg);});
if (!ZipAdd (z, Is64BitOs()? "EFI/Boot/bootx64.efi": "EFI/Boot/bootia32.efi", DcsRescueImg, sizeDcsRescue))
if (!ZipAdd (z, "EFI/Boot/bootx64.efi", DcsRescueImg, sizeDcsRescue))
throw ParameterIncorrect (SRC_POS);
#ifdef VC_EFI_CUSTOM_MODE
if (!ZipAdd (z, "EFI/VeraCrypt/DcsBml.dcs", BootMenuLockerImg, sizeBootMenuLocker))
@ -3849,7 +3803,7 @@ namespace VeraCrypt
sysBakFile.GetFileSize(fileSize);
fileBuf.Resize ((DWORD) fileSize);
DWORD sizeLoader = sysBakFile.Read (fileBuf.Ptr (), fileSize);
bLoadAdded = ZipAdd (z, Is64BitOs()? "EFI/Boot/original_bootx64.vc_backup": "EFI/Boot/original_bootia32.vc_backup", fileBuf.Ptr (), sizeLoader);
bLoadAdded = ZipAdd (z, "EFI/Boot/original_bootx64.vc_backup", fileBuf.Ptr (), sizeLoader);
}
catch (Exception &e)
{
@ -4076,19 +4030,6 @@ namespace VeraCrypt
L"EFI/VeraCrypt/svh_bak",
L"EFI/Boot/original_bootx64.vc_backup"
};
const wchar_t* efi32Files[] = {
L"EFI/Boot/bootia32.efi",
#ifdef VC_EFI_CUSTOM_MODE
L"EFI/VeraCrypt/DcsBml.dcs",
#endif
L"EFI/VeraCrypt/DcsBoot.efi",
L"EFI/VeraCrypt/DcsCfg.dcs",
L"EFI/VeraCrypt/DcsInt.dcs",
L"EFI/VeraCrypt/LegacySpeaker.dcs",
L"EFI/VeraCrypt/svh_bak",
L"EFI/Boot/original_bootia32.vc_backup"
};
zip_error_t zerr;
zip_source_t* zsrc = zip_source_buffer_create (RescueZipData, RescueZipSize, 0, &zerr);
@ -4117,8 +4058,8 @@ namespace VeraCrypt
&& !wcsncmp (szNameBuffer, L"FAT", 3))
{
int i;
const wchar_t** efiFiles = Is64BitOs()? efi64Files: efi32Files;
int efiFilesSize = Is64BitOs()? ARRAYSIZE(efi64Files): ARRAYSIZE(efi32Files);
const wchar_t** efiFiles = efi64Files;
int efiFilesSize = ARRAYSIZE(efi64Files);
for (i = 0; i < efiFilesSize; i++)
{
bool bMatch = false;
@ -4271,25 +4212,12 @@ namespace VeraCrypt
L"EFI/VeraCrypt/svh_bak",
L"EFI/Boot/original_bootx64.vc_backup"
};
const wchar_t* efi32Files[] = {
L"EFI/Boot/bootia32.efi",
#ifdef VC_EFI_CUSTOM_MODE
L"EFI/VeraCrypt/DcsBml.dcs",
#endif
L"EFI/VeraCrypt/DcsBoot.efi",
L"EFI/VeraCrypt/DcsCfg.dcs",
L"EFI/VeraCrypt/DcsInt.dcs",
L"EFI/VeraCrypt/LegacySpeaker.dcs",
L"EFI/VeraCrypt/svh_bak",
L"EFI/Boot/original_bootia32.vc_backup"
};
int i;
zip_stat_t statMem, statFile;
zip_int64_t indexMem, indexFile;
const wchar_t** efiFiles = Is64BitOs()? efi64Files: efi32Files;
int efiFilesSize = Is64BitOs()? ARRAYSIZE(efi64Files): ARRAYSIZE(efi32Files);
const wchar_t** efiFiles = efi64Files;
int efiFilesSize = ARRAYSIZE(efi64Files);
for (i = 0; i < efiFilesSize; i++)
{
bool bMatch = false;
@ -4382,14 +4310,14 @@ namespace VeraCrypt
if (!IsRandomNumberGeneratorStarted())
throw ParameterIncorrect (SRC_POS);
throw_sys_if (CreateVolumeHeaderInMemory (ParentWindow, TRUE, (char *) VolumeHeader, ea, mode, password, pkcs5, pim, NULL, &cryptoInfo,
throw_sys_if (CreateVolumeHeaderInMemory (ParentWindow, TRUE, VolumeHeader, ea, mode, password, pkcs5, pim, NULL, &cryptoInfo,
volumeSize, 0, encryptedAreaStart, 0, TC_SYSENC_KEYSCOPE_MIN_REQ_PROG_VERSION, TC_HEADER_FLAG_ENCRYPTED_SYSTEM, TC_SECTOR_SIZE_BIOS, FALSE) != 0);
finally_do_arg (PCRYPTO_INFO*, &cryptoInfo, { crypto_close (*finally_arg); });
// Initial rescue disk assumes encryption of the drive has been completed (EncryptedAreaLength == volumeSize)
memcpy (RescueVolumeHeader, VolumeHeader, sizeof (RescueVolumeHeader));
if (0 != ReadVolumeHeader (TRUE, (char *) RescueVolumeHeader, password, pkcs5, pim, NULL, cryptoInfo))
if (0 != ReadVolumeHeader (TRUE, RescueVolumeHeader, password, pkcs5, pim, NULL, cryptoInfo))
throw ParameterIncorrect (SRC_POS);
DecryptBuffer (RescueVolumeHeader + HEADER_ENCRYPTED_DATA_OFFSET, HEADER_ENCRYPTED_DATA_SIZE, cryptoInfo);
@ -4564,10 +4492,7 @@ namespace VeraCrypt
EfiBootInst.DeleteStartExec();
EfiBootInst.DeleteStartExec(0xDC5B, L"Driver"); // remove DcsBml boot driver it was installed
if (Is64BitOs())
EfiBootInst.RenameFile(L"\\EFI\\Boot\\original_bootx64.vc_backup", L"\\EFI\\Boot\\bootx64.efi", TRUE);
else
EfiBootInst.RenameFile(L"\\EFI\\Boot\\original_bootia32.vc_backup", L"\\EFI\\Boot\\bootia32.efi", TRUE);
EfiBootInst.RenameFile(L"\\EFI\\Boot\\original_bootx64.vc_backup", L"\\EFI\\Boot\\bootx64.efi", TRUE);
if (!EfiBootInst.RenameFile(L"\\EFI\\Microsoft\\Boot\\bootmgfw_ms.vc", L"\\EFI\\Microsoft\\Boot\\bootmgfw.efi", TRUE))
{
@ -5391,7 +5316,7 @@ namespace VeraCrypt
SystemDriveConfiguration config = GetSystemDriveConfiguration ();
char header[TC_BOOT_ENCRYPTION_VOLUME_HEADER_SIZE];
unsigned char header[TC_BOOT_ENCRYPTION_VOLUME_HEADER_SIZE];
Device device (config.DevicePath);
device.CheckOpened (SRC_POS);
@ -5421,7 +5346,7 @@ namespace VeraCrypt
}
device.SeekAt (headerOffset);
device.Read ((uint8 *) header, sizeof (header));
device.Read (header, sizeof (header));
PCRYPTO_INFO cryptoInfo = NULL;

View File

@ -24,8 +24,6 @@ int CachedPim[CACHE_SIZE];
int cacheEmpty = 1;
static int nPasswordIdx = 0;
#ifdef _WIN64
uint64 VcGetPasswordEncryptionID (Password* pPassword)
{
return ((uint64) pPassword->Text) + ((uint64) pPassword);
@ -41,9 +39,7 @@ void VcUnprotectPassword (Password* pPassword, uint64 encID)
VcProtectPassword (pPassword, encID);
}
#endif
int ReadVolumeHeaderWCache (BOOL bBoot, BOOL bCache, BOOL bCachePim, char *header, Password *password, int pkcs5_prf, int pim, PCRYPTO_INFO *retInfo)
int ReadVolumeHeaderWCache (BOOL bBoot, BOOL bCache, BOOL bCachePim, unsigned char *header, Password *password, int pkcs5_prf, int pim, PCRYPTO_INFO *retInfo)
{
int nReturnCode = ERR_PASSWORD_WRONG;
int i, effectivePim;
@ -56,37 +52,29 @@ int ReadVolumeHeaderWCache (BOOL bBoot, BOOL bCache, BOOL bCachePim, char *heade
/* Save mount passwords back into cache if asked to do so */
if (bCache && (nReturnCode == 0 || nReturnCode == ERR_CIPHER_INIT_WEAK_KEY))
{
#ifdef _WIN64
Password tmpPass;
#endif
for (i = 0; i < CACHE_SIZE; i++)
{
Password* pCurrentPassword = &CachedPasswords[i];
#ifdef _WIN64
if (IsRamEncryptionEnabled())
{
memcpy (&tmpPass, pCurrentPassword, sizeof (Password));
VcUnprotectPassword (&tmpPass, VcGetPasswordEncryptionID (pCurrentPassword));
pCurrentPassword = &tmpPass;
}
#endif
if (memcmp (pCurrentPassword, password, sizeof (Password)) == 0)
break;
}
#ifdef _WIN64
if (IsRamEncryptionEnabled())
burn (&tmpPass, sizeof (Password));
#endif
if (i == CACHE_SIZE)
{
/* Store the password */
CachedPasswords[nPasswordIdx] = *password;
#ifdef _WIN64
if (IsRamEncryptionEnabled ())
VcProtectPassword (&CachedPasswords[nPasswordIdx], VcGetPasswordEncryptionID (&CachedPasswords[nPasswordIdx]));
#endif
/* Store also PIM if requested, otherwise set to default */
if (bCachePim && (pim > 0))
@ -107,21 +95,18 @@ int ReadVolumeHeaderWCache (BOOL bBoot, BOOL bCache, BOOL bCachePim, char *heade
}
else if (!cacheEmpty)
{
#ifdef _WIN64
Password tmpPass;
#endif
/* Attempt to recognize volume using cached passwords */
for (i = 0; i < CACHE_SIZE; i++)
{
Password* pCurrentPassword = &CachedPasswords[i];
#ifdef _WIN64
if (IsRamEncryptionEnabled())
{
memcpy (&tmpPass, pCurrentPassword, sizeof (Password));
VcUnprotectPassword (&tmpPass, VcGetPasswordEncryptionID (pCurrentPassword));
pCurrentPassword = &tmpPass;
}
#endif
if ((pCurrentPassword->Length > 0) && (pCurrentPassword->Length <= (unsigned int) ((bBoot? MAX_LEGACY_PASSWORD: MAX_PASSWORD))))
{
if (pim == -1)
@ -134,10 +119,10 @@ int ReadVolumeHeaderWCache (BOOL bBoot, BOOL bCache, BOOL bCachePim, char *heade
break;
}
}
#ifdef _WIN64
if (IsRamEncryptionEnabled())
burn (&tmpPass, sizeof (Password));
#endif
}
return nReturnCode;
@ -146,21 +131,18 @@ int ReadVolumeHeaderWCache (BOOL bBoot, BOOL bCache, BOOL bCachePim, char *heade
void AddPasswordToCache (Password *password, int pim, BOOL bCachePim)
{
#ifdef _WIN64
Password tmpPass;
#endif
int i;
for (i = 0; i < CACHE_SIZE; i++)
{
Password* pCurrentPassword = &CachedPasswords[i];
#ifdef _WIN64
if (IsRamEncryptionEnabled())
{
memcpy (&tmpPass, pCurrentPassword, sizeof (Password));
VcUnprotectPassword (&tmpPass, VcGetPasswordEncryptionID (pCurrentPassword));
pCurrentPassword = &tmpPass;
}
#endif
if (memcmp (pCurrentPassword, password, sizeof (Password)) == 0)
break;
}
@ -168,10 +150,9 @@ void AddPasswordToCache (Password *password, int pim, BOOL bCachePim)
if (i == CACHE_SIZE)
{
CachedPasswords[nPasswordIdx] = *password;
#ifdef _WIN64
if (IsRamEncryptionEnabled ())
VcProtectPassword (&CachedPasswords[nPasswordIdx], VcGetPasswordEncryptionID (&CachedPasswords[nPasswordIdx]));
#endif
/* Store also PIM if requested, otherwise set to default */
if (bCachePim && (pim > 0))
CachedPim[nPasswordIdx] = pim;
@ -184,13 +165,12 @@ void AddPasswordToCache (Password *password, int pim, BOOL bCachePim)
{
CachedPim[i] = pim > 0? pim : 0;
}
#ifdef _WIN64
if (IsRamEncryptionEnabled())
burn (&tmpPass, sizeof (Password));
#endif
}
void AddLegacyPasswordToCache (PasswordLegacy *password, int pim)
void AddLegacyPasswordToCache (__unaligned PasswordLegacy *password, int pim)
{
Password inputPass = {0};
inputPass.Length = password->Length;

View File

@ -21,6 +21,6 @@
extern int cacheEmpty;
void AddPasswordToCache (Password *password, int pim, BOOL bCachePim);
void AddLegacyPasswordToCache (PasswordLegacy *password, int pim);
int ReadVolumeHeaderWCache (BOOL bBoot, BOOL bCache, BOOL bCachePim,char *header, Password *password, int pkcs5_prf, int pim, PCRYPTO_INFO *retInfo);
void AddLegacyPasswordToCache (__unaligned PasswordLegacy *password, int pim);
int ReadVolumeHeaderWCache (BOOL bBoot, BOOL bCache, BOOL bCachePim, unsigned char *header, Password *password, int pkcs5_prf, int pim, PCRYPTO_INFO *retInfo);
void WipeCache (void);

View File

@ -51,12 +51,7 @@ BOOL CALLBACK CommandHelpDlgProc (HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM
*tmp = 0;
StringCchCopyW (tmp, 8192, L"VeraCrypt " _T(VERSION_STRING) _T(VERSION_STRING_SUFFIX));
#ifdef _WIN64
StringCchCatW (tmp, 8192, L" (64-bit)");
#else
StringCchCatW (tmp, 8192, L" (32-bit)");
#endif
StringCchCopyW (tmp, 8192, L"VeraCrypt " _T(VERSION_STRING) _T(VERSION_STRING_SUFFIX) L" (64-bit)");
#if (defined(_DEBUG) || defined(DEBUG))
StringCchCatW (tmp, 8192, L" (debug)");
#endif

View File

@ -565,17 +565,6 @@ IDR_EFI_DCSBML BIN "..\\Boot\\EFI\\DcsBml.efi"
#endif
IDR_EFI_DCSRE BIN "..\\Boot\\EFI\\DcsRe.efi"
IDR_EFI_DCSINFO BIN "..\\Boot\\EFI\\DcsInfo.efi"
#ifndef WIN64
IDR_EFI_DCSBOOT32 BIN "..\\Boot\\EFI\\DcsBoot32.efi"
IDR_EFI_DCSINT32 BIN "..\\Boot\\EFI\\DcsInt32.efi"
IDR_EFI_DCSCFG32 BIN "..\\Boot\\EFI\\DcsCfg32.efi"
IDR_EFI_LEGACYSPEAKER32 BIN "..\\Boot\\EFI\\LegacySpeaker32.efi"
#ifdef VC_EFI_CUSTOM_MODE
IDR_EFI_DCSBML32 BIN "..\\Boot\\EFI\\DcsBml32.efi"
#endif
IDR_EFI_DCSRE32 BIN "..\\Boot\\EFI\\DcsRe32.efi"
IDR_EFI_DCSINFO32 BIN "..\\Boot\\EFI\\DcsInfo32.efi"
#endif
#endif
/////////////////////////////////////////////////////////////////////////////
//

View File

@ -26,6 +26,7 @@
#else
#include <strsafe.h>
#endif
#include "Crypto/t1ha.h"
#include "EncryptionThreadPool.h"
#endif
#endif
@ -192,8 +193,7 @@ void EncipherBlock(int cipher, void *data, void *ks)
switch (cipher)
{
case AES:
// In 32-bit kernel mode, due to KeSaveFloatingPointState() overhead, AES instructions can be used only when processing the whole data unit.
#if (defined (_WIN64) || !defined (TC_WINDOWS_DRIVER)) && !defined (TC_WINDOWS_BOOT)
#if !defined (TC_WINDOWS_BOOT)
if (IsAesHwCpuSupported())
aes_hw_cpu_encrypt (ks, data);
else
@ -220,16 +220,10 @@ void EncipherBlock(int cipher, void *data, void *ks)
void EncipherBlocks (int cipher, void *dataPtr, void *ks, size_t blockCount)
{
uint8 *data = dataPtr;
#if defined (TC_WINDOWS_DRIVER) && !defined (_WIN64)
KFLOATING_SAVE floatingPointState;
#endif
if (cipher == AES
&& (blockCount & (32 - 1)) == 0
&& IsAesHwCpuSupported()
#if defined (TC_WINDOWS_DRIVER) && !defined (_WIN64)
&& NT_SUCCESS (KeSaveFloatingPointState (&floatingPointState))
#endif
)
{
while (blockCount > 0)
@ -240,24 +234,15 @@ void EncipherBlocks (int cipher, void *dataPtr, void *ks, size_t blockCount)
blockCount -= 32;
}
#if defined (TC_WINDOWS_DRIVER) && !defined (_WIN64)
KeRestoreFloatingPointState (&floatingPointState);
#endif
}
#ifndef WOLFCRYPT_BACKEND
#if CRYPTOPP_BOOL_SSE2_INTRINSICS_AVAILABLE && !defined (_UEFI)
else if (cipher == SERPENT
&& (blockCount >= 4)
&& HasSSE2()
#if defined (TC_WINDOWS_DRIVER) && !defined (_WIN64)
&& NT_SUCCESS (KeSaveFloatingPointState (&floatingPointState))
#endif
)
{
serpent_encrypt_blocks (data, data, blockCount, ks);
#if defined (TC_WINDOWS_DRIVER) && !defined (_WIN64)
KeRestoreFloatingPointState (&floatingPointState);
#endif
}
#endif
#if CRYPTOPP_BOOL_X64 && !defined(CRYPTOPP_DISABLE_ASM)
@ -271,15 +256,9 @@ void EncipherBlocks (int cipher, void *dataPtr, void *ks, size_t blockCount)
#if CRYPTOPP_BOOL_SSE2_INTRINSICS_AVAILABLE && !defined (_UEFI)
else if (cipher == KUZNYECHIK
&& HasSSE2()
#if defined (TC_WINDOWS_DRIVER) && !defined (_WIN64)
&& (blockCount >= 4) && NT_SUCCESS (KeSaveFloatingPointState (&floatingPointState))
#endif
)
{
kuznyechik_encrypt_blocks (data, data, blockCount, ks);
#if defined (TC_WINDOWS_DRIVER) && !defined (_WIN64)
KeRestoreFloatingPointState (&floatingPointState);
#endif
}
#endif
#endif
@ -315,11 +294,9 @@ void DecipherBlock(int cipher, void *data, void *ks)
#ifndef TC_WINDOWS_BOOT
case AES:
#if defined (_WIN64) || !defined (TC_WINDOWS_DRIVER)
if (IsAesHwCpuSupported())
aes_hw_cpu_decrypt ((uint8 *) ks + sizeof (aes_encrypt_ctx), data);
else
#endif
aes_decrypt (data, data, (void *) ((char *) ks + sizeof(aes_encrypt_ctx)));
break;
@ -335,16 +312,10 @@ void DecipherBlock(int cipher, void *data, void *ks)
void DecipherBlocks (int cipher, void *dataPtr, void *ks, size_t blockCount)
{
uint8 *data = dataPtr;
#if defined (TC_WINDOWS_DRIVER) && !defined (_WIN64)
KFLOATING_SAVE floatingPointState;
#endif
if (cipher == AES
&& (blockCount & (32 - 1)) == 0
&& IsAesHwCpuSupported()
#if defined (TC_WINDOWS_DRIVER) && !defined (_WIN64)
&& NT_SUCCESS (KeSaveFloatingPointState (&floatingPointState))
#endif
)
{
while (blockCount > 0)
@ -355,24 +326,15 @@ void DecipherBlocks (int cipher, void *dataPtr, void *ks, size_t blockCount)
blockCount -= 32;
}
#if defined (TC_WINDOWS_DRIVER) && !defined (_WIN64)
KeRestoreFloatingPointState (&floatingPointState);
#endif
}
#ifndef WOLFCRYPT_BACKEND
#if CRYPTOPP_BOOL_SSE2_INTRINSICS_AVAILABLE && !defined (_UEFI)
else if (cipher == SERPENT
&& (blockCount >= 4)
&& HasSSE2()
#if defined (TC_WINDOWS_DRIVER) && !defined (_WIN64)
&& NT_SUCCESS (KeSaveFloatingPointState (&floatingPointState))
#endif
)
{
serpent_decrypt_blocks (data, data, blockCount, ks);
#if defined (TC_WINDOWS_DRIVER) && !defined (_WIN64)
KeRestoreFloatingPointState (&floatingPointState);
#endif
}
#endif
#if CRYPTOPP_BOOL_X64 && !defined(CRYPTOPP_DISABLE_ASM)
@ -386,15 +348,9 @@ void DecipherBlocks (int cipher, void *dataPtr, void *ks, size_t blockCount)
#if CRYPTOPP_BOOL_SSE2_INTRINSICS_AVAILABLE && !defined (_UEFI)
else if (cipher == KUZNYECHIK
&& HasSSE2()
#if defined (TC_WINDOWS_DRIVER) && !defined (_WIN64)
&& (blockCount >= 4) && NT_SUCCESS (KeSaveFloatingPointState (&floatingPointState))
#endif
)
{
kuznyechik_decrypt_blocks (data, data, blockCount, ks);
#if defined (TC_WINDOWS_DRIVER) && !defined (_WIN64)
KeRestoreFloatingPointState (&floatingPointState);
#endif
}
#endif
#endif
@ -659,8 +615,8 @@ int EAGetNextMode (int ea, int previousModeId)
return 0;
}
// Returns the name of the mode of operation of the whole EA
wchar_t *EAGetModeName (int ea, int mode, BOOL capitalLetters)
// Returns the name of the mode of operation
const wchar_t *EAGetModeName (int mode)
{
switch (mode)
{
@ -669,7 +625,7 @@ wchar_t *EAGetModeName (int ea, int mode, BOOL capitalLetters)
return L"XTS";
}
return L"[unknown]";
return L"[UNKNOWN]";
}
#endif // TC_WINDOWS_BOOT
@ -891,7 +847,7 @@ PCRYPTO_INFO crypto_open ()
}
#ifndef TC_WINDOWS_BOOT
void crypto_loadkey (PKEY_INFO keyInfo, char *lpszUserKey, int nUserKeyLen)
void crypto_loadkey (PKEY_INFO keyInfo, unsigned char *lpszUserKey, int nUserKeyLen)
{
keyInfo->keyLength = nUserKeyLen;
burn (keyInfo->userKey, sizeof (keyInfo->userKey));
@ -1239,9 +1195,11 @@ static BOOL RamEncryptionEnabled = FALSE;
BOOL IsCpuRngSupported ()
{
#ifndef _M_ARM64
if (HasRDSEED() || HasRDRAND())
return TRUE;
else
#endif
return FALSE;
}
@ -1257,14 +1215,10 @@ BOOL IsCpuRngEnabled ()
BOOL IsRamEncryptionSupported ()
{
#ifdef _WIN64
if (t1ha_selfcheck__t1ha2() == 0)
return TRUE;
else
return FALSE;
#else
return FALSE;
#endif
}
void EnableRamEncryption (BOOL enable)
@ -1313,7 +1267,7 @@ uint8 GetRandomIndex (ChaCha20RngCtx* pCtx, uint8 elementsCount)
return index;
}
#if defined(_WIN64) && !defined (_UEFI)
#if !defined (_UEFI)
/* declaration of variables and functions used for RAM encryption on 64-bit build */
static uint8* pbKeyDerivationArea = NULL;
static ULONG cbKeyDerivationArea = 0;

View File

@ -208,9 +208,7 @@ typedef struct
# include "Camellia.h"
#if !defined (_UEFI)
# include "chachaRng.h"
# ifdef _WIN64
# include "t1ha.h"
# endif
#endif
#else
# include "CamelliaSmall.h"
@ -228,9 +226,9 @@ typedef struct keyInfo_t
int noIterations; /* Number of times to iterate (PKCS-5) */
int keyLength; /* Length of the key */
uint64 dummy; /* Dummy field to ensure 16-byte alignment of this structure */
__int8 salt[PKCS5_SALT_SIZE]; /* PKCS-5 salt */
CRYPTOPP_ALIGN_DATA(16) __int8 master_keydata[MASTER_KEYDATA_SIZE]; /* Concatenated master primary and secondary key(s) (XTS mode). For LRW (deprecated/legacy), it contains the tweak key before the master key(s). For CBC (deprecated/legacy), it contains the IV seed before the master key(s). */
CRYPTOPP_ALIGN_DATA(16) __int8 userKey[MAX_PASSWORD]; /* Password (to which keyfiles may have been applied). WITHOUT +1 for the null terminator. */
unsigned __int8 salt[PKCS5_SALT_SIZE]; /* PKCS-5 salt */
CRYPTOPP_ALIGN_DATA(16) unsigned __int8 master_keydata[MASTER_KEYDATA_SIZE]; /* Concatenated master primary and secondary key(s) (XTS mode). For LRW (deprecated/legacy), it contains the tweak key before the master key(s). For CBC (deprecated/legacy), it contains the IV seed before the master key(s). */
CRYPTOPP_ALIGN_DATA(16) unsigned __int8 userKey[MAX_PASSWORD]; /* Password (to which keyfiles may have been applied). WITHOUT +1 for the null terminator. */
} KEY_INFO, *PKEY_INFO;
#endif
@ -309,7 +307,7 @@ typedef struct BOOT_CRYPTO_HEADER_t
PCRYPTO_INFO crypto_open (void);
#ifndef TC_WINDOWS_BOOT
void crypto_loadkey (PKEY_INFO keyInfo, char *lpszUserKey, int nUserKeyLen);
void crypto_loadkey (PKEY_INFO keyInfo, unsigned char *lpszUserKey, int nUserKeyLen);
void crypto_eraseKeys (PCRYPTO_INFO cryptoInfo);
#endif
void crypto_close (PCRYPTO_INFO cryptoInfo);
@ -348,7 +346,7 @@ int EAGetKeySize (int ea);
int EAGetFirstMode (int ea);
int EAGetNextMode (int ea, int previousModeId);
#ifndef TC_WINDOWS_BOOT
wchar_t * EAGetModeName (int ea, int mode, BOOL capitalLetters);
const wchar_t * EAGetModeName (int mode);
#endif
int EAGetKeyScheduleSize (int ea);
int EAGetLargestKey ();
@ -386,7 +384,7 @@ void DecryptDataUnitsCurrentThread (unsigned __int8 *buf, const UINT64_STRUCT *s
void EncryptBuffer (unsigned __int8 *buf, TC_LARGEST_COMPILER_UINT len, PCRYPTO_INFO cryptoInfo);
void DecryptBuffer (unsigned __int8 *buf, TC_LARGEST_COMPILER_UINT len, PCRYPTO_INFO cryptoInfo);
#if defined(_WIN64) && !defined (_UEFI)
#if !defined (TC_WINDOWS_BOOT) && !defined (_UEFI)
BOOL InitializeSecurityParameters(GetRandSeedFn rngCallback);
void ClearSecurityParameters();
#ifdef TC_WINDOWS_DRIVER

View File

@ -14,6 +14,7 @@
#include "Tcdefs.h"
#include <windowsx.h>
#include <versionhelpers.h>
#include <dbghelp.h>
#include <dbt.h>
#include <Setupapi.h>
@ -859,11 +860,6 @@ BOOL VerifyModuleSignature (const wchar_t* path)
WINTRUST_DATA WVTData = {0};
wchar_t filePath [TC_MAX_PATH + 1024];
// we check our own authenticode signature only starting from Windows 10 since this is
// the minimal supported OS apart from XP where we can't verify SHA256 signatures
if (!IsOSAtLeast (WIN_10))
return TRUE;
// Strip quotation marks (if any)
if (path [0] == L'"')
{
@ -1088,9 +1084,6 @@ static BOOL GetWindowsVersion(LPOSVERSIONINFOW lpVersionInformation)
bRet = TRUE;
}
if (!bRet)
bRet = GetVersionExW (lpVersionInformation);
#ifdef SETUP_DLL
// we get real version from Kernel32.dll version since MSI always sets current version to 6.0
// https://stackoverflow.com/questions/49335885/windows-10-not-detecting-on-installshield/49343826#49343826
@ -2133,12 +2126,8 @@ BOOL CALLBACK AboutDlgProc (HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lParam
// Version
SendMessage (GetDlgItem (hwndDlg, IDT_ABOUT_VERSION), WM_SETFONT, (WPARAM) hUserBoldFont, 0);
StringCbPrintfW (szTmp, sizeof(szTmp), L"VeraCrypt %s", _T(VERSION_STRING) _T(VERSION_STRING_SUFFIX));
#ifdef _WIN64
StringCbCatW (szTmp, sizeof(szTmp), L" (64-bit)");
#else
StringCbCatW (szTmp, sizeof(szTmp), L" (32-bit)");
#endif
StringCbPrintfW (szTmp, sizeof(szTmp), L"VeraCrypt %s", _T(VERSION_STRING) _T(VERSION_STRING_SUFFIX) L" (64-bit)");
#if (defined(_DEBUG) || defined(DEBUG))
StringCbCatW (szTmp, sizeof(szTmp), L" (debug)");
#endif
@ -3171,7 +3160,7 @@ BOOL LaunchElevatedProcess (HWND hwndDlg, const wchar_t* szModPath, const wchar_
StringCbCopyW (newCmdLine, sizeof(newCmdLine), L"/q UAC ");
StringCbCatW (newCmdLine, sizeof (newCmdLine), args);
if ((int)ShellExecuteW (hWnd, L"runas", szModPath, newCmdLine, NULL, SW_SHOWNORMAL) <= 32)
if ((INT_PTR)ShellExecuteW (hWnd, L"runas", szModPath, newCmdLine, NULL, SW_SHOWNORMAL) <= 32)
{
if (hwndDlg)
handleWin32Error (hwndDlg, SRC_POS);
@ -3603,10 +3592,16 @@ void InitApp (HINSTANCE hInstance, wchar_t *lpszCommandLine)
InitOSVersionInfo();
if (!IsOSAtLeast (WIN_7))
if (!IsOSAtLeast (WIN_10))
{
// abort using a message that says that VeraCrypt can run only on Windows 7 and later and that it is officially supported only on Windows 10 and later
AbortProcessDirect(L"VeraCrypt requires at least Windows 7 to run.");
// abort using a message that says that VeraCrypt can run only on Windows 10 and later
AbortProcessDirect(L"VeraCrypt requires at least Windows 10 to run.");
}
if (!Is64BitOs())
{
// abort using a message that says that VeraCrypt can run only on 64-bit Windows
AbortProcessDirect(L"VeraCrypt requires a 64-bit version of Windows to run.");
}
SetDefaultDllDirectoriesFn = (SetDefaultDllDirectoriesPtr) GetProcAddress (GetModuleHandle(L"kernel32.dll"), "SetDefaultDllDirectories");
@ -3794,14 +3789,14 @@ void InitApp (HINSTANCE hInstance, wchar_t *lpszCommandLine)
InitHelpFileName ();
#ifndef SETUP
#ifdef _WIN64
EnableRamEncryption ((ReadDriverConfigurationFlags() & VC_DRIVER_CONFIG_ENABLE_RAM_ENCRYPTION) ? TRUE : FALSE);
if (IsRamEncryptionEnabled())
{
if (!InitializeSecurityParameters(GetAppRandomSeed))
AbortProcess("OUTOFMEMORY");
}
#endif
if (!EncryptionThreadPoolStart (ReadEncryptionThreadPoolFreeCpuCountLimit()))
{
handleWin32Error (NULL, SRC_POS);
@ -3916,7 +3911,7 @@ void NotifyDriverOfPortableMode (void)
BOOL GetDriveLabel (int driveNo, wchar_t *label, int labelSize)
{
DWORD fileSystemFlags;
wchar_t root[] = { L'A' + (wchar_t) driveNo, L':', L'\\', 0 };
wchar_t root[] = { (wchar_t) (L'A' + driveNo), L':', L'\\', 0 };
return GetVolumeInformationW (root, label, labelSize / 2, NULL, NULL, &fileSystemFlags, NULL, 0);
}
@ -3946,11 +3941,12 @@ BOOL GetSysDevicePaths (HWND hwndDlg)
}
// Find extra boot partition
foreach (const HostDevice &drive, GetAvailableHostDevices (false, false))
std::vector <HostDevice> devices = GetAvailableHostDevices(false, false);
for (const HostDevice& drive : devices)
{
if (drive.ContainsSystem)
{
foreach (const HostDevice &sysDrivePartition, drive.Partitions)
for (const HostDevice &sysDrivePartition : drive.Partitions)
{
if (sysDrivePartition.Bootable)
{
@ -4870,7 +4866,7 @@ static int DriverLoad ()
else
*tmp = 0;
StringCbCatW (driverPath, sizeof(driverPath), !Is64BitOs () ? L"\\veracrypt.sys" : IsARM()? L"\\veracrypt-arm64.sys" : L"\\veracrypt-x64.sys");
StringCbCatW (driverPath, sizeof(driverPath), IsARM()? L"\\veracrypt-arm64.sys" : L"\\veracrypt-x64.sys");
file = FindFirstFile (driverPath, &find);
@ -5394,7 +5390,7 @@ BOOL SelectMultipleFiles(HWND hwndDlg, const char *stringId, BOOL keepHistory, s
return status;
}
BOOL BrowseDirectories(HWND hwndDlg, char *lpszTitle, wchar_t *dirName, const wchar_t *initialDir)
BOOL BrowseDirectories(HWND hwndDlg, char *lpszDlgTitle, wchar_t *dirName, const wchar_t *initialDir)
{
IFileDialog *pfd = NULL;
HRESULT hr;
@ -5419,9 +5415,9 @@ BOOL BrowseDirectories(HWND hwndDlg, char *lpszTitle, wchar_t *dirName, const wc
}
// Set the title.
if (lpszTitle)
if (lpszDlgTitle)
{
pfd->SetTitle(GetString(lpszTitle));
pfd->SetTitle(GetString(lpszDlgTitle));
}
IShellItem *psi;
@ -5759,7 +5755,7 @@ BOOL CloseVolumeExplorerWindows (HWND hwnd, int driveNo)
BOOL UpdateDriveCustomLabel (int driveNo, wchar_t* effectiveLabel, BOOL bSetValue)
{
wchar_t wszRegPath[MAX_PATH];
wchar_t driveStr[] = {L'A' + (wchar_t) driveNo, 0};
wchar_t driveStr[] = { (wchar_t) (L'A' + driveNo), 0};
HKEY hKey;
LSTATUS lStatus;
DWORD cbLabelLen = (DWORD) ((wcslen (effectiveLabel) + 1) * sizeof (wchar_t));
@ -6266,7 +6262,7 @@ static BOOL PerformBenchmark(HWND hBenchDlg, HWND hwndDlg)
*/
{
int thid, i;
char dk[MASTER_KEYDATA_SIZE];
unsigned char dk[MASTER_KEYDATA_SIZE];
char *tmp_salt = {"\x00\x11\x22\x33\x44\x55\x66\x77\x88\x99\xAA\xBB\xCC\xDD\xEE\xFF\x01\x23\x45\x67\x89\xAB\xCD\xEF\x00\x11\x22\x33\x44\x55\x66\x77\x88\x99\xAA\xBB\xCC\xDD\xEE\xFF\x01\x23\x45\x67\x89\xAB\xCD\xEF\x00\x11\x22\x33\x44\x55\x66\x77\x88\x99\xAA\xBB\xCC\xDD\xEE\xFF"};
for (thid = FIRST_PRF_ID; thid <= LAST_PRF_ID; thid++)
@ -6284,27 +6280,27 @@ static BOOL PerformBenchmark(HWND hBenchDlg, HWND hwndDlg)
case SHA512:
/* PKCS-5 test with HMAC-SHA-512 used as the PRF */
derive_key_sha512 ("passphrase-1234567890", 21, tmp_salt, 64, get_pkcs5_iteration_count(thid, benchmarkPim, benchmarkPreBoot), dk, MASTER_KEYDATA_SIZE);
derive_key_sha512 ((unsigned char*) "passphrase-1234567890", 21, (unsigned char*) tmp_salt, 64, get_pkcs5_iteration_count(thid, benchmarkPim, benchmarkPreBoot), dk, MASTER_KEYDATA_SIZE);
break;
case SHA256:
/* PKCS-5 test with HMAC-SHA-256 used as the PRF */
derive_key_sha256 ("passphrase-1234567890", 21, tmp_salt, 64, get_pkcs5_iteration_count(thid, benchmarkPim, benchmarkPreBoot), dk, MASTER_KEYDATA_SIZE);
derive_key_sha256 ((unsigned char*)"passphrase-1234567890", 21, (unsigned char*) tmp_salt, 64, get_pkcs5_iteration_count(thid, benchmarkPim, benchmarkPreBoot), dk, MASTER_KEYDATA_SIZE);
break;
#ifndef WOLFCRYPT_BACKEND
case BLAKE2S:
/* PKCS-5 test with HMAC-BLAKE2s used as the PRF */
derive_key_blake2s ("passphrase-1234567890", 21, tmp_salt, 64, get_pkcs5_iteration_count(thid, benchmarkPim, benchmarkPreBoot), dk, MASTER_KEYDATA_SIZE);
derive_key_blake2s ((unsigned char*)"passphrase-1234567890", 21, (unsigned char*) tmp_salt, 64, get_pkcs5_iteration_count(thid, benchmarkPim, benchmarkPreBoot), dk, MASTER_KEYDATA_SIZE);
break;
case WHIRLPOOL:
/* PKCS-5 test with HMAC-Whirlpool used as the PRF */
derive_key_whirlpool ("passphrase-1234567890", 21, tmp_salt, 64, get_pkcs5_iteration_count(thid, benchmarkPim, benchmarkPreBoot), dk, MASTER_KEYDATA_SIZE);
derive_key_whirlpool ((unsigned char*)"passphrase-1234567890", 21, (unsigned char*) tmp_salt, 64, get_pkcs5_iteration_count(thid, benchmarkPim, benchmarkPreBoot), dk, MASTER_KEYDATA_SIZE);
break;
case STREEBOG:
/* PKCS-5 test with HMAC-STREEBOG used as the PRF */
derive_key_streebog("passphrase-1234567890", 21, tmp_salt, 64, get_pkcs5_iteration_count(thid, benchmarkPim, benchmarkPreBoot), dk, MASTER_KEYDATA_SIZE);
derive_key_streebog((unsigned char*)"passphrase-1234567890", 21, (unsigned char*) tmp_salt, 64, get_pkcs5_iteration_count(thid, benchmarkPim, benchmarkPreBoot), dk, MASTER_KEYDATA_SIZE);
break;
}
#endif
@ -6328,19 +6324,11 @@ static BOOL PerformBenchmark(HWND hBenchDlg, HWND hwndDlg)
{
if (thid == SHA256)
{
#ifdef _WIN64
benchmarkTable[benchmarkTotalItems].meanBytesPerSec = (benchmarkTable[benchmarkTotalItems].meanBytesPerSec * 26);
#else
benchmarkTable[benchmarkTotalItems].meanBytesPerSec = (benchmarkTable[benchmarkTotalItems].meanBytesPerSec * 24);
#endif
}
else
{
#ifdef _WIN64
benchmarkTable[benchmarkTotalItems].meanBytesPerSec = (benchmarkTable[benchmarkTotalItems].meanBytesPerSec * 21) / 5;
#else
benchmarkTable[benchmarkTotalItems].meanBytesPerSec = (benchmarkTable[benchmarkTotalItems].meanBytesPerSec * 18) / 5;
#endif
}
}
}
@ -6363,10 +6351,8 @@ static BOOL PerformBenchmark(HWND hBenchDlg, HWND hwndDlg)
if (EAInitMode (ci, ci->k2))
{
int i;
#ifdef _WIN64
if (IsRamEncryptionEnabled ())
VcProtectKeys (ci, VcGetEncryptionID (ci));
#endif
for (i = 0; i < 10; i++)
{
@ -6388,10 +6374,8 @@ static BOOL PerformBenchmark(HWND hBenchDlg, HWND hwndDlg)
if (!EAInitMode (ci, ci->k2))
goto counter_error;
#ifdef _WIN64
if (IsRamEncryptionEnabled ())
VcProtectKeys (ci, VcGetEncryptionID (ci));
#endif
if (QueryPerformanceCounter (&performanceCountStart) == 0)
goto counter_error;
@ -7639,7 +7623,7 @@ CipherTestDialogProc (HWND hwndDlg, UINT uMsg, WPARAM wParam, LPARAM lParam)
else
{
CipherInit2(idTestCipher, key, ks_tmp, ks);
CipherInit2(idTestCipher, key, ks_tmp);
if (bEncrypt)
{
@ -8261,7 +8245,7 @@ void BroadcastDeviceChange (WPARAM message, int nDosDriveNo, DWORD driveMap)
{
if (driveMap & (1 << i))
{
wchar_t root[] = { (wchar_t) i + L'A', L':', L'\\', 0 };
wchar_t root[] = { (wchar_t) (i + L'A'), L':', L'\\', 0 };
SHChangeNotify (eventId, SHCNF_PATH, root, NULL);
@ -8818,12 +8802,12 @@ int MountVolume (HWND hwndDlg,
wstring drivePath = L"\\\\.\\X:";
HANDLE dev = INVALID_HANDLE_VALUE;
VOLUME_DISK_EXTENTS extents = {0};
DWORD dwResult = 0;
DWORD cbReturnedBytes = 0;
drivePath[4] = root[0];
if ((dev = CreateFile (drivePath.c_str(),0, 0, NULL, OPEN_EXISTING, 0, NULL)) != INVALID_HANDLE_VALUE)
{
if (DeviceIoControl (dev, IOCTL_VOLUME_GET_VOLUME_DISK_EXTENTS, NULL, 0, &extents, sizeof(extents), &dwResult, NULL))
if (DeviceIoControl (dev, IOCTL_VOLUME_GET_VOLUME_DISK_EXTENTS, NULL, 0, &extents, sizeof(extents), &cbReturnedBytes, NULL))
{
if (extents.NumberOfDiskExtents > 0)
{
@ -8960,18 +8944,18 @@ int MountVolume (HWND hwndDlg,
if (bDevice && mount.bProtectHiddenVolume)
{
int driveNo;
int diskNo;
if (swscanf (volumePath, L"\\Device\\Harddisk%d\\Partition", &driveNo) == 1)
if (swscanf (volumePath, L"\\Device\\Harddisk%d\\Partition", &diskNo) == 1)
{
OPEN_TEST_STRUCT openTestStruct;
memset (&openTestStruct, 0, sizeof (openTestStruct));
openTestStruct.bDetectTCBootLoader = TRUE;
StringCchPrintfW ((wchar_t *) openTestStruct.wszFileName, array_capacity (openTestStruct.wszFileName), L"\\Device\\Harddisk%d\\Partition0", driveNo);
StringCchPrintfW ((wchar_t *) openTestStruct.wszFileName, array_capacity (openTestStruct.wszFileName), L"\\Device\\Harddisk%d\\Partition0", diskNo);
DWORD dwResult;
if (DeviceIoControl (hDriver, TC_IOCTL_OPEN_TEST, &openTestStruct, sizeof (OPEN_TEST_STRUCT), &openTestStruct, sizeof (OPEN_TEST_STRUCT), &dwResult, NULL) && openTestStruct.TCBootLoaderDetected)
DWORD cbBytesReturned;
if (DeviceIoControl (hDriver, TC_IOCTL_OPEN_TEST, &openTestStruct, sizeof (OPEN_TEST_STRUCT), &openTestStruct, sizeof (OPEN_TEST_STRUCT), &cbBytesReturned, NULL) && openTestStruct.TCBootLoaderDetected)
WarningDirect ((GetWrongPasswordErrorMessage (hwndDlg) + L"\n\n" + GetString ("HIDDEN_VOL_PROT_PASSWORD_US_KEYB_LAYOUT")).c_str(), hwndDlg);
else
handleError (hwndDlg, mount.nReturnCode, SRC_POS);
@ -9010,7 +8994,7 @@ int MountVolume (HWND hwndDlg,
if (mount.FilesystemDirty)
{
wchar_t msg[1024];
wchar_t mountPoint[] = { L'A' + (wchar_t) driveNo, L':', 0 };
wchar_t mountPoint[] = { (wchar_t) (L'A' + driveNo), L':', 0 };
StringCbPrintfW (msg, sizeof(msg), GetString ("MOUNTED_VOLUME_DIRTY"), mountPoint);
if (AskWarnYesNoStringTopmost (msg, hwndDlg) == IDYES)
@ -9024,7 +9008,7 @@ int MountVolume (HWND hwndDlg,
&& !IsFileOnReadOnlyFilesystem (volumePath))
{
wchar_t msg[1024];
wchar_t mountPoint[] = { L'A' + (wchar_t) driveNo, L':', 0 };
wchar_t mountPoint[] = { (wchar_t) (L'A' + driveNo), L':', 0 };
StringCbPrintfW (msg, sizeof(msg), GetString ("MOUNTED_CONTAINER_FORCED_READ_ONLY"), mountPoint);
WarningDirect (msg, hwndDlg);
@ -9035,7 +9019,7 @@ int MountVolume (HWND hwndDlg,
&& bDevice)
{
wchar_t msg[1024];
wchar_t mountPoint[] = { L'A' + (wchar_t) driveNo, L':', 0 };
wchar_t mountPoint[] = { (wchar_t)(L'A' + driveNo), L':', 0 };
StringCbPrintfW (msg, sizeof(msg), GetString ("MOUNTED_DEVICE_FORCED_READ_ONLY"), mountPoint);
WarningDirect (msg, hwndDlg);
@ -9046,7 +9030,7 @@ int MountVolume (HWND hwndDlg,
&& wcsstr (volumePath, L"\\Device\\Harddisk") == volumePath)
{
wchar_t msg[1024];
wchar_t mountPoint[] = { L'A' + (wchar_t) driveNo, L':', 0 };
wchar_t mountPoint[] = { (wchar_t) (L'A' + driveNo), L':', 0 };
StringCbPrintfW (msg, sizeof(msg), GetString ("MOUNTED_DEVICE_FORCED_READ_ONLY_WRITE_PROTECTION"), mountPoint);
WarningDirect (msg, hwndDlg);
@ -9064,7 +9048,7 @@ int MountVolume (HWND hwndDlg,
&& bDevice)
{
wchar_t msg[1024];
wchar_t mountPoint[] = { L'A' + (wchar_t) driveNo, L':', 0 };
wchar_t mountPoint[] = { (wchar_t) (L'A' + driveNo), L':', 0 };
StringCbPrintfW (msg, sizeof(msg), GetString ("PARTIAL_SYSENC_MOUNT_READONLY"), mountPoint);
WarningDirect (msg, hwndDlg);
@ -9157,7 +9141,7 @@ static BOOL UnmountVolumeBase (HWND hwndDlg, int nDosDriveNo, BOOL forceUnmount,
}
// Undo SHCNE_DRIVEREMOVED
wchar_t root[] = { (wchar_t) nDosDriveNo + L'A', L':', L'\\', 0 };
wchar_t root[] = { (wchar_t) (nDosDriveNo + L'A'), L':', L'\\', 0 };
SHChangeNotify (SHCNE_DRIVEADD, SHCNF_PATH, root, NULL);
return FALSE;
@ -9511,7 +9495,7 @@ int GetDiskDeviceDriveLetter (PWSTR deviceName)
for (i = 0; i < 26; i++)
{
WCHAR drive[] = { (WCHAR) i + L'A', L':', 0 };
WCHAR drive[] = { (WCHAR) (i + L'A'), L':', 0 };
StringCchCopyW (link, MAX_PATH, L"\\DosDevices\\");
StringCchCatW (link, MAX_PATH, drive);
@ -10204,7 +10188,7 @@ std::wstring GetServiceConfigPath (const wchar_t *fileName, bool useLegacy)
{
wchar_t sysPath[TC_MAX_PATH];
if (Is64BitOs() && useLegacy)
if (useLegacy)
{
typedef UINT (WINAPI *GetSystemWow64Directory_t) (LPWSTR lpBuffer, UINT uSize);
@ -10709,12 +10693,12 @@ void OpenPageHelp (HWND hwndDlg, int nPage)
}
else
{
int r = (int)ShellExecuteW (NULL, L"open", szHelpFile, NULL, NULL, SW_SHOWNORMAL);
INT_PTR r = (INT_PTR)ShellExecuteW (NULL, L"open", szHelpFile, NULL, NULL, SW_SHOWNORMAL);
if (r == ERROR_FILE_NOT_FOUND)
{
// Try the secondary help file
r = (int)ShellExecuteW (NULL, L"open", szHelpFile2, NULL, NULL, SW_SHOWNORMAL);
r = (INT_PTR)ShellExecuteW (NULL, L"open", szHelpFile2, NULL, NULL, SW_SHOWNORMAL);
if (r == ERROR_FILE_NOT_FOUND)
{
@ -10941,14 +10925,11 @@ BOOL IsARM()
BOOL IsServerOS ()
{
OSVERSIONINFOEXW osVer;
osVer.dwOSVersionInfoSize = sizeof (OSVERSIONINFOEXW);
GetVersionExW ((LPOSVERSIONINFOW) &osVer);
return (osVer.wProductType == VER_NT_SERVER || osVer.wProductType == VER_NT_DOMAIN_CONTROLLER);
return IsWindowsServer()? TRUE : FALSE;
}
// Returns TRUE, if the currently running operating system is installed in a hidden volume. If it's not, or if
// there's an error, returns FALSE.
BOOL IsHiddenOSRunning (void)
@ -11023,100 +11004,105 @@ std::wstring GetWindowsEdition ()
{
wstring osname = L"win";
OSVERSIONINFOEXW osVer;
OSVERSIONINFOEXW osVer = { 0 };
osVer.dwOSVersionInfoSize = sizeof (OSVERSIONINFOEXW);
GetVersionExW ((LPOSVERSIONINFOW) &osVer);
BOOL home = (osVer.wSuiteMask & VER_SUITE_PERSONAL);
BOOL server = (osVer.wProductType == VER_NT_SERVER || osVer.wProductType == VER_NT_DOMAIN_CONTROLLER);
HKEY hkey;
wchar_t productName[300] = {0};
DWORD productNameSize = sizeof (productName);
if (RegOpenKeyEx (HKEY_LOCAL_MACHINE, L"SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion", 0, KEY_QUERY_VALUE, &hkey) == ERROR_SUCCESS)
if (GetWindowsVersion((LPOSVERSIONINFOW)&osVer))
{
if (RegQueryValueEx (hkey, L"ProductName", 0, 0, (LPBYTE) &productName, &productNameSize) != ERROR_SUCCESS || productNameSize < 1)
productName[0] = 0;
RegCloseKey (hkey);
BOOL home = (osVer.wSuiteMask & VER_SUITE_PERSONAL);
BOOL server = (osVer.wProductType == VER_NT_SERVER || osVer.wProductType == VER_NT_DOMAIN_CONTROLLER);
HKEY hkey;
wchar_t productName[300] = { 0 };
DWORD productNameSize = sizeof(productName);
if (RegOpenKeyEx(HKEY_LOCAL_MACHINE, L"SOFTWARE\\Microsoft\\Windows NT\\CurrentVersion", 0, KEY_QUERY_VALUE, &hkey) == ERROR_SUCCESS)
{
if (RegQueryValueEx(hkey, L"ProductName", 0, 0, (LPBYTE)&productName, &productNameSize) != ERROR_SUCCESS || productNameSize < 1)
productName[0] = 0;
RegCloseKey(hkey);
}
switch (nCurrentOS)
{
case WIN_2000:
osname += L"2000";
break;
case WIN_XP:
case WIN_XP64:
osname += L"xp";
osname += home ? L"-home" : L"-pro";
break;
case WIN_SERVER_2003:
osname += L"2003";
break;
case WIN_VISTA:
osname += L"vista";
break;
case WIN_SERVER_2008:
osname += L"2008";
break;
case WIN_7:
osname += L"7";
break;
case WIN_SERVER_2008_R2:
osname += L"2008r2";
break;
default:
wstringstream s;
s << CurrentOSMajor << L"." << CurrentOSMinor;
osname += s.str();
break;
}
if (server)
osname += L"-server";
if (IsOSAtLeast(WIN_VISTA))
{
if (home)
osname += L"-home";
else if (wcsstr(productName, L"Standard") != 0)
osname += L"-standard";
else if (wcsstr(productName, L"Professional") != 0)
osname += L"-pro";
else if (wcsstr(productName, L"Business") != 0)
osname += L"-business";
else if (wcsstr(productName, L"Enterprise") != 0)
osname += L"-enterprise";
else if (wcsstr(productName, L"Datacenter") != 0)
osname += L"-datacenter";
else if (wcsstr(productName, L"Ultimate") != 0)
osname += L"-ultimate";
}
if (GetSystemMetrics(SM_STARTER))
osname += L"-starter";
else if (wcsstr(productName, L"Basic") != 0)
osname += L"-basic";
osname += IsARM() ? L"-arm64" : L"-x64";
if (CurrentOSServicePack > 0)
{
wstringstream s;
s << L"-sp" << CurrentOSServicePack;
osname += s.str();
}
return osname;
}
switch (nCurrentOS)
else
{
case WIN_2000:
osname += L"2000";
break;
case WIN_XP:
case WIN_XP64:
osname += L"xp";
osname += home ? L"-home" : L"-pro";
break;
case WIN_SERVER_2003:
osname += L"2003";
break;
case WIN_VISTA:
osname += L"vista";
break;
case WIN_SERVER_2008:
osname += L"2008";
break;
case WIN_7:
osname += L"7";
break;
case WIN_SERVER_2008_R2:
osname += L"2008r2";
break;
default:
wstringstream s;
s << CurrentOSMajor << L"." << CurrentOSMinor;
osname += s.str();
break;
return L"";
}
if (server)
osname += L"-server";
if (IsOSAtLeast (WIN_VISTA))
{
if (home)
osname += L"-home";
else if (wcsstr (productName, L"Standard") != 0)
osname += L"-standard";
else if (wcsstr (productName, L"Professional") != 0)
osname += L"-pro";
else if (wcsstr (productName, L"Business") != 0)
osname += L"-business";
else if (wcsstr (productName, L"Enterprise") != 0)
osname += L"-enterprise";
else if (wcsstr (productName, L"Datacenter") != 0)
osname += L"-datacenter";
else if (wcsstr (productName, L"Ultimate") != 0)
osname += L"-ultimate";
}
if (GetSystemMetrics (SM_STARTER))
osname += L"-starter";
else if (wcsstr (productName, L"Basic") != 0)
osname += L"-basic";
if (Is64BitOs())
osname += IsARM()? L"-arm64" : L"-x64";
if (CurrentOSServicePack > 0)
{
wstringstream s;
s << L"-sp" << CurrentOSServicePack;
osname += s.str();
}
return osname;
}
#ifdef SETUP
@ -11129,7 +11115,7 @@ void Applink (const char *dest)
wchar_t page[TC_MAX_PATH] = {0};
wchar_t installDir[TC_MAX_PATH] = {0};
BOOL buildUrl = TRUE;
int r;
INT_PTR r;
ArrowWaitCursor ();
@ -11333,7 +11319,7 @@ void Applink (const char *dest)
}
else
{
r = (int) ShellExecuteW (NULL, L"open", url, NULL, NULL, SW_SHOWNORMAL);
r = (INT_PTR) ShellExecuteW (NULL, L"open", url, NULL, NULL, SW_SHOWNORMAL);
if (((r == ERROR_FILE_NOT_FOUND) || (r == ERROR_PATH_NOT_FOUND)) && buildUrl)
{
@ -11480,7 +11466,7 @@ int OpenVolume (OpenVolumeContext *context, const wchar_t *volumePath, Password
int volumeType;
wchar_t szDiskFile[TC_MAX_PATH], szCFDevice[TC_MAX_PATH];
wchar_t szDosDevice[TC_MAX_PATH];
char buffer[TC_VOLUME_HEADER_EFFECTIVE_SIZE];
unsigned char buffer[TC_VOLUME_HEADER_EFFECTIVE_SIZE];
LARGE_INTEGER headerOffset;
DWORD dwResult;
DISK_GEOMETRY_EX deviceGeometry;
@ -11694,7 +11680,7 @@ void CloseVolume (OpenVolumeContext *context)
}
int ReEncryptVolumeHeader (HWND hwndDlg, char *buffer, BOOL bBoot, CRYPTO_INFO *cryptoInfo, Password *password, int pim, BOOL wipeMode)
int ReEncryptVolumeHeader (HWND hwndDlg, unsigned char *buffer, BOOL bBoot, CRYPTO_INFO *cryptoInfo, Password *password, int pim, BOOL wipeMode)
{
CRYPTO_INFO *newCryptoInfo = NULL;
@ -13059,7 +13045,7 @@ BOOL IsFileOnReadOnlyFilesystem (const wchar_t *path)
void CheckFilesystem (HWND hwndDlg, int driveNo, BOOL fixErrors)
{
wchar_t msg[1024], param[1024], cmdPath[MAX_PATH];
wchar_t driveRoot[] = { L'A' + (wchar_t) driveNo, L':', 0 };
wchar_t driveRoot[] = { (wchar_t) (L'A' + driveNo), L':', 0 };
if (fixErrors && AskWarnYesNo ("FILESYS_REPAIR_CONFIRM_BACKUP", hwndDlg) == IDNO)
return;
@ -13305,18 +13291,18 @@ BOOL IsWindowsIsoBurnerAvailable ()
BOOL LaunchWindowsIsoBurner (HWND hwnd, const wchar_t *isoPath)
{
wchar_t path[MAX_PATH*2] = { 0 };
int r;
INT_PTR r;
if (SUCCEEDED(SHGetFolderPath (NULL, CSIDL_SYSTEM, NULL, 0, path)))
StringCbCatW (path, MAX_PATH*2, L"\\" ISO_BURNER_TOOL);
else
StringCbCopyW (path, MAX_PATH*2, L"C:\\Windows\\System32\\" ISO_BURNER_TOOL);
r = (int) ShellExecute (hwnd, L"open", path, (wstring (L"\"") + isoPath + L"\"").c_str(), NULL, SW_SHOWNORMAL);
r = (INT_PTR) ShellExecute (hwnd, L"open", path, (wstring (L"\"") + isoPath + L"\"").c_str(), NULL, SW_SHOWNORMAL);
if (r <= 32)
{
SetLastError (r);
SetLastError ((DWORD) r);
handleWin32Error (hwnd, SRC_POS);
return FALSE;
@ -14240,17 +14226,14 @@ void GetInstallationPath (HWND hwndDlg, wchar_t* szInstallPath, DWORD cchSize, B
SHGetSpecialFolderLocation (hwndDlg, CSIDL_PROGRAM_FILES, &itemList);
SHGetPathFromIDList (itemList, path);
if (Is64BitOs())
// Use a unified default installation path (registry redirection of %ProgramFiles% does not work if the installation path is user-selectable)
wstring s = path;
size_t p = s.find (L" (x86)");
if (p != wstring::npos)
{
// Use a unified default installation path (registry redirection of %ProgramFiles% does not work if the installation path is user-selectable)
wstring s = path;
size_t p = s.find (L" (x86)");
if (p != wstring::npos)
{
s = s.substr (0, p);
if (_waccess (s.c_str(), 0) != -1)
StringCbCopyW (path, sizeof (path), s.c_str());
}
s = s.substr (0, p);
if (_waccess (s.c_str(), 0) != -1)
StringCbCopyW (path, sizeof (path), s.c_str());
}
StringCbCatW (path, sizeof(path), L"\\VeraCrypt\\");
@ -14823,7 +14806,7 @@ void SafeOpenURL (LPCWSTR szUrl)
}
}
#if !defined(SETUP) && defined(_WIN64)
#if !defined(SETUP)
#define RtlGenRandom SystemFunction036
extern "C" BOOLEAN NTAPI RtlGenRandom(PVOID RandomBuffer, ULONG RandomBufferLength);
@ -15264,7 +15247,7 @@ void PasswordEditDropTarget::GotLeave(void)
DWORD PasswordEditDropTarget::GotEnter(void)
{
TCHAR szClassName[64];
DWORD dwStyles;
DWORD_PTR dwStyles;
int maxLen;
HWND hChild = WindowFromPoint (m_DropPoint);
// check that we are on password edit control (we use maximum length to correctly identify password fields since they don't always have ES_PASSWORD style (if the the user checked show password)
@ -15290,7 +15273,7 @@ void PasswordEditDropTarget::GotDrop(CLIPFORMAT format)
if(m_Data)
{
TCHAR szClassName[64];
DWORD dwStyles;
DWORD_PTR dwStyles;
int maxLen;
HWND hChild = WindowFromPoint (m_DropPoint);
if (hChild && GetClassName (hChild, szClassName, ARRAYSIZE (szClassName)) && (0 == _tcsicmp (szClassName, _T("EDIT")))

View File

@ -540,7 +540,7 @@ BOOL GetSysDevicePaths (HWND hwndDlg);
BOOL DoDriverInstall (HWND hwndDlg);
int OpenVolume (OpenVolumeContext *context, const wchar_t *volumePath, Password *password, int pkcs5_prf, int pim, BOOL write, BOOL preserveTimestamps, BOOL useBackupHeader);
void CloseVolume (OpenVolumeContext *context);
int ReEncryptVolumeHeader (HWND hwndDlg, char *buffer, BOOL bBoot, CRYPTO_INFO *cryptoInfo, Password *password, int pim, BOOL wipeMode);
int ReEncryptVolumeHeader (HWND hwndDlg, unsigned char *buffer, BOOL bBoot, CRYPTO_INFO *cryptoInfo, Password *password, int pim, BOOL wipeMode);
BOOL IsPagingFileActive (BOOL checkNonWindowsPartitionsOnly);
BOOL IsPagingFileWildcardActive ();
BOOL DisablePagingFile ();
@ -594,7 +594,7 @@ BitLockerEncryptionStatus GetBitLockerEncryptionStatus(WCHAR driveLetter);
BOOL IsTestSigningModeEnabled ();
DWORD SendServiceNotification (DWORD dwNotificationCmd);
DWORD FastResizeFile (const wchar_t* filePath, __int64 fileSize);
#ifdef _WIN64
#if !defined(SETUP)
void GetAppRandomSeed (unsigned char* pbRandSeed, size_t cbRandSeed);
#endif
BOOL IsInternetConnected();

View File

@ -98,14 +98,14 @@ typedef struct EncryptionThreadPoolWorkItemStruct
{
TC_EVENT *CompletionEvent;
LONG *CompletionFlag;
char *DerivedKey;
unsigned char *DerivedKey;
int IterationCount;
TC_EVENT *NoOutstandingWorkItemEvent;
LONG *OutstandingWorkItemCount;
char *Password;
unsigned char *Password;
int PasswordLength;
int Pkcs5Prf;
char *Salt;
unsigned char *Salt;
} KeyDerivation;
@ -143,7 +143,6 @@ static TC_MUTEX DequeueMutex;
static TC_EVENT WorkItemReadyEvent;
static TC_EVENT WorkItemCompletedEvent;
#if defined(_WIN64)
void EncryptDataUnitsCurrentThreadEx (unsigned __int8 *buf, const UINT64_STRUCT *structUnitNo, TC_LARGEST_COMPILER_UINT nbrUnits, PCRYPTO_INFO ci)
{
if (IsRamEncryptionEnabled())
@ -176,11 +175,6 @@ void DecryptDataUnitsCurrentThreadEx (unsigned __int8 *buf, const UINT64_STRUCT
DecryptDataUnitsCurrentThread (buf, structUnitNo, nbrUnits, ci);
}
#else
#define EncryptDataUnitsCurrentThreadEx EncryptDataUnitsCurrentThread
#define DecryptDataUnitsCurrentThreadEx DecryptDataUnitsCurrentThread
#endif
static WorkItemState GetWorkItemState (EncryptionThreadPoolWorkItem *workItem)
{
return InterlockedExchangeAdd ((LONG *) &workItem->State, 0);
@ -533,7 +527,7 @@ void EncryptionThreadPoolStop ()
}
void EncryptionThreadPoolBeginKeyDerivation (TC_EVENT *completionEvent, TC_EVENT *noOutstandingWorkItemEvent, LONG *completionFlag, LONG *outstandingWorkItemCount, int pkcs5Prf, char *password, int passwordLength, char *salt, int iterationCount, char *derivedKey)
void EncryptionThreadPoolBeginKeyDerivation (TC_EVENT *completionEvent, TC_EVENT *noOutstandingWorkItemEvent, LONG *completionFlag, LONG *outstandingWorkItemCount, int pkcs5Prf, unsigned char *password, int passwordLength, unsigned char *salt, int iterationCount, unsigned char *derivedKey)
{
EncryptionThreadPoolWorkItem *workItem;

View File

@ -32,7 +32,7 @@ typedef enum
size_t GetCpuCount (WORD* pGroupCount);
#endif
void EncryptionThreadPoolBeginKeyDerivation (TC_EVENT *completionEvent, TC_EVENT *noOutstandingWorkItemEvent, LONG *completionFlag, LONG *outstandingWorkItemCount, int pkcs5Prf, char *password, int passwordLength, char *salt, int iterationCount, char *derivedKey);
void EncryptionThreadPoolBeginKeyDerivation (TC_EVENT *completionEvent, TC_EVENT *noOutstandingWorkItemEvent, LONG *completionFlag, LONG *outstandingWorkItemCount, int pkcs5Prf, unsigned char *password, int passwordLength, unsigned char *salt, int iterationCount, unsigned char *derivedKey);
void EncryptionThreadPoolBeginReadVolumeHeaderFinalization (TC_EVENT *keyDerivationCompletedEvent, TC_EVENT *noOutstandingWorkItemEvent, LONG* outstandingWorkItemCount, void* keyInfoBuffer, int keyInfoBufferSize, void* keyDerivationWorkItems, int keyDerivationWorkItemsSize);
void EncryptionThreadPoolDoWork (EncryptionThreadPoolWorkType type, uint8 *data, const UINT64_STRUCT *startUnitNo, uint32 unitCount, PCRYPTO_INFO cryptoInfo);
BOOL EncryptionThreadPoolStart (size_t encryptionFreeCpuCount);

View File

@ -445,10 +445,8 @@ FormatFat (void* hwndDlgPtr, unsigned __int64 startSector, fatparams * ft, void
return ERR_MODE_INIT_FAILED;
}
#ifdef _WIN64
if (IsRamEncryptionEnabled ())
VcProtectKeys (cryptoInfo, VcGetEncryptionID (cryptoInfo));
#endif
x = ft->num_sectors - ft->reserved - ft->size_root_dir / ft->sector_size - ft->fat_length * 2;
while (x--)

View File

@ -84,7 +84,7 @@ int TCFormatVolume (volatile FORMAT_VOL_PARAMETERS *volParams)
PCRYPTO_INFO cryptoInfo = NULL;
HANDLE dev = INVALID_HANDLE_VALUE;
DWORD dwError;
char header[TC_VOLUME_HEADER_EFFECTIVE_SIZE];
unsigned char header[TC_VOLUME_HEADER_EFFECTIVE_SIZE];
unsigned __int64 num_sectors, startSector;
fatparams ft;
FILETIME ftCreationTime;
@ -100,10 +100,8 @@ int TCFormatVolume (volatile FORMAT_VOL_PARAMETERS *volParams)
LARGE_INTEGER offset;
BOOL bFailedRequiredDASD = FALSE;
HWND hwndDlg = volParams->hwndDlg;
#ifdef _WIN64
CRYPTO_INFO tmpCI;
PCRYPTO_INFO cryptoInfoBackup = NULL;
#endif
FormatSectorSize = volParams->sectorSize;
@ -175,12 +173,10 @@ int TCFormatVolume (volatile FORMAT_VOL_PARAMETERS *volParams)
return nStatus? nStatus : ERR_OUTOFMEMORY;
}
#ifdef _WIN64
if (IsRamEncryptionEnabled ())
{
VcProtectKeys (cryptoInfo, VcGetEncryptionID (cryptoInfo));
}
#endif
begin_format:
@ -511,9 +507,9 @@ int TCFormatVolume (volatile FORMAT_VOL_PARAMETERS *volParams)
// The previous file system format failed and the user wants to try again with a different file system.
// The volume header had been written successfully so we need to seek to the byte after the header.
LARGE_INTEGER offset;
offset.QuadPart = TC_VOLUME_DATA_OFFSET;
if (!SetFilePointerEx ((HANDLE) dev, offset, NULL, FILE_BEGIN))
LARGE_INTEGER volDataOffset;
volDataOffset.QuadPart = TC_VOLUME_DATA_OFFSET;
if (!SetFilePointerEx ((HANDLE) dev, volDataOffset, NULL, FILE_BEGIN))
{
nStatus = ERR_OS_ERROR;
goto error;
@ -640,7 +636,6 @@ int TCFormatVolume (volatile FORMAT_VOL_PARAMETERS *volParams)
goto error;
}
#ifdef _WIN64
if (IsRamEncryptionEnabled ())
{
VirtualLock (&tmpCI, sizeof (tmpCI));
@ -649,7 +644,6 @@ int TCFormatVolume (volatile FORMAT_VOL_PARAMETERS *volParams)
cryptoInfoBackup = cryptoInfo;
cryptoInfo = &tmpCI;
}
#endif
nStatus = CreateVolumeHeaderInMemory (hwndDlg, FALSE,
header,
@ -669,14 +663,12 @@ int TCFormatVolume (volatile FORMAT_VOL_PARAMETERS *volParams)
FormatSectorSize,
FALSE);
#ifdef _WIN64
if (IsRamEncryptionEnabled ())
{
cryptoInfo = cryptoInfoBackup;
burn (&tmpCI, sizeof (CRYPTO_INFO));
VirtualUnlock (&tmpCI, sizeof (tmpCI));
}
#endif
if (!WriteEffectiveVolumeHeader (volParams->bDevice, dev, header))
{
@ -689,7 +681,6 @@ int TCFormatVolume (volatile FORMAT_VOL_PARAMETERS *volParams)
{
BOOL bUpdateBackup = FALSE;
#ifdef _WIN64
if (IsRamEncryptionEnabled ())
{
VirtualLock (&tmpCI, sizeof (tmpCI));
@ -698,18 +689,15 @@ int TCFormatVolume (volatile FORMAT_VOL_PARAMETERS *volParams)
cryptoInfoBackup = cryptoInfo;
cryptoInfo = &tmpCI;
}
#endif
nStatus = WriteRandomDataToReservedHeaderAreas (hwndDlg, dev, cryptoInfo, dataAreaSize, FALSE, FALSE);
#ifdef _WIN64
if (IsRamEncryptionEnabled ())
{
cryptoInfo = cryptoInfoBackup;
burn (&tmpCI, sizeof (CRYPTO_INFO));
VirtualUnlock (&tmpCI, sizeof (tmpCI));
}
#endif
if (nStatus != ERR_SUCCESS)
goto error;
@ -915,9 +903,7 @@ int FormatNoFs (HWND hwndDlg, unsigned __int64 startSector, unsigned __int64 num
LARGE_INTEGER startOffset;
LARGE_INTEGER newOffset;
#ifdef _WIN64
CRYPTO_INFO tmpCI;
#endif
// Seek to start sector
startOffset.QuadPart = startSector * FormatSectorSize;
@ -936,7 +922,6 @@ int FormatNoFs (HWND hwndDlg, unsigned __int64 startSector, unsigned __int64 num
memset (sector, 0, sizeof (sector));
#ifdef _WIN64
if (IsRamEncryptionEnabled ())
{
VirtualLock (&tmpCI, sizeof (tmpCI));
@ -944,7 +929,6 @@ int FormatNoFs (HWND hwndDlg, unsigned __int64 startSector, unsigned __int64 num
VcUnprotectKeys (&tmpCI, VcGetEncryptionID (cryptoInfo));
cryptoInfo = &tmpCI;
}
#endif
// Remember the original secondary key (XTS mode) before generating a temporary one
memcpy (originalK2, cryptoInfo->k2, sizeof (cryptoInfo->k2));
@ -975,10 +959,8 @@ int FormatNoFs (HWND hwndDlg, unsigned __int64 startSector, unsigned __int64 num
goto fail;
}
#ifdef _WIN64
if (IsRamEncryptionEnabled ())
VcProtectKeys (cryptoInfo, VcGetEncryptionID (cryptoInfo));
#endif
while (num_sectors--)
{
@ -1051,13 +1033,11 @@ int FormatNoFs (HWND hwndDlg, unsigned __int64 startSector, unsigned __int64 num
VirtualUnlock (temporaryKey, sizeof (temporaryKey));
VirtualUnlock (originalK2, sizeof (originalK2));
TCfree (write_buf);
#ifdef _WIN64
if (IsRamEncryptionEnabled ())
{
burn (&tmpCI, sizeof (CRYPTO_INFO));
VirtualUnlock (&tmpCI, sizeof (tmpCI));
}
#endif
return 0;
@ -1069,13 +1049,11 @@ int FormatNoFs (HWND hwndDlg, unsigned __int64 startSector, unsigned __int64 num
VirtualUnlock (temporaryKey, sizeof (temporaryKey));
VirtualUnlock (originalK2, sizeof (originalK2));
TCfree (write_buf);
#ifdef _WIN64
if (IsRamEncryptionEnabled ())
{
burn (&tmpCI, sizeof (CRYPTO_INFO));
VirtualUnlock (&tmpCI, sizeof (tmpCI));
}
#endif
SetLastError (err);
return (retVal ? retVal : ERR_OS_ERROR);

View File

@ -270,7 +270,7 @@ BOOL KeyFilesApply (HWND hwndDlg, Password *password, KeyFile *firstKeyFile, con
unsigned __int32 writePos = 0;
size_t totalRead = 0;
for (size_t i = 0; i < keyfileData.size(); i++)
for (i = 0; i < keyfileData.size(); i++)
{
crc = UPDC32 (keyfileData[i], crc);
@ -496,7 +496,7 @@ BOOL CALLBACK KeyFilesDlgProc (HWND hwndDlg, UINT msg, WPARAM wParam, LPARAM lPa
// set the text colour in (HDC)wParam
SetBkMode((HDC)wParam,TRANSPARENT);
SetTextColor((HDC)wParam, RGB(255,0,0));
return (BOOL)GetSysColorBrush(COLOR_MENU);
return (BOOL)(INT_PTR)GetSysColorBrush(COLOR_MENU);
}
}
return 0;

View File

@ -342,7 +342,7 @@ static BOOL LoadLanguageData (int resourceid, BOOL bForceSetPreferredLanguage, B
xml = (char *) res;
while (xml = XmlFindElement (xml, xmlElements[i]))
{
void *key;
void *pkey;
void *text;
XmlGetAttributeText (xml, "lang", attr, sizeof (attr));
@ -351,8 +351,8 @@ static BOOL LoadLanguageData (int resourceid, BOOL bForceSetPreferredLanguage, B
{
if (XmlGetAttributeText (xml, "key", attr, sizeof (attr)))
{
key = AddPoolData (attr, strlen (attr) + 1);
if (key == NULL) return FALSE;
pkey = AddPoolData (attr, strlen (attr) + 1);
if (pkey == NULL) return FALSE;
XmlGetNodeText (xml, attr, sizeof (attr));
@ -371,7 +371,7 @@ static BOOL LoadLanguageData (int resourceid, BOOL bForceSetPreferredLanguage, B
case 'n': *out++ = 13; *out++ = 10; break;
default:
if (!bForceSilent)
MessageBoxA (0, key, "VeraCrypt: Unknown '\\' escape sequence in string", MB_ICONERROR);
MessageBoxA (0, pkey, "VeraCrypt: Unknown '\\' escape sequence in string", MB_ICONERROR);
return FALSE;
}
}
@ -386,7 +386,7 @@ static BOOL LoadLanguageData (int resourceid, BOOL bForceSetPreferredLanguage, B
if (len == 0)
{
if (!bForceSilent)
MessageBoxA (0, key, "VeraCrypt: Error while decoding UTF-8 string", MB_ICONERROR);
MessageBoxA (0, pkey, "VeraCrypt: Error while decoding UTF-8 string", MB_ICONERROR);
return FALSE;
}
@ -394,7 +394,7 @@ static BOOL LoadLanguageData (int resourceid, BOOL bForceSetPreferredLanguage, B
text = AddPoolData ((void *) wattr, len * 2);
if (text == NULL) return FALSE;
AddDictionaryEntry ((char *) key, 0, text);
AddDictionaryEntry ((char *)pkey, 0, text);
}
}

View File

@ -1,6 +1,10 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|ARM64">
<Configuration>Debug</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
@ -9,6 +13,10 @@
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|ARM64">
<Configuration>Release</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
@ -52,20 +60,29 @@
<ProjectGuid>{B896FE1F-6BF3-4F75-9148-F841829073D9}</ProjectGuid>
<Keyword>Win32Proj</Keyword>
<RootNamespace>Lzma</RootNamespace>
<ProjectName>Lzma</ProjectName>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>Windows7.1SDK</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
<WholeProgramOptimization>false</WholeProgramOptimization>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>Windows7.1SDK</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
<WholeProgramOptimization>false</WholeProgramOptimization>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v143</PlatformToolset>
<WholeProgramOptimization>false</WholeProgramOptimization>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
@ -73,14 +90,21 @@
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>false</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>Windows7.1SDK</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>false</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>Windows7.1SDK</PlatformToolset>
<PlatformToolset>v143</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>false</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v143</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
@ -91,24 +115,42 @@
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<OutDir>$(Configuration)\</OutDir>
<OutDir>$(ProjectDir)$(Configuration)\</OutDir>
<IntDir>$(ProjectDir)$(Configuration)\lzma\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<OutDir>$(Platform)\$(Configuration)\</OutDir>
<OutDir>$(ProjectDir)$(Platform)\$(Configuration)\</OutDir>
<IntDir>$(ProjectDir)$(Platform)\$(Configuration)\lzma\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<OutDir>$(ProjectDir)$(Platform)\$(Configuration)\</OutDir>
<IntDir>$(ProjectDir)$(Platform)\$(Configuration)\lzma\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<OutDir>$(Configuration)\</OutDir>
<OutDir>$(ProjectDir)$(Configuration)\</OutDir>
<IntDir>$(ProjectDir)$(Configuration)\lzma\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<OutDir>$(Platform)\$(Configuration)\</OutDir>
<OutDir>$(ProjectDir)$(Platform)\$(Configuration)\</OutDir>
<IntDir>$(ProjectDir)$(Platform)\$(Configuration)\lzma\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<OutDir>$(ProjectDir)$(Platform)\$(Configuration)\</OutDir>
<IntDir>$(ProjectDir)$(Platform)\$(Configuration)\lzma\</IntDir>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
@ -138,6 +180,20 @@
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<ClCompile>
<PrecompiledHeader>
</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
@ -148,6 +204,7 @@
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<ControlFlowGuard>Guard</ControlFlowGuard>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
@ -166,6 +223,26 @@
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<ControlFlowGuard>Guard</ControlFlowGuard>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>
</PrecompiledHeader>
<Optimization>MaxSpeed</Optimization>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<ControlFlowGuard>Guard</ControlFlowGuard>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>

View File

@ -1,257 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project DefaultTargets="Build" ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup Label="ProjectConfigurations">
<ProjectConfiguration Include="Debug|ARM64">
<Configuration>Debug</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|Win32">
<Configuration>Debug</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Debug|x64">
<Configuration>Debug</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|ARM64">
<Configuration>Release</Configuration>
<Platform>ARM64</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|Win32">
<Configuration>Release</Configuration>
<Platform>Win32</Platform>
</ProjectConfiguration>
<ProjectConfiguration Include="Release|x64">
<Configuration>Release</Configuration>
<Platform>x64</Platform>
</ProjectConfiguration>
</ItemGroup>
<ItemGroup>
<None Include="lzma\lzma-history.txt" />
<None Include="lzma\lzma-sdk.txt" />
</ItemGroup>
<ItemGroup>
<ClCompile Include="lzma\Alloc.c" />
<ClCompile Include="lzma\CpuArch.c" />
<ClCompile Include="lzma\LzFind.c" />
<ClCompile Include="lzma\LzFindMt.c" />
<ClCompile Include="lzma\LzFindOpt.c" />
<ClCompile Include="lzma\LzmaDec.c" />
<ClCompile Include="lzma\LzmaEnc.c" />
<ClCompile Include="lzma\LzmaLib.c" />
<ClCompile Include="lzma\Threads.c" />
</ItemGroup>
<ItemGroup>
<ClInclude Include="lzma\7zTypes.h" />
<ClInclude Include="lzma\7zWindows.h" />
<ClInclude Include="lzma\Alloc.h" />
<ClInclude Include="lzma\Compiler.h" />
<ClInclude Include="lzma\CpuArch.h" />
<ClInclude Include="lzma\LzFind.h" />
<ClInclude Include="lzma\LzFindMt.h" />
<ClInclude Include="lzma\LzHash.h" />
<ClInclude Include="lzma\LzmaDec.h" />
<ClInclude Include="lzma\LzmaEnc.h" />
<ClInclude Include="lzma\LzmaLib.h" />
<ClInclude Include="lzma\Precomp.h" />
<ClInclude Include="lzma\Threads.h" />
</ItemGroup>
<PropertyGroup Label="Globals">
<ProjectGuid>{B896FE1F-6BF3-4F75-9148-F841829073D9}</ProjectGuid>
<Keyword>Win32Proj</Keyword>
<RootNamespace>Lzma</RootNamespace>
<ProjectName>Lzma</ProjectName>
<WindowsTargetPlatformVersion>10.0</WindowsTargetPlatformVersion>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
<WholeProgramOptimization>false</WholeProgramOptimization>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
<WholeProgramOptimization>false</WholeProgramOptimization>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>true</UseDebugLibraries>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
<WholeProgramOptimization>false</WholeProgramOptimization>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>false</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>false</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="Configuration">
<ConfigurationType>StaticLibrary</ConfigurationType>
<UseDebugLibraries>false</UseDebugLibraries>
<WholeProgramOptimization>false</WholeProgramOptimization>
<CharacterSet>Unicode</CharacterSet>
<PlatformToolset>v142</PlatformToolset>
</PropertyGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
<ImportGroup Label="ExtensionSettings">
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'" Label="PropertySheets">
<Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" />
</ImportGroup>
<PropertyGroup Label="UserMacros" />
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<OutDir>$(ProjectDir)$(Configuration)\</OutDir>
<IntDir>$(ProjectDir)$(Configuration)\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<OutDir>$(ProjectDir)$(Platform)\$(Configuration)\</OutDir>
<IntDir>$(ProjectDir)$(Platform)\$(Configuration)\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<OutDir>$(ProjectDir)$(Platform)\$(Configuration)\</OutDir>
<IntDir>$(ProjectDir)$(Platform)\$(Configuration)\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<OutDir>$(ProjectDir)$(Configuration)\</OutDir>
<IntDir>$(ProjectDir)$(Configuration)\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<OutDir>$(ProjectDir)$(Platform)\$(Configuration)\</OutDir>
<IntDir>$(ProjectDir)$(Platform)\$(Configuration)\</IntDir>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<OutDir>$(ProjectDir)$(Platform)\$(Configuration)\</OutDir>
<IntDir>$(ProjectDir)$(Platform)\$(Configuration)\</IntDir>
</PropertyGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'">
<ClCompile>
<PrecompiledHeader>
</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'">
<ClCompile>
<PrecompiledHeader>
</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|ARM64'">
<ClCompile>
<PrecompiledHeader>
</PrecompiledHeader>
<WarningLevel>Level3</WarningLevel>
<Optimization>Disabled</Optimization>
<PreprocessorDefinitions>WIN32;_DEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreadedDebug</RuntimeLibrary>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>
</PrecompiledHeader>
<Optimization>MaxSpeed</Optimization>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<ControlFlowGuard>Guard</ControlFlowGuard>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>
</PrecompiledHeader>
<Optimization>MaxSpeed</Optimization>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<ControlFlowGuard>Guard</ControlFlowGuard>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
</Link>
</ItemDefinitionGroup>
<ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|ARM64'">
<ClCompile>
<WarningLevel>Level3</WarningLevel>
<PrecompiledHeader>
</PrecompiledHeader>
<Optimization>MaxSpeed</Optimization>
<FunctionLevelLinking>true</FunctionLevelLinking>
<IntrinsicFunctions>true</IntrinsicFunctions>
<PreprocessorDefinitions>WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions>
<RuntimeLibrary>MultiThreaded</RuntimeLibrary>
<ControlFlowGuard>Guard</ControlFlowGuard>
</ClCompile>
<Link>
<SubSystem>Windows</SubSystem>
<GenerateDebugInformation>true</GenerateDebugInformation>
<EnableCOMDATFolding>true</EnableCOMDATFolding>
<OptimizeReferences>true</OptimizeReferences>
</Link>
</ItemDefinitionGroup>
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
<ImportGroup Label="ExtensionTargets">
</ImportGroup>
</Project>

View File

@ -1,87 +0,0 @@
<?xml version="1.0" encoding="utf-8"?>
<Project ToolsVersion="4.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
<ItemGroup>
<Filter Include="Source Files">
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
<Extensions>cpp;c;cc;cxx;def;odl;idl;hpj;bat;asm;asmx</Extensions>
</Filter>
<Filter Include="Header Files">
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
<Extensions>h;hpp;hxx;hm;inl;inc;xsd</Extensions>
</Filter>
</ItemGroup>
<ItemGroup>
<None Include="lzma\lzma-history.txt" />
<None Include="lzma\lzma-sdk.txt" />
</ItemGroup>
<ItemGroup>
<ClCompile Include="lzma\Alloc.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="lzma\CpuArch.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="lzma\LzFind.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="lzma\LzFindMt.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="lzma\LzFindOpt.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="lzma\LzmaDec.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="lzma\LzmaEnc.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="lzma\LzmaLib.c">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="lzma\Threads.c">
<Filter>Source Files</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="lzma\7zTypes.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="lzma\Alloc.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="lzma\Compiler.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="lzma\CpuArch.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="lzma\LzFind.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="lzma\LzFindMt.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="lzma\LzHash.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="lzma\LzmaDec.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="lzma\LzmaEnc.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="lzma\LzmaLib.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="lzma\Precomp.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="lzma\Threads.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="lzma\7zWindows.h">
<Filter>Header Files</Filter>
</ClInclude>
</ItemGroup>
</Project>

Some files were not shown because too many files have changed in this diff Show More