Add partial support (zcid, rtmr, non-functional kms4k) for vista

Co-authored-by: InvoxiPlayGames <22731889+InvoxiPlayGames@users.noreply.github.com>
This commit is contained in:
2025-03-01 02:01:39 -05:00
parent 8aa1f9078d
commit 6d759899d8
24 changed files with 1023 additions and 347 deletions

View File

@ -7,7 +7,7 @@ namespace LibTSforge.Modifiers
public static class KMSHostCharge
{
public static void Charge(PSVersion version, Guid actId, bool production)
public static void Charge(PSVersion version, bool production, Guid actId)
{
if (actId == Guid.Empty)
{
@ -52,46 +52,46 @@ namespace LibTSforge.Modifiers
writer.Write((byte)currClients);
byte[] reqCounts = writer.GetBytes();
Utils.KillSPP();
SPPUtils.KillSPP(version);
Logger.WriteLine("Writing TrustedStore data...");
using (IPhysicalStore store = Utils.GetStore(version, production))
using (IPhysicalStore store = SPPUtils.GetStore(version, production))
{
VariableBag kmsCountData = new VariableBag();
kmsCountData.Blocks.AddRange(new CRCBlock[]
VariableBag kmsCountData = new VariableBag(version);
kmsCountData.Blocks.AddRange(new CRCBlockModern[]
{
new CRCBlock
new CRCBlockModern
{
DataType = CRCBlockType.BINARY,
KeyAsStr = "SppBindingLicenseData",
Value = hwidBlock
},
new CRCBlock
new CRCBlockModern
{
DataType = CRCBlockType.UINT,
Key = new byte[] { },
ValueAsInt = (uint)totalClients
},
new CRCBlock
new CRCBlockModern
{
DataType = CRCBlockType.UINT,
Key = new byte[] { },
ValueAsInt = 1051200000
},
new CRCBlock
new CRCBlockModern
{
DataType = CRCBlockType.UINT,
Key = new byte[] { },
ValueAsInt = (uint)currClients
},
new CRCBlock
new CRCBlockModern
{
DataType = CRCBlockType.BINARY,
Key = new byte[] { },
Value = cmidGuids
},
new CRCBlock
new CRCBlockModern
{
DataType = CRCBlockType.BINARY,
Key = new byte[] { },