Function at 0x40c8f0
Capabilities:
Resolve function by parsing pe exports
Set file attributes
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x4471a9
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x1e4
push ebx
push ebp
push esi
push edi
mov edi, ecx
mov dword [esp + 0x2c], edi
push 0x4000
mov dword [esp + 0x200], 1
call fcn.0042e02a
xor ebp, ebp
add esp, 4
cmp eax, ebp
mov dword [esp + 0x34], eax
jne 0x40c93e
push str.Error_SDC_1001_:_out_of_memory
jmp 0x40c9b8
mov eax, dword [esp + 0x204]
push 0x45e440
push eax
call fcn.0041c2b1
mov esi, eax
add esp, 8
cmp esi, ebp
mov dword [esp + 0x30], esi
jne 0x40c984
mov ecx, dword [esp + 0x204]
push str._for_input
push ecx
push str.Error_SDC_1002_:_unable_to_open
mov ecx, 0x467338
call fcn.00427794
mov ecx, eax
call fcn.00427794
mov ecx, eax
jmp 0x40c9bd
mov eax, dword [esp + 0x208]
mov ecx, dword [eax - 8]
mov al, byte [ecx + eax - 1]
cmp al, 0x5c
je 0x40c9a7
push 0x4597e0
lea ecx, [esp + 0x20c]
call fcn.0042e6c5
push esi
mov ecx, edi
call fcn.0040a8b0
test al, al
jne 0x40c9dc
push str.Error_SDC_1003_:_failed_to_load_package_header
mov ecx, 0x467338
call fcn.00427794
push 0x403350
push 0xa
mov ecx, eax
call fcn.00427550
mov ecx, eax
call fcn.00403330
jmp 0x40cfd5
mov ecx, edi
call fcn.00409ed0
lea edx, [esp + 0x60]
mov dword [esp + 0x38], ebp
push edx
push esi
mov dword [esp + 0x44], ebp
mov dword [esp + 0x68], ebp
mov dword [esp + 0x6c], ebp
call fcn.0041c25e
mov ecx, dword [esp + 0x20c]
add esp, 8
lea eax, [esp + 0xb4]
push eax
push ecx
call dword [sym.imp.KERNEL32.dll_FindFirstFileA]
push eax
call dword [sym.imp.KERNEL32.dll_FindClose]
mov edx, dword [esp + 0xd4]
mov eax, dword [esp + 0xd0]
mov ecx, dword [0x45e450]
mov dword [esp + 0x58], edx
mov dword [esp + 0x5c], eax
mov dword [esp + 0x1c], ecx
lea ecx, [esp + 0x80]
mov byte [esp + 0x1fc], 2
call fcn.00409aa0
lea edx, [esp + 0x80]
lea eax, [esp + 0x1c]
push edx
push eax
mov ecx, edi
mov byte [esp + 0x204], 3
call fcn.00409f30
test al, al
je 0x40ceb0
lea ecx, [esp + 0x4c]
call fcn.00409990
mov ecx, dword [esp + 0x20c]
mov bl, byte [ecx]
lea ecx, [esp + 0x4c]
call fcn.004099c0
test bl, bl
jne 0x40ceb0
push 0x45e344
lea ecx, [esp + 0x20]
call fcn.0042bed8
cmp eax, 0xffffffff
jne 0x40ce94
lea edx, [esp + 0x208]
lea ecx, [esp + 0x18]
push edx
call fcn.0042e05e
mov eax, dword [esp + 0x1c]
mov byte [esp + 0x1fc], 4
cmp byte [eax], 0x5c
jne 0x40cadd
push 0x5c
lea ecx, [esp + 0x1c]
call fcn.0042c271
lea ecx, [esp + 0x1c]
push ecx
lea ecx, [esp + 0x1c]
call fcn.0042e701
lea edx, [esp + 0x18]
lea ecx, [esp + 0x10]
push edx
call fcn.0042e05e
lea eax, [esp + 0x10]
lea ecx, [esp + 0x20]
push eax
mov byte [esp + 0x200], 5
call fcn.0042e05e
lea ecx, [esp + 0x10]
mov byte [esp + 0x1fc], 6
call fcn.0042e274
mov ecx, dword [esp + 0x20]
mov eax, dword [ecx - 8]
lea esi, [eax - 1]
cmp esi, ebp
jl 0x40cb4a
mov edx, dword [esp + 0x20]
mov al, byte [esi + edx]
mov byte [esp + 0x48], al
mov ecx, dword [esp + 0x48]
push ecx
lea ecx, [esp + 0x14]
call fcn.0042e6ec
dec esi
jns 0x40cb2e
push 0x5c
lea ecx, [esp + 0x14]
call fcn.0042e7b0
cmp eax, 0xffffffff
je 0x40cc23
mov edx, dword [0x45e450]
mov dword [esp + 0x14], edx
mov ecx, dword [esp + 0x10]
lea edx, [esp + 0x50]
mov byte [esp + 0x1fc], 7
mov ecx, dword [ecx - 8]
push ecx
push eax
push edx
lea ecx, [esp + 0x1c]
call fcn.0042bd2c
push eax
lea ecx, [esp + 0x18]
mov byte [esp + 0x200], 8
call fcn.0042e422
lea ecx, [esp + 0x50]
mov byte [esp + 0x1fc], 7
call fcn.0042e2e9
lea eax, [esp + 0x14]
lea ecx, [esp + 0x28]
push eax
call fcn.0042e05e
lea ecx, [esp + 0x14]
mov byte [esp + 0x1fc], 9
call fcn.0042e274
mov ecx, dword [esp + 0x28]
mov eax, dword [ecx - 8]
lea esi, [eax - 1]
cmp esi, ebp
jl 0x40cbf3
mov edx, dword [esp + 0x28]
mov al, byte [esi + edx]
mov byte [esp + 0x54], al
mov ecx, dword [esp + 0x54]
push ecx
lea ecx, [esp + 0x18]
call fcn.0042e6ec
dec esi
jns 0x40cbd7
lea edx, [esp + 0x14]
lea ecx, [esp + 0x10]
push edx
call fcn.0042e422
lea ecx, [esp + 0x28]
mov byte [esp + 0x1fc], 7
call fcn.0042e2e9
lea ecx, [esp + 0x14]
mov byte [esp + 0x1fc], 6
call fcn.0042e2e9
lea eax, [esp + 0x10]
lea ecx, [esp + 0x24]
push eax
call fcn.0042e05e
push ebp
push ecx
lea edx, [esp + 0x2c]
mov ecx, esp
mov dword [esp + 0x1c], esp
push edx
mov byte [esp + 0x208], 0xa
call fcn.0042e05e
mov ecx, edi
call fcn.0040d020
test byte [esp + 0x84], 0x10
jbe 0x40ccf4
mov eax, dword [0x45e450]
mov dword [esp + 0x14], eax
push str.md__
lea ecx, [esp + 0x18]
mov byte [esp + 0x200], 0xb
call fcn.0042e472
lea ecx, [esp + 0x10]
push ecx
lea ecx, [esp + 0x18]
call fcn.0042e701
push 0x45e35c
lea ecx, [esp + 0x18]
call fcn.0042e6c5
lea edx, [esp + 0x10]
lea ecx, [esp + 0x40]
push edx
call fcn.0042e05e
push ebp
push ecx
lea eax, [esp + 0x48]
mov ecx, esp
mov dword [esp + 0xb8], esp
push eax
mov byte [esp + 0x208], 0xc
call fcn.0042e05e
mov ecx, edi
call fcn.0040d020
lea ecx, [esp + 0x40]
mov byte [esp + 0x1fc], 0xb
call fcn.0042e2e9
lea ecx, [esp + 0x14]
mov byte [esp + 0x1fc], 0xa
call fcn.0042e2e9
jmp 0x40ce4c
mov ecx, dword [esp + 0x18]
push 0x80
push ecx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
mov edx, dword [esp + 0x18]
push ebp
push 0x80
push 2
push ebp
push ebp
push 0xc0000000
push edx
call dword [sym.imp.KERNEL32.dll_CreateFileA]
mov edi, eax
cmp edi, 0xffffffff
je 0x40cf6c
mov dword [esp + 0x44], 0
mov eax, dword [esp + 0xa0]
cmp ebp, eax
jae 0x40cdd4
sub eax, ebp
cmp eax, 0x4000
jle 0x40cd4e
mov eax, 0x4000
mov ecx, dword [esp + 0x30]
mov ebx, dword [esp + 0x34]
push ecx
push eax
push 1
push ebx
call fcn.0041be0d
mov esi, eax
add esp, 0x10
test esi, esi
jbe 0x40cdd4
lea edx, [esp + 0x44]
push 0
push edx
push esi
push ebx
push edi
add ebp, esi
call dword [sym.imp.KERNEL32.dll_WriteFile]
cmp dword [esp + 0x44], esi
jb 0x40cf3c
mov eax, dword [esp + 0x38]
mov ecx, dword [esp + 0x3c]
add eax, esi
push 0
adc ecx, 0
push 0x64
push ecx
push eax
mov dword [esp + 0x48], eax
mov dword [esp + 0x4c], ecx
call fcn.0041c2d0
mov ecx, dword [esp + 0x5c]
push ecx
mov ecx, dword [esp + 0x5c]
push ecx
push edx
push eax
call fcn.0041baa0
mov edx, dword [esp + 0x210]
push eax
mov eax, dword [esp + 0x218]
push 0
push edx
push eax
call dword [sym.imp.USER32.dll_PostMessageA]
jmp 0x40cd31
mov ecx, dword [esp + 0x88]
mov edx, dword [esp + 0x8c]
mov eax, dword [esp + 0x90]
mov dword [esp + 0x70], ecx
mov ecx, dword [esp + 0x94]
mov dword [esp + 0x74], edx
mov edx, dword [esp + 0x98]
mov dword [esp + 0x68], eax
mov eax, dword [esp + 0x9c]
mov dword [esp + 0x6c], ecx
mov dword [esp + 0x78], edx
lea ecx, [esp + 0x78]
mov dword [esp + 0x7c], eax
lea edx, [esp + 0x68]
push ecx
lea eax, [esp + 0x74]
push edx
push eax
push edi
call dword [sym.imp.KERNEL32.dll_SetFileTime]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov ecx, dword [esp + 0x84]
mov edx, dword [esp + 0x18]
push ecx
push edx
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
mov edi, dword [esp + 0x2c]
xor ebp, ebp
lea ecx, [esp + 0x24]
mov byte [esp + 0x1fc], 6
call fcn.0042e2e9
lea ecx, [esp + 0x20]
mov byte [esp + 0x1fc], 5
call fcn.0042e2e9
lea ecx, [esp + 0x10]
mov byte [esp + 0x1fc], 4
call fcn.0042e2e9
lea ecx, [esp + 0x18]
mov byte [esp + 0x1fc], 3
call fcn.0042e2e9
mov esi, dword [esp + 0x30]
lea eax, [esp + 0x80]
lea ecx, [esp + 0x1c]
push eax
push ecx
mov ecx, edi
call fcn.00409f30
test al, al
jne 0x40ca76
mov eax, dword [esp + 0x34]
push eax
call fcn.0042e053
push esi
call fcn.0041c1e1
add esp, 8
lea ecx, [esp + 0x2c]
call fcn.00409990
mov ecx, dword [esp + 0x20c]
mov bl, byte [ecx]
lea ecx, [esp + 0x2c]
call fcn.004099c0
test bl, bl
jne 0x40cfb0
lea ecx, [esp + 0x80]
mov byte [esp + 0x1fc], 2
call fcn.004099f0
lea ecx, [esp + 0x1c]
mov byte [esp + 0x1fc], 1
call fcn.0042e2e9
lea ecx, [esp + 0x204]
mov byte [esp + 0x1fc], bl
call fcn.0042e2e9
lea ecx, [esp + 0x208]
mov dword [esp + 0x1fc], 0xffffffff
call fcn.0042e2e9
mov al, 1
jmp 0x40d002
mov edx, dword [esp + 0x18]
mov ecx, 0x467338
push edx
push str.Error_SDC_1005_:_short_write_on
call fcn.00427794
mov ecx, eax
call fcn.00427794
push 0x403350
push 0xa
mov ecx, eax
call fcn.00427550
mov ecx, eax
call fcn.00403330
lea ecx, [esp + 0x24]
mov byte [esp + 0x1fc], 6
call fcn.0042e2e9
lea ecx, [esp + 0x20]
mov byte [esp + 0x1fc], 5
call fcn.0042e2e9
lea ecx, [esp + 0x10]
mov byte [esp + 0x1fc], 4
call fcn.0042e2e9
lea ecx, [esp + 0x18]
mov byte [esp + 0x1fc], 3
call fcn.0042e2e9
lea ecx, [esp + 0x80]
mov byte [esp + 0x1fc], 2
call fcn.004099f0
lea ecx, [esp + 0x1c]
mov byte [esp + 0x1fc], 1
call fcn.0042e2e9
lea ecx, [esp + 0x204]
mov byte [esp + 0x1fc], 0
call fcn.0042e2e9
lea ecx, [esp + 0x208]
mov dword [esp + 0x1fc], 0xffffffff
call fcn.0042e2e9
xor al, al
mov ecx, dword [esp + 0x1f4]
pop edi
pop esi
pop ebp
mov dword fs:[0], ecx
pop ebx
add esp, 0x1f0
ret 0x14