Function at 0x403c70
Capabilities:
Read file on windows
Write file on windows

Disassembly:
sub esp, 0x86c
push ebx
push ebp
push esi
push edi
mov ecx, 7
mov esi, str.MeXX_Media_BMP__JPG_Compress
lea edi, [esp + 0x5c]
mov ebx, dword [sym.imp.KERNEL32.dll_SetFilePointer]
rep movsd dword es:[edi], dword [esi]
movsb byte es:[edi], byte [esi]
mov ecx, 6
mov esi, str.Low_JPEG_Data_in_Memory
lea edi, [esp + 0x1c]
xor eax, eax
rep movsd dword es:[edi], dword [esi]
mov ecx, 6
mov esi, str.High_JPEG_Data_in_Memory
lea edi, [esp + 0x3c]
mov dword [esp + 0x34], eax
rep movsd dword es:[edi], dword [esi]
xor ecx, ecx
mov byte [esp + 0x79], 0
movsb byte es:[edi], byte [esi]
mov edi, dword [esp + 0x888]
mov esi, dword [esp + 0x884]
mov dword [esp + 0x55], ecx
mov word [esp + 0x38], ax
push ecx
push ecx
push edi
push esi
mov byte [esp + 0x69], cl
mov dword [esp + 0x24], ecx
call ebx
mov ebp, dword [sym.imp.KERNEL32.dll_ReadFile]
lea edx, [esp + 0x10]
push 0
push edx
lea eax, [esp + 0x84]
push 0x1e
push eax
push esi
call ebp
lea ecx, [esp + 0x1c]
lea edx, [esp + 0x7c]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
je 0x403e14
lea eax, [esp + 0x3c]
lea ecx, [esp + 0x7c]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
je 0x403e14
lea edx, [esp + 0x5c]
lea eax, [esp + 0x7c]
push edx
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
push 0
push 0
test eax, eax
push edi
push esi
jne 0x403d71
call ebx
mov ecx, dword [esp + 0x880]
mov dword [0x417dc4], 1
push ecx
push esi
mov byte [0x417db0], 1
call fcn.00403120
add esp, 8
jmp 0x403f7c
call ebx
mov edx, dword [esp + 0x880]
push 0
push 0x80
push 2
push 0
push 0
push 0x40000000
push edx
mov byte [0x417db0], 0
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov ebx, eax
cmp ebx, 0xffffffff
jne 0x403dae
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x86c
ret
mov edi, dword [esp + 0x88c]
test edi, edi
jle 0x403f80
cmp edi, 0x800
push 0
jle 0x403ddb
lea eax, [esp + 0x14]
lea ecx, [esp + 0x80]
push eax
push 0x800
push ecx
jmp 0x403de9
lea edx, [esp + 0x14]
lea eax, [esp + 0x80]
push edx
push edi
push eax
push esi
call ebp
mov edx, dword [esp + 0x10]
lea ecx, [esp + 0x18]
push 0
push ecx
lea eax, [esp + 0x84]
push edx
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_WriteFile]
sub edi, dword [esp + 0x10]
test edi, edi
jg 0x403dbd
jmp 0x403f80
mov edi, dword [sym.imp.KERNEL32.dll_lstrcmpiA]
lea ecx, [esp + 0x1c]
lea edx, [esp + 0x7c]
push ecx
push edx
call edi
test eax, eax
jne 0x403e33
mov byte [0x417db0], 2
jmp 0x403e4a
lea eax, [esp + 0x3c]
lea ecx, [esp + 0x7c]
push eax
push ecx
call edi
test eax, eax
jne 0x403e4a
mov byte [0x417db0], 3
lea edx, [esp + 0x10]
push 0
push edx
push 4
push 0x418298
push esi
call ebp
lea eax, [esp + 0x10]
push 0
push eax
push 2
push 0x4184a4
push esi
call ebp
mov edi, dword [sym.imp.KERNEL32.dll_GlobalAlloc]
xor ecx, ecx
mov cx, word [0x4184a4]
shl ecx, 1
push ecx
push 0x40
call edi
test eax, eax
mov dword [0x4184a8], eax
push 0
jne 0x403ebd
mov edx, dword [0x418304]
push str.error
push str.Out_of_memory
push edx
call dword [sym.imp.USER32.dll_MessageBoxA]
mov eax, dword [0x418304]
push eax
call dword [sym.imp.USER32.dll_DestroyWindow]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x86c
ret
xor edx, edx
lea ecx, [esp + 0x14]
mov dx, word [0x4184a4]
push ecx
shl edx, 1
push edx
push eax
push esi
call ebp
xor eax, eax
mov ax, word [0x4184a4]
test eax, eax
jle 0x403ef9
mov ecx, dword [0x4184a8]
mov ebx, dword [esp + 0x14]
xor edx, edx
mov dx, word [ecx]
add ecx, 2
add ebx, edx
dec eax
mov dword [esp + 0x14], ebx
jne 0x403ee4
mov eax, dword [esp + 0x14]
push eax
push 0x40
call edi
test eax, eax
mov dword [0x418434], eax
jne 0x403f3d
mov ecx, dword [0x418304]
push eax
push str.error
push str.Out_of_memory
push ecx
call dword [sym.imp.USER32.dll_MessageBoxA]
mov edx, dword [0x418304]
push edx
call dword [sym.imp.USER32.dll_DestroyWindow]
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x86c
ret
xor edi, edi
mov ebx, eax
cmp word [0x4184a4], di
jbe 0x403f7c
mov eax, dword [0x4184a8]
xor edx, edx
lea ecx, [esp + 0x10]
mov dx, word [eax + edi*2]
push 0
push ecx
push edx
push ebx
push esi
call ebp
mov eax, dword [0x4184a8]
xor ecx, ecx
xor edx, edx
mov cx, word [eax + edi*2]
mov dx, word [0x4184a4]
add ebx, ecx
inc edi
cmp edi, edx
jl 0x403f4f
mov ebx, dword [esp + 0x14]
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
pop edi
pop esi
pop ebp
mov eax, 1
pop ebx
add esp, 0x86c
ret