For Windows Vista, 7 and 8, MAK's Edition type is almost (?) always null so my The Ultimate PID Checker (and VAMT too) is getting the Edition from pkconfig's xml data. The easiest way to do so is getting it while looking for product description (see codes posted earlier) and if it's found and your edition is = null, then assign the Edition value from pkconfig xml to your edition variable
Check the pkeyconfig file (after base64 decode). Here is a part of it: Code: <Configuration> <ActConfigId>{949d6b86-bfa7-4ff1-b4df-17e67bb6320d}</ActConfigId> --- Look for this value to get Description and Edition <RefGroupId>1785</RefGroupId> <EditionId>Professional;ProfessionalN;Enterprise;EnterpriseN</EditionId> --- Grab this value as Edition if it's null <ProductDescription>Win 8 RTM Professional;ProfessionalN;Enterprise;EnterpriseN Volume:MAK</ProductDescription> --- Grab this value as Desctiption <ProductKeyType>Volume:MAK</ProductKeyType> <IsRandomized>false</IsRandomized> </Configuration> Here is my code for GetDescription + Edition + RefGroupId: Code: String GetDescription(String aid, String &edi, String pkeyconfig, String &cid) { CoInitialize(NULL); Form5->XMLDocument1->XML->LoadFromFile(pkeyconfig); Form5->XMLDocument1->Active = true; IXMLNode *TempNode = NULL; UnicodeString prefix = ""; aid = ("{"+aid+"}").LowerCase(); UnicodeString configurations; UnicodeString actconfigid; UnicodeString editionid; UnicodeString productdescription; UnicodeString refgroupid; if(Form5->XMLDocument1->DocumentElement->ChildNodes->FindNode("r:license")) { TempNode = Form5->XMLDocument1->DocumentElement->ChildNodes->FindNode("r:license"); if (TempNode->ChildNodes->FindNode("r:otherInfo")) { TempNode = TempNode->ChildNodes->FindNode("r:otherInfo"); if (TempNode->ChildNodes->First()) { TempNode = TempNode->ChildNodes->First(); if (TempNode->ChildNodes->First()) { TempNode = TempNode->ChildNodes->First(); if (TempNode->ChildNodes->FindNode("tm:infoBin")) { TempNode = TempNode->ChildNodes->FindNode("tm:infoBin"); Form5->XMLDocument1->XML->Text = Form5->IdDecoderMIME1->DecodeString(TempNode->Text); TempNode = NULL; Form5->XMLDocument1->Active = true; if(Form5->XMLDocument1->DocumentElement->ChildNodes->First()) { prefix = StringReplace(Form5->XMLDocument1->DocumentElement->ChildNodes->First()->GetNodeName(), "Configurations", "", TReplaceFlags() << rfReplaceAll << rfIgnoreCase); configurations = prefix + "Configurations"; actconfigid = prefix + "ActConfigId"; editionid = prefix + "EditionId"; productdescription = prefix + "ProductDescription"; refgroupid = prefix + "RefGroupId"; if (Form5->XMLDocument1->DocumentElement->ChildNodes->FindNode(configurations)) { TempNode = Form5->XMLDocument1->DocumentElement->ChildNodes->FindNode(configurations); int k = TempNode->ChildNodes->Count; for (int i = 0; i < k; i++) { if (TempNode->ChildNodes->Get(i)->ChildNodes->FindNode(actconfigid)) { if (TempNode->ChildNodes->Get(i)->ChildNodes->FindNode(actconfigid)->Text.LowerCase() == aid) { if (TempNode->ChildNodes->Get(i)->ChildNodes->FindNode(editionid))if (edi == "" || TempNode->ChildNodes->Get(i)->ChildNodes->FindNode(editionid)->Text.Pos(edi)) { if (edi == "") edi = TempNode->ChildNodes->Get(i)->ChildNodes->FindNode(editionid)->Text; if (TempNode->ChildNodes->Get(i)->ChildNodes->FindNode(refgroupid)) { cid = TempNode->ChildNodes->Get(i)->ChildNodes->FindNode(refgroupid)->Text; } return TempNode->ChildNodes->Get(i)->ChildNodes->FindNode(productdescription)->Text; } } } else return " Error - no '"+actconfigid+"'"; } CoUninitialize(); return "Error - ActivationID Not found"; } else CoUninitialize(); return "Error - no '"+configurations+"'"; } else CoUninitialize(); return "Error - no '"+configurations+"' #2"; } else CoUninitialize(); return "Error - no 'tm:infoBin'"; } else CoUninitialize(); return "Error - no 'tm:infoList'"; } else CoUninitialize(); return "Error - no 'tm:infoTables'"; } else CoUninitialize(); return "Error - no 'r:otherInfo'"; } else CoUninitialize(); return "Error - no r:license'"; }
hi after some trial and error i managed to get most of the setup.exe file somewhat decompiled. but its in c++ and i dont have a lot of experience in it here are the segements i found with the word pidkey in it. its probably not enough but i dont know what is needed, i can probably upload the entire thing if someone wants to take a look. Code: line 130: extern wchar_t aPidkeyElementS[]; // idb Code: extern wchar_t aInvalidPidkeyS[]; // idb Code: extern const WCHAR aPidkey[]; // idb Code: } LABEL_46: OXmlNode::OXmlNode(&v222); LOBYTE(v281) = 99; v45 = OString::OString((int)&v247, (int)L"/Configuration/PIDKEY"); LOBYTE(v281) = 100; v46 = OXmlNode::SelectSingleNode((int)&v232, v45, (int)&v222); LOBYTE(v281) = 99; OString::_OString((int)&v247); if ( v46 ) { OString::OString((int)&v246); LOBYTE(v281) = 101; OString::OString((int)&v259); LOBYTE(v281) = 102; v47 = OString::OString((int)&v254, (int)L"OEM"); LOBYTE(v281) = 103; v280 = 128; Code: if ( !OString::Empty((int)v270) ) { v50 = OString::OString((int)&v243, (int)&dword_3001246C); LOBYTE(v281) = 110; v51 = OString::OString((int)&v247, (int)L"-"); LOBYTE(v281) = 111; OString::Replace(v270, v51, v50); LOBYTE(v281) = 110; OString::_OString((int)&v247); LOBYTE(v281) = 108; OString::_OString((int)&v243); v52 = OString::OString((int)&v239, (int)&dword_3001246C); LOBYTE(v281) = 112; v53 = OString::OString((int)&v247, (int)L" "); LOBYTE(v281) = 113; OString::Replace(v270, v53, v52); LOBYTE(v281) = 112; OString::_OString((int)&v247); LOBYTE(v281) = 108; OString::_OString((int)&v239); OString::ToUpper((int)v270, &v256); counted_ptr<OString>::_counted_ptr<OString>(&v256); v54 = *(_DWORD *)(v3 + 272); v273 = 4; v272 = (char *)v270; (*(void (__cdecl **)(_DWORD, signed int, char *, signed int, int, signed int, signed int, int))(v54 + 4))( v270, 4, v274, v275, v276, v277, v278, v279); v55 = OString::Length((int)v270); v56 = v55 == 25; v57 = 0; if ( v55 != 25 ) goto LABEL_296; do { if ( v57 >= OString::Length((int)v270) ) break; v58 = OString::Char((int)v270, v57); v56 = OEnvironment::IsCDKeyDigitValid(v58); ++v57; } while ( v56 ); if ( v56 ) { v59 = OString::OString((int)&v239, (int)L"PIDKEY element successfully parsed in config.xml"); LOBYTE(v281) = 114; } else { LABEL_296: v59 = OString::OString( (int)&v239, (int)L"Invalid pidkey specified in config.xml. Ignoring value from config.xml"); LOBYTE(v281) = 115; } LogLine(1, v59); LOBYTE(v281) = 108; OString::_OString((int)&v239); } LOBYTE(v281) = 107; OString::_OString((int)v270); LOBYTE(v281) = 102; OXmlElement::_OXmlElement((int)&v228); } LOBYTE(v281) = 101; OString::_OString((int)&v259); LOBYTE(v281) = 99; OString::_OString((int)&v246); v16 = 1; } if ( !(_BYTE)i ) { Code: || !OString::CompareTo(a1, L"PIDKEY", 0) probably in this order,
its always worked fine for me... but i do use prepackaged dlls from the iso images and also pkeyconfigs from the same sources