Function at 0x409ae0
Capabilities:
Create directory
Delete file
Get common file path
Get file attributes
Set file attributes

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x12c4
call fcn.0043d750
mov eax, dword [0x47b014]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0x10]
push ebx
mov ebx, dword [ebp + 0xc]
push esi
push edi
mov edi, dword [ebp + 0x1c]
mov esi, ecx
mov dword [ebp - 0x12c0], eax
mov eax, dword [ebp + 0x18]
push 0x200
mov dword [ebp - 0x12b8], eax
lea eax, [ebp - 0x208]
push 0
push eax
mov dword [ebp - 0x12b4], edx
mov dword [ebp - 0x12c4], ebx
mov byte [ebp - 0x12b9], 1
call fcn.00423950
add esp, 0xc
lea eax, [ebp - 0x430]
push 0x228
push 0
push eax
call fcn.00423950
movzx eax, byte [ebx + 0xf]
add esp, 0xc
push eax
movzx eax, byte [ebx + 0xe]
push eax
movzx eax, byte [ebx + 0xd]
push eax
movzx eax, byte [ebx + 0xc]
push eax
movzx eax, byte [ebx + 0xb]
push eax
movzx eax, byte [ebx + 0xa]
push eax
movzx eax, byte [ebx + 9]
push eax
movzx eax, byte [ebx + 8]
push eax
movzx eax, word [ebx + 6]
push eax
movzx eax, word [ebx + 4]
push eax
push dword [ebx]
lea eax, [ebp - 0x208]
push str._08lx__04x__04x__02x_02x__02x_02x_02x_02x_02x_02x
push 0x100
push eax
call fcn.004019b0
push 0x228
lea eax, [ebp - 0x658]
push 0
push eax
call fcn.00423950
add esp, 0x44
lea eax, [ebp - 0xea0]
push 0x228
push 0
push eax
call fcn.00423950
add esp, 0xc
lea eax, [ebp - 0xa90]
push 0x228
push 0
push eax
call fcn.00423950
add esp, 0xc
mov dword [edi], 0xf
lea eax, [ebp - 0x10c8]
push 0x114
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
test eax, eax
jne 0x409c0e
xor al, al
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.00422009
mov esp, ebp
pop ebp
ret
lea eax, [ebp - 0x10c8]
push eax
push str._sAppPatch
lea eax, [ebp - 0x658]
push 0x114
push eax
call fcn.0040a030
lea eax, [ebp - 0x658]
push eax
push str._sCustom
lea eax, [ebp - 0xea0]
push 0x114
push eax
call fcn.0040a030
lea eax, [ebp - 0x658]
push eax
push str._sCustomSDB
lea eax, [ebp - 0xa90]
push 0x114
push eax
call fcn.0040a030
mov ebx, dword [sym.imp.KERNEL32.dll_GetLastError]
add esp, 0x30
cmp esi, 1
jne 0x409cd5
push 0
lea eax, [ebp - 0x658]
mov dword [edi], 0x10
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x409c95
call ebx
cmp eax, 0xb7
jne 0x409ccd
push 0
lea eax, [ebp - 0xea0]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x409cb1
call ebx
cmp eax, 0xb7
jne 0x409ccd
push 0
lea eax, [ebp - 0xa90]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x409cd5
call ebx
cmp eax, 0xb7
je 0x409cd5
xor al, al
mov byte [ebp - 0x12b9], al
push 0x20a
lea eax, [ebp - 0x868]
push 0
push eax
call fcn.00423950
add esp, 0xc
mov dword [edi], 0x1e
lea eax, [ebp - 0x868]
push eax
push 0x105
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
test eax, eax
je 0x409bfb
mov dword [edi], 0x1f
cmp esi, 1
jne 0x409d36
push 0
lea eax, [ebp - 0x868]
push eax
call dword [sym.imp.KERNEL32.dll_CreateDirectoryW]
test eax, eax
jne 0x409d36
call ebx
cmp eax, 0xb7
jne 0x409bfb
lea eax, [ebp - 0x208]
push eax
lea eax, [ebp - 0x868]
push eax
push str._s_s.sdb
lea eax, [ebp - 0x430]
push 0x114
push eax
call fcn.0040a030
mov al, byte [ebp - 0x12b9]
add esp, 0x14
test al, al
je 0x409f5e
mov eax, dword [ebp + 0x14]
cmp esi, 1
jne 0x409dd1
mov edx, dword [ebp + 8]
mov ecx, dword [ebp - 0x12b4]
push edi
push dword [ebp - 0x12b8]
push eax
push dword [ebp - 0x12c0]
lea eax, [ebp - 0x430]
push dword [ebp - 0x12c4]
push eax
call fcn.004090b0
mov bl, al
add esp, 0x18
test bl, bl
je 0x409f2d
mov eax, dword [ebp + 0x14]
cmp esi, 1
jne 0x409dd1
mov edx, dword [ebp - 0x12c4]
push edi
push eax
push dword [ebp - 0x12c0]
lea eax, [ebp - 0x208]
push ecx
push eax
call fcn.00409700
add esp, 0x14
jmp 0x409dda
cmp esi, 2
jne 0x409edb
lea eax, [ebp - 0x12b4]
mov dword [ebp - 0x12b8], 0
push eax
lea eax, [ebp - 0x12b8]
mov dword [edi], 0x1c
push eax
push 0
push 0xf013f
push 0
push 0
push 0
push str.SOFTWAREMicrosoftWindows_NTCurrentVersionAppCompatFlagsInstalledSDB
push closesocket
mov dword [ebp - 0x12b4], 0
call dword [sym.imp.ADVAPI32.dll_RegCreateKeyExW]
test eax, eax
jne 0x409e2f
push dword [ebp - 0x12b8]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
push 0x410
lea eax, [ebp - 0x12b0]
push 0
push eax
call fcn.00423950
add esp, 0xc
lea eax, [ebp - 0xc78]
push 0x410
push 0
push eax
call fcn.00423950
add esp, 0xc
lea eax, [ebp - 0x430]
push eax
push str.sdbinst__q___ws_
lea eax, [ebp - 0x12b0]
push 0x208
push eax
call fcn.0040a000
lea eax, [ebp - 0x208]
push eax
push str.sdbinst__q__u__g__ws
lea eax, [ebp - 0xc78]
push 0x208
push eax
call fcn.0040a000
add esp, 0x20
lea ecx, [ebp - 0xc78]
call fcn.00409a10
cmp esi, 1
jne 0x409ed0
lea ecx, [ebp - 0x12b0]
mov dword [edi], 0x1d
call fcn.00409a10
test eax, eax
je 0x409ee1
lea ecx, [ebp - 0x12b0]
call fcn.00409a10
test eax, eax
je 0x409ee1
xor bl, bl
jmp 0x409f2d
lea ecx, [ebp - 0xc78]
call fcn.00409a10
mov bl, 1
test esi, esi
jne 0x409efb
mov edx, dword [ebp - 0x12c0]
lea ecx, [ebp - 0x208]
push edi
push dword [ebp + 0x14]
call fcn.00409450
add esp, 8
mov bl, al
cmp esi, 2
jne 0x409f28
test bl, bl
jne 0x409f2d
mov edx, dword [ebp - 0x12c4]
lea eax, [ebp - 0x208]
push edi
push dword [ebp + 0x14]
push dword [ebp - 0x12c0]
push ecx
push eax
call fcn.00409700
add esp, 0x14
mov bl, al
jmp 0x409f2d
cmp esi, 1
jne 0x409f5c
lea eax, [ebp - 0x430]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
test eax, eax
je 0x409f4f
and eax, 0xfffffffe
push eax
lea eax, [ebp - 0x430]
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesW]
lea eax, [ebp - 0x430]
push eax
call dword [sym.imp.KERNEL32.dll_DeleteFileW]
mov al, bl
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.00422009
mov esp, ebp
pop ebp
ret