Closed Thread
Results 1 to 5 of 5

Thread: Reverser Wanted

  1. #1

    Default Reverser Wanted

    Hello, I'm looking for someone to understand and rewrite the following code to something understandable (python if possible):

    https://i.imgur.com/BXGJZvB.png

    If you are interested, please send your proposal including price as a private message or if you need more details.


  2. #2
    Darwin's Avatar

    Default Re: Reverser Wanted

    Code: Python

    # -*- coding: utf-8 -*-

    def shr32(val, width):
    return val >> width

    def shl32(val, width):
    return (val << width) & 0xFFFFFFFF

    def get_dword(data, offset=0):
    b1 = data[offset+0]
    b2 = data[offset+1]
    b3 = data[offset+2]
    b4 = data[offset+3]
    return (b4 << 24) + (b3 << 16) + (b2 << 8) + b1

    dword_61A918 = [0, 0, 0, 0] * 0x100

    def sub_448690(ecx, edx):
    eax = shr32(ecx, 0x18)
    eax = get_dword(dword_61A918, eax*4)
    ecx = shl32(ecx, 8)
    edx &= 0xFF
    ecx |= edx
    return eax ^ edx

    print(hex(sub_448690(10, 20)))
    Last edited by Darwin; 04-03-2018 at 21:33.
    Счастлив кто отдал, а не взял. (с) Inception

  3. Пользователь сказал cпасибо:
    skincast (16-03-2018)
  4. #3

    Default Re: Reverser Wanted

    Sorry, but didn't work or I don't get how to implement it (most probably). Let me explain how the code works then maybe you can give me a clue:

    Step 1 - binary generates a random hex (let's use 8711 as example);
    Step 2 - binary takes the input string and split it in characters using unicode. For example, if I write 12345678, the script is called 8 times (8 chars on string), and first input will be 31 (Unicode for 1);
    Step 3 - code keep in loop for string lenght as I said. In the example, 8 times.
    Step 4 - The output, does not matter string lenght, is a 4 hex digit string. Using "0x8711" as salt, I get "C1 5E B2 6D" on output.

  5. #4
    Darwin's Avatar

    Default Re: Reverser Wanted

    Code:
    dword_61A918 = [0, 0, 0, 0] * 0x100
    You need to fill the dword_61A918 array with the correct values from the program.
    Счастлив кто отдал, а не взял. (с) Inception

  6. Пользователь сказал cпасибо:
    skincast (16-03-2018)
  7. #5

    Default Re: Reverser Wanted

    After some modifications and corrections, I got it working. Thanks Darwin.

Closed Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
All times are GMT. The time now is 01:19
vBulletin® Copyright ©2000 - 2018
www.reverse4you.org