Function at 0x40fe40
Capabilities:
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x429db0
mov eax, dword fs:[0]
push eax
sub esp, 0x24c
mov eax, dword [0x438040]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov dword [ebp - 0x238], ecx
mov eax, dword [ebp - 0x238]
cmp dword [eax + 0xc], 0
je 0x40fe8a
mov ecx, dword [ebp - 0x238]
cmp dword [ecx], 0
jne 0x40fe91
xor eax, eax
jmp 0x4101bf
mov edx, dword [ebp - 0x238]
mov eax, dword [edx + 0xd0]
mov dword [ebp - 0x240], eax
mov ecx, dword [ebp - 0x238]
mov edx, dword [ecx + 0xbc]
shl edx, 6
add edx, dword [ebp - 0x240]
mov dword [ebp - 0x240], edx
mov ecx, 0xa
mov esi, str.IIME_CODETABLE_WRITE
lea edi, [ebp - 0x218]
rep movsd dword es:[edi], dword [esi]
movsw word es:[edi], word [esi]
push 0x1de
push 0
lea eax, [ebp - 0x1ee]
push eax
call fcn.0041de40
add esp, 0xc
lea ecx, [ebp - 0x218]
push ecx
mov edx, dword [ebp + 8]
push edx
call fcn.00418b70
add esp, 8
lea eax, [ebp - 0x218]
push eax
mov ecx, dword [ebp - 0x240]
push ecx
push 0
push 4
push 0
push 0xffffffffffffffff
call dword [sym.imp.KERNEL32.dll_CreateFileMappingW]
mov dword [ebp - 0x248], eax
cmp dword [ebp - 0x248], 0
jne 0x40ff2d
xor eax, eax
jmp 0x4101bf
mov dword [ebp - 0x250], 1
mov dword [ebp - 0x244], 0xffffffff
lea ecx, [ebp - 0x234]
call fcn.00412da0
mov dword [ebp - 4], 0
mov dword [ebp - 0x21c], 0
mov dword [ebp - 0x24c], 0
push 0
push 0
push 0
push 0xf001f
mov edx, dword [ebp - 0x248]
push edx
call dword [sym.imp.KERNEL32.dll_MapViewOfFile]
mov dword [ebp - 0x23c], eax
cmp dword [ebp - 0x23c], 0
jne 0x40ff9d
mov dword [ebp - 0x250], 0
jmp 0x41013b
mov eax, 0x7918
mov ecx, dword [ebp - 0x238]
mov word [ecx + 0xba], ax
mov edx, dword [ebp - 0x238]
cmp dword [edx + 0x6c8], 1
jne 0x40ffdf
mov eax, dword [ebp - 0x238]
mov ecx, dword [eax + 0x90c]
shr ecx, 0x14
add ecx, 2
mov edx, dword [ebp - 0x238]
mov word [edx + 0xce], cx
jmp 0x40fffe
mov eax, dword [ebp - 0x238]
mov ecx, dword [eax + 0x90c]
shr ecx, 0x14
add ecx, 2
mov edx, dword [ebp - 0x238]
mov word [edx + 0xda], cx
mov eax, dword [ebp - 0x238]
mov ecx, dword [ebp - 0x238]
mov edx, dword [ecx + 0xd0]
mov dword [eax + 0xd4], edx
mov eax, dword [ebp - 0x23c]
mov dword [ebp - 0x24c], eax
mov esi, dword [ebp - 0x238]
add esi, 0x14
mov ecx, 0x159
mov edi, dword [ebp - 0x24c]
rep movsd dword es:[edi], dword [esi]
mov ecx, dword [ebp - 0x24c]
mov dword [ecx + 0xa8], 0
mov edx, dword [ebp - 0x24c]
mov dword [edx + 0xac], 0
mov eax, dword [ebp - 0x238]
mov ecx, dword [eax + 0xd0]
sub ecx, 0x564
mov dword [ebp - 0x240], ecx
mov edx, dword [ebp - 0x240]
push edx
mov eax, dword [ebp - 0x238]
mov ecx, dword [eax + 0x10]
push ecx
mov edx, dword [ebp - 0x23c]
add edx, 0x564
push edx
call fcn.0041d8c0
add esp, 0xc
mov eax, dword [ebp - 0x23c]
push eax
sub esp, 0x18
mov ecx, esp
mov dword [ebp - 0x258], esp
lea edx, [ebp - 0x234]
push edx
call fcn.00412d10
mov eax, dword [ebp - 0x238]
mov ecx, dword [eax]
push ecx
mov ecx, dword [ebp - 0x238]
call fcn.00411fe0
push 0
push 0x80
push 2
push 0
push 0
push 0x40000000
mov edx, dword [ebp + 8]
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov dword [ebp - 0x244], eax
cmp dword [ebp - 0x244], 0xffffffff
jne 0x4100ff
mov dword [ebp - 0x250], 0
jmp 0x41013b
mov eax, dword [ebp - 0x23c]
mov ecx, dword [eax + 0xc0]
mov dword [ebp - 0x240], ecx
push 0
lea edx, [ebp - 0x21c]
push edx
mov eax, dword [ebp - 0x240]
push eax
mov ecx, dword [ebp - 0x23c]
push ecx
mov edx, dword [ebp - 0x244]
push edx
call dword [sym.imp.KERNEL32.dll_WriteFile]
mov dword [ebp - 0x250], eax
cmp dword [ebp - 0x244], 0xffffffff
je 0x41015b
mov eax, dword [ebp - 0x244]
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x244], 0
cmp dword [ebp - 0x23c], 0
je 0x41017b
mov ecx, dword [ebp - 0x23c]
push ecx
call dword [sym.imp.KERNEL32.dll_UnmapViewOfFile]
mov dword [ebp - 0x23c], 0
cmp dword [ebp - 0x248], 0
je 0x41019b
mov edx, dword [ebp - 0x248]
push edx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x248], 0
mov eax, dword [ebp - 0x250]
mov dword [ebp - 0x254], eax
mov dword [ebp - 4], 0xffffffff
lea ecx, [ebp - 0x234]
call fcn.00412cf0
mov eax, dword [ebp - 0x254]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0041c52e
mov esp, ebp
pop ebp
ret 4