Back home
中文
H7 / SECURITY RESEARCH NOTES

Collecting Information on windows with powershell and Saving It to the File System as html

Environment

IPHOSTNAMENOTE
10.10.10.88win10_dqyTest host

Reproduction Process

The PowerShell Script Is as Follows:

$bios_info = Get-WmiObject -Class Win32_BIOS;

$file_path = "$pwd\test_poc.html";
New-Item $file_path -ItemType File;
$output = "<html>$bios_info</html>";
Set-Content $file_path $output;

Execution Result

  • Collect BIOS information and save it as test_poc.html in the current path.