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

Disassembly:
sub esp, 0x340
push ebx
push ebp
push esi
push edi
lea eax, [esp + 0x24c]
push 0x104
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
lea ecx, [esp + 0x24c]
push 0x2e
push ecx
call fcn.00419d00
mov edx, dword [0x426bec]
add esp, 8
mov dword [eax + 1], edx
lea eax, [esp + 0x24c]
push 0
push pe_nt_image_headers32
push 3
push 0
push 0
push closesocket
push eax
mov dword [esp + 0x18c], 0
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov esi, eax
cmp esi, 0xffffffff
jne 0x419381
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov ebx, dword [esp + 0x10]
mov ebp, dword [esp + 0x10]
mov dword [esp + 0x170], eax
mov dword [esp + 0x16c], 0x4b0
jmp 0x41957d
push 0
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSize]
mov edi, eax
cmp edi, 0xffffffff
jne 0x4193bd
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
mov dword [esp + 0x174], eax
mov dword [esp + 0x170], 0x4b1
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ebx, dword [esp + 0x10]
mov ebp, dword [esp + 0x10]
jmp 0x41957d
cmp edi, 0x334
jae 0x4193e4
push esi
mov dword [esp + 0x170], 0x4b2
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ebx, dword [esp + 0x10]
mov ebp, dword [esp + 0x10]
jmp 0x41957d
mov ebx, dword [sym.imp.KERNEL32.dll_ReadFile]
xor ebp, ebp
lea ecx, [esp + 0x14]
push ebp
push ecx
lea edx, [esp + 0x24]
push 0x230
push edx
push esi
call ebx
test eax, eax
je 0x419421
lea eax, [esp + 0x14]
push ebp
push eax
push 0x104
push 0x42aaa0
push esi
mov dword [esp + 0x184], ebp
call ebx
test eax, eax
jne 0x41944d
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
mov dword [esp + 0x174], eax
mov dword [esp + 0x170], 0x4b3
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ebx, dword [esp + 0x10]
mov ebp, dword [esp + 0x10]
jmp 0x41957d
mov eax, dword [esp + 0x2c]
mov ebx, 1
cmp eax, 3
je 0x419469
cmp eax, 5
je 0x419469
cmp eax, 6
mov dword [esp + 0x10], ebp
jne 0x41946d
mov dword [esp + 0x10], ebx
cmp eax, 4
je 0x41947e
cmp eax, 5
je 0x41947e
cmp eax, 6
je 0x41947e
xor ebx, ebx
mov eax, dword [esp + 0x10]
add edi, 0xfffffccc
cmp eax, ebp
jne 0x419490
cmp ebx, ebp
je 0x4194cf
mov ecx, dword [esp + 0x40]
push ecx
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
mov ebp, eax
test ebp, ebp
jne 0x4194ba
push esi
mov dword [esp + 0x170], 0x190
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x41957d
test byte [esp + 0x30], 0x10
jne 0x4194d3
mov edx, dword [esp + 0x44]
mov dword [esp + 0x44], ebp
mov dword [esp + 0x18], edx
jmp 0x4194d3
mov ebp, dword [esp + 0x10]
mov eax, dword [esp + 0x10]
test eax, eax
je 0x419526
cmp edi, dword [esp + 0x40]
je 0x4194f1
mov dword [esp + 0x16c], 0x4b4
jmp 0x41957d
lea eax, [esp + 0x14]
push 0
push eax
push edi
push ebp
push esi
call dword [sym.imp.KERNEL32.dll_ReadFile]
test eax, eax
jne 0x419526
call dword [sym.imp.KERNEL32.dll_GetLastError]
push esi
mov dword [esp + 0x174], eax
mov dword [esp + 0x170], 0x4b3
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x41957d
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea ecx, [esp + 0x24c]
push ecx
call dword [sym.imp.KERNEL32.dll_DeleteFileA]
test byte [esp + 0x30], 0x10
je 0x419556
lea edx, [esp + 0x1c]
push ebp
push edx
call fcn.0040d490
mov dword [esp + 0x16c], eax
jmp 0x41957d
lea eax, [esp + 0x1c]
push 0
push eax
call fcn.0040d490
mov dword [esp + 0x16c], eax
mov eax, dword [esp + 0x10]
test eax, eax
jne 0x419575
test ebx, ebx
je 0x41957d
mov ecx, dword [esp + 0x18]
mov dword [esp + 0x44], ecx
mov edi, 0x426be8
or ecx, 0xffffffff
xor eax, eax
lea edx, [esp + 0x24c]
repne scasb al, byte es:[edi]
not ecx
sub edi, ecx
push eax
mov esi, edi
mov edi, edx
mov edx, ecx
or ecx, 0xffffffff
repne scasb al, byte es:[edi]
mov ecx, edx
dec edi
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
push pe_nt_image_headers32
push 2
mov ecx, edx
push eax
push eax
and ecx, 3
lea eax, [esp + 0x260]
push 0x40000000
rep movsb byte es:[edi], byte [esi]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, dword [sym.imp.KERNEL32.dll_WriteFile]
lea ecx, [esp + 0x14]
push 0
push ecx
lea edx, [esp + 0x24]
mov esi, eax
push 0x230
push edx
push esi
call edi
test ebx, ebx
je 0x419606
mov eax, dword [esp + 0x16c]
test eax, eax
jne 0x419606
mov ecx, dword [esp + 0x40]
lea eax, [esp + 0x14]
push 0
push eax
push ecx
push ebp
push esi
call edi
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov eax, dword [esp + 0x10]
test eax, eax
jne 0x419619
test ebx, ebx
je 0x419620
push ebp
call dword [sym.imp.KERNEL32.dll_GlobalFree]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x340
ret 0x10