Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion lib/engines/hckinstall/kits/HLK2022.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,8 @@
"FOD_2022",
"Test-NETHLK",
"winfsp",
"NDIS_Driver_Fix"
"NDIS_Driver_Fix",
"autoit"
],
"studio_platform": "Win2019x64",
"name": "HLK2022"
Expand Down
3 changes: 1 addition & 2 deletions lib/engines/hcktest/drivers/Balloon.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
"support": false,
"reject_test_names": [
"DF - Embedded Signature Verification Test (Certification)",
"DF - Embedded Signature Verification Test (Tuning and Validation)",
"Hardware-enforced Stack Protection Compatibility Test"
"DF - Embedded Signature Verification Test (Tuning and Validation)"
]
}
3 changes: 1 addition & 2 deletions lib/engines/hcktest/drivers/NetKVM.json
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,6 @@
"PrivateCloudSimulator - Device.Network.LAN.10GbOrGreater",
"Run RSC Tests",
"DF - Embedded Signature Verification Test (Certification)",
"DF - Embedded Signature Verification Test (Tuning and Validation)",
"Hardware-enforced Stack Protection Compatibility Test"
"DF - Embedded Signature Verification Test (Tuning and Validation)"
]
}
3 changes: 0 additions & 3 deletions lib/engines/hcktest/drivers/alinvme.json
Original file line number Diff line number Diff line change
Expand Up @@ -39,9 +39,6 @@
}
]
}
],
"reject_test_names": [
"Hardware-enforced Stack Protection Compatibility Test"
]
}

5 changes: 1 addition & 4 deletions lib/engines/hcktest/drivers/fwcfg64.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,5 @@
"inf": "fwcfg.inf",
"install_method": "PNP",
"type": 0,
"support": false,
"reject_test_names": [
"Hardware-enforced Stack Protection Compatibility Test"
]
"support": false
}
3 changes: 1 addition & 2 deletions lib/engines/hcktest/drivers/igb.json
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,6 @@
],
"reject_test_names": [
"NDISTest 6.5 - [2 Machine] - VMQReceiveQueueStateChecking",
"NDISTest 6.5 - [2 Machine] - VMQPowerManagement",
"Hardware-enforced Stack Protection Compatibility Test"
"NDISTest 6.5 - [2 Machine] - VMQPowerManagement"
]
}
3 changes: 1 addition & 2 deletions lib/engines/hcktest/drivers/ivshmem.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
"support": false,
"reject_test_names": [
"DF - Embedded Signature Verification Test (Certification)",
"DF - Embedded Signature Verification Test (Tuning and Validation)",
"Hardware-enforced Stack Protection Compatibility Test"
"DF - Embedded Signature Verification Test (Tuning and Validation)"
]
}
3 changes: 1 addition & 2 deletions lib/engines/hcktest/drivers/ovpn-dco-win.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@
"type": 0,
"support": false,
"reject_test_names": [
"Static Tools Logo Test",
"Hardware-enforced Stack Protection Compatibility Test"
"Static Tools Logo Test"
]
}
3 changes: 1 addition & 2 deletions lib/engines/hcktest/drivers/pvpanic.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
"support": false,
"reject_test_names": [
"DF - Embedded Signature Verification Test (Certification)",
"DF - Embedded Signature Verification Test (Tuning and Validation)",
"Hardware-enforced Stack Protection Compatibility Test"
"DF - Embedded Signature Verification Test (Tuning and Validation)"
]
}
3 changes: 1 addition & 2 deletions lib/engines/hcktest/drivers/viofs.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
"support": false,
"reject_test_names": [
"DF - Embedded Signature Verification Test (Certification)",
"DF - Embedded Signature Verification Test (Tuning and Validation)",
"Hardware-enforced Stack Protection Compatibility Test"
"DF - Embedded Signature Verification Test (Tuning and Validation)"
]
}
3 changes: 1 addition & 2 deletions lib/engines/hcktest/drivers/viogpu.json
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
"Test for EDID Requirements (Manual)",
"Multimon minimum resolution check - Multihead",
"WDDM HPD Notification Test (Manual)",
"Check Resolution for Dualview (WoW64) - multihead",
"Hardware-enforced Stack Protection Compatibility Test"
"Check Resolution for Dualview (WoW64) - multihead"
]
}
3 changes: 1 addition & 2 deletions lib/engines/hcktest/drivers/vioinput.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
"support": false,
"reject_test_names": [
"DF - Embedded Signature Verification Test (Certification)",
"DF - Embedded Signature Verification Test (Tuning and Validation)",
"Hardware-enforced Stack Protection Compatibility Test"
"DF - Embedded Signature Verification Test (Tuning and Validation)"
]
}
5 changes: 1 addition & 4 deletions lib/engines/hcktest/drivers/viomem.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,5 @@
"inf": "viomem.inf",
"install_method": "PNP",
"type": 0,
"support": false,
"reject_test_names": [
"Hardware-enforced Stack Protection Compatibility Test"
]
"support": false
}
3 changes: 1 addition & 2 deletions lib/engines/hcktest/drivers/viorng.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
"support": false,
"reject_test_names": [
"DF - Embedded Signature Verification Test (Certification)",
"DF - Embedded Signature Verification Test (Tuning and Validation)",
"Hardware-enforced Stack Protection Compatibility Test"
"DF - Embedded Signature Verification Test (Tuning and Validation)"
]
}
3 changes: 1 addition & 2 deletions lib/engines/hcktest/drivers/vioscsi.json
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,6 @@
"reject_test_names": [
"DF - Embedded Signature Verification Test (Certification)",
"DF - Embedded Signature Verification Test (Tuning and Validation)",
"DF - Reboot Restart with IO During (Reliability)",
"Hardware-enforced Stack Protection Compatibility Test"
"DF - Reboot Restart with IO During (Reliability)"
]
}
3 changes: 1 addition & 2 deletions lib/engines/hcktest/drivers/vioserial.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
"support": false,
"reject_test_names": [
"DF - Embedded Signature Verification Test (Certification)",
"DF - Embedded Signature Verification Test (Tuning and Validation)",
"Hardware-enforced Stack Protection Compatibility Test"
"DF - Embedded Signature Verification Test (Tuning and Validation)"
]
}
3 changes: 1 addition & 2 deletions lib/engines/hcktest/drivers/viosock.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@
"support": false,
"reject_test_names": [
"DF - Embedded Signature Verification Test (Certification)",
"DF - Embedded Signature Verification Test (Tuning and Validation)",
"Hardware-enforced Stack Protection Compatibility Test"
"DF - Embedded Signature Verification Test (Tuning and Validation)"
]
}
3 changes: 1 addition & 2 deletions lib/engines/hcktest/drivers/viostor.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,6 @@
"Thin Provisioning SCSI Compliance Test (LOGO)",
"Thin Provisioning Performance Test - RAW Disk (LOGO)",
"Thin Provisioning Performance Test - NTFS (LOGO)",
"Thin Provisioning Threshold and Resource Exhaustion Test (LOGO)",
"Hardware-enforced Stack Protection Compatibility Test"
"Thin Provisioning Threshold and Resource Exhaustion Test (LOGO)"
]
}
26 changes: 26 additions & 0 deletions lib/engines/hcktest/hcktest.json
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,32 @@
"value": "C:\\Windows\\mib.bin"
}
]
},
{
"tests": ["Hardware-enforced Stack Protection Compatibility Test"],
"pre_test_commands": [
{
"desc": "Upload HSP watcher script",
"files_action": [
{
"local_path": "lib/engines/hcktest/scripts/autoit/hsp_watcher.au3",
"remote_path": "C:\\UIAgent\\autoit\\hsp_watcher.au3",
"direction": "local-to-remote"
}
]
},
{
"desc": "Set HSP watcher to start on any user logon and reboot to activate",
"guest_run": "New-ItemProperty -Path 'HKLM:\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run' -Name 'AutoHCK_UIWatcher' -Value '\"C:\\Program Files (x86)\\AutoIt3\\AutoIt3.exe\" \"C:\\UIAgent\\autoit\\hsp_watcher.au3\"' -PropertyType String -Force",
"guest_reboot": true
}
],
"post_test_commands": [
{
"desc": "Stop and remove HSP watcher",
"guest_run": "Remove-ItemProperty -Path 'HKLM:\\SOFTWARE\\Microsoft\\Windows\\CurrentVersion\\Run' -Name 'AutoHCK_UIWatcher' -ErrorAction SilentlyContinue; Stop-Process -Name AutoIt3 -Force -ErrorAction SilentlyContinue; exit 0"
}
]
}
]
}
52 changes: 52 additions & 0 deletions lib/engines/hcktest/scripts/autoit/hsp_watcher.au3
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
#NoTrayIcon
#include <AutoItConstants.au3>

