Function at 0x10001000
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10023391
mov eax, dword fs:[0]
push eax
sub esp, 0x278
mov eax, dword [0x10034034]
xor eax, ebp
mov dword [ebp - 0x14], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, dword [ebp + 8]
xor eax, eax
mov dword [ebp - 0x22c], 7
mov dword [ebp - 0x230], 0
mov word [ebp - 0x240], ax
mov dword [ebp - 4], eax
mov dword [ebp - 0x228], eax
mov dword [ebp - 0x224], eax
mov byte [ebp - 0x220], al
lea eax, [ebp - 0x228]
push eax
push 0x20019
push 0
push str.SoftwareMicrosoftInternet_Explorer
push 0x80000001
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
mov byte [ebp - 4], 1
cmp dword [ebp - 0x228], 0
mov edi, dword [sym.imp.MSVCR110.dll_void___cdecl_operator_delete_void__]
je 0x100010ff
lea eax, [ebp - 0x240]
push eax
push str.Download_Directory
lea ecx, [ebp - 0x228]
call fcn.1000c120
test eax, eax
jne 0x100010ff
cmp dword [ebp - 0x22c], 8
lea ecx, [ebp - 0x264]
push ecx
lea eax, [ebp - 0x240]
cmovae eax, dword [ebp - 0x240]
push 0
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesExW]
test eax, eax
je 0x100010ff
test byte [ebp - 0x264], 0x10
je 0x100010ff
lea eax, [ebp - 0x240]
cmp esi, eax
je 0x1000124e
push 0xffffffffffffffff
push 0
push eax
mov ecx, esi
call fcn.100025e0
jmp 0x1000124e
push str.SHGetKnownFolderPath
push str.shell32.dll
call dword [sym.imp.KERNEL32.dll_GetModuleHandleW]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
test eax, eax
je 0x1000116e
lea ecx, [ebp - 0x268]
push ecx
push 0
push 0
push 0x10026418
call eax
test eax, eax
js 0x1000116e
mov edx, dword [ebp - 0x268]
cmp word [edx], 0
jne 0x10001140
xor ecx, ecx
jmp 0x10001154
mov ecx, edx
lea ebx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x10001145
sub ecx, ebx
sar ecx, 1
push ecx
push edx
mov ecx, esi
call fcn.10002160
push dword [ebp - 0x268]
call dword [sym.imp.ole32.dll_CoTaskMemFree]
jmp 0x1000124e
xor eax, eax
push 0x206
push eax
mov word [ebp - 0x21c], ax
lea eax, [ebp - 0x21a]
push eax
call sub.MSVCR110.dll_memset
add esp, 0xc
lea eax, [ebp - 0x21c]
push eax
push 0
push 0
push 5
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
test eax, eax
jns 0x100011ac
xor esi, esi
jmp 0x10001253
lea eax, [ebp - 0x21c]
push eax
lea ecx, [ebp - 0x258]
call fcn.10002260
push str.Downloads
lea edx, [ebp - 0x258]
lea ecx, [ebp - 0x280]
mov byte [ebp - 4], 2
call fcn.100144f0
mov ebx, eax
add esp, 4
cmp esi, ebx
je 0x10001209
cmp dword [esi + 0x14], 8
jb 0x100011ee
push dword [esi]
call edi
add esp, 4
xor eax, eax
mov dword [esi + 0x14], 7
mov dword [esi + 0x10], 0
push ebx
mov ecx, esi
mov word [esi], ax
call fcn.10002000
cmp dword [ebp - 0x26c], 8
jb 0x1000121d
push dword [ebp - 0x280]
call edi
add esp, 4
xor eax, eax
cmp dword [ebp - 0x244], 8
mov dword [ebp - 0x26c], 7
mov dword [ebp - 0x270], 0
mov word [ebp - 0x280], ax
jb 0x1000124e
push dword [ebp - 0x258]
call edi
add esp, 4
mov esi, 1
mov eax, dword [ebp - 0x224]
test eax, eax
je 0x1000126e
push eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
mov dword [ebp - 0x224], 0
mov eax, dword [ebp - 0x228]
test eax, eax
je 0x1000127f
push eax
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
cmp dword [ebp - 0x22c], 8
jb 0x10001293
push dword [ebp - 0x240]
call edi
add esp, 4
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x14]
xor ecx, ebp
call fcn.10020d6c
mov esp, ebp
pop ebp
ret 4