Function at 0x420300
Capabilities:
Access peb ldr_data

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x51037c
mov eax, dword fs:[0]
push eax
sub esp, 0x2c
push esi
push edi
mov eax, dword [0x56fcd4]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov edx, ecx
mov dword [ebp - 0x2c], edx
mov dword [ebp - 0x1c], edx
mov dword [ebp - 0x30], edx
mov eax, dword [ebp + 8]
mov dword [edx], eax
mov dword [ebp - 4], 0
mov dword [edx + 4], 0
mov dword [edx + 8], 0
mov dword [edx + 0xc], 0
lea esi, [edx + 0x10]
mov dword [esi], 0
mov dword [ebp - 0x24], esi
mov dword [esi + 4], 0
mov dword [esi + 8], 0
mov dword [esi + 0xc], 0
mov dword [edx + 0x20], 0
mov dword [edx + 0x24], 0
mov dword [edx + 0x28], 0
mov dword [edx + 0x2c], 0
lea edi, [edx + 0x38]
mov dword [edx + 0x30], 0
mov byte [edx + 0x34], 0
mov dword [ebp - 0x1c], edi
mov dword [edi + 0x24], 0
mov ecx, dword [ebp + 0x30]
mov byte [ebp - 4], 4
test ecx, ecx
je 0x4203c0
mov eax, dword [ecx]
push edi
mov eax, dword [eax]
call eax
mov edx, dword [ebp - 0x2c]
mov dword [edi + 0x24], eax
mov al, byte [ebp + 0x34]
lea ecx, [edx + 0x68]
push 9
mov byte [ebp - 4], 5
mov byte [edx + 0x60], al
call fcn.0041f600
mov edx, dword [esi + 0xc]
xor edi, edi
mov ecx, dword [esi]
mov byte [ebp - 4], 6
mov byte [ebp - 0xd], 1
mov dword [ebp - 0x20], ecx
test edx, edx
jns 0x420407
mov eax, edx
neg eax
cmp edi, eax
jae 0x420407
lea eax, [edi + edx]
mov edi, ecx
not eax
shr eax, 5
lea eax, [eax*4 + 4]
sub edi, eax
jmp 0x420410
lea eax, [edi + edx]
shr eax, 5
lea edi, [ecx + eax*4]
xor esi, esi
sub edi, ecx
sar edi, 2
mov eax, 0x1f
shl edi, 5
lea ecx, [esi + edx]
mov esi, dword [ebp - 0x24]
and eax, ecx
add edi, eax
mov eax, closesocket
sub eax, edx
mov dword [ebp - 0x28], edi
cmp eax, 1
jb 0x420617
mov eax, dword [esi]
lea ecx, [edx + 0x20]
mov edx, dword [esi + 4]
sub edx, eax
shr ecx, 5
sar edx, 2
mov dword [ebp - 0x14], 0
cmp ecx, edx
jae 0x42045c
lea eax, [eax + ecx*4]
jmp 0x420488
jbe 0x42048b
mov eax, dword [esi + 8]
sub eax, dword [esi]
sar eax, 2
cmp ecx, eax
lea eax, [ebp - 0x14]
jbe 0x420478
push eax
push ecx
mov ecx, esi
call fcn.00407d10
jmp 0x42048b
push esi
push eax
sub ecx, edx
push ecx
push dword [esi + 4]
call fcn.004088a0
add esp, 0x10
mov dword [esi + 4], eax
mov edx, dword [esi + 0xc]
test edx, edx
jne 0x42049d
lea eax, [edx + 1]
mov dword [esi + 0xc], eax
jmp 0x4205a4
mov ecx, dword [esi]
xor edi, edi
mov dword [ebp - 0x20], ecx
test edx, edx
jns 0x4204c4
mov eax, edx
neg eax
cmp edi, eax
jae 0x4204c4
mov edi, edx
mov eax, edi
not eax
shr eax, 5
lea eax, [eax*4 + 4]
sub ecx, eax
jmp 0x4204ce
add edi, edx
mov eax, edi
shr eax, 5
lea ecx, [ecx + eax*4]
mov dword [ebp - 0x18], ecx
and edi, 0x1f
lea ecx, [edx + 1]
mov edx, dword [esi]
mov dword [esi + 0xc], ecx
xor esi, esi
mov dword [ebp - 0x20], edx
test ecx, ecx
jns 0x420503
mov eax, ecx
neg eax
cmp esi, eax
jae 0x420503
mov esi, ecx
mov ecx, edx
mov eax, esi
not eax
shr eax, 5
lea eax, [eax*4 + 4]
sub ecx, eax
jmp 0x42050d
add esi, ecx
mov eax, esi
shr eax, 5
lea ecx, [edx + eax*4]
push dword [ebp - 0x28]
lea eax, [ebp - 0x38]
mov dword [ebp - 0x14], ecx
push eax
lea ecx, [ebp - 0x20]
mov dword [ebp - 0x20], edx
mov dword [ebp - 0x1c], 0
and esi, 0x1f
call fcn.0042b030
mov ecx, dword [eax]
mov eax, dword [eax + 4]
mov dword [ebp - 0x30], ecx
mov ecx, dword [ebp - 0x14]
mov dword [ebp - 0x1c], eax
nop word [eax + eax]
mov eax, dword [ebp - 0x18]
mov edx, esi
cmp dword [ebp - 0x30], eax
jne 0x42054f
cmp dword [ebp - 0x1c], edi
je 0x42059e
test edi, edi
je 0x420556
dec edi
jmp 0x420561
sub eax, 4
mov edi, 0x1f
mov dword [ebp - 0x18], eax
test esi, esi
je 0x420568
dec esi
jmp 0x42056d
mov esi, 0x1f
lea eax, [ecx - 4]
test edx, edx
cmove ecx, eax
mov eax, 1
mov dword [ebp - 0x14], ecx
mov edx, dword [ecx]
mov ecx, edi
shl eax, cl
mov ecx, dword [ebp - 0x18]
test dword [ecx], eax
je 0x420594
mov ecx, dword [ebp - 0x14]
bts edx, esi
mov dword [ecx], edx
jmp 0x420540
mov ecx, dword [ebp - 0x14]
btr edx, esi
mov dword [ecx], edx
jmp 0x420540
mov esi, dword [ebp - 0x24]
mov edi, dword [ebp - 0x28]
mov edx, dword [esi]
xor ecx, ecx
test edi, edi
jns 0x4205c8
mov eax, edi
neg eax
cmp ecx, eax
jae 0x4205c8
mov ecx, edi
mov eax, ecx
not eax
shr eax, 5
lea eax, [eax*4 + 4]
sub edx, eax
jmp 0x4205d2
add ecx, edi
mov eax, ecx
shr eax, 5
lea edx, [edx + eax*4]
lea eax, [ebp - 0xd]
and ecx, 0x1f
push eax
push 1
push ecx
push edx
lea eax, [ebp - 0x38]
push eax
call fcn.0040db80
mov ecx, dword [ebp + 0x30]
add esp, 0x14
test ecx, ecx
je 0x420601
mov esi, dword [ecx]
lea eax, [ebp + 0xc]
cmp ecx, eax
setne dl
movzx edx, dl
push edx
call dword [esi + 0x10]
mov eax, dword [ebp - 0x2c]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov esp, ebp
pop ebp
ret 0x30
mov ecx, esi
call fcn.004376f0
int3