Opt("WinTitleMatchMode", 2)
HotKeySet("+{ESC}", "Terminate")

Global $hspDone = False
Global $ignoredCmds = "|"

ConsoleWrite("[" & @HOUR & ":" & @MIN & ":" & @SEC & "] HSP Watcher Started..." & @CRLF)

While 1
If Not $hspDone And WinExists("C:\Windows\SYSTEM32\cmd.exe") Then
Local $hWnd = WinGetHandle("C:\Windows\SYSTEM32\cmd.exe")

If Not StringInStr($ignoredCmds, "|" & $hWnd & "|") Then
WinActivate($hWnd)
WinWaitActive($hWnd, "", 2)
Comment thread
kostyanf14 marked this conversation as resolved.

Local $bakClip = ClipGet()
ClipPut("")

Send("^a")
Sleep(100)
Send("{ENTER}")
Sleep(200)

Local $winText = ClipGet()
ClipPut($bakClip)

If StringInStr($winText, "Hardware-enforced") Then
ConsoleWrite("[" & @HOUR & ":" & @MIN & ":" & @SEC & "] Confirmed HSP test window, sending Y..." & @CRLF)
Send("{ESC}")
Sleep(100)
Send("Y")
Sleep(200)
Send("{ENTER}")
$hspDone = True
Sleep(5000)
Else
Send("{ESC}")
$ignoredCmds &= $hWnd & "|"
EndIf
EndIf
EndIf

Sleep(200)
WEnd

Func Terminate()
Exit
EndFunc
5 changes: 5 additions & 0 deletions lib/engines/hcktest/tests.rb
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,11 @@ def run_guest_test_command(command, replacement)

run_command_on_client(@client, command.guest_run, command.desc, replacement)
run_command_on_client(@support, command.guest_run, command.desc, replacement) unless @support.nil?

return unless command.guest_reboot

@logger.info("Rebooting client #{@client.name} after command (#{command.desc})")
@tools.restart_machine(@client.name)
end

def run_host_test_command(command)
Expand Down
Loading