EasyManua.ls Logo

Rohde & Schwarz R&S Trusted Disk 3.3.1 - Stealth Mode PowerShell Script (UEFI;GPT)

Rohde & Schwarz R&S Trusted Disk 3.3.1
49 pages
To Next Page IconTo Next Page
To Next Page IconTo Next Page
To Previous Page IconTo Previous Page
To Previous Page IconTo Previous Page
Loading...
Appendix
45Administration manual 4603.7988.02 ─ 03
17. To confirm, click "Yes".
18. Click "Apply".
19. Exit the UEFI.
7.2 Stealth mode PowerShell script (UEFI/GPT)
bcdedit /export bcd-boot.Save
bcdedit /enum '{bootmgr}' /v > info.txt
$store = Get-Content info.txt
$print = $false
$result = @()
foreach ($line in $store)
{
if ($line.StartsWith("displayorder"))
{
$print = $true
}
elseif (-Not $line.StartsWith(" "))
{
$print = $false
}
if ($print)
{
$data = $line.Split(" ");
foreach ($word in $data)
{
if ($word.StartsWith("{"))
{
$result += $word
}
}
}
}
mountvol s: /s
[int] $lfdNr = 1
foreach ($id in $result)
{
$name = 'bcd-boot.'+ $lfdNr
bcdedit /export $name
bcdedit /store $name /bootsequence $id
$target = 'S:\\EFI\\Microsoft\\Boot\\' + $name
copy $name $target
$lfdNr += 1
Stealth mode PowerShell script (UEFI/GPT)

Table of Contents