Commit Graph

82 Commits

Author SHA1 Message Date
Pete Batard 3aac3f5583
[misc] improve Windows edition reporting
* Closes #1808
* Also update rufus-next to 3.18
2021-10-27 09:51:28 +01:00
Pete Batard 05382d8c7d
[core] ReFS improvements
* Allow 4K/64K cluster size selection
* Only enable ReFS on relevant platforms
* Also recognize a few more Windows editions
2021-10-21 02:02:17 +01:00
Pete Batard d8a2c29a67
[core] fix MBR cleanup regression
* Commit 9dc045a701 introduced a regression on account that we didn't set the
  file pointer to 0 before clearing the disk.
* This leads to the MBR not being properly cleared, with the result that Windows may in turn
  produce errors when trying to repartition the disk.
* Fix this by making sure we do invoke SetFilePointerEx() before calling WriteFileWithRetry().
* Also set rufus-next to 3.17
* Also fix a MinGW warning
2021-10-17 13:35:31 +01:00
Pete Batard 0b618f3de7
[misc] misc improvements and fixes
* Remove BypassRAMCheck from Extended Windows 11 installation since the minimum
  RAM requirements for Windows 11 are 4 GB and not 8 GB as pointed out in #1791.
* Display Windows edition code when we can't resolve it.
* VS2019 wants us to have PackageOptionalProjectsInIdeBuilds enabled? So be it.
2021-10-15 13:13:36 +01:00
Pete Batard b043db33e6
[core] add option to bypass TPM 2.0/Secure Boot/RAM requirements for Windows 11 ISOs
* If 'Extended Windows 11 Installation' mode is selected, the system registry hive of
  'sources\boot.wim' is patched to add the Setup\LabConfig registry keys that bypass
  the TPM 2.0/Secure Boot/8GB+ RAM Windows 11 system requirements.
2021-10-08 19:24:10 +01:00
Pete Batard aba6c7d996
[misc] small Windows versioning improvement
* Actually define a WINDOWS_11 version and use it when Windows 11 is detected.
* Also some comment cleanup.
2021-09-28 15:39:51 +01:00
Pete Batard d203c91403
[core] report Windows edition
* Also use build number to detect Windows Server 2019 and Windows 11
  since Microsoft are COMPLETE ASSES about their version reporting.
* Also fix a compilation warning.
2021-09-26 16:20:46 +01:00
Pete Batard 2e1833e91e
[misc] improve CoInitialize calls
* Balance with CoUninitialize and add COINIT_DISABLE_OLE1DDE
* Also add /BREPRO linker flag for reproducible VS2019 release builds
2021-04-09 12:36:30 +01:00
Pete Batard b3caf638b6
[misc] miscellaneous code cleanup and fixes
* Don't use hDrive handle for longer than necessary
* Move all the popcount() function calls into missing.h
* Ensure that the thread_affinity[] array is properly sized
* Improve timeouts for conflicting process search
2020-09-09 17:00:39 +01:00
Pete Batard 3d1ec358b5
[core] improve protective MBR for GPT media
* Use the upgraded msg.bin MBR along with its more comprehensive message.
* Also fixes and issue in GetResource().
2020-02-19 19:51:32 +00:00
Pete Batard b8579c04da
[misc] add arbitrary buffer allocation to GetResource()
* If duplicate is TRUE and len is non-zero, then a buffer of len size,
  padded with zeroes, is allocated for the resource.
