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

Disassembly:
push ebp
mov ebp, esp
mov eax, 0x20ac
call fcn.00412d10
mov dl, byte [0x41fd7c]
push ebx
push esi
mov esi, 0x81
push edi
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0x837]
mov byte [ebp - 0x838], dl
mov byte [ebp - 0x428], dl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0x427]
mov byte [ebp - 0x1684], dl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0x1683]
mov byte [ebp - 0xc48], dl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0xc47]
mov byte [ebp - 0x1a94], dl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0x1a93]
mov byte [ebp - 0x220], dl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0x21f]
mov byte [ebp - 0x630], dl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0x62f]
mov byte [ebp - 0xa40], dl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0xa3f]
mov byte [ebp - 0x1ea4], dl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0x1ea3]
xor ebx, ebx
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0x1c9b]
mov byte [ebp - 0x1c9c], dl
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov dword [ebp - 4], ebx
mov dword [ebp - 0x10], ebx
stosb byte es:[edi], al
mov dword [ebp - 0xc], ebx
push 1
lea ecx, [ebp - 0x14]
pop eax
push ecx
lea ecx, [ebp - 0x147c]
push ecx
push eax
push dword [ebp + 8]
mov dword [ebp - 8], eax
call fcn.0040656e
add esp, 0x10
test eax, eax
je 0x407172
mov ebx, dword [sym.imp.KERNEL32.dll_lstrcpyA]
mov edi, dword [sym.imp.USER32.dll_wsprintfA]
cmp dword [ebp - 0x14], 1
je 0x4071fc
lea eax, [ebp - 0x126c]
push eax
call fcn.00412070
cmp byte [eax], 0x40
pop ecx
jne 0x406ab4
inc eax
push eax
lea eax, [ebp - 0x126c]
push eax
call fcn.00412c20
pop ecx
lea eax, [ebp - 0x126c]
pop ecx
push eax
lea eax, [ebp - 0x838]
push eax
call ebx
lea eax, [ebp - 0x428]
push 0x424020
push eax
call ebx
lea eax, [ebp - 0x428]
push eax
call fcn.0040a097
pop ecx
lea eax, [ebp - 0x838]
push eax
lea eax, [ebp - 0x428]
push eax
lea eax, [ebp - 0xc48]
push 0x41c268
push eax
call edi
add esp, 0x10
lea eax, [ebp - 0xc48]
push eax
lea eax, [ebp - 0x1474]
push eax
call ebx
cmp dword [ebp - 4], 5
jne 0x406b39
lea eax, [ebp - 0x126c]
push 0x420240
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
je 0x406b85
cmp dword [ebp + 0xc], 0
je 0x406b8d
lea eax, [ebp - 0x126c]
push str._MSRSTRT.EXE
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x406b66
cmp dword [0x421178], eax
je 0x406b66
mov dword [ebp - 0xc], 1
jmp 0x406b6a
and dword [ebp - 0xc], 0
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0x126c]
push eax
call fcn.00402f85
pop ecx
test eax, eax
pop ecx
jne 0x406b8d
cmp dword [ebp - 0xc], eax
jne 0x406b8d
inc dword [ebp - 8]
jmp 0x407151
and dword [ebp - 4], 0
lea eax, [ebp - 0xc48]
push eax
call fcn.00406412
test eax, eax
pop ecx
jne 0x406c27
push 0x5c
lea eax, [ebp - 0x428]
push dword [ebp - 0x147c]
push dword [0x424b2c]
push 0x5c
push eax
lea eax, [ebp - 0x1684]
push str._s.._c_s_d_c
push eax
call edi
add esp, 0x1c
lea eax, [ebp - 0x838]
push eax
lea eax, [ebp - 0x1684]
push eax
lea eax, [ebp - 0x1a94]
push 0x41c268
push eax
call edi
add esp, 0x10
lea eax, [ebp - 0x1a94]
push eax
call fcn.00406412
test eax, eax
pop ecx
je 0x407184
lea eax, [ebp - 0x1684]
push eax
call fcn.00407204
pop ecx
push eax
lea eax, [ebp - 0x428]
push eax
call ebx
lea eax, [ebp - 0x428]
push eax
push 0x423740
call ebx
cmp byte [ebp - 0x1064], 0
je 0x406edf
lea eax, [ebp - 0x1064]
push 0
push eax
lea eax, [ebp - 0x630]
push eax
call fcn.0040685e
add esp, 0xc
lea eax, [ebp - 0x126c]
push eax
lea eax, [ebp - 0x220]
push eax
call ebx
cmp dword [ebp + 0xc], 0
jne 0x406c78
lea eax, [ebp - 0x630]
push eax
call fcn.00405b25
cmp eax, 0xfffffffe
pop ecx
je 0x4071fc
lea eax, [ebp - 0x20ac]
push 0x208
push eax
lea eax, [ebp - 0x630]
push eax
call fcn.00409e62
add esp, 0xc
test eax, eax
je 0x4071fc
lea eax, [ebp - 0x20ac]
push eax
lea eax, [ebp - 0x630]
push eax
call ebx
lea eax, [ebp - 0xc48]
push eax
push 0x41c310
push 0x4248e0
call edi
add esp, 0xc
lea eax, [ebp - 0x220]
push eax
lea eax, [ebp - 0x630]
push eax
lea eax, [ebp - 0xa40]
push 0x41c268
push eax
call edi
add esp, 0x10
cmp dword [ebp + 0xc], 0
je 0x406d4a
cmp dword [ebp - 0xc], 0
jne 0x406d4a
lea eax, [ebp - 0x630]
push eax
push 0x208
call dword [sym.imp.KERNEL32.dll_GetTempPathA]
test eax, eax
je 0x4071fc
push 0x4239c0
push 0
lea eax, [ebp - 0x630]
push 0x41c5cc
push eax
call dword [sym.imp.KERNEL32.dll_GetTempFileNameA]
test eax, eax
je 0x4071fc
lea eax, [ebp - 0x1ea4]
push 0x4239c0
push eax
call ebx
lea eax, [ebp - 0x1c9c]
push eax
push 0x4239c0
call fcn.0040a0d9
pop ecx
pop ecx
jmp 0x406d58
lea eax, [ebp - 0xa40]
push eax
push 0x4239c0
call ebx
push 0x4239c0
call fcn.00406412
pop ecx
mov dword [ebp - 0x10], eax
lea eax, [ebp - 0x220]
push str.CTL3D32.DLL
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x406dad
call fcn.00409d77
test eax, eax
je 0x406dad
lea eax, [ebp - 0x220]
mov dword [ebp - 4], 5
push eax
push 0x41c06c
push dword [0x424684]
call fcn.00403adc
add esp, 0xc
push eax
call fcn.00404da3
pop ecx
lea eax, [ebp - 0x220]
push 0x4213b8
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
je 0x406df8
lea eax, [ebp - 0x220]
push str._MSRSTRT.EXE
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x406e14
push str.BootStrap
push dword [ebp + 8]
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x406e14
cmp dword [0x421178], eax
je 0x406e08
cmp dword [ebp + 0xc], eax
je 0x406e08
push 0x4239c0
call fcn.00410b60
pop ecx
jmp 0x406ea0
mov dword [ebp - 4], 5
jmp 0x406ea0
lea eax, [ebp - 0xc54]
push eax
call fcn.00407934
test eax, eax
pop ecx
jne 0x406ea0
lea eax, [ebp - 0xa40]
mov dword [ebp - 4], 5
push eax
push dword [ebp - 0xc4c]
call fcn.0040501f
pop ecx
cmp eax, 0xfffffffe
pop ecx
je 0x4071fc
push dword [0x424444]
call fcn.00404d36
cmp eax, 0xfffffffe
pop ecx
je 0x4071fc
cmp dword [0x421198], 0
jne 0x406e92
cmp dword [ebp - 0xc4c], 1
je 0x406e79
cmp dword [ebp - 0xc4c], 3
jne 0x406e92
push dword [ebp - 0x10]
lea eax, [ebp - 0xa40]
push eax
call fcn.00405e07
pop ecx
test eax, eax
pop ecx
je 0x4071fc
call fcn.00404d4b
cmp eax, 0xfffffffe
je 0x4071fc
mov eax, dword [ebp - 0x1478]
cmp eax, 1
mov dword [ebp - 0x10], eax
jne 0x406edf
cmp dword [ebp - 4], 5
je 0x406edf
push 0x423e00
push 0x4239c0
call ebx
call fcn.00406490
cmp eax, 0xfffffffe
mov dword [0x424b1c], eax
je 0x4071fc
cmp eax, 0xffffffff
jne 0x406edf
mov dword [ebp - 4], 5
cmp dword [ebp - 0x10], 1
jne 0x406f45
cmp dword [ebp - 4], 5
je 0x406f17
lea eax, [ebp - 0x838]
push eax
lea eax, [ebp - 0x428]
push eax
push 0x41c268
push 0x4248e0
call edi
add esp, 0x10
push dword [0x424b1c]
call fcn.00405c6e
pop ecx
mov dword [ebp - 4], eax
push 0xfffffffffffffffe
pop eax
cmp dword [ebp - 4], eax
je 0x40717f
cmp dword [ebp - 4], 5
jne 0x406f3c
push dword [0x424b1c]
call dword [sym.imp.KERNEL32.dll__lclose]
and dword [0x424b1c], 0
mov eax, dword [ebp - 0x1478]
mov dword [ebp - 0x10], eax
cmp dword [ebp - 0x10], 0
jne 0x4070b9
mov eax, dword [0x424b1c]
test eax, eax
jle 0x406f99
push eax
call dword [sym.imp.KERNEL32.dll__lclose]
push 0x5c
push 0x423e00
call fcn.00406796
pop ecx
mov edi, eax
pop ecx
inc edi
mov ecx, edi
mov eax, 0x423e00
sub ecx, eax
inc ecx
push ecx
push eax
lea eax, [ebp - 0x428]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcpynA]
lea eax, [ebp - 0x838]
push edi
push eax
call ebx
mov edi, dword [sym.imp.USER32.dll_wsprintfA]
cmp dword [ebp - 4], 5
je 0x40709e
mov eax, dword [ebp - 0xc4c]
push 0x4213b8
mov dword [ebp - 4], eax
lea eax, [ebp - 0x220]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x406fc9
mov dword [ebp - 4], 2
lea eax, [ebp - 0xa40]
push eax
push dword [ebp - 4]
call fcn.0040501f
pop ecx
cmp eax, 0xfffffffe
pop ecx
je 0x4071fc
cmp dword [ebp - 0xc], 0
jne 0x406fff
cmp dword [ebp + 0xc], 0
je 0x406fff
lea eax, [ebp - 0x1c9c]
push eax
lea eax, [ebp - 0x220]
push eax
call ebx
push 1
lea eax, [ebp - 0x220]
push dword [ebp - 0xc4c]
push eax
lea eax, [ebp - 0x838]
push eax
lea eax, [ebp - 0x630]
push eax
lea eax, [ebp - 0x428]
push eax
call fcn.00405fcd
add esp, 0x18
mov dword [ebp - 4], eax
lea eax, [ebp - 0x220]
push 0x4213b8
push eax
call dword [sym.imp.KERNEL32.dll_lstrcmpiA]
test eax, eax
jne 0x407088
lea eax, [ebp - 0x630]
push eax
push 0x4213b8
call ebx
push 0x4213b8
call dword [sym.imp.KERNEL32.dll_lstrlenA]
cmp byte [eax + 0x4213b7], 0x5c
je 0x407076
push 0x41c030
push 0x4213b8
call dword [sym.imp.KERNEL32.dll_lstrcatA]
lea eax, [ebp - 0x220]
push eax
push 0x4213b8
call dword [sym.imp.KERNEL32.dll_lstrcatA]
push 0xfffffffffffffffe
pop eax
cmp dword [ebp - 4], eax
je 0x40717f
cmp dword [ebp - 4], 3
je 0x40717f
cmp dword [0x424b1c], 0
jle 0x4070b9
push 0x423e00
call fcn.00410b60
and dword [0x424b1c], 0
pop ecx
cmp dword [ebp + 0xc], 0
je 0x4070e2
cmp dword [ebp - 0xc], 0
jne 0x4070e2
lea eax, [ebp - 0xa40]
push eax
lea eax, [ebp - 0x1ea4]
push eax
call fcn.00403003
pop ecx
test eax, eax
pop ecx
je 0x4071c2
lea eax, [ebp - 0x126c]
push eax
push 0x420240
call ebx
and byte [ebp - 0x188c], 0
mov ecx, esi
xor eax, eax
lea edi, [ebp - 0x188b]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
stosb byte es:[edi], al
lea eax, [ebp - 0x838]
push eax
lea eax, [ebp - 0x428]
push eax
lea eax, [ebp - 0x188c]
push 0x41c268
push eax
call dword [sym.imp.USER32.dll_wsprintfA]
add esp, 0x10
lea eax, [ebp - 0x188c]
push 0x80
push eax
call dword [sym.imp.KERNEL32.dll_SetFileAttributesA]
lea eax, [ebp - 0x188c]
push eax
call fcn.00410b60
inc dword [ebp - 8]
mov edi, dword [sym.imp.USER32.dll_wsprintfA]
pop ecx
lea eax, [ebp - 0x14]
push eax
lea eax, [ebp - 0x147c]
push eax
push dword [ebp - 8]
push dword [ebp + 8]
call fcn.0040656e
add esp, 0x10
test eax, eax
jne 0x406a97
mov eax, dword [ebp - 0x14]
dec eax
neg eax
sbb eax, eax
and eax, 3
dec eax
dec eax
pop edi
pop esi
pop ebx
leave
ret
lea eax, [ebp - 0xc48]
push eax
push 0x41c06c
push dword [0x423950]
call fcn.00403adc
add esp, 0xc
mov esi, 0x424240
push eax
push 0x41c310
push esi
call edi
add esp, 0xc
push esi
push 1
push 0x10
push 1
call fcn.00405105
add esp, 0x10
xor eax, eax
jmp 0x40717f
lea eax, [ebp - 0xa40]
push eax
push 0x41c06c
push dword [0x423988]
call fcn.00403adc
add esp, 0xc
mov esi, 0x424240
push eax
push 0x41c310
push esi
call edi
add esp, 0xc
push esi
push 1
push 0x10
push 1
call fcn.00405105
add esp, 0x10
push 0xfffffffffffffffe
pop eax
jmp 0x40717f