Brand notebook Win10 PowerShell script activation system

The whole idea is that some brands of notebook will record the serial number of the original system in one chip, called on MSDM, after win10, powershell can display the serial number. Vbs activated using activation method using this sequence number.


cd C:\Windows\System32\

$ProductKey = (Get-WmiObject -query 'select * from SoftwareLicensingService').OA3xOriginalProductKey


if ($ProductKey.Length -ne 0) {

    cscript slmgr.vbs /ipk $ProductKey

    cscript slmgr.vbs /ato 

    slmgr.vbs -xpr

} else {

    msg /server:127.0.0.1 * "Activate failed, couldn't get product key."

}


Guess you like

Origin blog.51cto.com/181647568/2444510