Function at 0x436430
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x20
mov eax, dword [ebp + 0xc]
push ebx
push esi
mov esi, dword [ebp + 8]
push edi
mov edi, dword [eax]
mov ecx, edi
mov edx, edi
mov dword [ebp - 0x18], 0
mov eax, dword [esi + 0x58]
and ecx, 1
and edx, 2
mov dword [ebp - 0x10], ecx
and edi, 4
mov dword [ebp - 0x20], edx
mov dword [ebp - 0x14], edi
test eax, 0x200
je 0x436473
mov dword [ebp + 8], 1
test ecx, ecx
jne 0x43647a
mov dword [ebp + 8], 0
test edx, edx
je 0x43649b
test eax, 0x4000000
jne 0x43649b
push dword [esi + 0x70]
call fcn.00446a80
add esp, 4
test eax, eax
je 0x43649b
mov ebx, 1
jmp 0x43649d
xor ebx, ebx
test dword [esi + 0x58], 0x4000000
je 0x4364b1
test edi, edi
je 0x4364b1
mov edi, 1
jmp 0x4364b3
xor edi, edi
call fcn.004284e0
mov ecx, eax
mov dword [ebp - 8], edx
mov eax, dword [ebp + 0x10]
cdq
add eax, ecx
mov dword [ebp - 4], ecx
mov dword [ebp - 0xc], eax
adc edx, dword [ebp - 8]
mov dword [ebp - 0x1c], edx
mov edx, dword [ebp + 0xc]
mov dword [edx], 0
mov eax, dword [0x5ea8f8]
test eax, eax
je 0x4364f2
mov eax, dword [eax + 0x1c]
test eax, eax
je 0x4364f2
push dword [esi]
call eax
mov edx, dword [ebp + 0xc]
add esp, 4
mov ecx, dword [ebp + 8]
test ecx, ecx
jne 0x4367e0
test ebx, ebx
jne 0x4367cf
test edi, edi
jne 0x4367be
cmp dword [ebp - 0x10], edi
je 0x43668b
test dword [esi + 0x58], 0x400
jne 0x43668b
mov eax, dword [esi + 0xe0]
xorps xmm0, xmm0
mov dword [ebp - 0x18], 1
movups xmmword [eax], xmm0
mov dword [eax + 0x10], edi
mov eax, dword [esi + 0xe0]
mov dword [eax + 0x10], esi
lea eax, [esi + 0xd4]
lock inc dword [eax]
or dword [esi + 0x58], 0x400
push esi
call fcn.00439940
add esp, 4
lea eax, [esi + 0x100]
push 0x433ae0
push dword [esi + 0xe0]
push 1
push eax
push dword [esi + 0x60]
call dword [sym.imp.KERNEL32.dll_ReadFileEx]
mov edi, eax
push edi
call fcn.00539b90
add esp, 4
test eax, eax
jne 0x4365bb
mov eax, dword fs:[0x2c]
mov eax, dword [eax]
mov eax, dword [eax + 0x28f0]
test eax, eax
jne 0x43659e
call fcn.0053fcd2
push 6
push 0x6d
push 0xe8
push 3
push dword [eax]
call fcn.004322a0
add esp, 0x14
test eax, eax
je 0x4367f0
test edi, edi
jne 0x436670
push 0x5fe820
call fcn.00427d70
mov ecx, dword [esi + 0xbc]
add esp, 4
cmp esi, dword [0x5fe7f8]
jne 0x4365e6
mov dword [0x5fe7f8], ecx
jmp 0x4365f8
mov eax, dword [esi + 0xc0]
mov dword [eax + 0xbc], ecx
mov ecx, dword [0x5fe7f8]
mov edx, dword [esi + 0xbc]
test edx, edx
je 0x436610
mov eax, dword [esi + 0xc0]
mov dword [edx + 0xc0], eax
jmp 0x436620
test ecx, ecx
je 0x436620
mov eax, dword [esi + 0xc0]
mov dword [ecx + 0xc0], eax
push 0x5fe820
mov dword [esi + 0xbc], 0
mov dword [esi + 0xc0], 0
call fcn.00427d80
and dword [esi + 0x58], 0xfffffbff
lea ecx, [esi + 0xd4]
add esp, 4
or eax, 0xffffffff
lock xadd dword [ecx], eax
jne 0x436660
push esi
call fcn.00433280
add esp, 4
or dword [esi + 0x58], 0x100000
push esi
call fcn.004399d0
add esp, 4
test dword [esi + 0x58], 0x4000000
je 0x436686
cmp dword [ebp - 0x14], 0
je 0x436686
mov edi, 1
jmp 0x436688
xor edi, edi
mov ecx, dword [ebp + 8]
mov eax, dword [ebp - 4]
nop
test ebx, ebx
jne 0x43674f
test edi, edi
jne 0x43674f
cmp dword [ebp + 0x10], edi
jl 0x4366c4
mov edx, dword [ebp - 0x1c]
cmp dword [ebp - 8], edx
ja 0x43674f
jb 0x4366bc
cmp eax, dword [ebp - 0xc]
jae 0x43674f
mov eax, dword [ebp - 0xc]
sub eax, dword [ebp - 4]
jmp 0x4366c7
or eax, 0xffffffff
push 1
push eax
call dword [sym.imp.KERNEL32.dll_SleepEx]
mov eax, dword [esi + 0x58]
test eax, 0x200
je 0x4366e7
cmp dword [ebp - 0x10], 0
mov dword [ebp + 8], 1
jne 0x4366ee
mov dword [ebp + 8], 0
cmp dword [ebp - 0x20], 0
je 0x436711
test eax, 0x4000000
jne 0x436711
push dword [esi + 0x70]
call fcn.00446a80
add esp, 4
test eax, eax
je 0x436711
mov ebx, 1
jmp 0x436713
xor ebx, ebx
test dword [esi + 0x58], 0x4000000
je 0x436729
cmp dword [ebp - 0x14], 0
je 0x436729
mov edi, 1
jmp 0x43672b
xor edi, edi
call fcn.004284e0
mov ecx, dword [ebp + 8]
mov dword [ebp - 4], eax
mov dword [ebp - 8], edx
test ecx, ecx
je 0x436690
mov eax, dword [ebp + 0xc]
mov edi, 1
mov ebx, edi
mov dword [eax], edi
jmp 0x43677d
test ecx, ecx
jne 0x436741
test ebx, ebx
jne 0x43676c
test edi, edi
je 0x43677b
mov eax, dword [ebp + 0xc]
lea ebx, [ecx + 1]
neg edi
sbb edi, edi
and edi, 4
mov dword [eax], edi
jmp 0x43677d
mov eax, dword [ebp + 0xc]
mov edi, 2
mov dword [eax], edi
lea ebx, [edi - 1]
jmp 0x43677d
xor ebx, ebx
cmp dword [ebp - 0x18], 0
je 0x4367b5
test dword [esi + 0x58], 0x400
je 0x4367b5
push dword [esi + 0x60]
call fcn.00441570
add esp, 4
test dword [esi + 0x58], 0x400
je 0x4367b5
mov edi, dword [sym.imp.KERNEL32.dll_SleepEx]
push 0xffffffffffffffff
push 0xffffffffffffffff
call edi
test dword [esi + 0x58], 0x400
jne 0x4367a6
pop edi
pop esi
mov eax, ebx
pop ebx
mov esp, ebp
pop ebp
ret
shl edi, 2
mov eax, 1
mov dword [edx], edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov edi, 2
mov dword [edx], edi
lea eax, [edi - 1]
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
mov edi, 1
mov dword [edx], edi
mov eax, edi
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push str.cant_read_from_handle:__m
push 0x360000
call fcn.004232c0
int3