2020-02-19 12:43:05 +00:00
Pete Batard fa8be68c54
[misc] display Windows Update Build Revision (UBR) when available
Yet another link in the long chain of Microsoft making it UNFATHOMABLY DIFFICULT
to figure out what version of Windows an application is actually running on...
2019-11-14 22:43:24 +00:00
Pete Batard 4c816a519e
[misc] update license URLs and align ms-sys's write_data buffer to 4K
* Also remove some obsolete TODOs
2019-09-06 11:32:37 +01:00
Pete Batard 0c368b4e69
[loc] finalize translations for 3.5
* Also update for latest Fido and simplify SetLGP
2019-03-12 19:53:25 +00:00
Pete Batard e073fb47b0
[net] add Windows retail ISO downloads
* This is accomplished through Fido (https://github.com/pbatard/Fido), a *SIGNED*
  PowerShell script, that is downloaded from GitHub and that resides in memory for
  the duration of a session.
* The reason we use a downloaded PS script, rather than an embedded on, is because:
  - Microsoft have regularly been changing the deal with regards to how retail ISOs
    can be downloaded, and not for the better, so we can't simply embed a static
    means of downloading ISOs and expect that to work forever.
  - By using an external script, we can immediately respond to whatever new means of
    *ANNOYING* their legitimate users Microsoft will come up with next, as well as
    make sure that, the minute a new retail version of Windows becomes available, it
    also becomes available for download in Rufus.
* Note that if you are concerned about downloading a remote PS script that is being
  run at the same level as an elevated application, you should understand that:
  - Only scripts downloaded from GitHub, from an account that is protected with 2FA,
    are allowed to run (i.e. someone would first have to steal a *physical* 2FA key
    to be in a position to upload a malicious script).
  - On top of this, only scripts that are signed with a separate private key (RSA +
    AES-256), that is itself also protected with a strong unique password which only
    a single person knows (and must manually enter each time they want to make a new
    version of the script available for download), are allowed to run.
  The above means that there's about as much chance for someone to manage to upload
  a malicious script on the GitHub servers, that Rufus would allow to run, as there
  is for someone to upload a malicious version of Rufus itself.
  Still, if you are paranoid and have concerns that, even as you can validate from
  its source that Rufus does not attempt to execute any remote script unless a user
  actively selected and clicked the DOWNLOAD button, you can also completely disable
  the remote script download feature, if you just set the update check to disabled
  (which, by the way, Rufus *EXPLICITLY* asks you to choose whether you want to
  enable or not, the very first time you run the application).
* Also remove _unlinkU() which duplicates what DeleteFileU() already does.
2019-03-02 23:34:32 +00:00
Pete Batard f98c243eb8
[iso] fix crash when opening Windows ISOs
* Closes #1268
* Issue was introduced in 521034da99 and has
  to do with VS2017's handling of static strings in RELEASE mode.
  Fix is to use a static char array instead.
* Also fix MinGw build warnings and increase process search timeout
2019-01-31 13:50:03 +00:00
Pete Batard 326ae54f45
[togo] add a notice about WppRecorder.sys BSOD with 1809 ISOs
* Also improve detection of build number
2019-01-30 17:15:25 +00:00
Pete Batard 081d7b3a0b
[misc] remove the need for endpoint duplication in RunCommand() 2019-01-30 00:21:50 +00:00
Pete Batard 336e24c8c7
[loc] drop GetMuiString() and use formal loc data instead
* Relying on system MUIs was too brittle and provides us with no guarantee
  that the translated messages we need will actually be there.
* Also fix space before question mark in French translation.
2019-01-09 15:53:44 +00:00
Pete Batard 7757cab3c5 [ui] fix possible truncation of short image path
* Closes #1233
* Also fix MinGW builds due to missing PROCESSOR_ARCHITECTURE_ARM64 define
2018-10-22 22:28:20 +01:00
Pete Batard 6109d91c38 [net] add automated update support for ARM/ARM64 2018-10-22 17:42:40 +01:00
Pete Batard 05f8400451 [misc] reorganize UI function calls into their own source
* Also fix ARM/ARM64 broken compilation due to missing __popcnt()
2018-07-06 05:46:36 +01:00
Pete Batard 8238de67e1 [ui] fix more potential notification message truncation
* Some Thai UTF-8 notification messages went over the buffer size limit we used for vsnprintf()
* Also, revert part of 645184f11e and use LRE+PDF marks instead:
  Don't handle in the code what is better handled in the loc file.
2018-06-08 16:29:41 +01:00
Pete Batard 645184f11e [ui] fix some unwanted display of LTR or RTL strings
* Some English messages could appear RTL in the log
* Folder paths with RTL strings could appear scrambled in the UI
2018-06-07 22:30:53 +01:00
Pete Batard 1dbbe69a4b [ui] improve partition scheme default selection
* Also rename our variable to PartitionStyle/ps for clarity
2018-03-26 19:06:55 +01:00
Pete Batard a44518355f [ui] UI redesign
* Better guide the user through the flow of operations
* Also follow a concept design by Fahad Al-Riyami
* Closes #117
2018-03-22 23:14:21 +00:00
Pete Batard 903ac993f2 [misc] remove no longer needed XP workarounds 2017-11-13 14:30:25 +00:00
ip_gpu fa94abcc8e [misc] fix a potential resource leak
* IsFontAvailable() could exit without releasing its 'hDC' handle resulting in a resource leak
* Fix V773 from PSV-Studio
* Closes #1050
2017-10-28 19:01:49 +01:00
Pete Batard 8286a0f63a [core] add a cheat mode to reset the current USB device (cycle port)
* Will not work on Vista, Windows 7 or Server 2008
* Also update Windows version info
2017-09-15 13:56:01 +01:00
Pete Batard 90dc847e24 [misc] add static_strcat & static_strcpy and use static_ calls wherever possible
* Also set Rufus next to 2.17 and fix a warning
2017-08-10 19:43:52 +01:00
Pete Batard b4a2c06a2e [ui] ask user if they want proceed when conflicting processes are found
* Rufus now checks for processes with handles opened on the drives/volumes before
  starting the format operation and asks the user if they want to continue.
* This mimics Windows' behaviour when formatting drives, and actually uses the
  same message as the one from shell32.dll.mui.
* Closes #773
2017-07-16 22:42:19 +01:00
Pete Batard d1927ac1ef [core] handle search improvements
* Fix memory leaks due to not releasing the heap
* Also speed up lookups by not reopening the same process twice in a row
* Also make the usb_debug variable global so we can use uuprintf everywhere
2017-04-29 17:14:16 +01:00
Pete Batard d5f6ddb653 [core] list potentially blocking processes on disk access error
* Using functionality from Process Hacker:
  https://github.com/processhacker2/processhacker2/
* Part of the #773 enhancement
* Also fix minor MinGW and WDK warnings
2017-04-27 23:06:42 +01:00
Pete Batard 55b7d5c2da [misc] code cleanup
* Also fix WDK compilation issues
2017-04-25 20:25:50 +01:00
Pete Batard afec69c428 [ui] improve logging data
* Display the selected locate as well as LGP info in the log
* Also fix some potential Coverity warnings
2017-04-25 14:32:19 +01:00
Pete Batard aec2736245 [togo] improve Windows To Go support for Windows 10 Creators Update
* Enable the use of GPT on REMOVABLE drives, if the host is Windows 10 CU
* Don't display the message about REMOVABLE boot, if the target is Windows 10 CU
2017-04-19 11:30:24 +01:00
Pete Batard 7d302d340f [togo] enable selection of Windows version
* Closes #847
* Also set rufus-next to 2.12
2016-12-13 14:26:27 +00:00
Pete Batard 9dd06e93bc [ui] improve Windows format prompt autoclose
* Closes #794
* Also reorder some messages (so that RUFUS_TEST comes first)
* Also update issue template
2016-07-09 16:20:58 +01:00
Pete Batard b9da0cf057 [ui] fix missing partition scheme tooltip after selecting an ISO
* Tooltips can only be manipulated from the same thread as the one that created their parent
* Also increase the SetLGP() timeout as this seems to be problematic
* Closes #764
2016-05-30 17:32:49 +01:00
Pete Batard 3fe6894f8b [misc] increase SetLGP thread wait delay
* Someone running Rufus in a VirtualBox environment, where their CPU
  was also seeing 100% usage, reported getting the following message:
  "SetLGP: Killing stuck thread!"
2016-03-17 21:56:36 +00:00
Pete Batard 5afffd1018 [checksum] additional cleanup and optimization
* Use the commonly used function names for SHA-256 (Sigma, etc.)
* Use the same xxx_write for all, and avoid unwarranted memcpy
* Remove the bitcount
* Use nested ROR() speedup
2016-03-05 21:20:09 +00:00
Pete Batard 71520baf31 [core] factorize the img/zero disk writing code
* Also fix a WDK warning
2016-03-04 16:34:50 +00:00
Pete Batard d385a097c0 [misc] make the affinity setup fn more generic and move it to stdfn
* Also align checksum context to 64 bytes (cache line)
2016-03-03 17:24:54 +00:00
Pete Batard c3f47ada06 [misc] add missing.h header
* Also clean up code
2016-02-20 22:52:32 +00:00
Pete Batard 0fe0086c8f [core] improve WriteFileWithRetry() and move it to stdio.c
* Also fix uprintf() generating an error code if the log window
  is not instantiated yet.
2016-01-15 12:26:31 +00:00
Pete Batard f2a539a48c [core] add and use WriteFileWithRetry() where possible 2016-01-14 17:43:02 +00:00
Pete Batard 0f56c2d1ef [ui] use 'Segoe UI Symbol' when available
* This is required to display Thai in RTF fields (#217)
* Also fix the position of the Advanced groupbox
2015-12-30 15:27:52 +01:00
Pete Batard 4a5aa4bd2f [misc] add build number to Windows version for Windows 8 or later
* Also set rufus-next to 2.5
2015-09-30 23:08:07 +01:00
Pete Batard d1eccbd107 [togo] fix bcdboot errors
* Closes #558
2015-08-23 17:03:35 +01:00
Pete Batard 485b016f17 [internal] use DialogIndirect to reduce the number of dialogs in the RC
* Since Microsoft forces our hand, we hack away into our compiled RC
  resources and change dialog attributes on the fly so that:
  - we can switch between LTR & RTL
  - change the font for Windows XP
* Note that the base RC font has been changed to "Segoe UI Symbols"
  so that it looks the same in the editor (at least for English) but
  can accommodate the length required for "MS Shell Dlg"
2015-07-04 18:27:15 +01:00