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

Disassembly:
push 0xffffffffffffffff
push 0x6272f8
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x10
push ebx
push esi
push edi
xor edi, edi
mov dword [esp + 0x18], edi
mov eax, dword [0x6e0ea0]
mov dword [esp + 0xc], eax
mov ebx, dword [esp + 0x30]
mov dword [esp + 0x24], edi
mov ecx, dword [ebx]
mov eax, dword [ecx - 8]
lea ecx, [esp + 0xc]
push eax
call fcn.004e9e10
mov eax, dword [ebx]
xor esi, esi
mov edx, dword [eax - 8]
cmp edx, edi
jbe 0x51a7df
push ebp
xor ecx, ecx
mov cx, word [eax + esi*2]
cmp ecx, 0x24
jl 0x51a61d
cmp ecx, 0x25
jle 0x51a632
cmp ecx, 0x5c
jne 0x51a61d
dec edx
cmp esi, edx
je 0x51a61d
mov cx, word [eax + esi*2 + 2]
cmp cx, 0x25
je 0x51a61c
cmp cx, 0x24
jne 0x51a61d
inc esi
mov dx, word [eax + esi*2]
lea ecx, [esp + 0x10]
push edx
push 1
call fcn.004e9db0
jmp 0x51a7d0
cmp word [eax + esi*2], 0x25
jne 0x51a643
mov dword [esp + 0x14], 0x25
jmp 0x51a67b
mov ecx, dword [eax - 8]
dec ecx
cmp esi, ecx
jne 0x51a651
mov dword [esp + 0x14], edi
jmp 0x51a67b
xor ecx, ecx
mov cx, word [eax + esi*2 + 2]
cmp ecx, 0x28
je 0x51a672
cmp ecx, 0x7b
je 0x51a668
mov dword [esp + 0x14], edi
jmp 0x51a67b
mov dword [esp + 0x14], 0x7d
jmp 0x51a67a
mov dword [esp + 0x14], 0x29
inc esi
mov ecx, dword [eax - 8]
lea ebp, [esi + 1]
mov edi, ebp
cmp edi, ecx
jae 0x51a6af
mov ax, word [eax + edi*2]
push 0x107
push eax
call dword [sym.imp.MSVCRT.dll_iswctype]
add esp, 8
test eax, eax
jne 0x51a6a7
mov eax, dword [ebx]
cmp word [eax + edi*2], 0x5f
jne 0x51a6af
mov eax, dword [ebx]
inc edi
cmp edi, dword [eax - 8]
jb 0x51a687
mov eax, dword [ebx]
mov ecx, edi
sub ecx, esi
dec ecx
lea edx, [eax + ebp*2]
push ecx
push 0
push edx
lea ecx, [esp + 0x28]
call fcn.004e9b90
mov eax, dword [0x6e0ea0]
xor ebp, ebp
mov dword [esp + 0x18], eax
lea ecx, [esp + 0x18]
lea edx, [esp + 0x1c]
push ecx
push edx
mov byte [esp + 0x30], 2
call fcn.0050dc00
add esp, 8
test al, al
je 0x51a712
mov eax, dword [esp + 0x18]
test eax, eax
mov ebp, eax
je 0x51a712
push eax
call dword [sym.imp.MSVCRT.dll_wcslen]
add esp, 4
lea ecx, [esp + 0x10]
push eax
push ebp
push eax
call fcn.004ea760
mov ebx, dword [esp + 0x34]
jmp 0x51a761
mov eax, dword [esp + 0x14]
cmp eax, 0x25
je 0x51a738
test eax, eax
je 0x51a738
mov ebx, dword [esp + 0x34]
lea ecx, [esp + 0x10]
mov eax, dword [ebx]
mov ax, word [eax + esi*2 - 2]
push eax
push 1
call fcn.004e9db0
jmp 0x51a73c
mov ebx, dword [esp + 0x34]
mov eax, dword [ebx]
lea ecx, [esp + 0x10]
mov ax, word [eax + esi*2]
push eax
push 1
call fcn.004e9db0
mov ecx, dword [esp + 0x1c]
mov eax, dword [ecx - 8]
push eax
push ecx
push eax
lea ecx, [esp + 0x1c]
call fcn.004ea760
mov ecx, dword [esp + 0x14]
test ecx, ecx
je 0x51a787
mov eax, dword [ebx]
cmp edi, dword [eax - 8]
je 0x51a787
cmp word [eax + edi*2], cx
jne 0x51a787
test ebp, ebp
jne 0x51a786
push ecx
push 1
lea ecx, [esp + 0x18]
call fcn.004e9db0
inc edi
mov eax, dword [esp + 0x18]
lea esi, [edi - 1]
add eax, 0xfffffff4
mov ecx, dword [eax]
cmp ecx, 0xffffffff
je 0x51a7a9
dec ecx
test ecx, ecx
mov dword [eax], ecx
jne 0x51a7a9
push eax
call dword [sym.imp.MSVCRT.dll_free]
add esp, 4
mov ecx, dword [esp + 0x1c]
mov byte [esp + 0x28], 0
lea eax, [ecx - 0xc]
mov ecx, dword [ecx - 0xc]
cmp ecx, 0xffffffff
je 0x51a7ce
dec ecx
test ecx, ecx
mov dword [eax], ecx
jne 0x51a7ce
push eax
call dword [sym.imp.MSVCRT.dll_free]
add esp, 4
xor edi, edi
mov eax, dword [ebx]
inc esi
mov edx, dword [eax - 8]
cmp esi, edx
jb 0x51a5f1
pop ebp
mov eax, dword [esp + 0xc]
mov esi, dword [esp + 0x2c]
cmp dword [eax - 8], edi
jne 0x51a7f6
mov ecx, dword [0x6e0ea0]
mov dword [esi], ecx
jmp 0x51a808
mov dword [esi], eax
mov ecx, dword [eax - 0xc]
cmp ecx, 0xffffffff
je 0x51a808
inc ecx
mov dword [eax - 0xc], ecx
mov eax, dword [esp + 0xc]
mov ecx, dword [eax - 0xc]
add eax, 0xfffffff4
cmp ecx, 0xffffffff
je 0x51a824
dec ecx
cmp ecx, edi
mov dword [eax], ecx
jne 0x51a824
push eax
call dword [sym.imp.MSVCRT.dll_free]
add esp, 4
mov ecx, dword [esp + 0x1c]
mov eax, esi
pop edi
pop esi
pop ebx
mov dword fs:[0], ecx
add esp, 0x1c
ret