Function at 0x401070
Capabilities:
Resolve function by parsing pe exports

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x2c
mov eax, dword [section.noname_3]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, ecx
mov dword [ebp - 0x20], edx
push ebx
push esi
mov dword [ebp - 0x10], eax
xor edx, edx
mov ecx, dword [eax + 0x3c]
add ecx, eax
push edi
mov dword [ebp - 0x1c], ecx
mov eax, dword [ecx + 0x28]
movzx esi, word [ecx + 6]
movzx edi, word [ecx + 0x14]
mov dword [ebp - 0x28], eax
add edi, ecx
mov eax, esi
test eax, eax
je 0x4010be
lea ecx, [edi + 0x3c]
mov edi, edi
dec eax
test byte [ecx], 0x20
je 0x4010b7
inc edx
add ecx, 0x28
test eax, eax
jne 0x4010b0
mov eax, 1
cmp eax, edx
sbb eax, eax
xor ebx, ebx
neg eax
mov dword [ebp - 0xc], ebx
mov dword [ebp - 0x2c], eax
test esi, esi
je 0x401170
add edi, 0x28
lea esp, [esp]
dec esi
cmp byte [edi - 9], 1
mov dword [ebp - 0xc], esi
jne 0x401162
mov eax, 0xc
call fcn.00407710
mov eax, dword [edi - 4]
mov esi, esp
mov dword [esi], eax
mov eax, dword [edi - 8]
mov dword [esi + 4], eax
mov ecx, dword [edi]
cmp eax, ecx
jbe 0x40110a
mov dword [esi + 4], ecx
cmp dword [ebp - 0x2c], 0
je 0x401122
mov ecx, dword [edi - 4]
mov edx, dword [ebp - 0x28]
cmp edx, ecx
jb 0x401122
mov eax, dword [edi]
add eax, ecx
cmp edx, eax
jb 0x40115f
lea eax, [ebp - 8]
push eax
mov eax, dword [esi]
add eax, dword [ebp - 0x10]
push 4
push dword [esi + 4]
push eax
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
xor ecx, ecx
mov eax, ebx
test ebx, ebx
je 0x40115a
mov edx, dword [esi]
cmp dword [eax], edx
ja 0x40114e
mov ecx, eax
mov eax, dword [eax + 8]
test eax, eax
jne 0x401141
test ecx, ecx
je 0x40115a
mov dword [esi + 8], eax
mov dword [ecx + 8], esi
jmp 0x40115f
mov dword [esi + 8], eax
mov ebx, esi
mov esi, dword [ebp - 0xc]
add edi, 0x28
test esi, esi
jne 0x4010e0
mov dword [ebp - 0xc], ebx
mov eax, 0xc
call fcn.00407710
mov edi, dword [ebp - 0x1c]
xor ebx, ebx
mov esi, esp
add edi, 0x78
cmp ebx, 4
je 0x4011b7
mov eax, dword [edi]
test eax, eax
je 0x4011b7
cmp dword [edi + 4], 0
je 0x4011b7
mov dword [esi], eax
lea ecx, [ebp - 0xc]
mov eax, dword [edi + 4]
mov edx, esi
mov dword [esi + 4], eax
call fcn.00401940
test eax, eax
je 0x4011b7
mov eax, 0xc
call fcn.00407710
mov esi, esp
inc ebx
add edi, 8
cmp ebx, 0x10
jb 0x401184
mov ecx, dword [ebp - 0x1c]
mov eax, 0xcccccccd
mov edi, dword [ebp - 0x10]
mul dword [ecx + 0x84]
mov ebx, dword [ecx + 0x80]
mov eax, edx
add ebx, edi
shr eax, 4
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x14], eax
test eax, eax
je 0x4012e7
lea esp, [esp]
cmp dword [ebx], 0
je 0x4012d4
mov eax, dword [ebx + 0xc]
mov dword [esi], eax
lea ecx, [eax + edi]
call fcn.00401a40
inc eax
lea ecx, [ebp - 0xc]
mov edx, esi
mov dword [esi + 4], eax
call fcn.00401940
test eax, eax
je 0x401224
mov eax, 0xc
call fcn.00407710
mov esi, esp
mov edx, dword [ebx]
mov ecx, 1
cmp dword [edx + edi], 0
lea eax, [edx + edi]
je 0x40123d
lea eax, [eax + 4]
inc ecx
cmp dword [eax], 0
jne 0x401234
lea edi, [ecx*4]
mov dword [esi], edx
mov edx, esi
mov dword [esi + 4], edi
lea ecx, [ebp - 0xc]
call fcn.00401940
test eax, eax
je 0x401263
mov eax, 0xc
call fcn.00407710
mov esi, esp
mov eax, dword [ebx + 0x10]
lea ecx, [ebp - 0xc]
mov edx, esi
mov dword [esi], eax
mov dword [esi + 4], edi
call fcn.00401940
test eax, eax
je 0x401285
mov eax, 0xc
call fcn.00407710
mov esi, esp
mov edi, dword [ebx]
add edi, dword [ebp - 0x10]
mov eax, dword [edi]
test eax, eax
je 0x4012ce
mov ebx, dword [ebp - 0x10]
js 0x4012c1
lea ecx, [ebx + 2]
mov dword [esi], eax
add ecx, eax
call fcn.00401a40
add eax, 3
lea ecx, [ebp - 0xc]
mov edx, esi
mov dword [esi + 4], eax
call fcn.00401940
test eax, eax
je 0x4012c1
mov eax, 0xc
call fcn.00407710
mov esi, esp
mov eax, dword [edi + 4]
add edi, 4
test eax, eax
jne 0x401293
mov ebx, dword [ebp - 0x18]
mov edi, dword [ebp - 0x10]
mov eax, dword [ebp - 0x14]
add ebx, 0x14
dec eax
mov dword [ebp - 0x18], ebx
mov dword [ebp - 0x14], eax
jne 0x4011f0
mov ecx, dword [ebp - 0x1c]
mov eax, dword [ecx + 0xa0]
mov ebx, edi
sub ebx, dword [ebp - 0x20]
mov ecx, dword [ebp - 0xc]
mov dword [ebp - 0x18], ebx
test eax, eax
je 0x4013a1
test ebx, ebx
je 0x4013a1
lea edx, [eax + edi]
mov eax, dword [ebp - 0x1c]
mov esi, dword [eax + 0xa4]
test esi, esi
je 0x4013a1
lea esp, [esp]
mov eax, dword [edx + 4]
lea ebx, [edx + 8]
mov ecx, dword [edx]
sub esi, eax
add edx, eax
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x20], edx
lea edi, [eax - 8]
mov dword [ebp - 0x24], esi
shr edi, 1
je 0x401394
lea esp, [esp]
movzx edx, word [ebx]
dec edi
mov eax, edx
and eax, 0xf000
cmp eax, 0x3000
jne 0x401387
mov eax, dword [ebp - 0xc]
and edx, 0xfff
add edx, ecx
mov ecx, eax
test eax, eax
je 0x401384
mov esi, dword [ecx]
cmp edx, esi
jb 0x401372
mov eax, dword [ecx + 4]
add eax, esi
cmp edx, eax
jb 0x40137b
mov ecx, dword [ecx + 8]
test ecx, ecx
jne 0x401363
jmp 0x401384
mov ecx, dword [ebp - 0x10]
mov eax, dword [ebp - 0x18]
sub dword [ecx + edx], eax
mov ecx, dword [ebp - 0x14]
add ebx, 2
test edi, edi
jne 0x401340
mov edx, dword [ebp - 0x20]
mov esi, dword [ebp - 0x24]
test esi, esi
jne 0x401320
mov ecx, dword [ebp - 0xc]
mov ebx, dword [ebp - 0x18]
mov edi, dword [ebp - 0x10]
mov esi, ecx
test ecx, ecx
je 0x4013ba
mov ecx, dword [esi]
mov edx, dword [esi + 4]
add ecx, edi
call fcn.00401500
mov esi, dword [esi + 8]
test esi, esi
jne 0x4013a7
mov ecx, dword [ebp - 0x1c]
mov eax, dword [ecx + 0xa0]
test eax, eax
je 0x40145b
test ebx, ebx
je 0x40145b
mov esi, dword [ecx + 0xa4]
lea edx, [eax + edi]
test esi, esi
je 0x40145b
mov eax, dword [edx + 4]
lea ebx, [edx + 8]
mov ecx, dword [edx]
sub esi, eax
add edx, eax
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x24], edx
lea edi, [eax - 8]
mov dword [ebp - 0x20], esi
shr edi, 1
je 0x401454
lea esp, [esp]
movzx edx, word [ebx]
dec edi
mov eax, edx
and eax, 0xf000
cmp eax, 0x3000
jne 0x401447
mov esi, dword [ebp - 0xc]
and edx, 0xfff
add edx, ecx
mov eax, esi
test esi, esi
je 0x401447
mov esi, dword [eax]
cmp edx, esi
jb 0x401432
mov ecx, dword [eax + 4]
add ecx, esi
cmp edx, ecx
jb 0x40143b
mov eax, dword [eax + 8]
test eax, eax
jne 0x401423
jmp 0x401444
mov ecx, dword [ebp - 0x10]
mov eax, dword [ebp - 0x18]
add dword [ecx + edx], eax
mov ecx, dword [ebp - 0x14]
add ebx, 2
test edi, edi
jne 0x401400
mov edx, dword [ebp - 0x24]
mov esi, dword [ebp - 0x20]
test esi, esi
jne 0x4013e0
mov ecx, dword [ebp - 0x1c]
movzx ebx, word [ecx + 6]
movzx eax, word [ecx + 0x14]
test ebx, ebx
je 0x4014e7
lea esi, [ecx + 0x24]
add esi, eax
dec ebx
cmp byte [esi - 5], 1
jne 0x4014e0
cmp dword [ebp - 0x2c], 0
je 0x40148f
mov ecx, dword [esi]
mov edx, dword [ebp - 0x28]
cmp edx, ecx
jb 0x40148f
mov eax, dword [esi + 4]
add eax, ecx
cmp edx, eax
jb 0x4014e0
mov eax, dword [esi + 0x18]
test eax, 0x20000000
je 0x4014a0
mov eax, 0x10
jmp 0x4014af
and eax, 0x80000000
neg eax
sbb eax, eax
and eax, 2
add eax, 2
lea ecx, [ebp - 8]
mov dword [ebp - 8], eax
mov edi, dword [esi]
add edi, dword [ebp - 0x10]
push ecx
push eax
push dword [esi - 4]
push edi
call dword [sym.imp.KERNEL32.dll_VirtualProtect]
test dword [esi + 0x18], 0x20000000
je 0x4014e0
push dword [esi - 4]
push edi
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call dword [sym.imp.KERNEL32.dll_FlushInstructionCache]
add esi, 0x28
test ebx, ebx
jne 0x401470
lea esp, [ebp - 0x38]
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00401ab4
mov esp, ebp
pop ebp
ret