Function at 0x4074ac
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xf8
push esi
mov dword [ebp - 0x18], 0xc
cmp dword [ebp + 8], 0
je 0x407dd0
push 0x10000
call fcn.004095ed
add esp, 4
mov dword [ebp - 0x6c], eax
mov eax, dword [ebp - 0x6c]
mov dword [ebp - 0x34], eax
mov dword [ebp - 4], 0x10000
mov ecx, dword [ebp + 0x10]
push ecx
lea edx, [ebp - 4]
push edx
mov eax, dword [ebp - 0x34]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call fcn.0040716f
add esp, 0x10
and eax, 0xff
test eax, eax
jne 0x40750c
xor al, al
jmp 0x407dd2
cmp dword [ebp - 4], 0
jne 0x407519
mov al, 1
jmp 0x407dd2
mov edx, dword [ebp - 0x34]
mov eax, dword [edx]
mov dword [ebp - 0x14], eax
mov ecx, dword [ebp - 0x14]
mov dword [ebp - 0x10], ecx
mov edx, dword [ebp - 0x34]
mov eax, dword [edx + 4]
mov dword [ebp - 8], eax
push 2
mov ecx, dword [ebp - 0x34]
add ecx, 8
push ecx
push 0x412254
call fcn.00409600
add esp, 0xc
cmp dword [ebp - 8], 0
jne 0x407553
mov al, 1
jmp 0x407dd2
mov dword [ebp - 0x2c], 0
mov dword [ebp - 0x30], 0
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x3c], 0x1000
xor edx, edx
mov dl, byte [0x41236e]
test edx, edx
je 0x407997
mov eax, dword [ebp - 8]
add eax, 0xfff
shr eax, 0xc
mov dword [ebp - 0x2c], eax
mov ecx, dword [ebp - 0x2c]
shl ecx, 2
push ecx
call fcn.004095ed
add esp, 4
mov dword [ebp - 0x70], eax
mov edx, dword [ebp - 0x70]
mov dword [ebp - 0x40], edx
push 0
call fcn.0040a19c
add esp, 4
xor eax, dword [0x41115c]
xor eax, dword [0x411168]
xor eax, dword [0x41117c]
xor eax, dword [0x411184]
xor eax, dword [0x411178]
mov dword [ebp - 0x84], eax
mov eax, dword [ebp - 0x84]
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x44], 0
jmp 0x4075f5
mov ecx, dword [ebp - 0x44]
add ecx, 1
mov dword [ebp - 0x44], ecx
mov edx, dword [ebp - 0x44]
cmp edx, dword [ebp - 0x2c]
jge 0x407970
mov dword [ebp - 0xa8], 0x100
mov eax, dword [ebp - 0x48]
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0x9c], eax
mov eax, dword [ebp - 0x48]
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0x98], edx
mov eax, 0x1df5e0d
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xa4], eax
mov eax, 0x1df5e0d
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xa0], edx
mov ecx, dword [ebp - 0x98]
imul ecx, dword [ebp - 0xa0]
mov edx, dword [ebp - 0x9c]
imul edx, dword [ebp - 0xa0]
mov eax, dword [ebp - 0x98]
imul eax, dword [ebp - 0xa4]
add eax, edx
xor edx, edx
mov esi, 0x2710
div esi
mov eax, edx
imul eax, eax, 0x2710
add eax, ecx
xor edx, edx
mov ecx, 0x5f5e100
div ecx
mov eax, edx
add eax, 1
xor edx, edx
mov ecx, 0x5f5e100
div ecx
mov dword [ebp - 0x48], edx
mov eax, dword [ebp - 0x48]
xor edx, edx
mov ecx, 0x2710
div ecx
imul eax, dword [ebp - 0xa8]
xor edx, edx
mov ecx, 0x2710
div ecx
and eax, 0xff
mov dword [ebp - 0x94], eax
mov dword [ebp - 0xbc], 0x100
mov eax, dword [ebp - 0x48]
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xb0], eax
mov eax, dword [ebp - 0x48]
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xac], edx
mov eax, 0x1df5e0d
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xb8], eax
mov eax, 0x1df5e0d
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xb4], edx
mov ecx, dword [ebp - 0xac]
imul ecx, dword [ebp - 0xb4]
mov edx, dword [ebp - 0xb0]
imul edx, dword [ebp - 0xb4]
mov eax, dword [ebp - 0xac]
imul eax, dword [ebp - 0xb8]
add eax, edx
xor edx, edx
mov esi, 0x2710
div esi
mov eax, edx
imul eax, eax, 0x2710
add eax, ecx
xor edx, edx
mov ecx, 0x5f5e100
div ecx
mov eax, edx
add eax, 1
xor edx, edx
mov ecx, 0x5f5e100
div ecx
mov dword [ebp - 0x48], edx
mov eax, dword [ebp - 0x48]
xor edx, edx
mov ecx, 0x2710
div ecx
imul eax, dword [ebp - 0xbc]
xor edx, edx
mov ecx, 0x2710
div ecx
and eax, 0xff
mov dword [ebp - 0x88], eax
mov dword [ebp - 0xd0], 0x100
mov eax, dword [ebp - 0x48]
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xc4], eax
mov eax, dword [ebp - 0x48]
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xc0], edx
mov eax, 0x1df5e0d
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xcc], eax
mov eax, 0x1df5e0d
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xc8], edx
mov ecx, dword [ebp - 0xc0]
imul ecx, dword [ebp - 0xc8]
mov edx, dword [ebp - 0xc4]
imul edx, dword [ebp - 0xc8]
mov eax, dword [ebp - 0xc0]
imul eax, dword [ebp - 0xcc]
add eax, edx
xor edx, edx
mov esi, 0x2710
div esi
mov eax, edx
imul eax, eax, 0x2710
add eax, ecx
xor edx, edx
mov ecx, 0x5f5e100
div ecx
mov eax, edx
add eax, 1
xor edx, edx
mov ecx, 0x5f5e100
div ecx
mov dword [ebp - 0x48], edx
mov eax, dword [ebp - 0x48]
xor edx, edx
mov ecx, 0x2710
div ecx
imul eax, dword [ebp - 0xd0]
xor edx, edx
mov ecx, 0x2710
div ecx
and eax, 0xff
mov dword [ebp - 0x8c], eax
mov dword [ebp - 0xe4], 0x100
mov eax, dword [ebp - 0x48]
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xd8], eax
mov eax, dword [ebp - 0x48]
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xd4], edx
mov eax, 0x1df5e0d
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xe0], eax
mov eax, 0x1df5e0d
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xdc], edx
mov ecx, dword [ebp - 0xd4]
imul ecx, dword [ebp - 0xdc]
mov edx, dword [ebp - 0xd8]
imul edx, dword [ebp - 0xdc]
mov eax, dword [ebp - 0xd4]
imul eax, dword [ebp - 0xe0]
add eax, edx
xor edx, edx
mov esi, 0x2710
div esi
mov eax, edx
imul eax, eax, 0x2710
add eax, ecx
xor edx, edx
mov ecx, 0x5f5e100
div ecx
mov eax, edx
add eax, 1
xor edx, edx
mov ecx, 0x5f5e100
div ecx
mov dword [ebp - 0x48], edx
mov eax, dword [ebp - 0x48]
xor edx, edx
mov ecx, 0x2710
div ecx
imul eax, dword [ebp - 0xe4]
xor edx, edx
mov ecx, 0x2710
div ecx
and eax, 0xff
mov dword [ebp - 0x90], eax
mov edx, dword [ebp - 0x8c]
shl edx, 8
mov eax, dword [ebp - 0x88]
shl eax, 0x10
mov ecx, dword [ebp - 0x94]
shl ecx, 0x18
or ecx, eax
or ecx, edx
or ecx, dword [ebp - 0x90]
mov edx, dword [ebp - 0x44]
mov eax, dword [ebp - 0x40]
mov dword [eax + edx*4], ecx
jmp 0x4075ec
mov ecx, dword [0x411160]
xor ecx, dword [0x411178]
xor ecx, dword [0x41117c]
push ecx
mov edx, dword [ebp - 0x40]
push edx
mov eax, dword [ebp - 8]
push eax
mov ecx, dword [ebp - 0x14]
push ecx
call fcn.004053e7
add esp, 0x10
lea edx, [ebp - 0x1c]
push edx
push 4
mov eax, dword [ebp - 8]
push eax
mov ecx, dword [ebp - 0x10]
push ecx
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.KERNEL32.dll_VirtualProtectEx]
test eax, eax
jne 0x4079ba
xor al, al
jmp 0x407dd2
xor eax, eax
mov al, byte [0x41236e]
test eax, eax
je 0x407a09
mov ecx, dword [ebp - 0x34]
add ecx, dword [ebp - 0x18]
mov dword [ebp - 0x20], ecx
mov edx, dword [ebp - 0x34]
add edx, dword [ebp - 4]
mov dword [ebp - 0x24], edx
mov eax, dword [ebp - 0x20]
cmp eax, dword [ebp - 0x24]
jae 0x407a09
mov ecx, dword [ebp - 0x38]
shr ecx, 0xc
mov edx, dword [ebp - 0x20]
mov eax, dword [ebp - 0x40]
mov edx, dword [edx]
xor edx, dword [eax + ecx*4]
mov eax, dword [ebp - 0x20]
mov dword [eax], edx
mov ecx, dword [ebp - 0x20]
add ecx, 4
mov dword [ebp - 0x20], ecx
mov edx, dword [ebp - 0x38]
add edx, 4
mov dword [ebp - 0x38], edx
jmp 0x4079d7
lea eax, [ebp - 0xc]
push eax
mov ecx, dword [ebp - 4]
sub ecx, dword [ebp - 0x18]
push ecx
mov edx, dword [ebp - 0x34]
add edx, dword [ebp - 0x18]
push edx
mov eax, dword [ebp - 0x10]
push eax
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
jne 0x407a34
xor al, al
jmp 0x407dd2
mov edx, dword [ebp - 4]
sub edx, dword [ebp - 0x18]
mov eax, dword [ebp - 0x10]
add eax, edx
mov dword [ebp - 0x10], eax
mov ecx, 1
test ecx, ecx
je 0x407b05
mov dword [ebp - 4], 0x10000
mov edx, dword [ebp + 0x10]
push edx
lea eax, [ebp - 4]
push eax
mov ecx, dword [ebp - 0x34]
push ecx
mov edx, dword [ebp + 0xc]
push edx
call fcn.0040716f
add esp, 0x10
and eax, 0xff
test eax, eax
jne 0x407a7e
xor al, al
jmp 0x407dd2
cmp dword [ebp - 4], 0
jne 0x407a86
jmp 0x407b05
xor eax, eax
mov al, byte [0x41236e]
test eax, eax
je 0x407ad2
mov ecx, dword [ebp - 0x34]
mov dword [ebp - 0x20], ecx
mov edx, dword [ebp - 0x34]
add edx, dword [ebp - 4]
mov dword [ebp - 0x24], edx
mov eax, dword [ebp - 0x20]
cmp eax, dword [ebp - 0x24]
jae 0x407ad2
mov ecx, dword [ebp - 0x38]
shr ecx, 0xc
mov edx, dword [ebp - 0x20]
mov eax, dword [ebp - 0x40]
mov edx, dword [edx]
xor edx, dword [eax + ecx*4]
mov eax, dword [ebp - 0x20]
mov dword [eax], edx
mov ecx, dword [ebp - 0x20]
add ecx, 4
mov dword [ebp - 0x20], ecx
mov edx, dword [ebp - 0x38]
add edx, 4
mov dword [ebp - 0x38], edx
jmp 0x407aa0
lea eax, [ebp - 0xc]
push eax
mov ecx, dword [ebp - 4]
push ecx
mov edx, dword [ebp - 0x34]
push edx
mov eax, dword [ebp - 0x10]
push eax
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
jne 0x407af7
xor al, al
jmp 0x407dd2
mov edx, dword [ebp - 0x10]
add edx, dword [ebp - 4]
mov dword [ebp - 0x10], edx
jmp 0x407a42
mov dword [ebp - 0x28], 0
jmp 0x407b17
mov eax, dword [ebp - 0x28]
add eax, 1
mov dword [ebp - 0x28], eax
xor ecx, ecx
mov cx, word [0x41248c]
cmp dword [ebp - 0x28], ecx
jge 0x407d8a
mov edx, dword [ebp - 0x28]
shl edx, 1
mov eax, dword [0x412490]
mov ecx, dword [eax + edx*4]
mov dword [ebp - 0x58], ecx
mov edx, dword [ebp - 0x28]
shl edx, 1
mov eax, dword [0x412490]
mov ecx, dword [eax + edx*4 + 4]
mov dword [ebp - 0x54], ecx
mov word [ebp - 0x50], 0
push 0
lea edx, [ebp - 0x4c]
push edx
push 2
lea eax, [ebp - 0x50]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_ReadFile]
mov edx, dword [ebp - 0x50]
and edx, 0xffff
push edx
call fcn.004095ed
add esp, 4
mov dword [ebp - 0x74], eax
mov eax, dword [ebp - 0x74]
mov dword [ebp - 0x5c], eax
push 0
lea ecx, [ebp - 0x4c]
push ecx
mov edx, dword [ebp - 0x50]
and edx, 0xffff
push edx
mov eax, dword [ebp - 0x5c]
push eax
mov ecx, dword [ebp + 0xc]
push ecx
call dword [sym.imp.KERNEL32.dll_ReadFile]
cmp dword [ebp - 0x58], 0
je 0x407d73
mov edx, dword [ebp - 0x54]
mov dword [ebp - 0x68], edx
mov eax, dword [ebp - 0x5c]
mov dword [ebp - 0x60], eax
mov ecx, dword [ebp - 0x50]
and ecx, 0xffff
mov edx, dword [ebp - 0x60]
add edx, ecx
mov dword [ebp - 0x64], edx
jmp 0x407bd1
mov eax, dword [ebp - 0x60]
add eax, 1
mov dword [ebp - 0x60], eax
mov ecx, dword [ebp - 0x60]
cmp ecx, dword [ebp - 0x64]
jae 0x407cb2
mov dword [ebp - 0xf8], 0x100
mov eax, dword [ebp - 0x68]
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xec], eax
mov eax, dword [ebp - 0x68]
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xe8], edx
mov eax, 0x1df5e0d
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xf4], eax
mov eax, 0x1df5e0d
cdq
mov ecx, 0x2710
idiv ecx
mov dword [ebp - 0xf0], edx
mov ecx, dword [ebp - 0xe8]
imul ecx, dword [ebp - 0xf0]
mov edx, dword [ebp - 0xec]
imul edx, dword [ebp - 0xf0]
mov eax, dword [ebp - 0xe8]
imul eax, dword [ebp - 0xf4]
add eax, edx
xor edx, edx
mov esi, 0x2710
div esi
mov eax, edx
imul eax, eax, 0x2710
add eax, ecx
xor edx, edx
mov ecx, 0x5f5e100
div ecx
mov eax, edx
add eax, 1
xor edx, edx
mov ecx, 0x5f5e100
div ecx
mov dword [ebp - 0x68], edx
mov eax, dword [ebp - 0x68]
xor edx, edx
mov ecx, 0x2710
div ecx
imul eax, dword [ebp - 0xf8]
xor edx, edx
mov ecx, 0x2710
div ecx
mov edx, dword [ebp - 0x60]
mov cl, byte [edx]
xor cl, al
mov edx, dword [ebp - 0x60]
mov byte [edx], cl
jmp 0x407bc8
xor eax, eax
mov al, byte [0x41236e]
test eax, eax
je 0x407d4b
push 0
mov ecx, dword [ebp - 0x58]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.00405010
add esp, 0xc
push 0
mov eax, dword [ebp - 0x50]
and eax, 0xffff
mov ecx, dword [ebp - 0x58]
add ecx, eax
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.00405010
add esp, 0xc
lea eax, [ebp - 0xc]
push eax
mov ecx, dword [ebp - 0x50]
and ecx, 0xffff
push ecx
mov edx, dword [ebp - 0x5c]
push edx
mov eax, dword [ebp - 0x58]
push eax
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
jne 0x407d1a
xor al, al
jmp 0x407dd2
push 1
mov edx, dword [ebp - 0x50]
and edx, 0xffff
mov eax, dword [ebp - 0x58]
add eax, edx
push eax
mov ecx, dword [ebp + 8]
push ecx
call fcn.00405010
add esp, 0xc
push 1
mov edx, dword [ebp - 0x58]
push edx
mov eax, dword [ebp + 8]
push eax
call fcn.00405010
add esp, 0xc
jmp 0x407d73
lea ecx, [ebp - 0xc]
push ecx
mov edx, dword [ebp - 0x50]
and edx, 0xffff
push edx
mov eax, dword [ebp - 0x5c]
push eax
mov ecx, dword [ebp - 0x58]
push ecx
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.KERNEL32.dll_WriteProcessMemory]
test eax, eax
jne 0x407d73
xor al, al
jmp 0x407dd2
mov eax, dword [ebp - 0x5c]
mov dword [ebp - 0x78], eax
mov ecx, dword [ebp - 0x78]
push ecx
call fcn.004095e2
add esp, 4
jmp 0x407b0e
lea edx, [ebp - 0x1c]
push edx
mov eax, dword [ebp - 0x1c]
push eax
mov ecx, dword [ebp - 8]
push ecx
mov edx, dword [ebp - 0x14]
push edx
mov eax, dword [ebp + 8]
push eax
call dword [sym.imp.KERNEL32.dll_VirtualProtectEx]
test eax, eax
jne 0x407dac
xor al, al
jmp 0x407dd2
mov ecx, dword [ebp - 0x34]
mov dword [ebp - 0x7c], ecx
mov edx, dword [ebp - 0x7c]
push edx
call fcn.004095e2
add esp, 4
mov eax, dword [ebp - 0x40]
mov dword [ebp - 0x80], eax
mov ecx, dword [ebp - 0x80]
push ecx
call fcn.004095e2
add esp, 4
mov al, 1
pop esi
mov esp, ebp
pop ebp
ret