first, in low level, all operation managed by GUID, not partial product KEY, or else. let's say i want remove License or product key, i pass Guid, who belond to specifc product {SKU} that i want to remove SLC.dll offer function to convert one type to another SKU - GUID -> to this other type's Code: "SL_ID_APPLICATION" -> mainly know as WindowsAppID & OfficeAppID ~~~~~~~~~~~~~~~~~~~~~~~~ "SL_ID_PRODUCT_SKU", ID under Main Application ~~~~~~~~~~~~~~~~~~~~~~~~ "SL_ID_LICENSE", Don't know what used for Yet "SL_ID_PKEY", GUID that we receive after install Product Key, mainly use for remove Product KEY "SL_ID_LICENSE_FILE", Guid for uninstall license blob function ~~~~~~~~~~~~~~~~~~~~~~~~ For Application ID ONLY ~~~~~~~~~~~~~~~~~~~~~~~~ "SL_ID_ALL_LICENSES", "SL_ID_ALL_LICENSE_FILES", So, main function that do the Convert, is SLGetSLIDList, which offical supprot by MS, but, there is also other function's. Offical & Not offical. Let's start with the offical One's, it fail to convert SKU_ID to SL_ID_LICENSE_FILE but do let you receive All SL_ID_LICENSE_FILE GUID, so, you can remove all license's per APP { WINDOWS APP / OFFICE APP} and if you want remove ProductKEY, it does let's you get PKEY guid from SKU Another offical function, to Get PKEY Guid from SKU, {for remove with other SLC API } is SLGetInstalledProductKeyIds, and if you have actualy whole product key you can use SLGetPKeyId to get Pkey guid, and pass it to API. now let's go to un document on'e -> SLGetProductSkuInformation, first i say it in TSforge, didn't understand too much, after much resaerch. found even more hidden gem's Code: "fileId", # SL_ID_LICENSE_FILE "pkeyId", # SL_ID_PKEY "pkeyIdList" # SL_ID_PKEY [Same] "productSkuId", # SL_ID_PRODUCT_SKU "applicationId" # SL_ID_APPLICATION "licenseId", # SL_ID_LICENSE "privateCertificateId" # SL_ID_LICENSE this one convert any to any, include Single SKU to SL_ID_LICENSE_FILE that the offical one don't support. what does it matter, well,you can remove now A specific SKU before that, you would remove store file, and re install all license's, no, you can locate SKU per Product, Convert SKU -> LICENSE FILE ID -> remove it
let's say you sociopath crazy person, who want to remove windows key, without know current key. we can use janek2012's magic decoding Function, to decode --> HKLM:\SOFTWARE\Microsoft\Windows NT\CurrentVersion --> DigitalProductId4 at offset 808 [part of BCDKEY] Code: struct DigitalProductId4 { unsigned int uiSize; unsigned short MajorVersion; unsigned short MinorVersion; WCHAR szAdvancedPid[64]; WCHAR szActivationId[64]; WCHAR szOemID[8]; WCHAR szEditionType[260]; BYTE bIsUpgrade; BYTE bReserved[7]; BYTE bCDKey[16]; than get Windows Current Product Key, Use SLGetPKeyId to get PKEY GUID, from current Product Key than call SLUninstallProofOfPurchase to remove current windows Product Key it dumb, stupid, but worked. i tried it. the most hard way to remove Windows product Key.
Another way, to remove you own windows key,without know it, i can get creative ... when i want. Extract SKU from value of Pro' Security-SPP-Action-StateData using API ---> --> RtlInitUnicodeString, ZwQueryLicenseValue Api.if you want higher API, can use SLGetWindowsInformation instead Get Pkey GUID from SKU GUID using SLGetInstalledProductKeyIds, Remove using SLUninstallProofOfPurchase