Function at 0x51d500
Capabilities:
Access peb ldr_data
Get kernel32 base address

Disassembly:
push 0xffffffffffffffff
push 0x59037f
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x30
push ebx
push ebp
mov ebp, dword [esp + 0x4c]
xor ebx, ebx
push esi
mov dword [esp + 0x18], ebx
mov eax, dword [ebp]
cmp eax, ebx
je 0x51d537
cmp dword [eax + 8], ebx
jbe 0x51d537
cmp byte [eax + 0xc], 0x10
je 0x51d570
mov esi, dword [esp + 0x4c]
mov dword [ecx], 0xbb9
lea ecx, [esi + 4]
mov dword [esi], ebx
call fcn.004e0c90
mov dword [esi + 0xc], ebx
mov dword [esi + 0x10], ebx
mov dword [esi + 0x14], ebx
mov dword [esi + 0x18], ebx
mov byte [esi + 0x1c], bl
mov eax, esi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x30]
mov dword fs:[0], ecx
add esp, 0x3c
ret 8
push edi
lea ecx, [esp + 0x24]
mov dword [esp + 0x20], ebx
call fcn.004e0c90
mov dword [esp + 0x2c], ebx
mov dword [esp + 0x30], ebx
mov dword [esp + 0x34], ebx
mov dword [esp + 0x38], ebx
mov byte [esp + 0x3c], bl
mov esi, 1
mov dword [esp + 0x48], esi
mov eax, dword [ebp]
mov ecx, esi
inc esi
cmp eax, ebx
jne 0x51d5ab
mov byte [esp + 0x54], bl
jmp 0x51d5c7
cmp ecx, dword [eax + 8]
jb 0x51d5b6
mov byte [esp + 0x54], bl
jmp 0x51d5c7
mov cl, byte [eax + ecx + 0xc]
cmp cl, 0x86
mov byte [esp + 0x54], cl
je 0x51d703
cmp eax, ebx
je 0x51d703
mov ecx, dword [eax + 8]
cmp esi, ecx
jae 0x51d703
mov edx, dword [esp + 0x54]
and edx, 0xff
add edx, 0xffffff80
cmp edx, 5
ja case.default.0x51d5ec
jmp dword [edx*4 + 0x51d740]
mov edi, esi
inc esi
cmp edi, ecx
jb 0x51d600
mov byte [esp + 0x18], bl
jmp 0x51d608
mov dl, byte [eax + edi + 0xc]
mov byte [esp + 0x18], dl
mov edx, esi
inc esi
cmp edx, ecx
jb 0x51d615
mov byte [esp + 0x14], bl
jmp 0x51d61d
mov al, byte [eax + edx + 0xc]
mov byte [esp + 0x14], al
mov edi, esi
mov ecx, ebp
inc esi
call fcn.0051d760
cmp edi, eax
jb 0x51d631
mov byte [esp + 0x10], bl
jmp 0x51d63c
mov ecx, dword [ebp]
mov dl, byte [ecx + edi + 0xc]
mov byte [esp + 0x10], dl
mov eax, dword [esp + 0x10]
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x18]
and eax, 0xff
and ecx, 0xff
push eax
and edx, 0xff
push ecx
push edx
lea ecx, [esp + 0x30]
call fcn.0046f380
jmp case.default.0x51d5ec
mov edi, esi
mov ecx, ebp
inc esi
call fcn.0051d760
cmp edi, eax
jb 0x51d686
xor al, al
movsx ecx, al
mov dword [esp + 0x2c], ecx
jmp case.default.0x51d5ec
mov eax, dword [ebp]
mov al, byte [eax + edi + 0xc]
movsx ecx, al
mov dword [esp + 0x2c], ecx
jmp case.default.0x51d5ec
mov edx, dword [esp + 0x50]
add esi, 4
movsx eax, word [edx + esi - 4]
mov dword [esp + 0x34], eax
jmp case.default.0x51d5ec
mov ecx, dword [esp + 0x50]
add esi, 4
movsx edx, word [ecx + esi - 4]
mov dword [esp + 0x38], edx
jmp case.default.0x51d5ec
mov edi, esi
mov ecx, ebp
inc esi
call fcn.0051d760
cmp edi, eax
jb 0x51d6dc
xor al, al
mov byte [esp + 0x3c], al
jmp case.default.0x51d5ec
mov eax, dword [ebp]
mov al, byte [eax + edi + 0xc]
mov byte [esp + 0x3c], al
jmp case.default.0x51d5ec
mov eax, esi
mov ecx, ebp
push eax
inc esi
call fcn.0051d770
movsx ecx, al
mov dword [esp + 0x30], ecx
jmp case.default.0x51d5ec
mov esi, dword [esp + 0x50]
lea edx, [esp + 0x20]
push edx
mov ecx, esi
call fcn.0051d7a0
lea ecx, [esp + 0x24]
mov dword [esp + 0x1c], 1
mov byte [esp + 0x48], bl
call fcn.0046f260
mov ecx, dword [esp + 0x40]
mov eax, esi
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x3c
ret 8