Function at 0x1314d5e4
Capabilities:
Copy file
Extract resource via kernel32 functions
Get file size
Read file on windows

Disassembly:
push ebp
mov ebp, esp
mov ecx, 0x45
push 0
push 0
dec ecx
jne 0x1314d5ec
push ebx
push esi
push edi
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.131448dc
lea eax, [ebp - 0x1a8]
mov edx, dword [0x13145ddc]
call fcn.13144af8
xor eax, eax
push ebp
push 0x1314df96
push dword fs:[eax]
mov dword fs:[eax], esp
mov dword [ebp - 0x50], 1
xor eax, eax
mov dword [ebp - 0x4c], eax
lea eax, [ebp - 0x1ac]
mov ecx, 0x1314dfac
mov edx, dword [ebp - 4]
call fcn.13144738
mov eax, dword [ebp - 0x1ac]
lea ecx, [ebp - 0x1a8]
mov edx, 0x3f
call fcn.13146a2c
jmp 0x1314df34
mov eax, dword [ebp - 0x19c]
mov bl, byte [eax]
cmp bl, 0x2e
jne 0x1314d68a
lea eax, [ebp - 0x1b0]
mov edx, ebx
call fcn.13144638
mov eax, dword [ebp - 0x1b0]
mov edx, 0x1314dfbc
call fcn.13144838
je 0x1314def2
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x1b4]
mov edx, 3
call fcn.131447ac
mov edx, dword [ebp - 0x1b4]
mov eax, 0x1314dfd4
call fcn.131449d4
test eax, eax
jg 0x1314d82e
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x1b8]
mov edx, 3
call fcn.131447ac
mov edx, dword [ebp - 0x1b8]
mov eax, 0x1314dfe4
call fcn.131449d4
test eax, eax
jg 0x1314d82e
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x1bc]
mov edx, 3
call fcn.131447ac
mov edx, dword [ebp - 0x1bc]
mov eax, 0x1314dff4
call fcn.131449d4
test eax, eax
jle 0x1314d7f8
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x1c0]
mov edx, 3
call fcn.131447ac
mov edx, dword [ebp - 0x1c0]
mov eax, 0x1314e004
call fcn.131449d4
test eax, eax
jne 0x1314d7f8
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x1c4]
mov edx, 3
call fcn.131447ac
mov edx, dword [ebp - 0x1c4]
mov eax, 0x1314e014
call fcn.131449d4
test eax, eax
jne 0x1314d7f8
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x1c8]
mov edx, 3
call fcn.131447ac
mov edx, dword [ebp - 0x1c8]
mov eax, 0x1314e028
call fcn.131449d4
test eax, eax
jne 0x1314d7f8
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x1cc]
mov edx, 3
call fcn.131447ac
mov edx, dword [ebp - 0x1cc]
mov eax, 0x1314e034
call fcn.131449d4
test eax, eax
je 0x1314d82e
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x1d0]
mov edx, 3
call fcn.131447ac
mov edx, dword [ebp - 0x1d0]
mov eax, 0x1314e044
call fcn.131449d4
test eax, eax
jle 0x1314def2
xor eax, eax
push ebp
push 0x1314d8b4
push dword fs:[eax]
mov dword fs:[eax], esp
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x1d4]
mov edx, 3
call fcn.131447ac
mov eax, dword [ebp - 0x1d4]
call fcn.131448ec
push eax
call sub.kernel32.dll_CreateFileA_1
mov esi, eax
push 0
push esi
call sub.kernel32.dll_GetFileSize_1
mov edi, eax
mov eax, edi
call fcn.131428c4
mov dword [ebp - 0x48], eax
push 0
lea eax, [ebp - 0xc]
push eax
push edi
mov eax, dword [ebp - 0x48]
push eax
push esi
call sub.kernel32.dll_ReadFile_1
push esi
call sub.kernel32.dll_CloseHandle_1
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x1314d8be
lea eax, [ebp - 0x40]
mov edx, dword [ebp - 0x48]
call fcn.13144648
lea eax, [ebp - 0x1d8]
push eax
mov ecx, 2
xor edx, edx
mov eax, dword [ebp - 0x40]
call fcn.1314494c
mov eax, dword [ebp - 0x1d8]
mov edx, 0x1314e054
call fcn.13144838
jne 0x1314def2
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x1dc]
mov edx, 3
call fcn.131447ac
mov eax, dword [ebp - 0x1dc]
call fcn.131448ec
push eax
call sub.kernel32.dll_LoadLibraryA
mov dword [ebp - 0x20], eax
cmp dword [ebp - 0x20], 0
je 0x1314df52
push 0x1314e058
push 1
mov eax, dword [ebp - 0x20]
push eax
call sub.kernel32.dll_FindResourceA
mov dword [ebp - 0x24], eax
mov eax, dword [ebp - 0x24]
push eax
mov eax, dword [ebp - 0x20]
push eax
call sub.kernel32.dll_LoadResource
mov dword [ebp - 0x28], eax
mov eax, dword [ebp - 0x28]
push eax
call sub.kernel32.dll_LockResource
mov dword [ebp - 0x44], eax
mov eax, dword [ebp - 0x24]
push eax
mov eax, dword [ebp - 0x20]
push eax
call sub.kernel32.dll_SizeofResource
mov dword [ebp - 0x2c], eax
lea eax, [ebp - 0x38]
push eax
lea eax, [ebp - 0x1e0]
mov edx, dword [ebp - 0x44]
call fcn.13144648
mov eax, dword [ebp - 0x1e0]
mov ecx, dword [ebp - 0x2c]
mov edx, 1
call fcn.1314494c
mov eax, dword [ebp - 0x20]
push eax
call sub.kernel32.dll_FreeLibrary_1
mov eax, dword [ebp - 0x38]
mov edx, 0x1314e06c
call fcn.13144838
je 0x1314def2
mov eax, dword [ebp - 0x50]
add dword [ebp - 0x4c], eax
cmp dword [ebp - 0x4c], 0xa
jg 0x1314df47
cmp dword [ebp - 0x4c], 0xa
jge 0x1314def2
push 0
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
push 0x1314dfd4
lea eax, [ebp - 0x1e4]
mov edx, 4
call fcn.131447ac
mov eax, dword [ebp - 0x1e4]
call fcn.131448ec
push eax
lea edx, [ebp - 0x1f0]
xor eax, eax
call fcn.13142c40
mov ecx, dword [ebp - 0x1f0]
lea eax, [ebp - 0x1ec]
mov edx, 0x1314e078
call fcn.13144738
mov eax, dword [ebp - 0x1ec]
lea edx, [ebp - 0x1e8]
call fcn.1314c4a8
mov eax, dword [ebp - 0x1e8]
call fcn.131448ec
push eax
call sub.kernel32.dll_CopyFileA
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x1f4]
mov edx, 3
call fcn.131447ac
mov eax, dword [ebp - 0x1f4]
call fcn.131448ec
push eax
call sub.kernel32.dll_LoadLibraryA
mov dword [ebp - 0x10], eax
push 0x10
push 1
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FindResourceA
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
je 0x1314daff
mov eax, dword [ebp - 0x14]
push eax
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_LoadResource
push eax
call sub.kernel32.dll_LockResource
mov dword [ebp - 0x34], eax
mov eax, dword [ebp - 0x14]
push eax
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_SizeofResource
mov dword [ebp - 0x18], eax
push 0
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
push 0x1314dfd4
lea eax, [ebp - 0x1f8]
mov edx, 4
call fcn.131447ac
mov eax, dword [ebp - 0x1f8]
call fcn.131448ec
push eax
call sub.kernel32.dll_BeginUpdateResourceA
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x18]
push eax
mov eax, dword [ebp - 0x34]
push eax
push 0
push 1
push 0x10
mov eax, dword [ebp - 0x1c]
push eax
call sub.kernel32.dll_UpdateResourceA
push 0
mov eax, dword [ebp - 0x1c]
push eax
call sub.kernel32.dll_EndUpdateResourceA
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FreeLibrary_1
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x1fc]
mov edx, 3
call fcn.131447ac
mov eax, dword [ebp - 0x1fc]
call fcn.131448ec
push eax
call sub.kernel32.dll_LoadLibraryA
mov dword [ebp - 0x10], eax
push 3
push 1
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FindResourceA
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jbe 0x1314db6b
push 3
push 2
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FindResourceA
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jbe 0x1314db81
push 3
push 3
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FindResourceA
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jbe 0x1314db97
push 3
push 4
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FindResourceA
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jbe 0x1314dbad
push 3
push 5
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FindResourceA
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jbe 0x1314dbc3
push 3
push 6
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FindResourceA
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jbe 0x1314dbd9
push 3
push 7
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FindResourceA
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jbe 0x1314dbef
push 3
push 8
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FindResourceA
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jbe 0x1314dc05
push 3
push 9
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FindResourceA
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jbe 0x1314dc1b
push 3
push 0xa
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FindResourceA
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jbe 0x1314dc31
push 3
push 0xb
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FindResourceA
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
jbe 0x1314dc47
push 3
push 0xc
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FindResourceA
mov dword [ebp - 0x14], eax
cmp dword [ebp - 0x14], 0
ja 0x1314dcc2
push 0
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
push 0x1314dfd4
lea eax, [ebp - 0x200]
mov edx, 4
call fcn.131447ac
mov eax, dword [ebp - 0x200]
call fcn.131448ec
push eax
call sub.kernel32.dll_BeginUpdateResourceA
mov dword [ebp - 0x1c], eax
mov eax, dword [ebp - 0x1c]
push eax
push 0x1314c698
push 3
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_EnumResourceNamesA
mov eax, dword [ebp - 0x1c]
push eax
push 0x1314c698
push 0xe
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_EnumResourceNamesA
push 0
mov eax, dword [ebp - 0x1c]
push eax
call sub.kernel32.dll_EndUpdateResourceA
mov eax, dword [ebp - 0x10]
push eax
call sub.kernel32.dll_FreeLibrary_1
push 0
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
push 0x1314dfd4
lea eax, [ebp - 0x204]
mov edx, 4
call fcn.131447ac
mov eax, dword [ebp - 0x204]
call fcn.131448ec
push eax
call sub.kernel32.dll_BeginUpdateResourceA
mov dword [ebp - 8], eax
push 0
push 0x80
push 3
push 0
push 1
push 0x80000000
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x208]
mov edx, 3
call fcn.131447ac
mov eax, dword [ebp - 0x208]
call fcn.131448ec
push eax
call sub.kernel32.dll_CreateFileA_1
mov esi, eax
push 0
push esi
call sub.kernel32.dll_GetFileSize_1
mov edi, eax
mov eax, edi
call fcn.131428c4
mov dword [ebp - 0x30], eax
push 0
lea eax, [ebp - 0xc]
push eax
push edi
mov eax, dword [ebp - 0x30]
push eax
push esi
call sub.kernel32.dll_ReadFile_1
push esi
call sub.kernel32.dll_CloseHandle_1
lea eax, [ebp - 0x3c]
mov edx, 0x1314e06c
call fcn.13144504
push edi
mov eax, dword [ebp - 0x30]
push eax
xor edx, edx
xor eax, eax
call fcn.13145a58
push eax
push 1
push 0x1314e080
mov eax, dword [ebp - 8]
push eax
call sub.kernel32.dll_UpdateResourceA
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x210]
mov edx, 3
call fcn.131447ac
mov eax, dword [ebp - 0x210]
lea edx, [ebp - 0x20c]
call fcn.1314bda0
mov eax, dword [ebp - 0x20c]
call fcn.131446ec
push eax
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x218]
mov edx, 3
call fcn.131447ac
mov eax, dword [ebp - 0x218]
lea edx, [ebp - 0x214]
call fcn.1314bda0
mov eax, dword [ebp - 0x214]
call fcn.131448ec
push eax
xor edx, edx
xor eax, eax
call fcn.13145a58
push eax
push 1
push 0x1314e088
mov eax, dword [ebp - 8]
push eax
call sub.kernel32.dll_UpdateResourceA
mov eax, dword [ebp - 0x3c]
call fcn.131446ec
push eax
mov eax, dword [ebp - 0x3c]
call fcn.131448ec
push eax
xor edx, edx
xor eax, eax
call fcn.13145a58
push eax
push 1
push 0x1314e058
mov eax, dword [ebp - 8]
push eax
call sub.kernel32.dll_UpdateResourceA
mov eax, dword [ebp - 0x30]
call fcn.131428f4
push 0
mov eax, dword [ebp - 8]
push eax
call sub.kernel32.dll_EndUpdateResourceA
push 0
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x21c]
mov edx, 3
call fcn.131447ac
mov eax, dword [ebp - 0x21c]
call fcn.131448ec
push eax
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
push 0x1314dfd4
lea eax, [ebp - 0x220]
mov edx, 4
call fcn.131447ac
mov eax, dword [ebp - 0x220]
call fcn.131448ec
push eax
call sub.kernel32.dll_CopyFileA
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
push 0x1314dfd4
lea eax, [ebp - 0x224]
mov edx, 4
call fcn.131447ac
mov eax, dword [ebp - 0x224]
call fcn.13146abc
mov eax, dword [ebp - 0x1a0]
and eax, 0x10
cmp eax, 0x10
jne 0x1314df34
mov eax, dword [ebp - 0x19c]
cmp byte [eax], 0x2e
je 0x1314df34
push dword [ebp - 4]
push 0x1314dfc8
push dword [ebp - 0x19c]
lea eax, [ebp - 0x228]
mov edx, 3
call fcn.131447ac
mov eax, dword [ebp - 0x228]
call fcn.1314d5e4
lea eax, [ebp - 0x1a8]
call fcn.13146a7c
test eax, eax
je 0x1314d65a
lea eax, [ebp - 0x1a8]
call fcn.13146aa0
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x1314df9d
lea eax, [ebp - 0x228]
mov edx, 0x20
call fcn.13144490
lea eax, [ebp - 0x1a8]
mov edx, dword [0x13145ddc]
call fcn.13144bbc
lea eax, [ebp - 0x40]
mov edx, 3
call fcn.13144490
lea eax, [ebp - 4]
call fcn.1314446c
ret