Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int __stdcall CloudAuthX::DecryptCode(int a1, const char **a2)
- {
- const char *v2; // eax@2
- int v3; // edx@3
- int v4; // edi@3
- int v5; // edi@5
- char v6; // cl@6
- char v7; // cl@8
- int v8; // edi@10
- char v9; // si@11
- int v10; // eax@13
- int v11; // edx@13
- int v12; // eax@16
- int result; // eax@21
- const char *v14; // [sp+10h] [bp-74h]@10
- size_t v15; // [sp+14h] [bp-70h]@10
- int v16; // [sp+18h] [bp-6Ch]@3
- char v17; // [sp+18h] [bp-6Ch]@8
- char v18; // [sp+1Ch] [bp-68h]@10
- int v19; // [sp+20h] [bp-64h]@13
- const char v20; // [sp+24h] [bp-60h]@3
- char v21; // [sp+24h] [bp-60h]@10
- char v22; // [sp+28h] [bp-5Ch]@21
- char v23; // [sp+3Bh] [bp-49h]@18
- int v24; // [sp+3Ch] [bp-48h]@10
- int v25; // [sp+4Ch] [bp-38h]@6
- int v26; // [sp+5Ch] [bp-28h]@6
- if ( (unsigned __int8)IsDebuggingModule() )
- {
- std::string::string(a1, &unk_290766, &v26);
- result = a1;
- }
- else
- {
- v2 = *a2;
- if ( *((_DWORD *)*a2 - 1) < 0 )
- {
- v3 = *((_DWORD *)v2 - 3);
- v20 = *v2;
- v16 = *v2 - 48;
- v4 = v3 - 1;
- }
- else
- {
- std::string::_M_leak_hard(a2);
- v2 = *a2;
- v3 = *((_DWORD *)*a2 - 3);
- v20 = **a2;
- v16 = **a2 - 48;
- v4 = v3 - 1;
- if ( *((_DWORD *)*a2 - 1) >= 0 )
- {
- std::string::_M_leak_hard(a2);
- v2 = *a2;
- v3 = *((_DWORD *)*a2 - 3);
- }
- }
- v5 = v2[v4];
- if ( !v3 )
- std::__throw_out_of_range("basic_string::substr");
- std::string::string(&v26, a2, 1, v3 - 2);
- std::string::assign(a2, &v26);
- std::string::_Rep::_M_dispose(v26 - 12, &v25);
- v6 = v20 - 51;
- if ( v16 < 3 )
- v6 = v16;
- v17 = v6;
- v7 = v5 - 53;
- if ( v5 - 48 < 3 )
- v7 = v5 - 48;
- v18 = v7;
- v14 = *a2;
- v15 = strlen(*a2);
- std::string::string(&v24, &unk_290766, &v26);
- std::string::string(&v25, &unk_290766, &v26);
- v8 = 0;
- v21 = 1;
- if ( (signed int)v15 > 0 )
- {
- do
- {
- v9 = v14[v8] - v17;
- if ( !v21 )
- v9 = v18 + v14[v8];
- v10 = v24;
- v11 = *(_DWORD *)(v24 - 12);
- v19 = v11 + 1;
- if ( (unsigned int)(v11 + 1) > *(_DWORD *)(v24 - 8) || *(_DWORD *)(v24 - 4) > 0 )
- {
- std::string::reserve(&v24, v19);
- v10 = v24;
- v11 = *(_DWORD *)(v24 - 12);
- }
- *(_BYTE *)(v10 + v11) = v9;
- v12 = v24;
- if ( (_DWORD *)(v24 - 12) != dword_333B48 )
- {
- *(_DWORD *)(v24 - 4) = 0;
- *(_DWORD *)(v12 - 12) = v19;
- *(_BYTE *)(v12 + v19) = 0;
- }
- v21 ^= 1u;
- ++v8;
- }
- while ( v15 != v8 );
- }
- base64decode(&v26);
- std::string::assign(&v25, &v26);
- std::string::_Rep::_M_dispose(v26 - 12, &v23);
- if ( *(_DWORD *)(v24 - 4) >= 0 )
- {
- std::string::_M_leak_hard(&v24);
- if ( *(_DWORD *)(v24 - 4) >= 0 )
- std::string::_M_leak_hard(&v24);
- }
- std::string::erase(&v22);
- std::string::string(a1, &v25);
- std::string::_Rep::_M_dispose(v25 - 12, &v26);
- std::string::_Rep::_M_dispose(v24 - 12, &v26);
- result = a1;
- }
- return result;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement