Function at 0x407710
Capabilities:
Get common file path

Disassembly:
push ebp
push edi
push esi
push ebx
push eax
mov eax, 0x10d8
call fcn.0040f0c8
xor esi, esi
sub esp, eax
mov eax, dword [esp + eax]
mov ebx, eax
mov word [eax], si
movzx eax, word [edx]
test ax, ax
je 0x407784
lea ebp, [edx + 2]
mov edi, ecx
xor edx, edx
jmp 0x407752
mov word [edx], ax
add edx, 2
movzx eax, word [ebp]
add ebp, 2
test ax, ax
je 0x407784
cmp ax, 0x7b
je 0x4077a0
cmp ax, 0x7d
je 0x4077b8
test edx, edx
jne 0x407740
test edi, edi
je 0x407a50
xor ecx, ecx
mov word [ebx], ax
sub edi, 1
add ebx, 2
mov word [ebx], cx
movzx eax, word [ebp]
add ebp, 2
test ax, ax
jne 0x407752
xor eax, eax
mov word [ebx], ax
mov eax, 1
add esp, 0x10dc
pop ebx
pop esi
pop edi
pop ebp
ret
xor eax, eax
lea edx, [esp + 0x8d0]
mov word [esp + 0x8d0], ax
jmp 0x407746
xor eax, eax
mov word [edx], ax
lea eax, [esp + 0x8d0]
mov dword [esp + 4], str.TEMP
mov dword [esp], eax
call sub.msvcrt.dll__wcsicmp
test eax, eax
je 0x407a60
lea eax, [esp + 0x8d0]
mov dword [esp + 4], 0x4170bc
mov dword [esp], eax
call sub.msvcrt.dll__wcsicmp
test eax, eax
je 0x407ab8
lea eax, [esp + 0x8d0]
mov dword [esp + 4], str.PROGRAM_BASE
mov dword [esp], eax
call sub.msvcrt.dll__wcsicmp
test eax, eax
je 0x407a30
lea eax, [esp + 0x8d0]
mov dword [esp + 4], 0x417104
mov dword [esp], eax
call sub.msvcrt.dll__wcsicmp
test eax, eax
je 0x407ce8
lea eax, [esp + 0x8d0]
mov dword [esp + 4], 0x417110
mov dword [esp], eax
call sub.msvcrt.dll__wcsicmp
test eax, eax
je 0x407c58
lea eax, [esp + 0x8d0]
mov dword [esp + 4], str.CACHE_DIR
mov dword [esp], eax
call sub.msvcrt.dll__wcsicmp
test eax, eax
je 0x407b28
lea eax, [esp + 0x8d0]
mov dword [esp + 4], str.COMPANY
mov dword [esp], eax
call sub.msvcrt.dll__wcsicmp
test eax, eax
je 0x407dcf
lea eax, [esp + 0x8d0]
mov dword [esp + 4], str.PRODUCT
mov dword [esp], eax
call sub.msvcrt.dll__wcsicmp
test eax, eax
je 0x407e21
lea eax, [esp + 0x8d0]
mov dword [esp + 4], str.VERSION
mov dword [esp], eax
call sub.msvcrt.dll__wcsicmp
test eax, eax
je 0x407c03
lea eax, [esp + 0x8d0]
mov dword [esp + 4], str.TIME
mov dword [esp], eax
call sub.msvcrt.dll__wcsicmp
test eax, eax
jne 0x407a50
lea eax, [esp + 0x38]
mov dword [esp + 0x38], 0
mov dword [esp], eax
mov dword [esp + 0x3c], 0
call dword [sym.imp.KERNEL32.dll_GetSystemTimeAsFileTime]
sub esp, 4
mov eax, dword [esp + 0x38]
mov edx, dword [esp + 0x3c]
lea esi, [esp + 0x4d0]
mov dword [esp + 8], str._lld
mov dword [esp + 4], 0x400
mov dword [esp + 0xc], eax
mov dword [esp + 0x10], edx
mov dword [esp], esi
call fcn.00401ad0
cmp word [ebx], 0
je 0x407e8d
mov eax, edi
mov ecx, ebx
add ecx, 2
sub eax, 1
cmp word [ecx], 0
jne 0x407950
movzx edx, byte [esp + 0x4d0]
mov byte [esp + 0x24], dl
test dl, dl
je 0x407a0c
add eax, esi
mov dword [esp + 0x28], ebp
movzx ebp, byte [esp + 0x24]
mov edx, esi
mov dword [esp + 0x20], eax
mov esi, ecx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x2c], edi
mov edi, edx
lea esi, [esi]
mov eax, dword [esp + 0x20]
mov ebx, esi
sub eax, edi
cmp word [esi], 0
je 0x4079ac
nop
add ebx, 2
sub eax, 1
cmp word [ebx], 0
jne 0x4079a0
test eax, eax
je 0x415100
mov dword [esp], ebx
add edi, 1
add esi, 2
call sub.msvcrt.dll_wcslen
mov ecx, ebp
mov dword [esp + 8], 2
mov byte [esp + 0x2c8], cl
lea eax, [ebx + eax*2]
lea ecx, [esp + 0x2c8]
mov dword [esp + 4], ecx
mov dword [esp], eax
mov byte [esp + 0x2c9], 0
call sub.msvcrt.dll_mbstowcs
movzx ebp, byte [edi]
mov eax, ebp
test al, al
jne 0x407990
mov ebx, dword [esp + 0x24]
mov ebp, dword [esp + 0x28]
mov edi, dword [esp + 0x2c]
cmp word [ebx], 0
je 0x407a28
xor eax, eax
add ebx, 2
sub edi, 1
cmp word [ebx], 0
jne 0x407a80
test al, al
jne 0x407aa3
lea esi, [esi]
xor edx, edx
jmp 0x407746
mov dword [esp], ebx
call sub.msvcrt.dll_wcslen
mov ecx, edi
mov edx, str.PROGRAM
sub ecx, eax
mov eax, ebx
call fcn.00407710
test al, al
jne 0x407bc0
xor eax, eax
jmp 0x40778e
mov dword [esp + 4], ebx
mov dword [esp], edi
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
sub esp, 8
cmp word [ebx], 0
je 0x407aa3
mov eax, 1
lea esi, [esi]
nop
add ebx, 2
sub edi, 1
cmp word [ebx], 0
jne 0x407a80
test al, al
je 0x407a28
jmp 0x407aa3
sub ebx, 2
xor esi, esi
add edi, 1
mov word [ebx], si
cmp word [ebx - 2], 0x5c
je 0x407a98
xor edx, edx
jmp 0x407746
mov eax, dword [sym.imp.msvcrt.dll___wargv]
cmp word [ebx], 0
mov edx, edi
mov eax, dword [eax]
mov ecx, dword [eax]
mov eax, ebx
je 0x407adc
lea esi, [esi]
nop
add eax, 2
sub edx, 1
cmp word [eax], 0
jne 0x407ad0
movzx esi, word [ecx]
test si, si
je 0x407b0c
test edx, edx
jne 0x407af8
jmp 0x407eac
test edx, edx
je 0x415100
add ecx, 2
mov word [eax], si
add eax, 2
sub edx, 1
movzx esi, word [ecx]
test si, si
jne 0x407af0
xor esi, esi
mov word [eax], si
cmp word [ebx], 0
je 0x407a28
xor eax, eax
jmp 0x407a0e
lea esi, [esp + 0x2c8]
mov dword [esp + 0xc], 0
mov dword [esp + 0x10], esi
mov dword [esp + 8], 0
mov dword [esp + 4], 0x1c
mov dword [esp], 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
sub esp, 0x14
test eax, eax
jne 0x407a50
cmp word [ebx], 0
mov edx, edi
mov eax, ebx
je 0x407b7c
lea esi, [esi]
add eax, 2
sub edx, 1
cmp word [eax], 0
jne 0x407b70
movzx ecx, word [esp + 0x2c8]
test cx, cx
je 0x407bac
lea esi, [esi]
test edx, edx
je 0x415100
add esi, 2
mov word [eax], cx
add eax, 2
sub edx, 1
movzx ecx, word [esi]
test cx, cx
jne 0x407b90
xor edx, edx
mov word [eax], dx
cmp word [ebx], 0
jne 0x407a76
jmp 0x407aa3
mov dword [esp], ebx
call sub.msvcrt.dll_wcslen
cmp eax, 3
jbe 0x407b11
lea esi, [ebx + eax*2 - 8]
mov dword [esp + 4], str..exe
mov dword [esp], esi
call sub.msvcrt.dll__wcsicmp
test eax, eax
jne 0x407b11
xor ecx, ecx
mov word [esi], cx
cmp word [ebx], 0
je 0x407a28
xor eax, eax
jmp 0x407a0e
cmp word [ebx], 0
mov edx, edi
mov eax, ebx
je 0x407c1c
lea esi, [esi]
add eax, 2
sub edx, 1
cmp word [eax], 0
jne 0x407c10
test edx, edx
je 0x415100
mov esi, 0x30
mov ecx, 0x4170a2
jmp 0x407c38
test edx, edx
je 0x415100
add ecx, 2
mov word [eax], si
add eax, 2
sub edx, 1
movzx esi, word [ecx]
test si, si
jne 0x407c30
jmp 0x407b0c
lea esi, [esp + 0xc0]
mov dword [esp + 0xc], 0
mov dword [esp + 0x10], esi
mov dword [esp + 8], 0
mov dword [esp + 4], 0x28
mov dword [esp], 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
sub esp, 0x14
test eax, eax
jne 0x407a50
cmp word [ebx], 0
mov edx, edi
mov eax, ebx
je 0x407cac
lea esi, [esi]
add eax, 2
sub edx, 1
cmp word [eax], 0
jne 0x407ca0
movzx ecx, word [esp + 0xc0]
test cx, cx
je 0x407bac
lea esi, [esi]
test edx, edx
je 0x415100
add esi, 2
mov word [eax], cx
add eax, 2
sub edx, 1
movzx ecx, word [esi]
test cx, cx
jne 0x407cc0
jmp 0x407bac
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
lea esi, [esp + 0x40]
mov dword [esp + 8], 0x41710c
mov dword [esp + 0xc], eax
mov dword [esp + 4], pe_nt_image_headers32
mov dword [esp], esi
call fcn.00401ad0
cmp word [ebx], 0
je 0x407e71
mov eax, edi
mov ecx, ebx
lea esi, [esi]
add ecx, 2
sub eax, 1
cmp word [ecx], 0
jne 0x407d20
movzx edx, byte [esp + 0x40]
mov byte [esp + 0x24], dl
test dl, dl
je 0x407a0c
add eax, esi
mov dword [esp + 0x28], ebp
movzx ebp, byte [esp + 0x24]
mov edx, esi
mov dword [esp + 0x20], eax
mov esi, ecx
mov dword [esp + 0x24], ebx
mov dword [esp + 0x2c], edi
mov edi, edx
lea esi, [esi]
mov eax, dword [esp + 0x20]
mov ebx, esi
sub eax, edi
cmp word [esi], 0
je 0x407d7c
nop
add ebx, 2
sub eax, 1
cmp word [ebx], 0
jne 0x407d70
test eax, eax
je 0x415100
mov dword [esp], ebx
add edi, 1
add esi, 2
call sub.msvcrt.dll_wcslen
mov ecx, ebp
mov dword [esp + 8], 2
mov byte [esp + 0x4d0], cl
lea eax, [ebx + eax*2]
lea ecx, [esp + 0x4d0]
mov dword [esp + 4], ecx
mov dword [esp], eax
mov byte [esp + 0x4d1], 0
call sub.msvcrt.dll_mbstowcs
movzx ebp, byte [edi]
mov eax, ebp
test al, al
jne 0x407d60
jmp 0x4079fa
cmp word [ebx], 0
mov edx, edi
mov eax, ebx
je 0x407dec
lea esi, [esi]
add eax, 2
sub edx, 1
cmp word [eax], 0
jne 0x407de0
test edx, edx
je 0x415100
mov esi, 0x67
mov ecx, 0x417060
jmp 0x407e08
test edx, edx
je 0x415100
add ecx, 2
mov word [eax], si
add eax, 2
sub edx, 1
movzx esi, word [ecx]
test si, si
jne 0x407e00
jmp 0x407b0c
cmp word [ebx], 0
mov edx, edi
mov eax, ebx
je 0x407e3c
lea esi, [esi]
nop
add eax, 2
sub edx, 1
cmp word [eax], 0
jne 0x407e30
test edx, edx
je 0x415100
mov esi, 0x71
mov ecx, 0x417074
jmp 0x407e58
test edx, edx
je 0x415100
add ecx, 2
mov word [eax], si
add eax, 2
sub edx, 1
movzx esi, word [ecx]
test si, si
jne 0x407e50
jmp 0x407b0c
movzx edx, byte [esp + 0x40]
mov eax, edi
mov ecx, ebx
mov byte [esp + 0x24], dl
test dl, dl
jne 0x407d3d
xor edx, edx
jmp 0x407746
movzx edx, byte [esp + 0x4d0]
mov eax, edi
mov ecx, ebx
mov byte [esp + 0x24], dl
test dl, dl
jne 0x407970
xor edx, edx
jmp 0x407746
jmp 0x415100
call sub.msvcrt.dll_abort