Function at 0x1017a400
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x10192bf0
mov eax, dword fs:[0]
push eax
sub esp, 0x10
push ebx
push esi
push edi
mov eax, dword [0x101f7210]
xor eax, ebp
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
xor eax, eax
mov dword [ebp - 0x1c], 0
mov word [ebp - 0x10], ax
call fcn.100308cf
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x1017a451
push 0x80004005
call fcn.1001f790
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
lea esi, [eax + 0x10]
mov dword [ebp - 0x14], esi
mov edx, dword [ebp + 0xc]
mov ebx, 1
mov dword [ebp - 4], 0
test edx, edx
je 0x1017a4a9
mov ecx, edx
lea esi, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x1017a476
sub ecx, esi
sar ecx, 1
push ecx
push edx
lea ecx, [ebp - 0x14]
call fcn.1001f5e0
mov esi, dword [ebp - 0x14]
push esi
call fcn.1017a1f0
add esp, 4
cmp eax, dword [ebp + 0x10]
setb al
test al, al
je 0x1017a586
mov ebx, dword [sym.imp.KERNEL32.dll_GetTempPathW]
push 0
push 0
call ebx
mov edi, eax
test edi, edi
jne 0x1017a4fe
mov edi, dword [ebp + 8]
lea eax, [ebp - 0x10]
push eax
mov ecx, edi
call fcn.1001eb00
add esi, 0xfffffff0
mov dword [ebp - 4], 0xffffffff
or ecx, 0xffffffff
lea eax, [esi + 0xc]
lock xadd dword [eax], ecx
dec ecx
test ecx, ecx
jg 0x1017a4ea
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, edi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
jns 0x1017a50a
push 0x80070057
call fcn.1001f790
mov eax, dword [esi - 8]
mov ecx, 1
sub ecx, dword [esi - 4]
sub eax, edi
or eax, ecx
jge 0x1017a527
push edi
lea ecx, [ebp - 0x14]
call fcn.1001f500
mov esi, dword [ebp - 0x14]
push esi
push edi
call ebx
push dword [esi - 8]
push esi
call fcn.1014e66e
add esp, 8
test eax, eax
js 0x1017a500
cmp eax, dword [esi - 8]
jg 0x1017a500
xor ecx, ecx
mov dword [esi - 0xc], eax
push esi
mov word [esi + eax*2], cx
call fcn.1017a1f0
mov edi, dword [ebp + 0x10]
add esp, 4
cmp eax, edi
jae 0x1017a581
lea eax, [ebp - 0x14]
push eax
call fcn.1017a130
mov esi, dword [ebp - 0x14]
add esp, 4
test al, al
je 0x1017a4bb
push esi
call fcn.1017a1f0
add esp, 4
cmp eax, edi
jb 0x1017a4bb
mov ebx, 1
call fcn.100308cf
xor ecx, ecx
mov edx, eax
test edx, edx
setne cl
test ecx, ecx
jne 0x1017a5a2
push 0x80004005
call fcn.1001f790
mov eax, dword [edx]
mov ecx, edx
call dword [eax + 0xc]
lea edi, [eax + 0x10]
mov dword [ebp - 0x18], edi
mov eax, dword [edi - 8]
sub ebx, dword [edi - 4]
sub eax, 0x104
or eax, ebx
mov byte [ebp - 4], 1
jge 0x1017a5d2
push 0x104
lea ecx, [ebp - 0x18]
call fcn.1001f500
mov edi, dword [ebp - 0x18]
push edi
push 0
push 0x101cb724
push esi
call dword [sym.imp.KERNEL32.dll_GetTempFileNameW]
test eax, eax
jne 0x1017a645
mov ebx, dword [ebp + 8]
lea eax, [ebp - 0x10]
push eax
mov ecx, ebx
call fcn.1001eb00
lea edx, [edi - 0x10]
mov byte [ebp - 4], 0
or edi, 0xffffffff
lea ecx, [edx + 0xc]
mov eax, edi
lock xadd dword [ecx], eax
dec eax
test eax, eax
jg 0x1017a613
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
add esi, 0xfffffff0
mov dword [ebp - 4], 0xffffffff
lea eax, [esi + 0xc]
lock xadd dword [eax], edi
dec edi
test edi, edi
jg 0x1017a631
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push dword [edi - 8]
push edi
call fcn.1014e66e
add esp, 8
test eax, eax
js 0x1017a500
cmp eax, dword [edi - 8]
jg 0x1017a500
xor ecx, ecx
mov dword [edi - 0xc], eax
lea ebx, [edi - 0x10]
mov word [edi + eax*2], cx
push ebx
call fcn.1001f7c0
mov ecx, dword [ebp + 8]
add eax, 0x10
or edi, 0xffffffff
mov byte [ebp - 4], 0
add esp, 4
mov dword [ecx], eax
lea ecx, [ebx + 0xc]
mov eax, edi
lock xadd dword [ecx], eax
dec eax
test eax, eax
jg 0x1017a69c
mov ecx, dword [ebx]
push ebx
mov eax, dword [ecx]
call dword [eax + 4]
add esi, 0xfffffff0
mov dword [ebp - 4], 0xffffffff
lea eax, [esi + 0xc]
lock xadd dword [eax], edi
dec edi
test edi, edi
jg 0x1017a6ba
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, dword [ebp + 8]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret