Function at 0x5846fe
Capabilities:
Get file size
Read file on windows
Write file on windows

Disassembly:
push ebp
sub esp, 0x940
lea ebp, [esp - 4]
mov eax, dword [0x70b744]
xor eax, ebp
mov dword [ebp + 0x940], eax
push 0x104
mov eax, 0x5f2ea2
call fcn.005234b0
mov eax, dword [ebp + 0x950]
mov edi, ecx
xor ebx, ebx
mov dword [ebp - 0x24], eax
mov dword [eax], ebx
lea eax, [edi + 0x9c]
mov dword [ebp - 0x10], edi
mov dword [ebp - 0x14], ebx
call fcn.00441ebf
test eax, eax
jbe 0x584c1b
mov esi, dword [ebp - 0x14]
add edi, 0x9c
call fcn.004454cc
mov eax, dword [eax]
cmp dword [eax + 0x30], ebx
jne 0x584bff
mov edi, dword [ebp - 0x10]
add edi, 0x9c
call fcn.004454cc
mov eax, dword [eax]
cmp dword [eax], ebx
je 0x584bff
mov edi, dword [ebp - 0x10]
add edi, 0x9c
call fcn.004454cc
mov eax, dword [eax]
mov eax, dword [eax]
push dword [eax]
call dword [sym.imp.USER32.dll_GetDlgCtrlID]
movzx ecx, word [ebp + 0x94c]
cmp eax, ecx
jne 0x584bff
mov eax, dword [ebp - 0x24]
mov edi, dword [ebp - 0x10]
add edi, 0x9c
mov dword [eax], 1
call fcn.004454cc
mov eax, dword [eax]
mov eax, dword [eax + 0xb8]
dec eax
je 0x584bd6
dec eax
je 0x584a59
dec eax
je 0x5848ee
dec eax
je 0x5848dd
dec eax
je 0x5848d0
dec eax
jne 0x584bff
mov edi, dword [ebp - 0x10]
mov eax, dword [edi + 0x68]
cmp eax, ebx
je 0x58480b
push dword [eax + 4]
call dword [sym.imp.USER32.dll_IsWindow]
test eax, eax
jne 0x584bff
call fcn.0057cf97
mov dword [edi + 0x68], eax
lea eax, [ebp - 0xbc]
push 0x2996
push eax
call fcn.004b9340
pop ecx
pop ecx
xor esi, esi
inc esi
mov dword [ebp - 4], esi
cmp dword [eax + 0x18], 8
jb 0x584837
mov eax, dword [eax + 4]
jmp 0x58483a
add eax, 4
push eax
lea ecx, [ebp + 0x908]
call fcn.004120e9
push ebx
push esi
lea ecx, [ebp - 0xbc]
mov byte [ebp - 4], 3
call fcn.00410779
cmp dword [ebp + 0x920], 8
mov eax, dword [ebp + 0x90c]
jae 0x58486c
lea eax, [ebp + 0x90c]
push eax
lea ecx, [ebp + 0x924]
call fcn.004120e9
mov eax, dword [edi + 0x68]
mov byte [ebp - 4], 4
cmp dword [ebp + 0x93c], 8
mov ecx, dword [ebp + 0x928]
jae 0x584894
lea ecx, [ebp + 0x928]
add eax, 0x5c
push ecx
push eax
call fcn.00423fa7
push ebx
push esi
lea ecx, [ebp + 0x924]
mov byte [ebp - 4], 3
call fcn.00410779
push dword [edi + 4]
push dword [edi + 0x68]
call fcn.0044197a
push ebx
push esi
lea ecx, [ebp + 0x908]
or dword [ebp - 4], 0xffffffff
call fcn.00410779
jmp 0x584bff
mov eax, dword [ebp - 0x10]
push dword [eax + 4]
call fcn.005c8ff3
jmp 0x5848e8
mov eax, dword [ebp - 0x10]
push dword [eax + 4]
call fcn.005c920d
pop ecx
jmp 0x584bff
push ebx
lea ecx, [ebp - 0xa0]
call fcn.004cb9f4
mov dword [ebp - 4], 9
cmp byte [0x722275], bl
je 0x584912
cmp byte [ebp - 0x78], bl
je 0x584c49
push str.INI_Files__.ini_
push 0x801004
push ebx
push 0x6a6f84
push 1
lea eax, [ebp]
push eax
call fcn.00423c44
mov dword [ebp], 0x6a0d50
mov byte [ebp - 4], 0xa
call dword [sym.imp.USER32.dll_GetActiveWindow]
lea edi, [ebp]
call fcn.00423a82
cmp eax, 1
jne 0x5849b2
push ebx
push 0x80
push 3
push ebx
push ebx
push bind
lea eax, [ebp + 0x27c]
push eax
call dword [0x71f620]
cmp eax, 0xffffffff
mov dword [ebp - 0x18], eax
jne 0x5849d7
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea edi, [ebp - 0x110]
call fcn.004af895
cmp dword [eax + 0x18], 8
pop ecx
jb 0x58498d
mov eax, dword [eax + 4]
jmp 0x584990
add eax, 4
push 0x30
push str.Error
push eax
mov eax, dword [ebp - 0x10]
push dword [eax + 4]
call dword [0x71f790]
push ebx
push 1
lea ecx, [ebp - 0x110]
call fcn.00410779
mov byte [ebp - 4], 9
cmp dword [ebp + 0x14], ebx
je 0x5849c3
push dword [ebp + 0x14]
call fcn.004fde16
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0xa0]
call fcn.004cbcf8
jmp 0x584bff
push ebx
push eax
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
mov dword [ebp - 0x20], edi
shr edi, 1
inc edi
xor ecx, ecx
push 2
pop edx
mov eax, edi
mul edx
seto cl
neg ecx
or ecx, eax
push ecx
call fcn.004fed14
pop ecx
push ebx
mov esi, eax
lea eax, [ebp - 0x28]
push eax
push dword [ebp - 0x20]
push esi
push dword [ebp - 0x18]
call dword [sym.imp.KERNEL32.dll_ReadFile]
push dword [ebp - 0x18]
mov word [esi + edi*2 - 2], bx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
sub esp, 0x1c
mov ecx, esp
mov dword [ebp - 0x20], esp
push esi
call fcn.004120e9
mov ecx, 0x721f18
call fcn.004ba939
push esi
call fcn.0051d89c
mov eax, dword [ebp - 0x10]
pop ecx
push dword [eax + 0x64]
call fcn.00441646
mov eax, dword [0x764c14]
call fcn.0058cc77
jmp 0x5849b2
lea eax, [ebp + 0x924]
mov esi, 0x721f18
push eax
mov ecx, esi
call fcn.004bb444
push ebx
lea ecx, [ebp - 0x64]
mov dword [ebp - 4], 5
call fcn.004cb9f4
mov byte [ebp - 4], 6
cmp byte [0x722275], bl
je 0x584a91
cmp byte [ebp - 0x3c], bl
je 0x584c78
push str.INI_Files__.ini_
push 0x800006
push ebx
push 0x6a6f84
push ebx
lea eax, [ebp + 0x484]
push eax
call fcn.00423c44
mov dword [ebp + 0x484], 0x6a0d50
mov byte [ebp - 4], 7
call dword [sym.imp.USER32.dll_GetActiveWindow]
lea edi, [ebp + 0x484]
call fcn.00423a82
cmp eax, 1
jne 0x584b71
push ebx
push 0x80
push 2
push ebx
push ebx
push 0x40000000
lea eax, [ebp + 0x700]
push eax
call dword [0x71f620]
mov esi, eax
cmp esi, 0xffffffff
jne 0x584ba2
lea eax, [ebp - 0xd8]
push 0x408
push eax
call fcn.004b9340
pop ecx
pop ecx
mov esi, eax
mov byte [ebp - 4], 8
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea edi, [ebp - 0xf4]
call fcn.004af895
cmp dword [esi + 0x18], 8
pop ecx
jb 0x584b34
mov esi, dword [esi + 4]
jmp 0x584b37
add esi, 4
cmp dword [eax + 0x18], 8
jb 0x584b42
mov eax, dword [eax + 4]
jmp 0x584b45
add eax, 4
push 0x30
push esi
push eax
mov eax, dword [ebp - 0x10]
push dword [eax + 4]
call dword [0x71f790]
push ebx
push 1
lea ecx, [ebp - 0xf4]
call fcn.00410779
push ebx
push 1
lea ecx, [ebp - 0xd8]
call fcn.00410779
mov byte [ebp - 4], 6
cmp dword [ebp + 0x498], ebx
je 0x584b88
push dword [ebp + 0x498]
call fcn.004fde16
lea ecx, [ebp - 0x64]
mov byte [ebp - 4], 5
call fcn.004cbcf8
push ebx
push 1
lea ecx, [ebp + 0x924]
jmp 0x5848c2
cmp dword [ebp + 0x93c], 8
mov eax, dword [ebp + 0x928]
jae 0x584bb7
lea eax, [ebp + 0x928]
push ebx
lea ecx, [ebp - 0x1c]
push ecx
mov ecx, dword [ebp + 0x938]
add ecx, ecx
push ecx
push eax
push esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x584b71
lea eax, [ebp - 0x64]
push eax
call fcn.0044159e
mov dword [ebp - 4], ebx
call dword [sym.imp.USER32.dll_GetActiveWindow]
push eax
lea eax, [ebp - 0x64]
push eax
call fcn.00441f2c
or dword [ebp - 4], 0xffffffff
lea eax, [ebp - 0x64]
push eax
call fcn.00441601
mov eax, dword [ebp - 0x10]
inc dword [ebp - 0x14]
add eax, 0x9c
call fcn.00441ebf
cmp dword [ebp - 0x14], eax
mov edi, dword [ebp - 0x10]
jb 0x58474d
mov eax, edi
call fcn.005821a5
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 + 0x940]
xor ecx, ebp
call fcn.0051d721
add ebp, 0x944
leave
ret 8
push ebx
sub esp, 0x24
mov ecx, esp
mov dword [ebp - 0x1c], esp
push ebx
push str.Could_not_impersonate_user
call fcn.004ac9bc
mov ecx, 0x721f18
call fcn.0041122b
or dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0xa0]
call fcn.004cbcf8
jmp 0x584cad
push ebx
sub esp, 0x24
mov ecx, esp
mov dword [ebp - 0x1c], esp
push ebx
push str.Could_not_impersonate_user
call fcn.004ac9bc
mov ecx, esi
call fcn.0041122b
lea ecx, [ebp - 0x64]
mov byte [ebp - 4], 5
call fcn.004cbcf8
push ebx
push 1
lea ecx, [ebp + 0x924]
call fcn.00410779
xor eax, eax
inc eax
jmp 0x584c24