Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void DecryptARCode(std::vector<std::string> vCodes)
- {
- // The almighty buildseeds() function!! without this, the crypto routines are useless
- buildseeds();
- u32 uCodes[1200];
- std::string code;
- char temp[128];
- int i,ret;
- for (std::vector<std::string>::const_iterator iter = vCodes.begin(); iter != vCodes.end(); ++iter)
- {
- //NEED to make this operate on the vector itself instead of copying+changeing
- code = *iter;
- for (int i = 0; i < code.size(); i++)
- {
- if (isalnum(code[i]))
- code[i] = toupper(code[i]);
- }
- PanicAlert("Encrypted AR Code\n%s", code.c_str());
- }
- total++;
- if ((ret=alphatobin(uCodes, vCodes, vCodes.size())))
- {
- PanicAlert("Code Decryption Error\nParity Check Failed\n\nCode #%d, Line %d", total, ret);
- batchdecrypt(uCodes, vCodes.size()<<1);
- }
- else if (!batchdecrypt(uCodes, vCodes.size()<<1))
- {
- PanicAlert("Code Decryption Error\nCRC Check Failed\n\nCode #%d", total);
- }
- for (i = 0; i < (vCodes.size()<<1); i+=2)
- {
- sprintf(temp, "%08X %08X\r\n", uCodes[i], uCodes[i+1]);
- //strcat(textout,temp.c_str());
- PanicAlert("YAY\n%s", temp);
- }
- }
Add Comment
Please, Sign In to add comment