Function at 0x40cf50
Capabilities:
Create directory
Get common file path
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x451a81
mov eax, dword fs:[0]
push eax
sub esp, 0x1a8
mov eax, dword [0x4650c0]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov eax, dword [ebp + 8]
xor ebx, ebx
push 0x103
mov edi, ecx
lea ecx, [ebp - 0x197]
push ebx
push ecx
mov dword [ebp - 0x1a8], eax
mov byte [ebp - 0x198], bl
call fcn.0043c440
add esp, 0xc
push ebx
push 0x23
lea edx, [ebp - 0x198]
push edx
push ebx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathA]
mov esi, dword [sym.imp.SHLWAPI.dll_PathAppendA]
push str.SQ_PlatForm
lea eax, [ebp - 0x198]
push eax
call esi
lea ecx, [ebp - 0x1b4]
push ecx
lea edx, [ebp - 0x198]
push edx
mov dword [ebp - 0x1b4], 0xc
mov dword [ebp - 0x1b0], ebx
mov dword [ebp - 0x1ac], ebx
call dword [sym.imp.KERNEL32.dll_CreateDirectoryA]
push str.UContext
lea eax, [ebp - 0x198]
push eax
call esi
lea ecx, [ebp - 0x198]
push 0x458d74
push ecx
call fcn.0043a133
mov esi, eax
add esp, 8
cmp esi, ebx
je 0x40d1e4
push 0x80
lea edx, [ebp - 0x93]
push ebx
push edx
mov byte [ebp - 0x94], bl
call fcn.0043c440
add esp, 0xc
lea eax, [ebp - 0x19c]
push eax
mov ecx, 0x4589e4
call fcn.00401e30
lea ecx, [ebp - 0x1a4]
push ecx
mov ecx, 0x4589e4
mov dword [ebp - 4], ebx
call fcn.00401e30
push esi
push 0x80
lea edx, [ebp - 0x94]
push 1
push edx
mov byte [ebp - 4], 1
call fcn.0043a646
add esp, 0x10
test eax, eax
je 0x40d0bf
lea eax, [ebp - 0x19c]
push eax
lea ecx, [ebp - 0x94]
call fcn.004016f0
push 0x81
lea ecx, [ebp - 0x94]
push ebx
push ecx
call fcn.0043c440
push esi
push 0x80
lea edx, [ebp - 0x94]
push 1
push edx
call fcn.0043a646
add esp, 0x1c
test eax, eax
jne 0x40d080
push esi
call fcn.0043a388
mov ecx, dword [ebp - 0x19c]
add esp, 4
cmp dword [ecx - 0xc], ebx
jl 0x40d196
push 0x458b18
push ecx
call fcn.00439fad
add esp, 8
cmp eax, ebx
je 0x40d196
sub eax, dword [ebp - 0x19c]
sar eax, 1
mov esi, eax
cmp esi, 0xffffffff
je 0x40d196
lea ecx, [ebp - 0x1a0]
lea edx, [ebp - 0x19c]
call fcn.0040de50
mov eax, dword [eax]
push eax
call fcn.0043a02e
mov dword [edi], eax
mov eax, dword [ebp - 0x1a0]
add eax, 0xfffffff0
mov dword [edi + 4], edx
add esp, 4
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d143
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [ebp - 0x19c]
mov eax, dword [ecx - 0xc]
sub eax, esi
lea edx, [ebp - 0x19c]
dec eax
push edx
lea ecx, [ebp - 0x1a0]
call fcn.0040ddd0
mov edi, dword [ebp - 0x1a8]
mov byte [ebp - 4], 2
call fcn.004138d0
mov byte [ebp - 4], 1
mov eax, dword [ebp - 0x1a0]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d196
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov byte [ebp - 4], bl
mov eax, dword [ebp - 0x1a4]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d1bb
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x19c]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40d1e4
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.004397ee
mov esp, ebp
pop ebp
ret 4