Function at 0x401280
Capabilities:
Delete file
Get file size
Move file
Print debug messages
Read file on windows
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xfffffffffffffffe
push 0x42b710
push 0x4179a0
mov eax, dword fs:[0]
push eax
sub esp, 0x8a8
mov eax, dword [section..data]
xor dword [ebp - 8], eax
xor eax, ebp
mov dword [ebp - 0x1c], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0x10]
mov dword fs:[0], eax
mov dword [ebp - 0x18], esp
mov dword [ebp - 0x894], edx
mov edi, ecx
mov dword [ebp - 0x884], edi
mov eax, dword [ebp + 0xc]
mov dword [ebp - 0x8ac], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x89c], eax
xor eax, eax
mov word [ebp - 0x438], ax
push 0x206
push eax
lea eax, [ebp - 0x436]
push eax
call fcn.00419530
add esp, 0xc
xor eax, eax
mov word [ebp - 0x848], ax
push 0x40e
push eax
lea eax, [ebp - 0x846]
push eax
call fcn.00419530
add esp, 0xc
mov byte [ebp - 0x230], 0
push 0x103
push 0
lea eax, [ebp - 0x22f]
push eax
call fcn.00419530
add esp, 0xc
mov byte [ebp - 0x128], 0
push 0x103
push 0
lea eax, [ebp - 0x127]
push eax
call fcn.00419530
add esp, 0xc
mov dword [ebp - 0x898], 0
xor eax, eax
mov word [ebp - 0x858], ax
mov dword [ebp - 0x856], eax
mov dword [ebp - 0x852], eax
mov dword [ebp - 0x84e], eax
mov word [ebp - 0x84a], ax
mov dword [ebp - 0x880], eax
mov dword [ebp - 0x88c], 0xffffffff
mov dword [ebp - 0x888], eax
lea ebx, [eax + 0x32]
mov dword [ebp - 0x87c], eax
mov dword [ebp - 0x878], eax
mov dword [ebp - 0x874], eax
mov dword [ebp - 0x870], eax
mov dword [ebp - 0x86c], eax
mov dword [ebp - 0x868], eax
mov dword [ebp - 0x864], eax
mov dword [ebp - 0x860], eax
mov dword [ebp - 0x85c], eax
mov dword [ebp - 0x8a8], eax
mov dword [ebp - 0x8a4], eax
mov dword [ebp - 0x890], 0x140003
mov esi, dword [ebp + 0x14]
test esi, esi
jne 0x4013ee
xor eax, eax
jmp 0x4019ea
call fcn.004010c0
cmp eax, 1
je 0x4013fe
cmp dword [ebp + 8], 1
jg 0x4013e7
mov dword [ebp - 4], 0
mov dword [ebp - 4], 1
lea eax, [ebp - 0x858]
push eax
call dword [sym.imp.KERNEL32.dll_GetLocalTime]
cmp word [0x42ef70], 0
je 0x40154b
push str.mbae_default.log
push 0x42ef70
push 0x4281e8
lea eax, [ebp - 0x438]
push eax
call fcn.004029c0
add esp, 0x10
lea eax, [ebp - 0x87c]
push eax
push 0
lea eax, [ebp - 0x438]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesExW]
test eax, eax
je 0x40154b
xor ecx, ecx
mov eax, dword [ebp - 0x860]
add ecx, dword [ebp - 0x85c]
adc eax, 0
mov dword [ebp - 0x8b4], eax
jne 0x401607
cmp ecx, 0x1900000
ja 0x401607
cmp byte [0x42e1d8], 1
jne 0x401544
push 0
push 0x80
push 3
push 0
push 1
push 1
lea eax, [ebp - 0x438]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
mov dword [ebp - 0x88c], edi
cmp edi, 0xffffffff
je 0x40153e
push 0
lea eax, [ebp - 0x888]
push eax
push 4
lea eax, [ebp - 0x890]
push eax
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x88c], 0xffffffff
cmp dword [ebp - 0x890], 0x140003
je 0x40153e
lea eax, [ebp - 0x438]
push eax
push str._s.old
lea eax, [ebp - 0x848]
push eax
call fcn.004029e0
add esp, 0xc
lea eax, [ebp - 0x848]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
lea eax, [ebp - 0x848]
push eax
lea eax, [ebp - 0x438]
push eax
call dword [sym.imp.KERNEL32.dll_MoveFileW]
mov dword [ebp - 0x890], 0x140003
mov edi, dword [ebp - 0x884]
mov byte [0x42e1d8], 0
push 0x104
lea eax, [ebp - 0x128]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameA]
test eax, eax
jne 0x40157c
push str.NoProc
push 0x104
lea eax, [ebp - 0x128]
push eax
call fcn.00413155
add esp, 0xc
push 0x5c
lea eax, [ebp - 0x128]
push eax
call fcn.00413850
add esp, 8
test eax, eax
je 0x4015bf
inc eax
push eax
push 0x104
lea eax, [ebp - 0x128]
push eax
call fcn.00413155
add esp, 0xc
push 0x2e
lea eax, [ebp - 0x128]
push eax
call fcn.00412b80
add esp, 8
test eax, eax
je 0x4015bf
mov byte [eax], 0
test edi, edi
je 0x40161a
cmp byte [edi], 0
je 0x40161a
push 0x5c
push edi
call fcn.00413850
add esp, 8
test eax, eax
je 0x401617
inc eax
push eax
push 0x104
lea eax, [ebp - 0x230]
push eax
call fcn.00413155
add esp, 0xc
push 0x2e
lea eax, [ebp - 0x230]
push eax
call fcn.00412b80
add esp, 8
test eax, eax
je 0x401633
mov byte [eax], 0
jmp 0x401633
sub esp, 8
call fcn.00402880
add esp, 8
jmp 0x401544
push edi
jmp 0x40161f
push str.NoMod
push 0x104
lea eax, [ebp - 0x230]
push eax
call fcn.00413155
add esp, 0xc
mov ecx, dword [ebp - 0x89c]
lea edx, [ecx + 1]
lea esp, [esp]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x401640
sub ecx, edx
lea eax, [ecx + 0x514]
mov dword [ebp - 0x880], eax
add eax, 0xa
push eax
call fcn.00412ac8
add esp, 4
mov edi, eax
mov dword [ebp - 0x898], edi
test edi, edi
jne 0x4016a3
push esi
lea eax, [ebp - 0x438]
push eax
push str.Memory_allocation_error_in_log_file:__s____d_n
call fcn.004130a6
add esp, 0xc
push edi
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push 0xfffffffffffffffe
lea eax, [ebp - 0x10]
push eax
push section..data
call fcn.0041dd90
add esp, 0xc
mov eax, esi
jmp 0x4019ea
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
push eax
call dword [sym.imp.KERNEL32.dll_GetCurrentThreadId]
push eax
push esi
push dword [ebp - 0x89c]
push dword [ebp - 0x8ac]
push dword [ebp + 8]
movzx eax, word [ebp - 0x84c]
push eax
movzx eax, word [ebp - 0x84e]
push eax
movzx eax, word [ebp - 0x850]
push eax
movzx eax, word [ebp - 0x852]
push eax
movzx eax, word [ebp - 0x856]
push eax
movzx eax, word [ebp - 0x858]
push eax
push dword [ebp - 0x894]
lea eax, [ebp - 0x230]
push eax
lea eax, [ebp - 0x128]
push eax
push str._s__s__d_____04d__02d__02d____02d:_02d:_02d____X____s:__s____t_d____u____u_r_n
mov eax, dword [ebp - 0x880]
dec eax
push eax
push edi
call fcn.00412a74
add esp, 0x48
cmp word [ebp - 0x438], 0
jne 0x401730
push edi
jmp 0x401683
push 0
push 0x80
push 4
push 0
push 1
push 4
lea eax, [ebp - 0x438]
push eax
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov esi, eax
mov dword [ebp - 0x88c], esi
cmp esi, 0xffffffff
jne 0x401801
push str.Retry_log_file_open_n
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
push 0xc8
call dword [sym.imp.KERNEL32.dll_Sleep]
cmp esi, esi
jne 0x401801
mov eax, ebx
dec ebx
mov dword [ebp - 0x8b0], ebx
test eax, eax
jne 0x401730
cmp esi, esi
jne 0x401801
push edi
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push edi
push 0x4282cc
call fcn.004130a6
add esp, 8
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x438]
push eax
push 0x4282d0
mov eax, dword [ebp - 0x880]
dec eax
push eax
lea eax, [ebp - 0x848]
push eax
call fcn.00412a58
add esp, 0x14
lea eax, [ebp - 0x848]
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
lea eax, [ebp - 0x848]
push eax
push 0x42831c
call fcn.00412f3c
push 0xfffffffffffffffe
lea eax, [ebp - 0x10]
push eax
push section..data
call fcn.0041dd90
add esp, 0x14
jmp 0x4019e7
lea eax, [ebp - 0x8a8]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_GetFileSizeEx]
test eax, eax
je 0x401875
mov eax, dword [ebp - 0x8a8]
or eax, dword [ebp - 0x8a4]
jne 0x401875
push eax
lea eax, [ebp - 0x888]
push eax
push 4
lea eax, [ebp - 0x890]
push eax
push esi
mov ebx, dword [sym.imp.KERNEL32.dll_WriteFile]
call ebx
test eax, eax
je 0x401848
cmp dword [ebp - 0x888], 4
je 0x40187b
push str.Error_writting_the_log_file_header_n
mov eax, dword [ebp - 0x880]
dec eax
push eax
push edi
call fcn.00412a74
add esp, 0xc
push edi
call dword [sym.imp.KERNEL32.dll_OutputDebugStringA]
push edi
push 0x428348
call fcn.004130a6
jmp 0x4017e9
mov ebx, dword [sym.imp.KERNEL32.dll_WriteFile]
mov ecx, edi
lea edx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x401880
sub ecx, edx
mov dword [ebp - 0x880], ecx
mov ecx, edi
call fcn.00401a10
mov ecx, eax
mov dword [ebp - 0x884], ecx
mov eax, dword [ebp - 0x880]
cdq
and edx, 7
add eax, edx
sar eax, 3
cmp ecx, eax
jge 0x4018cb
mov eax, dword [ebp - 0x880]
push eax
push ecx
push str.Error_MbaeEncryptBuffer:__d____d_n
dec eax
push eax
push edi
call fcn.00412a74
add esp, 0x14
jmp 0x40185e
push 0
lea eax, [ebp - 0x888]
push eax
push 4
lea eax, [ebp - 0x880]
push eax
push esi
call ebx
test eax, eax
je 0x40197b
cmp dword [ebp - 0x888], 4
jne 0x40197b
mov eax, dword [ebp - 0x884]
shl eax, 3
mov dword [ebp - 0x894], eax
push 0
lea ecx, [ebp - 0x888]
push ecx
push eax
push edi
push esi
call ebx
test eax, eax
je 0x401924
mov eax, dword [ebp - 0x894]
cmp dword [ebp - 0x888], eax
je 0x40196d
push dword [ebp - 0x884]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x438]
push eax
push str.Error_writting_the_log_file:__s____d____d_n
lea eax, [ebp - 0x848]
push eax
call fcn.004029e0
add esp, 0x14
lea eax, [ebp - 0x848]
push eax
call dword [sym.imp.KERNEL32.dll_OutputDebugStringW]
lea eax, [ebp - 0x848]
push eax
push 0x42831c
call fcn.00412f3c
add esp, 8
mov dword [ebp - 4], 0
call fcn.004019b1
jmp 0x4019e0
push dword [ebp - 0x884]
call dword [sym.imp.KERNEL32.dll_GetLastError]
push eax
lea eax, [ebp - 0x438]
push eax
push str.Error_writting_the_log_file:__s____d____d_n
lea eax, [ebp - 0x848]
push eax
call fcn.004029e0
jmp 0x4017c8
mov dword [ebp - 4], 0xfffffffe
mov eax, dword [ebp + 0x14]
mov ecx, dword [ebp - 0x10]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x1c]
xor ecx, ebp
call fcn.0041297c
mov esp, ebp
pop ebp
ret