Compare commits

..

6 Commits
v1.35 ... v1.40

Author SHA1 Message Date
Pete Batard
ad79094c30 Improve error handling and reporting when querying vlscppe.microsoft.com
* Also use a better default icon and add a preemptive localized message for
  future countermeasures from Microsoft.
2023-01-09 17:32:59 +00:00
Pete Batard
8cf4a279ff Work around Microsoft's new ISO download countermeasures
* The Microsoft servers now use session Id whitelisting, so add querying
  of https://vlscppe.microsoft.com/tags with the session Id.
* Closes #52.
* Also harmonize/improve -replace calls
* Also make sure we use POST for the getskuinformationbyproductedition
  query (in case Microsoft add some more countermeasures).
* Also drop 'cmd /c' invocation in sign.sh since the cygwin people can't
  seem to get their act together there...
2023-01-08 22:10:01 +00:00
Pete Batard
84f833b067 Improve error reporting
* Now return the error message from the Microsoft server where possible (See #52)
2023-01-06 21:58:20 +00:00
Pete Batard
c34a41fe3f Add UEFI Shell 2.2 22H2 download 2022-12-15 00:20:19 +00:00
Erik Dansbo
6593585ff3 Add an option to disable progress report for commandline
* Closes #50
2022-12-14 17:11:09 +00:00
Pete Batard
fac4c49262 Add Windows 10 22H2 builds
* And remove Windows 11 22H2 *v0* builds since Microsoft removed the ISOs from their servers
2022-10-19 13:48:03 +01:00
3 changed files with 74 additions and 50 deletions

121
Fido.ps1
View File

@@ -1,6 +1,6 @@
# #
# Fido v1.35 - Feature ISO Downloader, for retail Windows images and UEFI Shell # Fido v1.40 - Feature ISO Downloader, for retail Windows images and UEFI Shell
# Copyright © 2019-2022 Pete Batard <pete@akeo.ie> # Copyright © 2019-2023 Pete Batard <pete@akeo.ie>
# Command line support: Copyright © 2021 flx5 # Command line support: Copyright © 2021 flx5
# ConvertTo-ImageSource: Copyright © 2016 Chris Carter # ConvertTo-ImageSource: Copyright © 2016 Chris Carter
# #
@@ -24,7 +24,7 @@
#region Parameters #region Parameters
param( param(
# (Optional) The title to display on the application window. # (Optional) The title to display on the application window.
[string]$AppTitle = "Fido - Retail Windows ISO Downloader", [string]$AppTitle = "Fido - Feature ISO Downloader",
# (Optional) '|' separated UI localization strings. # (Optional) '|' separated UI localization strings.
[string]$LocData, [string]$LocData,
# (Optional) Path to a file that should be used for the UI icon. # (Optional) Path to a file that should be used for the UI icon.
@@ -45,7 +45,9 @@ param(
# (Optional) Only display the download URL [Toggles commandline mode] # (Optional) Only display the download URL [Toggles commandline mode]
[switch]$GetUrl = $False, [switch]$GetUrl = $False,
# (Optional) Increase verbosity # (Optional) Increase verbosity
[switch]$Verbose = $False [switch]$Verbose = $False,
# (Optional) Disable the progress bar
[switch]$DisableProgress = $False
) )
#endregion #endregion
@@ -103,11 +105,6 @@ $WindowsVersions = @(
@("Windows 11 Home/Pro/Edu", 2370), @("Windows 11 Home/Pro/Edu", 2370),
@("Windows 11 Home China ", ($zh + 2371)) @("Windows 11 Home China ", ($zh + 2371))
), ),
@(
"22H2 (Build 22621.382 - 2022.09)",
@("Windows 11 Home/Pro/Edu", 2360),
@("Windows 11 Home China ", ($zh + 2361))
),
@( @(
"21H2 v1 (Build 22000.318 - 2021.11)", "21H2 v1 (Build 22000.318 - 2021.11)",
@("Windows 11 Home/Pro/Edu", 2093), @("Windows 11 Home/Pro/Edu", 2093),
@@ -121,12 +118,11 @@ $WindowsVersions = @(
), ),
@( @(
@("Windows 10", "Windows10ISO"), @("Windows 10", "Windows10ISO"),
# Not yet enabled by Microsoft... @(
# @( "22H2 (Build 19045.2006 - 2022.10)",
# "22H2 (Build 1904?.???? - 2022.10)", @("Windows 10 Home/Pro/Edu", 2377),
# @("Windows 10 Home/Pro/Edu", 2377), @("Windows 10 Home China ", ($zh + 2378))
# @("Windows 10 Home China ", ($zh + 2378)) ),
# ),
@( @(
"21H2 (Build 19044.1288 - 2021.11)", "21H2 (Build 19044.1288 - 2021.11)",
@("Windows 10 Home/Pro/Edu", 2084), @("Windows 10 Home/Pro/Edu", 2084),
@@ -290,6 +286,11 @@ $WindowsVersions = @(
), ),
@( @(
@("UEFI Shell 2.2", "UEFI_SHELL 2.2"), @("UEFI Shell 2.2", "UEFI_SHELL 2.2"),
@(
"22H2 (edk2-stable202211)",
@("Release", 0),
@("Debug", 1)
),
@( @(
"22H1 (edk2-stable202205)", "22H1 (edk2-stable202205)",
@("Release", 0), @("Release", 0),
@@ -498,7 +499,7 @@ function ConvertTo-ImageSource
function Throw-Error([object]$Req, [string]$Alt) function Throw-Error([object]$Req, [string]$Alt)
{ {
$Err = $(GetElementById -Request $r -Id "errorModalMessage").innerText $Err = $(GetElementById -Request $Req -Id "errorModalMessage").innerText -replace "<[^>]+>" -replace "\s+", " "
if (-not $Err) { if (-not $Err) {
$Err = $Alt $Err = $Alt
} else { } else {
@@ -601,7 +602,7 @@ $RequestData["GetLangs"] = @("a8f8f489-4c7f-463a-9ca6-5cff94d8d041", "getskuinfo
# This GUID applies to visitors of the en-US download page. Other locales may get a different GUID. # This GUID applies to visitors of the en-US download page. Other locales may get a different GUID.
$RequestData["GetLinks"] = @("6e2a1789-ef16-4f27-a296-74ef7ef5d96b", "GetProductDownloadLinksBySku" ) $RequestData["GetLinks"] = @("6e2a1789-ef16-4f27-a296-74ef7ef5d96b", "GetProductDownloadLinksBySku" )
# Create a semi-random Linux User-Agent string # Create a semi-random Linux User-Agent string
$FirefoxVersion = Get-Random -Minimum 50 -Maximum 90 $FirefoxVersion = Get-Random -Minimum 90 -Maximum 110
$FirefoxDate = Get-RandomDate $FirefoxDate = Get-RandomDate
$UserAgent = "Mozilla/5.0 (X11; Linux i586; rv:$FirefoxVersion.0) Gecko/$FirefoxDate Firefox/$FirefoxVersion.0" $UserAgent = "Mozilla/5.0 (X11; Linux i586; rv:$FirefoxVersion.0) Gecko/$FirefoxDate Firefox/$FirefoxVersion.0"
$Verbosity = 2 $Verbosity = 2
@@ -616,7 +617,7 @@ if ($Cmd) {
# Localization # Localization
$EnglishMessages = "en-US|Version|Release|Edition|Language|Architecture|Download|Continue|Back|Close|Cancel|Error|Please wait...|" + $EnglishMessages = "en-US|Version|Release|Edition|Language|Architecture|Download|Continue|Back|Close|Cancel|Error|Please wait...|" +
"Download using a browser|Temporarily banned by Microsoft for requesting too many downloads - Please try again later...|" + "Download using a browser|Download of Windows ISOs is unavailable due to Microsoft having altered their website to prevent it.|" +
"PowerShell 3.0 or later is required to run this script.|Do you want to go online and download it?" "PowerShell 3.0 or later is required to run this script.|Do you want to go online and download it?"
[string[]]$English = $EnglishMessages.Split('|') [string[]]$English = $EnglishMessages.Split('|')
[string[]]$Localized = $null [string[]]$Localized = $null
@@ -709,6 +710,17 @@ function Get-Windows-Languages([int]$SelectedVersion, [int]$SelectedEdition)
} elseif ($WindowsVersions[$SelectedVersion][0][1].StartsWith("UEFI_SHELL")) { } elseif ($WindowsVersions[$SelectedVersion][0][1].StartsWith("UEFI_SHELL")) {
$languages += @(New-Object PsObject -Property @{ DisplayLanguage = "English (US)"; Language = "en-us"; Id = 0 }) $languages += @(New-Object PsObject -Property @{ DisplayLanguage = "English (US)"; Language = "en-us"; Id = 0 })
} else { } else {
# Microsoft download protection now requires the sessionId to be whitelisted through vlscppe.microsoft.com/tags
$url = "https://vlscppe.microsoft.com/tags?org_id=y6jn8c31&session_id=" + $SessionId
if ($Verbosity -ge 2) {
Write-Host Querying $url
}
try {
Invoke-WebRequest -UseBasicParsing -MaximumRedirection 0 -UserAgent $UserAgent $url | Out-Null
} catch {
Error($_.Exception.Message)
return @()
}
$url = "https://www.microsoft.com/" + $QueryLocale + "/api/controls/contentinclude/html" $url = "https://www.microsoft.com/" + $QueryLocale + "/api/controls/contentinclude/html"
$url += "?pageId=" + $RequestData["GetLangs"][0] $url += "?pageId=" + $RequestData["GetLangs"][0]
$url += "&host=www.microsoft.com" $url += "&host=www.microsoft.com"
@@ -723,7 +735,7 @@ function Get-Windows-Languages([int]$SelectedVersion, [int]$SelectedEdition)
$script:SelectedIndex = 0 $script:SelectedIndex = 0
try { try {
$r = Invoke-WebRequest -UseBasicParsing -UserAgent $UserAgent -SessionVariable "Session" $url $r = Invoke-WebRequest -Method Post -UseBasicParsing -UserAgent $UserAgent -SessionVariable "Session" $url
if ($r -match "errorModalMessage") { if ($r -match "errorModalMessage") {
Throw-Error -Req $r -Alt "Could not retrieve languages from server" Throw-Error -Req $r -Alt "Could not retrieve languages from server"
} }
@@ -810,7 +822,7 @@ function Get-Windows-Download-Links([int]$SelectedVersion, [int]$SelectedRelease
try { try {
$Is64 = [Environment]::Is64BitOperatingSystem $Is64 = [Environment]::Is64BitOperatingSystem
# Must add a referer for POST requests, else Microsoft's servers will deny them # Must add a referer for this request, else Microsoft's servers will deny it
$ref = "https://www.microsoft.com/software-download/windows11" $ref = "https://www.microsoft.com/software-download/windows11"
$wr = [System.Net.WebRequest]::Create($url) $wr = [System.Net.WebRequest]::Create($url)
# Windows 7 PowerShell doesn't support 'Invoke-WebRequest -Headers @{"Referer" = $ref}' # Windows 7 PowerShell doesn't support 'Invoke-WebRequest -Headers @{"Referer" = $ref}'
@@ -823,7 +835,15 @@ function Get-Windows-Download-Links([int]$SelectedVersion, [int]$SelectedRelease
$sr = New-Object System.IO.StreamReader($wr.GetResponse().GetResponseStream()) $sr = New-Object System.IO.StreamReader($wr.GetResponse().GetResponseStream())
$r = $sr.ReadToEnd() $r = $sr.ReadToEnd()
if ($r -match "errorModalMessage") { if ($r -match "errorModalMessage") {
Throw-Error -Req $r -Alt "Could not retrieve architectures from server" $regex = New-Object Text.RegularExpressions.Regex '<p id="errorModalMessage">(.+?)<\/p>'
$m = $regex.Match($r)
# Make the typical error message returned by Microsoft's servers more presentable
$Alt = $m.Groups[1] -replace "<[^>]+>" -replace "\s+", " "
$Alt += " " + $SessionId + "."
if (-not $Alt) {
$Alt = "Could not retrieve architectures from server"
}
Throw-Error -Req $r -Alt $Alt
} }
$pattern = '(?s)(<input.*?></input>)' $pattern = '(?s)(<input.*?></input>)'
ForEach-Object { [regex]::Matches($r, $pattern) } | ForEach-Object { $html += $_.Groups[1].value } ForEach-Object { [regex]::Matches($r, $pattern) } | ForEach-Object { $html += $_.Groups[1].value }
@@ -871,6 +891,9 @@ function Process-Download-Link([string]$Url)
$tmp_size = [uint64]::Parse($str_size) $tmp_size = [uint64]::Parse($str_size)
$Size = Size-To-Human-Readable $tmp_size $Size = Size-To-Human-Readable $tmp_size
Write-Host "Downloading '$File' ($Size)..." Write-Host "Downloading '$File' ($Size)..."
if ($DisableProgress) {
$ProgressPreference = 'SilentlyContinue'
}
Invoke-WebRequest -UseBasicParsing -Uri $Url -OutFile $File Invoke-WebRequest -UseBasicParsing -Uri $Url -OutFile $File
} else { } else {
Write-Host Download Link: $Url Write-Host Download Link: $Url
@@ -952,7 +975,7 @@ if ($Cmd) {
if (!$Ed -and $Verbosity -ge 1) { if (!$Ed -and $Verbosity -ge 1) {
Write-Host "No edition specified (-Ed). Defaulting to '$($edition.Edition)'." Write-Host "No edition specified (-Ed). Defaulting to '$($edition.Edition)'."
} }
$Selected += "," + $edition.Edition -replace "Windows [0-9\.]*", "" $Selected += "," + $edition.Edition -replace "Windows [0-9\.]*"
$winEditionId = $edition.Id $winEditionId = $edition.Id
break; break;
} }
@@ -1050,7 +1073,7 @@ $XMLForm.Title = $AppTitle
if ($Icon) { if ($Icon) {
$XMLForm.Icon = $Icon $XMLForm.Icon = $Icon
} else { } else {
$XMLForm.Icon = [Gui.Utils]::ExtractIcon("shell32.dll", -41, $true) | ConvertTo-ImageSource $XMLForm.Icon = [Gui.Utils]::ExtractIcon("imageres.dll", -5205, $true) | ConvertTo-ImageSource
} }
if ($Locale.StartsWith("ar") -or $Locale.StartsWith("fa") -or $Locale.StartsWith("he")) { if ($Locale.StartsWith("ar") -or $Locale.StartsWith("fa") -or $Locale.StartsWith("he")) {
$XMLForm.FlowDirection = "RightToLeft" $XMLForm.FlowDirection = "RightToLeft"
@@ -1188,8 +1211,8 @@ exit $ExitCode
# SIG # Begin signature block # SIG # Begin signature block
# MIIkWQYJKoZIhvcNAQcCoIIkSjCCJEYCAQExDzANBglghkgBZQMEAgEFADB5Bgor # MIIkWQYJKoZIhvcNAQcCoIIkSjCCJEYCAQExDzANBglghkgBZQMEAgEFADB5Bg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
# LgWGsxXn040/9cei5szi4Z4ltGUYI7gdNTYafRS/mCRbgfITpfzlpAzk07II # EJjcjiwTaR+PrDbskzu+knaphRGWkk8TmqKVLC3Zi/puTeDBafarunOPzXIV
# SIG # End signature block # SIG # End signature block

View File

@@ -87,6 +87,7 @@ The options are:
architecture as the one from the current system. architecture as the one from the current system.
- `GetUrl`: By default, the script attempts to automatically launch the download. But when using the `-GetUrl` switch, - `GetUrl`: By default, the script attempts to automatically launch the download. But when using the `-GetUrl` switch,
the script only displays the download URL, which can then be piped into another command or into a file. the script only displays the download URL, which can then be piped into another command or into a file.
- `DisableProgress`: Disable progress report. This may speed up downloads when using the command line.
Examples of a commandline download: Examples of a commandline download:

View File

@@ -21,7 +21,7 @@ sign_file() {
} }
# Update the Authenticode signature # Update the Authenticode signature
cmd.exe /c '"C:\Program Files (x86)\Windows Kits\10\bin\10.0.22000.0\x64\signtool" sign /v /sha1 3dbc3a2a0e9ce8803b422cfdbc60acd33164965d /fd SHA256 /tr http://sha256timestamp.ws.symantec.com/sha256/timestamp /td SHA256 Fido.ps1' MSYS2_ARG_CONV_EXCL='*' "C:\Program Files (x86)\Windows Kits\10\bin\10.0.22000.0\x64\signtool" sign /v /sha1 3dbc3a2a0e9ce8803b422cfdbc60acd33164965d /fd SHA256 /tr http://sha256timestamp.ws.symantec.com/sha256/timestamp /td SHA256 Fido.ps1
read -s -p "Enter pass phrase for `realpath $PRIVATE_KEY`: " PASSWORD read -s -p "Enter pass phrase for `realpath $PRIVATE_KEY`: " PASSWORD
echo echo
# Confirm that the pass phrase is valid by trying to sign a dummy file # Confirm that the pass phrase is valid by trying to sign a dummy file