Function at 0x413d00
Capabilities:
Check if file exists
Get file attributes
Resolve function by parsing pe exports
Write file on windows

Disassembly:
push 0xffffffffffffffff
push 0x636568
mov eax, dword fs:[0]
push eax
sub esp, 0x238
mov eax, dword [0x7496c8]
xor eax, esp
mov dword [esp + 0x234], eax
push ebx
push ebp
push esi
push edi
mov eax, dword [0x7496c8]
xor eax, esp
push eax
lea eax, [esp + 0x24c]
mov dword fs:[0], eax
mov ecx, dword [esp + 0x26c]
mov eax, dword [esp + 0x25c]
mov esi, dword [esp + 0x264]
xor ebp, ebp
push ebp
push ebp
push ebp
push ebp
push 0x100
lea edx, [esp + 0x15c]
mov dword [esp + 0x34], ecx
push edx
lea ecx, [esp + 0x3c]
push ecx
push eax
mov dword [esp + 0x38], eax
call fcn.005d89c0
add esp, 0x20
cmp eax, ebp
jne 0x414422
push ebp
lea eax, [esp + 0x14c]
xor edx, edx
push eax
lea ecx, [esp + 0xb8]
mov dword [esp + 0xb8], ebp
mov dword [esp + 0xc0], ebp
mov word [esp + 0xbc], dx
call fcn.00401980
mov dword [esp + 0x254], ebp
xor ecx, ecx
mov dword [esp + 0x80], ebp
mov dword [esp + 0x88], ebp
mov word [esp + 0x84], cx
mov byte [esp + 0x254], 1
mov ecx, dword [esp + 0xb0]
cmp ecx, ebp
jne 0x413de7
lea ecx, [esp + 0xb4]
mov eax, dword [0x74ea5c]
cmp eax, ebp
jne 0x413df5
mov eax, 0x74ea60
push ebp
push ecx
push esi
push eax
push 0x66e4a4
lea ecx, [esp + 0x94]
call fcn.004118f0
push 0x5c
push 0x2f
lea ecx, [esp + 0x88]
call fcn.0040fc40
xor edx, edx
mov dword [esp + 0x8c], ebp
mov dword [esp + 0x94], ebp
mov word [esp + 0x90], dx
mov byte [esp + 0x254], 2
mov eax, dword [esp + 0x80]
cmp eax, ebp
jne 0x413e4c
lea eax, [esp + 0x84]
push ebp
push eax
push 0x66ae98
lea ecx, [esp + 0x98]
call fcn.004021b0
mov eax, dword [esp + 0x8c]
cmp eax, ebp
jne 0x413e71
lea eax, [esp + 0x90]
push 0x5c
push eax
call fcn.00612d55
add esp, 8
cmp eax, ebp
je 0x413fb1
add eax, 2
xor ecx, ecx
mov word [eax], cx
mov eax, dword [esp + 0x8c]
cmp eax, ebp
jne 0x413e9e
lea eax, [esp + 0x90]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
jne 0x413fb1
mov eax, dword [esp + 0x8c]
cmp eax, ebp
jne 0x413ec0
lea eax, [esp + 0x90]
add eax, 6
push 0x5c
push eax
call fcn.00614db0
mov esi, eax
add esp, 8
cmp esi, ebp
je 0x413fb1
mov bl, 3
lea ebx, [ebx]
mov eax, dword [esp + 0x8c]
cmp eax, ebp
jne 0x413ef2
lea eax, [esp + 0x90]
xor edx, edx
push eax
lea ecx, [esp + 0x78]
mov dword [esp + 0x78], ebp
mov dword [esp + 0x80], ebp
mov word [esp + 0x7c], dx
call fcn.004017f0
mov byte [esp + 0x254], bl
mov eax, dword [esp + 0x74]
mov ecx, eax
cmp eax, ebp
jne 0x413f23
lea ecx, [esp + 0x78]
mov eax, dword [esp + 0x8c]
cmp eax, ebp
jne 0x413f35
lea eax, [esp + 0x90]
mov edx, esi
sub edx, eax
xor eax, eax
sar edx, 1
mov word [ecx + edx*2], ax
mov eax, dword [esp + 0x74]
cmp eax, ebp
jne 0x413f4d
lea eax, [esp + 0x78]
push ebp
push eax
call fcn.004a29e0
add esp, 8
test eax, eax
jne 0x413f75
mov eax, dword [esp + 0x74]
cmp eax, ebp
jne 0x413f67
lea eax, [esp + 0x78]
push ebp
push eax
call fcn.004a2bc0
add esp, 8
test eax, eax
je 0x413fa0
push 0x5c
add esi, 2
push esi
call fcn.00614db0
add esp, 8
mov esi, eax
mov byte [esp + 0x254], 2
lea ecx, [esp + 0x74]
call fcn.004011f0
cmp esi, ebp
jne 0x413ee0
jmp 0x413fb1
mov byte [esp + 0x254], 2
lea ecx, [esp + 0x74]
call fcn.004011f0
push 0x2000
call fcn.0061586f
add esp, 4
mov dword [esp + 0x1c], eax
cmp eax, ebp
jne 0x41400f
mov byte [esp + 0x254], 1
lea ecx, [esp + 0x8c]
call fcn.004011f0
mov byte [esp + 0x254], 0
lea ecx, [esp + 0x80]
call fcn.004011f0
mov dword [esp + 0x254], 0xffffffff
lea ecx, [esp + 0xb0]
call fcn.004011f0
mov eax, 0xffffff98
jmp 0x414422
xor ecx, ecx
mov byte [esp + 0x17], 0
mov dword [esp + 0x98], ebp
mov dword [esp + 0xa0], ebp
mov word [esp + 0x9c], cx
mov byte [esp + 0x254], 4
mov edx, dword [esp + 0x18]
push edx
call fcn.005d9050
mov edi, eax
add esp, 4
cmp edi, ebp
jne 0x4143b6
mov eax, dword [esp + 0x80]
cmp eax, ebp
jne 0x41405d
lea eax, [esp + 0x84]
push 0x66e49c
push eax
call fcn.00615f0d
mov esi, eax
add esp, 8
cmp esi, ebp
jne 0x4140c5
mov eax, dword [esp + 0x80]
cmp eax, ebp
jne 0x414083
lea eax, [esp + 0x84]
push ebp
push eax
push 0x66e534
lea ecx, [esp + 0xa4]
call fcn.004021b0
mov eax, dword [esp + 0x98]
cmp eax, ebp
jne 0x4140a8
lea eax, [esp + 0x9c]
push 0x66e49c
push eax
call fcn.00615f0d
mov esi, eax
add esp, 8
cmp esi, ebp
je 0x4143b6
mov byte [esp + 0x17], 1
mov ebx, dword [esp + 0x1c]
lea esp, [esp]
mov eax, dword [esp + 0x18]
push 0x2000
push ebx
push eax
call fcn.005d8c60
mov edi, eax
add esp, 0xc
cmp edi, ebp
jle 0x4140fe
push esi
push 1
push edi
push ebx
call fcn.00615dc5
add esp, 0x10
cmp eax, 1
je 0x4140d0
or edi, 0xffffffff
push esi
call fcn.00615be7
lea ecx, [esp + 0x14c]
push str.idmcchandler2.dll
push ecx
call fcn.006148e0
add esp, 0xc
test eax, eax
jne 0x41413a
lea edx, [esp + 0x148]
push str.idmcchandler2_64.dll
push edx
call fcn.006148e0
add esp, 8
test eax, eax
je 0x4142e8
cmp byte [esp + 0x17], 0
je 0x414155
mov eax, dword [esp + 0x98]
cmp eax, ebp
jne 0x414167
lea eax, [esp + 0x9c]
jmp 0x414167
mov eax, dword [esp + 0x80]
cmp eax, ebp
jne 0x414167
lea eax, [esp + 0x84]
push eax
lea ecx, [esp + 0xc0]
call fcn.00402180
mov byte [esp + 0x254], 5
xor eax, eax
mov dword [esp + 0x74], ebp
mov dword [esp + 0x7c], ebp
mov word [esp + 0x78], ax
mov bl, 6
mov byte [esp + 0x254], bl
lea ecx, [esp + 0x148]
push str.idmcchandler2.dll
push ecx
call fcn.006148e0
add esp, 8
mov ecx, 0x66e4e4
test eax, eax
jne 0x4141b7
mov ecx, 0x66e4b8
mov eax, dword [0x74ea7c]
cmp eax, ebp
jne 0x4141c5
mov eax, 0x74ea80
push ebp
push ecx
push eax
push 0x66add0
lea ecx, [esp + 0x84]
call fcn.00402320
mov eax, dword [esp + 0x74]
mov ecx, eax
cmp eax, ebp
jne 0x4141e7
lea ecx, [esp + 0x78]
mov eax, dword [esp + 0xbc]
cmp eax, ebp
jne 0x4141f9
lea eax, [esp + 0xc0]
push ebp
push ebp
push ecx
push eax
call fcn.004a2610
add esp, 0x10
test eax, eax
jne 0x4142bf
xor edx, edx
mov dword [esp + 0xa4], ebp
mov dword [esp + 0xac], ebp
mov word [esp + 0xa8], dx
mov byte [esp + 0x254], 7
mov eax, dword [esp + 0x74]
cmp eax, ebp
jne 0x414239
lea eax, [esp + 0x78]
push ebp
push eax
push 0x66e4b4
lea ecx, [esp + 0xb0]
call fcn.004021b0
mov eax, dword [esp + 0xa4]
mov ecx, eax
cmp eax, ebp
jne 0x414260
lea ecx, [esp + 0xa8]
mov eax, dword [esp + 0xbc]
cmp eax, ebp
jne 0x414272
lea eax, [esp + 0xc0]
push ebp
push ebp
push ecx
push eax
call fcn.004a2610
add esp, 0x10
test eax, eax
je 0x4142ac
mov eax, dword [esp + 0x74]
mov ecx, eax
cmp eax, ebp
jne 0x414290
lea ecx, [esp + 0x78]
mov eax, dword [esp + 0xa4]
cmp eax, ebp
jne 0x4142a2
lea eax, [esp + 0xa8]
push ecx
push eax
call fcn.004110d0
add esp, 8
mov byte [esp + 0x254], bl
lea ecx, [esp + 0xa4]
call fcn.004011f0
mov byte [esp + 0x254], 5
lea ecx, [esp + 0x74]
call fcn.004011f0
mov byte [esp + 0x254], 4
lea ecx, [esp + 0xbc]
call fcn.004011f0
mov ebx, dword [esp + 0x1c]
cmp byte [esp + 0x17], 0
je 0x4143ba
lea eax, [esp + 0x148]
push str..dll
push eax
call fcn.006148e0
add esp, 8
test eax, eax
je 0x414384
mov eax, dword [esp + 0x80]
cmp eax, ebp
jne 0x41431e
lea eax, [esp + 0x84]
push 0x40
lea ecx, [esp + 0x10c]
push ecx
push eax
call fcn.004110f0
add esp, 0xc
test eax, eax
je 0x41437a
mov eax, dword [esp + 0x98]
cmp eax, ebp
jne 0x414347
lea eax, [esp + 0x9c]
push 0x40
lea edx, [esp + 0xcc]
push edx
push eax
call fcn.004110f0
add esp, 0xc
test eax, eax
je 0x41437a
lea eax, [esp + 0xc8]
push eax
lea ecx, [esp + 0x10c]
push ecx
call fcn.00614d5e
add esp, 8
test eax, eax
je 0x414384
mov edx, dword [esp + 0x20]
mov dword [edx], 1
mov eax, dword [esp + 0x80]
mov ecx, eax
cmp eax, ebp
jne 0x414398
lea ecx, [esp + 0x84]
mov eax, dword [esp + 0x98]
cmp eax, ebp
jne 0x4143aa
lea eax, [esp + 0x9c]
push ecx
push eax
call fcn.004110d0
add esp, 8
jmp 0x4143ba
mov ebx, dword [esp + 0x1c]
mov eax, dword [esp + 0x18]
push eax
call fcn.005d8e10
push ebx
call fcn.0061477c
add esp, 8
mov byte [esp + 0x254], 2
lea ecx, [esp + 0x98]
call fcn.004011f0
mov byte [esp + 0x254], 1
lea ecx, [esp + 0x8c]
call fcn.004011f0
mov byte [esp + 0x254], 0
lea ecx, [esp + 0x80]
call fcn.004011f0
mov dword [esp + 0x254], 0xffffffff
lea ecx, [esp + 0xb0]
call fcn.004011f0
mov eax, edi
mov ecx, dword [esp + 0x24c]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebp
pop ebx
mov ecx, dword [esp + 0x234]
xor ecx, esp
call fcn.00613241
add esp, 0x244
ret