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

Disassembly:
push ebp
mov ebp, esp
add esp, 0xffffff40
xor ecx, ecx
mov dword [ebp - 0xc0], ecx
mov dword [ebp - 0xb8], ecx
mov dword [ebp - 0xbc], ecx
mov dword [ebp - 0xb0], ecx
mov dword [ebp - 0xb4], ecx
mov dword [ebp - 0x1c], ecx
mov dword [ebp - 8], edx
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.00404a14
mov eax, dword [ebp - 8]
call fcn.00404a14
xor eax, eax
push ebp
push 0x461fd1
push dword fs:[eax]
mov dword fs:[eax], esp
mov eax, dword [0x4671a8]
mov edx, 0x461fe8
call fcn.004045b8
mov byte [ebp - 9], 0
mov eax, dword [ebp - 4]
call fcn.00404824
test eax, eax
je 0x461f98
mov eax, dword [ebp - 8]
call fcn.00404824
test eax, eax
je 0x461f98
push 0
lea eax, [ebp - 0xac]
push eax
mov eax, dword [ebp - 4]
call fcn.00404a24
push eax
call sub.kernel32.dll_OpenFile
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0xffffffff
jne 0x461d47
push 0x4620a8
push dword [ebp - 4]
push 0x4620b8
lea edx, [ebp - 0xb4]
xor eax, eax
call fcn.00408a9c
push dword [ebp - 0xb4]
lea eax, [ebp - 0xb0]
mov edx, 4
call fcn.004048e4
mov eax, dword [ebp - 0xb0]
call fcn.0045a7ac
jmp 0x461f98
push 0
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_GetFileSize_1
add eax, 5
mov dword [ebp - 0x14], eax
mov eax, dword [0x4671a8]
mov edx, 0x4620c4
call fcn.004045b8
mov eax, dword [ebp - 0x14]
push eax
lea eax, [ebp - 0x1c]
mov ecx, 1
mov edx, dword [0x461c44]
call fcn.00405564
add esp, 4
mov edx, 0x466f60
mov eax, dword [ebp - 0x1c]
mov ecx, 5
call fcn.00406f4c
push 0
lea eax, [ebp - 0x18]
push eax
mov eax, dword [ebp - 0x14]
sub eax, 5
push eax
mov eax, dword [ebp - 0x1c]
add eax, 5
push eax
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_ReadFile_1
test eax, eax
jne 0x461df4
push 0x4620fc
push dword [ebp - 4]
push 0x4620b8
lea edx, [ebp - 0xbc]
xor eax, eax
call fcn.00408a9c
push dword [ebp - 0xbc]
lea eax, [ebp - 0xb8]
mov edx, 4
call fcn.004048e4
mov eax, dword [ebp - 0xb8]
call fcn.0045a7ac
jmp 0x461f98
mov eax, dword [0x4671a8]
mov edx, 0x462110
call fcn.004045b8
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_CloseHandle_1
cmp dword [ebp - 0x14], 0xa
jbe 0x461e9b
mov eax, dword [ebp - 0x1c]
mov al, byte [eax + 5]
cmp al, byte [0x466f60]
jne 0x461e9b
mov eax, dword [ebp - 0x1c]
mov al, byte [eax + 6]
cmp al, byte [0x466f61]
jne 0x461e9b
mov eax, dword [ebp - 0x1c]
mov al, byte [eax + 7]
cmp al, byte [0x466f62]
jne 0x461e9b
mov eax, dword [ebp - 0x1c]
mov al, byte [eax + 8]
cmp al, byte [0x466f63]
jne 0x461e9b
mov eax, dword [ebp - 0x1c]
mov al, byte [eax + 9]
cmp al, byte [0x466f64]
jne 0x461e9b
push 0x46216c
push dword [ebp - 4]
push 0x46217c
push dword [ebp - 8]
lea eax, [ebp - 0xc0]
mov edx, 4
call fcn.004048e4
mov eax, dword [ebp - 0xc0]
call fcn.0045a7ac
mov eax, dword [0x4671a8]
mov edx, 0x462194
call fcn.004045b8
jmp 0x461f98
mov eax, dword [0x4671a8]
mov edx, 0x46226c
call fcn.004045b8
mov eax, dword [ebp - 0x14]
dec eax
sub eax, 5
jb 0x461f03
inc eax
mov dword [ebp - 0x24], eax
mov dword [ebp - 0x18], 5
mov eax, dword [ebp - 0x1c]
mov edx, dword [ebp - 0x18]
xor byte [eax + edx], 0xc2
mov eax, dword [ebp - 0x1c]
mov edx, dword [ebp - 0x18]
movzx eax, byte [eax + edx]
add ax, 0x79
mov word [ebp - 0x1e], ax
cmp word [ebp - 0x1e], 0xff
jle 0x461eef
mov ax, word [ebp - 0x1e]
sub ax, 0xff
dec eax
mov word [ebp - 0x1e], ax
mov eax, dword [ebp - 0x1c]
mov edx, dword [ebp - 0x18]
mov cl, byte [ebp - 0x1e]
mov byte [eax + edx], cl
inc dword [ebp - 0x18]
dec dword [ebp - 0x24]
jne 0x461ebe
mov eax, dword [ebp - 8]
call fcn.00404824
test eax, eax
jne 0x461f1a
lea eax, [ebp - 8]
mov edx, dword [ebp - 4]
call fcn.004045fc
mov eax, dword [0x4671a8]
mov edx, 0x4622b8
call fcn.004045b8
push 0
push 0x80
push 2
push 0
push 0
push 0x40000000
mov eax, dword [ebp - 8]
call fcn.00404a24
push eax
call sub.kernel32.dll_CreateFileA_1
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0xffffffff
je 0x461f98
push 0
lea eax, [ebp - 0x18]
push eax
mov eax, dword [ebp - 0x14]
push eax
mov eax, dword [ebp - 0x1c]
push eax
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_WriteFile_1
test eax, eax
je 0x461f71
mov byte [ebp - 9], 1
mov eax, dword [0x4671a8]
mov edx, 0x462354
call fcn.004045b8
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_CloseHandle_1
mov eax, dword [0x4671a8]
mov edx, 0x462404
call fcn.004045b8
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x461fd8
lea eax, [ebp - 0xc0]
mov edx, 5
call fcn.00404588
lea eax, [ebp - 0x1c]
mov edx, dword [0x461c44]
call fcn.00405570
lea eax, [ebp - 8]
mov edx, 2
call fcn.00404588
ret