Rating:
Not too hard.
All you need is understanding the code "genHash"
============= genhash =============
```
__int64 __fastcall genhash(char *a1)
{
unsigned int v1; // eax
char *v2; // rax
__int64 result; // rax
char *v4; // [rsp+8h] [rbp-18h]
unsigned int v5; // [rsp+14h] [rbp-Ch]
signed __int64 v6; // [rsp+18h] [rbp-8h]
v4 = a1;
v6 = 13LL;
v5 = 0;
while ( 1 )
{
v2 = v4++;
result = (unsigned int)*v2;
if ( !(_DWORD)result )
break;
v6 = 3 * v6 + (signed int)result;
v1 = v5++;
printf("hash-%d : %ld\n", v1, v6);
}
return result;
}
```
==================================
variable result will be each letter of a1
firstly, the v6 is going to be a result of "3 * 13(v6) + (int)a1[0]"
After this, the v6 is will be encrypted result of before letter.
Now, What you need is just make hashes origin using the encrypted letters.
```
# Hashish Decryptor by sqrtrev
flag = ''
f = [138,512,1645,5034,15218,45756,137391,412292,1236927,3710845,11132642,33398021,100194167,300582553,901747774,2705243426,8115730373,24347191171,73041573621,219124720917,657374162799,1972122488522,5916367465576]
v6 = 13
for i in range(0,len(f)):
if i != 0:
v6 = f[i-1]
tmp = f[i]
tmp -= 3 * v6
flag += chr(tmp)
print flag
```