[HELP] Decode udb_hash
#1

hello, i need a scropt or a function tu decode udb_hash.

udb_hash script is :


stock udb_hash(buf[]) {
new length=strlen(buf);
new s1 = 1;
new s2 = 0;
new n;
for (n=0; n<length; n++)
{
s1 = (s1 + buf[n]) % 65521;
s2 = (s2 + s1) % 65521;
}
return (s2 << 16) + s1;
}


Please, help my

Thanks
Reply
#2

You should never need to decode it, just hash what it is you're comparing it to, hash is usually meant for passwords so you really shouldn't get to see it lol
Reply
#3

it maybe sounds dumb to you, but have you try switching the code, positive to negative?

Quote:

stock udb_hash(buf[]) {
new length=strlen(buf);
new s1 = 1;
new s2 = 0;
new n;
for (n=0; n<length; n++)
{
s1 = (s1 - buf[n]) % 65521;
s2 = (s2 - s1) % 65521;
}
return (s2 >> 16) - s1;
}

i dont know how this code does its job, so it was just a random thought:
anyways, the solution shouldnt be that hard, because for any good thing, there is a bad thing, for any beautiful thing, there is a ugly thing etc.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)