Function at 0x452ab8
Capabilities:
Read file on windows

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x30074
call fcn.004c5de0
push ebx
mov ebx, ecx
xor eax, eax
xor ecx, ecx
cmp dword [ebp + 8], eax
push esi
push edi
setl cl
cmp ecx, eax
mov dword [ebp - 0x28], ecx
je 0x452ae3
mov ecx, dword [ebp + 8]
neg ecx
mov dword [ebp + 8], ecx
mov ecx, dword [ebx + 0x64]
lea esi, [ebx + 0x64]
mov edi, 0x4d823c
cmp dword [ecx - 8], eax
je 0x452b16
cmp dword [ebp + 0x10], eax
jne 0x452b06
mov ecx, dword [ebx + 0x68]
shr ecx, 0xa
and ecx, 1
cmp ecx, dword [ebp - 0x28]
je 0x452b16
and word [ebx + 0x68], 0xfa01
push edi
mov ecx, esi
call fcn.00402e2b
xor eax, eax
mov ecx, dword [esi]
cmp dword [ecx - 8], eax
jne 0x453506
mov ecx, dword [ebx + 0x48]
call fcn.00461390
test eax, eax
jne 0x452b43
mov ecx, dword [ebp + 0xc]
push edi
call fcn.00402e2b
and word [ebx + 0x68], 0xfa01
xor eax, eax
jmp 0x453534
mov eax, dword [0x4e9e94]
mov ecx, dword fs:[0x2c]
mov edi, dword [ecx + eax*4]
mov dword [ebp - 0x5c], edi
mov ecx, dword [edi + 4]
cmp dword [ecx + 0x84], 0
je 0x452b6b
push 1
call fcn.0047a9a3
mov ecx, ebx
call fcn.0045aaed
test eax, eax
mov dword [ebp - 0x1c], eax
mov dword [ebp - 0x18], edx
mov esi, 0x40000000
jne 0x452bb3
test edx, edx
jne 0x452bb3
test dword [ebx + 0x24], esi
je 0x452bb3
mov ecx, ebx
call fcn.0041d8dd
test eax, eax
jne 0x452bb3
mov ecx, ebx
call fcn.0041d9b9
test eax, eax
je 0x452bb3
mov eax, dword [edi + 4]
and dword [ebp - 0x18], 0
mov eax, dword [eax + 0x680]
mov dword [ebp - 0x1c], eax
mov eax, dword [0x4cfce8]
mov dword [ebp - 0x44], eax
mov eax, dword [ebp - 0x1c]
or eax, dword [ebp - 0x18]
je 0x452c25
mov eax, dword [edi + 4]
cmp dword [eax + 0x680], 0
je 0x452c25
mov ecx, ebx
call fcn.00421820
test eax, eax
jne 0x452c25
test byte [0x4d9124], 0x80
jne 0x452c07
test dword [ebx + 0x24], esi
je 0x452c07
mov ecx, ebx
call fcn.0045a7aa
mov ecx, eax
mov eax, 0x1000
and ecx, eax
sub ecx, eax
neg ecx
sbb ecx, ecx
inc ecx
mov dword [ebp - 0x10], ecx
jne 0x452c25
mov eax, dword [ebx]
lea ecx, [ebp - 4]
push 1
push ecx
mov ecx, ebx
call dword [eax + 0x1c]
push eax
lea ecx, [ebp - 0x44]
call fcn.00402dbe
lea ecx, [ebp - 4]
call fcn.004010b4
mov eax, dword [ebp - 0x44]
xor esi, esi
cmp dword [eax - 8], esi
je 0x4533fd
push esi
push 0x8000080
push 3
push esi
push 3
push SysReAllocStringLen
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
cmp eax, 0xffffffff
mov dword [ebp - 0x50], eax
je 0x4533fd
mov eax, dword [edi + 4]
xor ecx, ecx
cmp dword [ebp - 0x18], ecx
mov eax, dword [eax + 0x680]
jb 0x452c70
ja 0x452c73
cmp dword [ebp - 0x1c], eax
ja 0x452c73
mov eax, dword [ebp - 0x1c]
mov dword [ebp - 0x14], eax
mov eax, 0x10000
cmp dword [ebp - 0x14], eax
jbe 0x452c83
mov dword [ebp - 0x14], eax
lea eax, [ebp - 8]
push esi
push eax
lea eax, [ebp - 0x10070]
push dword [ebp - 0x14]
push eax
push dword [ebp - 0x50]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4533ef
mov eax, dword [ebp - 8]
test al, 1
mov word [ebp + eax - 0x10070], si
je 0x452cba
and byte [ebp + eax - 0x1006e], 0
mov dword [ebp - 0x24], eax
xor eax, eax
cmp word [ebp - 0x10070], 0xfeff
mov dword [ebp - 0x20], esi
mov dword [ebp - 0x34], esi
sete al
cmp eax, esi
mov dword [ebp - 0xc], eax
je 0x452cdf
mov dword [ebp - 0x34], 2
mov edi, dword [0x4d58d0]
push 3
pop eax
lea esi, [ebp - 0x10070]
mov ecx, eax
xor edx, edx
repe cmpsb byte [esi], byte es:[edi]
sete dl
test edx, edx
mov dword [ebp - 0x40], edx
je 0x452d01
mov dword [ebp - 0x34], eax
mov eax, dword [ebx]
and dword [ebp - 0x58], 0
and dword [ebp - 0x54], 0
mov ecx, ebx
call dword [eax + 0x18]
push eax
call fcn.0046bde8
test eax, eax
pop ecx
mov dword [ebp - 0x30], eax
je 0x452d33
push 0x4d0520
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
mov edi, eax
neg edi
sbb edi, edi
inc edi
jmp 0x452d35
xor edi, edi
mov eax, dword [ebx + 0xd0]
test eax, eax
je 0x452d46
mov eax, dword [eax]
mov esi, dword [eax + 0x34]
jmp 0x452d48
xor esi, esi
xor eax, eax
cmp dword [ebp - 0xc], eax
jne 0x452db5
cmp dword [ebp - 0x40], eax
jne 0x452db5
cmp esi, eax
jne 0x452d7d
cmp edi, eax
jne 0x452da7
cmp dword [ebp + 0x10], eax
jne 0x452dac
push dword [ebp - 8]
lea eax, [ebp - 0x10070]
push eax
call fcn.004726ad
pop ecx
cmp eax, 2
pop ecx
jb 0x452db7
test eax, eax
mov esi, eax
je 0x452db7
mov eax, esi
dec eax
je 0x452d9e
dec eax
je 0x452d95
dec eax
je 0x452dac
dec eax
dec eax
jne 0x452db7
mov dword [ebp - 0x54], 1
jmp 0x452db7
mov dword [ebp - 0x40], 1
jmp 0x452db7
mov dword [ebp - 0x58], 1
jmp 0x452db7
cmp dword [ebp + 0x10], eax
je 0x452db7
mov dword [ebp - 0xc], 1
jmp 0x452db7
xor edi, edi
xor eax, eax
cmp dword [ebp - 0xc], eax
mov dword [ebp - 4], eax
jne 0x452dd2
cmp edi, eax
je 0x452e21
cmp dword [0x4d9570], eax
je 0x452e21
xor edi, edi
push 1
pop eax
xor edx, edx
cmp esi, 4
mov dword [ebp - 0x30], edx
mov dword [ebp - 0x48], edx
jne 0x452ded
push 1
xor eax, eax
pop ecx
mov dword [ebp - 0x34], edx
mov dword [ebp - 0x30], ecx
mov dword [ebp - 0x48], ecx
cmp eax, edx
je 0x452e6f
push dword [ebp - 0x14]
lea eax, [ebp - 0x10070]
mov ecx, ebx
push eax
push dword [ebp - 0x44]
call fcn.00454627
test eax, eax
jne 0x4533ef
and dword [ebp - 0x28], eax
cmp dword [ebx + 0xd0], eax
je 0x452e68
mov dword [ebp - 0x48], 1
jmp 0x452e75
push dword [ebp - 8]
lea eax, [ebp - 0x10070]
push eax
call fcn.0047266f
pop ecx
test eax, eax
pop ecx
jne 0x452dcf
cmp dword [0x4d9ab4], eax
jne 0x452e46
cmp dword [0x4d0350], eax
je 0x452e61
cmp dword [ebp - 0x30], eax
je 0x452e61
push 0x4d4c24
push dword [ebp - 0x30]
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
je 0x452dcf
xor eax, eax
jmp 0x452dd2
mov dword [ebp - 4], 1
cmp dword [ebp - 0x48], 0
je 0x452e9e
mov eax, dword [ebp - 8]
lea esi, [ebp - 0x10070]
lea ecx, [ebp - 0x10070]
lea edx, [ebp + eax - 0x10070]
cmp esi, edx
jae 0x452ea1
cmp byte [ecx], 0
jne 0x452e97
mov byte [ecx], 0x2e
inc ecx
cmp ecx, edx
jb 0x452e8f
jmp 0x452ea1
mov eax, dword [ebp - 8]
xor edx, edx
cmp dword [ebp - 0x30], edx
je 0x452ec2
lea eax, [ebp - 0x10070]
lea esi, [ebx + 0x64]
push eax
mov ecx, esi
call fcn.00402e2b
or dword [ebx + 0x68], 2
jmp 0x453028
cmp dword [ebp - 0xc], edx
je 0x452f19
mov esi, dword [ebp - 0x34]
cmp esi, edx
jne 0x452efe
shr eax, 1
lea edi, [ebp - 0x10070]
mov dword [ebp - 0x48], 1
lea eax, [ebp + eax*2 - 0x10070]
lea ecx, [ebp - 0x10070]
cmp edi, eax
jae 0x452efe
cmp word [ecx], dx
jne 0x452ef8
mov word [ecx], 0x2e
inc ecx
inc ecx
cmp ecx, eax
jb 0x452eee
lea eax, [ebp + esi - 0x10070]
lea esi, [ebx + 0x64]
push eax
mov ecx, esi
call fcn.0040c114
or dword [ebx + 0x68], 0x12
jmp 0x453028
cmp dword [ebp - 4], edx
je 0x452f51
push dword [ebp + 8]
push eax
lea eax, [ebp - 0x10070]
push eax
lea eax, [ebp - 4]
push eax
call fcn.00470ee8
add esp, 0x10
lea esi, [ebx + 0x64]
mov ecx, esi
push eax
call fcn.00402dbe
lea ecx, [ebp - 4]
call fcn.004010b4
or dword [ebx + 0x68], 8
jmp 0x453028
cmp dword [ebp - 0x40], edx
je 0x452f8b
mov eax, dword [ebp - 0x34]
push 0xffffffffffffffff
lea eax, [ebp + eax - 0x10070]
push eax
lea eax, [ebp - 4]
push eax
call fcn.0046f767
add esp, 0xc
lea esi, [ebx + 0x64]
mov ecx, esi
push eax
call fcn.00402dbe
lea ecx, [ebp - 4]
call fcn.004010b4
or dword [ebx + 0x68], 0x22
jmp 0x453028
cmp dword [ebp - 0x58], edx
je 0x452fbb
lea eax, [ebp - 0x10070]
push eax
lea eax, [ebp - 0x10070]
push eax
call dword [sym.imp.USER32.dll_OemToCharA]
lea eax, [ebp - 0x10070]
lea esi, [ebx + 0x64]
push eax
mov ecx, esi
call fcn.00402e2b
or dword [ebx + 0x68], 0x42
jmp 0x453028
cmp dword [ebp - 0x54], edx
je 0x45300b
lea eax, [ebp - 0x30074]
push 0x10002
push eax
and word [ebp - 0x30074], 0
lea eax, [ebp - 0x10070]
push 0xffffffffffffffff
push eax
mov eax, dword [ebp - 0x5c]
push 0
mov eax, dword [eax + 4]
push dword [eax + 0xb4]
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
lea eax, [ebp - 0x30074]
lea esi, [ebx + 0x64]
push eax
mov ecx, esi
call fcn.0040c114
or byte [ebx + 0x68], 0x82
jmp 0x453028
lea eax, [ebp - 0x10070]
lea esi, [ebx + 0x64]
push eax
mov ecx, esi
call fcn.00402e2b
neg edi
sbb edi, edi
and edi, 2
inc edi
inc edi
or dword [ebx + 0x68], edi
mov eax, dword [0x4cfce8]
push 0x2bcc
lea ecx, [ebp - 0x4c]
mov dword [ebp - 0x4c], eax
call fcn.00403548
mov eax, dword [ebp - 0x18]
xor edi, edi
and dword [ebp - 0x38], edi
cmp dword [ebp - 0x20], eax
ja 0x45313a
jb 0x45305c
mov eax, dword [ebp - 0x24]
cmp eax, dword [ebp - 0x1c]
jae 0x45313a
cmp dword [ebx + 0xd0], 0
je 0x45311f
and dword [ebp - 0x28], 0
lea eax, [ebp - 0x10]
push eax
lea eax, [ebp - 4]
push 0
push eax
mov ecx, ebx
call fcn.0045be1b
mov eax, dword [ebx + 0xd0]
mov edx, dword [eax + 4]
mov eax, dword [ebp - 0x10]
mov ecx, dword [edx + eax*8]
cmp ecx, 0xfffffffe
mov eax, dword [edx + eax*8 + 4]
mov dword [ebp - 0x60], eax
jne 0x4530a3
cmp eax, 0xffffffff
jne 0x4530a3
xor ecx, ecx
mov dword [ebp - 0x60], ecx
mov eax, dword [ebp - 4]
mov eax, dword [eax - 8]
cdq
add eax, ecx
adc edx, dword [ebp - 0x60]
mov dword [ebp - 0x6c], eax
cmp edx, dword [ebp - 0x20]
jb 0x453115
ja 0x4530be
cmp eax, dword [ebp - 0x24]
jbe 0x453115
mov eax, dword [ebp - 0x14]
mov edx, ecx
shr eax, 1
xor edi, edi
add edx, eax
mov dword [ebp - 0x6c], edx
mov edx, dword [ebp - 0x60]
adc edx, edi
mov dword [ebp - 8], eax
cmp edx, dword [ebp - 0x18]
jb 0x4530f2
ja 0x4530e3
mov edx, dword [ebp - 0x6c]
cmp edx, dword [ebp - 0x1c]
jbe 0x4530f2
mov edi, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x18]
xor ecx, ecx
sub edi, dword [ebp - 0x14]
sbb eax, ecx
jmp 0x4530fe
push 0
sub ecx, eax
mov eax, dword [ebp - 0x60]
pop edx
sbb eax, edx
mov edi, ecx
mov ecx, dword [ebp - 0x20]
mov dword [ebp - 0x38], eax
cmp eax, ecx
ja 0x453115
jb 0x45310f
cmp edi, dword [ebp - 0x24]
jae 0x453115
mov edi, dword [ebp - 0x24]
mov dword [ebp - 0x38], ecx
lea ecx, [ebp - 4]
call fcn.004010b4
jmp 0x453148
cmp dword [ebp - 0x28], 0
je 0x4533ae
mov edi, dword [ebp - 0x1c]
mov eax, dword [ebp - 0x18]
sub edi, dword [ebp - 0x24]
sbb eax, dword [ebp - 0x20]
mov dword [ebp - 0x38], eax
jmp 0x45314b
cmp dword [ebp - 0x28], 0
je 0x4533ae
or byte [ebx + 0x69], 4
mov eax, dword [ebp - 0x38]
mov ecx, edi
or ecx, eax
je 0x4533ae
xor ecx, ecx
cmp dword [ebp - 0xc], ecx
je 0x45316b
mov eax, edi
and eax, 1
or eax, ecx
je 0x45316b
add edi, 1
adc dword [ebp - 0x38], ecx
mov eax, dword [ebp - 0x38]
push 0
mov dword [ebp - 8], eax
lea eax, [ebp - 8]
push eax
push edi
push dword [ebp - 0x50]
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
cmp eax, 0xffffffff
jne 0x453193
mov eax, dword [ebp - 0x20]
mov edi, dword [ebp - 0x24]
and dword [ebp - 0x14], 0
mov dword [ebp - 0x38], eax
lea eax, [ebp - 8]
push 0
push eax
lea eax, [ebp - 0x10070]
push dword [ebp - 0x14]
push eax
push dword [ebp - 0x50]
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x4533ae
mov edx, dword [ebp - 8]
test edx, edx
je 0x4533ae
cmp dword [ebp - 0x28], 0
je 0x4531c9
or byte [ebx + 0x69], 4
mov eax, dword [ebp - 0x38]
cmp eax, dword [ebp - 0x20]
jb 0x453216
ja 0x4531d8
cmp edi, dword [ebp - 0x24]
jbe 0x453216
mov eax, 0x4d4c54
lea ecx, [ebp - 0x4c]
push eax
push ecx
push eax
lea eax, [ebp - 4]
push eax
call fcn.00402f03
push eax
lea eax, [ebp - 0x10]
push eax
call fcn.00402e70
mov eax, dword [eax]
mov ecx, esi
push eax
push dword [eax - 8]
call fcn.00402f96
lea ecx, [ebp - 0x10]
call fcn.004010b4
lea ecx, [ebp - 4]
call fcn.004010b4
mov edx, dword [ebp - 8]
and word [ebp + edx - 0x10070], 0
cmp dword [ebp - 0xc], 0
lea esi, [ebp + edx - 0x10070]
je 0x453239
test dl, 1
je 0x453239
and byte [ebp + edx - 0x1006e], 0
mov eax, edx
xor ecx, ecx
add eax, edi
adc ecx, dword [ebp - 0x38]
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x20], ecx
xor ecx, ecx
cmp dword [ebp - 0x48], ecx
je 0x453271
cmp dword [ebp - 0xc], ecx
jne 0x453271
lea edi, [ebp - 0x10070]
lea eax, [ebp - 0x10070]
cmp edi, esi
jae 0x453271
cmp byte [eax], 0
jne 0x45326c
mov byte [eax], 0x2e
inc eax
cmp eax, esi
jb 0x453264
cmp dword [ebp - 0x30], ecx
jne 0x453385
cmp dword [ebp - 0xc], ecx
je 0x4532da
cmp dword [ebp - 0x34], ecx
jne 0x4532ad
shr edx, 1
lea esi, [ebp - 0x10070]
lea eax, [ebp - 0x10070]
lea edx, [ebp + edx*2 - 0x10070]
cmp esi, edx
jae 0x4532ad
cmp word [eax], cx
jne 0x4532a7
mov word [eax], 0x2e
inc eax
inc eax
cmp eax, edx
jb 0x45329d
lea eax, [ebp - 0x10070]
lea ecx, [ebp - 4]
push eax
call fcn.0040b8b5
mov eax, dword [ebp - 4]
lea esi, [ebx + 0x64]
push eax
mov ecx, esi
push dword [eax - 8]
call fcn.00402f96
lea ecx, [ebp - 4]
call fcn.004010b4
jmp 0x4533ae
cmp dword [ebp - 0x40], ecx
je 0x453309
lea eax, [ebp - 0x10070]
push 0xffffffffffffffff
push eax
lea eax, [ebp - 0x10]
push eax
call fcn.0046f767
mov eax, dword [eax]
add esp, 0xc
lea esi, [ebx + 0x64]
push eax
mov ecx, esi
push dword [eax - 8]
call fcn.00402f96
lea ecx, [ebp - 0x10]
jmp 0x4532d0
cmp dword [ebp - 0x54], ecx
je 0x45336a
lea eax, [ebp - 0x30074]
push 0x10002
push eax
and word [ebp - 0x30074], 0
lea eax, [ebp - 0x10070]
push 0xffffffffffffffff
push eax
mov eax, dword [ebp - 0x5c]
push 0
mov eax, dword [eax + 4]
push dword [eax + 0xb4]
call dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
lea eax, [ebp - 0x30074]
lea ecx, [ebp - 4]
push eax
call fcn.0040b8b5
mov eax, dword [ebp - 4]
lea esi, [ebx + 0x64]
push eax
mov ecx, esi
push dword [eax - 8]
call fcn.00402f96
lea ecx, [ebp - 4]
jmp 0x4532d0
cmp dword [ebp - 0x58], ecx
je 0x453385
lea eax, [ebp - 0x10070]
push eax
lea eax, [ebp - 0x10070]
push eax
call dword [sym.imp.USER32.dll_OemToCharA]
xor ecx, ecx
lea eax, [ebp - 0x10070]
test eax, eax
je 0x45339c
lea eax, [ebp - 0x10070]
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
lea ecx, [ebp - 0x10070]
lea esi, [ebx + 0x64]
push ecx
push eax
mov ecx, esi
call fcn.00402f96
mov eax, dword [ebp - 0x18]
cmp dword [ebp - 0x20], eax
ja 0x4533e7
jb 0x4533c0
mov eax, dword [ebp - 0x1c]
cmp dword [ebp - 0x24], eax
jae 0x4533e7
lea eax, [ebp - 0x4c]
push eax
lea eax, [ebp - 0x10]
push 0x4d4c54
push eax
call fcn.00402f03
mov eax, dword [eax]
mov ecx, esi
push eax
push dword [eax - 8]
call fcn.00402f96
lea ecx, [ebp - 0x10]
call fcn.004010b4
lea ecx, [ebp - 0x4c]
call fcn.004010b4
push dword [ebp - 0x50]
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov edi, dword [ebp - 0x5c]
xor esi, esi
mov ecx, dword [edi + 4]
cmp dword [ecx + 0x84], esi
je 0x453411
push esi
call fcn.0047a9a3
mov eax, dword [ebx + 0x64]
lea esi, [ebx + 0x64]
cmp dword [eax - 8], 0
jne 0x45342e
push str.__r_t_n
mov ecx, esi
call fcn.00402e2b
jmp 0x4534f9
mov ecx, dword [ebx + 0xd0]
test ecx, ecx
je 0x4534f9
call fcn.0045bf46
test eax, eax
je 0x4534f9
push 0
lea eax, [ebp - 0x10]
push 0
push eax
mov ecx, ebx
call fcn.0045be1b
mov eax, dword [eax]
mov ecx, dword [esi]
push eax
push ecx
call dword [0x4d7a84]
neg eax
sbb al, al
lea ecx, [ebp - 0x10]
inc al
mov byte [ebp - 0x29], al
call fcn.004010b4
cmp byte [ebp - 0x29], 0
je 0x4534f9
mov eax, dword [ebx + 0xd0]
mov eax, dword [eax]
push dword [eax + 0x38]
push eax
push dword [ebp - 0x44]
call fcn.00471b10
add esp, 0xc
test eax, eax
jle 0x4534f9
mov ecx, dword [edi + 4]
cmp dword [ecx + 0x84], 0
je 0x4534ac
push 1
call fcn.0047a9a3
mov eax, dword [ebx + 0xd0]
mov ecx, ebx
mov eax, dword [eax]
inc dword [eax + 0x68]
mov eax, dword [ebx + 0xd0]
push dword [eax]
call fcn.0045bc7a
mov eax, dword [ebx + 0xd0]
mov ecx, dword [eax]
call fcn.004399b8
push dword [ebp + 0x10]
mov ecx, ebx
push dword [ebp + 0xc]
push dword [ebp + 8]
call fcn.00452ab8
mov ecx, dword [edi + 4]
cmp dword [ecx + 0x84], 0
je 0x4534f9
push 0
call fcn.0047a9a3
lea ecx, [ebp - 0x44]
call fcn.004010b4
mov edi, 0x4d823c
mov eax, dword [esi]
push str.__r_t_n
push eax
call dword [sym.imp.MSVCRT.dll__mbscmp]
pop ecx
test eax, eax
pop ecx
jne 0x453525
mov ecx, dword [ebp + 0xc]
push edi
call fcn.00402e2b
jmp 0x45352e
mov ecx, dword [ebp + 0xc]
push esi
call fcn.00402dbe
mov eax, dword [ebx + 0x68]
and eax, 0xe
pop edi
pop esi
pop ebx
leave
ret 0xc