Function at 0x460257
Capabilities:
Get file size
Read file on windows

Disassembly:
push ebp
sub esp, 0x820
lea ebp, [esp - 4]
mov eax, dword [0x69c24c]
xor eax, ebp
mov dword [ebp + 0x820], eax
push 0x38
mov eax, 0x5f337a
call fcn.005bb14d
mov dword [ebp - 0x20], ecx
mov eax, dword [ebp + 0x834]
mov edi, dword [ebp + 0x82c]
mov ebx, dword [ebp + 0x830]
mov dword [ebp - 0x28], eax
xor eax, eax
mov esi, eax
mov dword [ebp - 0x38], edi
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x1c], esi
mov dword [ebp - 4], eax
mov dword [ebp - 0x18], eax
xor ecx, ecx
inc ecx
mov byte [ebp - 4], cl
mov dword [ebp - 0x14], eax
push 2
pop ecx
mov byte [ebp - 4], cl
push eax
test ebx, ebx
jne 0x4602dc
push 0x8000000
push 3
push eax
push 3
push SysReAllocStringLen
push edi
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
mov ebx, esi
mov dword [ebp - 0x1c], esi
mov dword [ebp - 0x30], ebx
jmp 0x4602e5
push eax
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_SetFilePointer]
or eax, 0xffffffff
cmp ebx, eax
jne 0x46034f
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor ebx, ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 0x75
push str.d:_sourcesmachetemachete51_3machetemachete.._XMLCommon.cpp
push edi
push str.CreateFile
push eax
xor edi, edi
inc edi
push edi
push dword [ebp - 0x28]
call fcn.0046e15b
xor eax, eax
add esp, 0x34
inc eax
mov byte [ebp - 4], al
test ebx, ebx
je 0x460330
push 2
pop edx
push edx
push ebx
call fcn.005bb24c
pop ecx
xor eax, eax
pop ecx
inc eax
mov dword [ebp - 0x14], ebx
mov byte [ebp - 4], bl
test ebx, ebx
je 0x460343
push eax
push ebx
call fcn.005bb24c
pop ecx
pop ecx
mov dword [ebp - 0x18], ebx
or dword [ebp - 4], 0xffffffff
jmp 0x4607f6
push 0
push ebx
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
mov dword [ebp - 0x2c], edi
test edi, edi
je 0x460791
cmp edi, 0xffffffff
je 0x460791
cmp edi, 0x3200000
ja 0x460791
lea eax, [edi + 1]
push eax
call fcn.004878e1
pop ecx
mov ebx, eax
lea eax, [ebp - 0x44]
push 0
push eax
push edi
push ebx
push dword [ebp - 0x30]
mov dword [ebp - 0x18], ebx
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
je 0x46072c
cmp edi, dword [ebp - 0x44]
jne 0x46072c
test esi, esi
je 0x4603bb
cmp esi, 0xffffffff
je 0x4603bb
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
xor eax, eax
push eax
push eax
push edi
mov edi, dword [sym.imp.KERNEL32.dll_MultiByteToWideChar]
push ebx
push eax
push dword [ebp + 0x840]
mov dword [ebp - 0x1c], eax
call edi
mov esi, eax
xor ecx, ecx
push 2
pop edx
lea eax, [esi + 1]
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.004878e1
pop ecx
push esi
mov esi, eax
mov dword [ebp - 0x14], eax
push esi
push dword [ebp - 0x2c]
push ebx
push 0
push dword [ebp + 0x840]
call edi
test eax, eax
jne 0x46046b
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor ecx, ecx
xor edi, edi
push ecx
push ecx
push ecx
push ecx
push ecx
push ecx
push 0x9c
push str.d:_sourcesmachetemachete51_3machetemachete.._XMLCommon.cpp
push ecx
push 0x61b594
push eax
inc edi
push edi
push dword [ebp - 0x28]
call fcn.0046e15b
xor eax, eax
add esp, 0x34
inc eax
mov byte [ebp - 4], al
test esi, esi
je 0x46044d
push 2
pop eax
push eax
push esi
call fcn.005bb24c
pop ecx
xor eax, eax
pop ecx
inc eax
and dword [ebp - 0x14], 0
mov byte [ebp - 4], 0
test ebx, ebx
je 0x460462
push eax
push ebx
call fcn.005bb24c
pop ecx
pop ecx
and dword [ebp - 0x18], 0
jmp 0x460346
xor edi, edi
xor ecx, ecx
inc edi
mov word [esi + eax*2], cx
test ebx, ebx
je 0x460481
push edi
push ebx
call fcn.005bb24c
pop ecx
pop ecx
and dword [ebp - 0x18], 0
mov ecx, 0xfeff
xor eax, eax
cmp word [esi], cx
cmove eax, edi
and dword [ebp - 0x10], 0
lea edi, [esi + eax*2]
call fcn.004887ac
push eax
push 0x80
push edi
lea ecx, [ebp - 0x2c]
call fcn.00408e46
mov byte [ebp - 4], 4
lea eax, [ebp - 0x3c]
push 5
push eax
lea ecx, [ebp - 0x2c]
call fcn.004096af
mov byte [ebp - 4], 5
lea ecx, [ebp - 0x2c]
call fcn.00448923
push str.__xml
lea ecx, [ebp - 0x3c]
call fcn.0043d47c
test eax, eax
je 0x4604fb
push str._asx
lea ecx, [ebp - 0x3c]
call fcn.0043d47c
mov ecx, dword [ebp - 0x10]
test eax, eax
mov edx, 0xc00ce565
cmovne ecx, edx
mov dword [ebp - 0x10], ecx
jmp 0x4604fe
mov ecx, dword [ebp - 0x10]
mov ebx, dword [ebp - 0x20]
test ecx, ecx
jne 0x460519
mov eax, dword [ebx]
lea edx, [ebp - 0x40]
push edx
push edi
push eax
mov ecx, dword [eax]
call dword [ecx + 0x104]
mov edi, eax
jmp 0x46051c
mov edi, dword [ebp - 0x44]
push 2
pop eax
push eax
push esi
call fcn.005bb24c
and dword [ebp - 0x14], 0
pop ecx
pop ecx
test edi, edi
jne 0x460582
or edi, 0xffffffff
cmp word [ebp - 0x40], di
jne 0x460585
cmp dword [ebp - 0x10], 0
jne 0x460585
mov byte [ebp - 4], 4
mov ecx, dword [ebp - 0x3c]
lea ecx, [ecx - 0x10]
call fcn.00406e44
push 2
pop eax
mov byte [ebp - 4], al
mov ecx, dword [ebp - 0x2c]
lea ecx, [ecx - 0x10]
call fcn.00406e44
xor ebx, ebx
inc ebx
mov byte [ebp - 4], bl
xor eax, eax
mov dword [ebp - 0x14], eax
mov byte [ebp - 4], al
mov dword [ebp - 0x18], eax
mov dword [ebp - 4], edi
lea ecx, [ebp - 0x1c]
call fcn.00412e16
mov eax, ebx
jmp 0x460800
or edi, 0xffffffff
and dword [ebp - 0x24], 0
mov byte [ebp - 4], 6
lea edx, [ebp - 0x24]
mov eax, dword [ebx]
push edx
push eax
mov ecx, dword [eax]
call dword [ecx + 0xf0]
test eax, eax
jne 0x4606b1
mov eax, dword [ebp - 0x24]
test eax, eax
je 0x4606b1
mov ecx, dword [ebp - 0x10]
xor ebx, ebx
mov dword [ebp - 0x20], ebx
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x34], ebx
test ecx, ecx
jne 0x460647
mov ecx, dword [eax]
lea edx, [ebp - 0x10]
push edx
push eax
call dword [ecx + 0x1c]
mov eax, dword [ebp - 0x24]
lea edx, [ebp - 0x20]
push edx
push eax
mov ecx, dword [eax]
call dword [ecx + 0x24]
mov ecx, dword [ebp - 0x10]
test eax, eax
jne 0x460647
test ecx, ecx
jne 0x460647
mov eax, dword [ebp - 0x24]
lea edx, [ebp - 0x34]
push edx
push eax
mov ecx, dword [eax]
call dword [ecx + 0x2c]
mov ecx, dword [ebp - 0x34]
lea edx, [ebp - 0x30]
test eax, eax
mov eax, dword [ebp - 0x24]
push edx
cmovne ecx, edi
mov dword [ebp - 0x34], ecx
mov ecx, dword [eax]
push eax
call dword [ecx + 0x28]
mov ecx, dword [ebp - 0x34]
test eax, eax
push dword [ebp - 0x20]
cmovne ecx, edi
lea eax, [ebp]
mov dword [ebp - 0x34], ecx
cmp ecx, edi
jne 0x460626
push dword [ebp - 0x10]
jmp 0x460650
push dword [ebp - 0x30]
push ecx
push dword [ebp - 0x10]
push dword [ebp - 0x38]
push dword [ebp + 0x838]
push edi
push 0x410
push eax
call fcn.0040c5e7
add esp, 0x24
jmp 0x460668
push 0x60bba8
push ecx
lea eax, [ebp]
push dword [ebp - 0x38]
push dword [ebp + 0x83c]
push edi
push 0x410
push eax
call fcn.0040c5e7
add esp, 0x1c
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
xor eax, eax
push 0xe0
mov word [ebp + 0x81e], ax
lea eax, [ebp]
push str.d:_sourcesmachetemachete51_3machetemachete.._XMLCommon.cpp
push eax
push str.IXMLDOMDocument::load
push dword [ebp - 0x10]
xor eax, eax
inc eax
push eax
push dword [ebp - 0x28]
call fcn.0046e15b
mov esi, dword [sym.imp.OLEAUT32.dll_SysStringLen]
add esp, 0x34
push dword [ebp - 0x20]
call esi
push dword [ebp - 0x30]
mov dword [ebp - 0x20], ebx
call esi
jmp 0x4606e1
mov eax, dword [ebp - 0x10]
xor ebx, ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 0xec
push str.d:_sourcesmachetemachete51_3machetemachete.._XMLCommon.cpp
push ebx
push str.IXMLDOMDocument::load
push 1
pop ecx
test eax, eax
cmove eax, ecx
push eax
push ecx
push dword [ebp - 0x28]
call fcn.0046e15b
add esp, 0x34
mov byte [ebp - 4], 5
mov eax, dword [ebp - 0x24]
test eax, eax
je 0x4606f2
mov ecx, dword [eax]
push eax
call dword [ecx + 8]
mov dword [ebp - 0x24], ebx
mov byte [ebp - 4], 4
mov ecx, dword [ebp - 0x3c]
lea ecx, [ecx - 0x10]
call fcn.00406e44
push 2
pop eax
mov byte [ebp - 4], al
mov ecx, dword [ebp - 0x2c]
lea ecx, [ecx - 0x10]
call fcn.00406e44
xor eax, eax
inc eax
mov byte [ebp - 4], al
mov dword [ebp - 0x14], ebx
mov byte [ebp - 4], bl
mov dword [ebp - 0x18], ebx
mov dword [ebp - 4], edi
jmp 0x4607f6
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor ecx, ecx
push ecx
push ecx
push ecx
push ecx
push ecx
push ecx
push 0x8a
push str.d:_sourcesmachetemachete51_3machetemachete.._XMLCommon.cpp
push dword [ebp - 0x38]
push 0x61b580
push eax
xor eax, eax
inc eax
push eax
push dword [ebp - 0x28]
call fcn.0046e15b
xor ecx, ecx
add esp, 0x34
inc ecx
mov byte [ebp - 4], cl
xor eax, eax
je 0x460777
push 2
pop edx
push edx
push eax
call fcn.005bb24c
pop ecx
pop ecx
xor ecx, ecx
xor eax, eax
inc ecx
mov dword [ebp - 0x14], eax
mov byte [ebp - 4], al
test ebx, ebx
je 0x46078c
push ecx
push ebx
call fcn.005bb24c
pop ecx
pop ecx
xor eax, eax
mov dword [ebp - 0x18], eax
jmp 0x4607f0
call dword [sym.imp.KERNEL32.dll_GetLastError]
xor ebx, ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push ebx
push 0x80
push str.d:_sourcesmachetemachete51_3machetemachete.._XMLCommon.cpp
push dword [ebp - 0x38]
push 0x61b568
push eax
xor eax, eax
inc eax
push eax
push dword [ebp - 0x28]
call fcn.0046e15b
xor eax, eax
add esp, 0x34
inc eax
mov byte [ebp - 4], al
test ebx, ebx
je 0x4607da
push 2
pop eax
push eax
push ebx
call fcn.005bb24c
pop ecx
xor eax, eax
pop ecx
inc eax
mov dword [ebp - 0x14], ebx
mov byte [ebp - 4], bl
test ebx, ebx
je 0x4607ed
push eax
push ebx
call fcn.005bb24c
pop ecx
pop ecx
mov dword [ebp - 0x18], ebx
or eax, 0xffffffff
mov dword [ebp - 4], eax
lea ecx, [ebp - 0x1c]
call fcn.00412e16
xor eax, eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp + 0x820]
xor ecx, ebp
call fcn.005bb105
lea esp, [ebp + 0x824]
pop ebp
ret 0x18