Function at 0x519e30
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x5c3c31
mov eax, dword fs:[0]
push eax
mov dword fs:[0], esp
sub esp, 0x728
push ebx
push esi
push edi
push 0
push 0
lea eax, [ebp - 0x2f8]
mov ebx, ecx
push eax
push 0
mov dword [ebp - 0x80], ebx
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x519edc
lea edi, [ebp - 0x2f8]
add edi, 0xfffffffe
mov ax, word [edi + 2]
lea edi, [edi + 2]
test ax, ax
jne 0x519e76
mov eax, dword [0x5ed894]
lea ecx, [ebp - 0x2f8]
mov dword [edi], eax
lea edx, [ecx + 2]
mov dword [ebx + 0x10], 0
xor eax, eax
mov dword [ebx + 0x14], 0
mov dword [ebx], 0
mov dword [ebx + 0x10], 0
mov dword [ebx + 0x14], 7
mov word [ebx], ax
lea esp, [esp]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x519ec0
sub ecx, edx
lea eax, [ebp - 0x2f8]
sar ecx, 1
push ecx
push eax
jmp 0x51a6ef
push 0
push 2
call dword [sym.imp.KERNEL32.dll_CreateToolhelp32Snapshot]
mov esi, eax
mov dword [ebp - 0x64], esi
cmp esi, 0xffffffff
je 0x51a6c1
push 0x28
mov dword [ebp - 0x14], 0
mov dword [ebp - 0x10], 0
call fcn.005838a8
add esp, 4
mov dword [eax], eax
mov dword [eax + 4], eax
mov dword [eax + 8], eax
mov word [eax + 0xc], 0x101
mov dword [ebp - 0x14], eax
lea eax, [ebp - 0x528]
mov dword [ebp - 4], 0
push eax
push esi
mov dword [ebp - 0x528], 0x22c
call dword [sym.imp.KERNEL32.dll_Process32FirstW]
test eax, eax
je 0x51a089
jmp 0x519f50
mov edi, 7
mov dword [ebp - 0x60], 0
xor eax, eax
mov dword [ebp - 0x50], 0
mov dword [ebp - 0x4c], edi
mov word [ebp - 0x60], ax
mov esi, edi
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x38], eax
mov dword [ebp - 0x34], esi
mov word [ebp - 0x48], ax
mov byte [ebp - 4], 2
push dword [ebp - 0x520]
push eax
push 0x400
call dword [sym.imp.KERNEL32.dll_OpenProcess]
mov ebx, eax
test ebx, ebx
je 0x519ff7
lea eax, [ebp - 0x30]
mov dword [ebp - 0x30], 0
push eax
push 8
push ebx
call dword [sym.imp.ADVAPI32.dll_OpenProcessToken]
test eax, eax
jne 0x519fb8
push ebx
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x519ff7
mov ecx, dword [ebp - 0x30]
lea eax, [ebp - 0x48]
push eax
lea edx, [ebp - 0x60]
call fcn.00519a70
mov edi, dword [sym.imp.KERNEL32.dll_CloseHandle]
add esp, 4
mov esi, eax
push dword [ebp - 0x30]
call edi
push ebx
call edi
test esi, esi
je 0x519ff1
lea eax, [ebp - 0x60]
push eax
lea eax, [ebp - 0xec]
push eax
lea ecx, [ebp - 0x14]
call fcn.00523fd0
mov esi, dword [ebp - 0x34]
mov edi, dword [ebp - 0x4c]
mov byte [ebp - 4], 1
cmp esi, 8
jb 0x51a032
mov ecx, dword [ebp - 0x48]
lea esi, [esi*2 + 2]
mov eax, ecx
cmp esi, 0x1000
jb 0x51a028
mov ecx, dword [eax - 4]
add esi, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x51a70e
push esi
push ecx
call fcn.00583877
add esp, 8
mov byte [ebp - 4], 0
cmp edi, 8
jb 0x51a06d
mov ecx, dword [ebp - 0x60]
lea edi, [edi*2 + 2]
mov eax, ecx
cmp edi, 0x1000
jb 0x51a063
mov ecx, dword [eax - 4]
add edi, 0x23
sub eax, ecx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x51a70e
push edi
push ecx
call fcn.00583877
add esp, 8
mov esi, dword [ebp - 0x64]
lea eax, [ebp - 0x528]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_Process32NextW]
test eax, eax
jne 0x519f50
mov ebx, dword [ebp - 0x80]
push esi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
push 0
push 0
lea eax, [ebp - 0x730]
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderPathW]
test eax, eax
je 0x51a69c
lea eax, [ebp - 0x730]
push eax
lea ecx, [ebp - 0x2c]
call fcn.00446ee0
mov byte [ebp - 4], 3
lea edx, [ebp - 0x2c]
cmp dword [ebp - 0x18], 8
mov edi, dword [ebp - 0x1c]
cmovae edx, dword [ebp - 0x2c]
test edi, edi
je 0x51a0f8
or ecx, 0xffffffff
lea eax, [edi - 1]
cmp eax, ecx
cmovb ecx, eax
cmp word [edx + ecx*2], 0x5c
lea esi, [edx + ecx*2]
je 0x51a0f2
cmp esi, edx
je 0x51a0f8
sub esi, 2
cmp word [esi], 0x5c
jne 0x51a0e5
sub esi, edx
sar esi, 1
jmp 0x51a0fb
or esi, 0xffffffff
mov edx, edi
mov dword [ebp - 0x60], 0
sub edx, esi
mov dword [ebp - 0x50], 0
lea ecx, [esi + 1]
mov dword [ebp - 0x4c], 7
xor eax, eax
dec edx
mov word [ebp - 0x60], ax
cmp edi, ecx
jb 0x51a709
sub edi, ecx
lea eax, [ebp - 0x2c]
cmp edi, edx
cmovb edx, edi
cmp dword [ebp - 0x18], 8
push edx
cmovae eax, dword [ebp - 0x2c]
lea eax, [eax + ecx*2]
push eax
lea ecx, [ebp - 0x60]
call fcn.004496e0
mov byte [ebp - 4], 4
lea edx, [ebp - 0x2c]
cmp dword [ebp - 0x18], 8
mov edi, dword [ebp - 0x1c]
cmovae edx, dword [ebp - 0x2c]
dec esi
test edi, edi
je 0x51a183
lea eax, [edi - 1]
cmp eax, esi
cmovb esi, eax
cmp word [edx + esi*2], 0x5c
lea ecx, [edx + esi*2]
je 0x51a17d
mov edi, edi
cmp ecx, edx
je 0x51a183
sub ecx, 2
cmp word [ecx], 0x5c
jne 0x51a170
sub ecx, edx
sar ecx, 1
jmp 0x51a186
or ecx, 0xffffffff
xor eax, eax
mov dword [ebp - 0x7c], 0
cmp edi, ecx
mov word [ebp - 0x7c], ax
lea eax, [ebp - 0x2c]
mov dword [ebp - 0x6c], 0
cmovb ecx, edi
mov dword [ebp - 0x68], 7
cmp dword [ebp - 0x18], 8
push ecx
cmovae eax, dword [ebp - 0x2c]
lea ecx, [ebp - 0x7c]
push eax
call fcn.004496e0
mov byte [ebp - 4], 5
mov eax, dword [ebp - 0x14]
mov esi, dword [eax]
cmp esi, eax
je 0x51a475
lea esp, [esp]
mov ecx, dword [ebp - 0x6c]
lea edi, [esi + 0x10]
mov eax, SysReAllocString
sub eax, ecx
cmp eax, 1
jb 0x51a713
cmp dword [ebp - 0x68], 8
lea eax, [ebp - 0x7c]
push 1
cmovae eax, dword [ebp - 0x7c]
push 0x5ed894
push ecx
push eax
push ecx
push dword [ebp - 0x64]
lea ecx, [ebp - 0xe4]
call fcn.0044f200
push edi
lea edx, [ebp - 0xe4]
mov byte [ebp - 4], 6
lea ecx, [ebp - 0xcc]
call fcn.0044ce40
add esp, 4
push 0x5ed894
mov edx, eax
mov byte [ebp - 4], 7
lea ecx, [ebp - 0xb4]
call fcn.0044cdc0
add esp, 4
lea ecx, [ebp - 0x60]
mov byte [ebp - 4], 8
push ecx
mov edx, eax
lea ecx, [ebp - 0x9c]
call fcn.0044ce40
add esp, 4
push 0x5ed894
mov edx, eax
mov byte [ebp - 4], 9
lea ecx, [ebp - 0x48]
call fcn.0044cdc0
mov byte [ebp - 4], 8
add esp, 4
mov ecx, dword [ebp - 0x88]
cmp ecx, 8
jb 0x51a2ad
mov edx, dword [ebp - 0x9c]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x51a2a3
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x51a70e
push ecx
push edx
call fcn.00583877
add esp, 8
xor eax, eax
mov byte [ebp - 4], 7
mov ecx, dword [ebp - 0xa0]
mov dword [ebp - 0x8c], 0
mov dword [ebp - 0x88], 7
mov word [ebp - 0x9c], ax
cmp ecx, 8
jb 0x51a30e
mov edx, dword [ebp - 0xb4]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x51a304
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x51a70e
push ecx
push edx
call fcn.00583877
add esp, 8
xor eax, eax
mov byte [ebp - 4], 6
mov ecx, dword [ebp - 0xb8]
mov dword [ebp - 0xa4], 0
mov dword [ebp - 0xa0], 7
mov word [ebp - 0xb4], ax
cmp ecx, 8
jb 0x51a36f
mov edx, dword [ebp - 0xcc]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x51a365
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x51a70e
push ecx
push edx
call fcn.00583877
add esp, 8
xor eax, eax
mov byte [ebp - 4], 5
mov ecx, dword [ebp - 0xd0]
mov dword [ebp - 0xbc], 0
mov dword [ebp - 0xb8], 7
mov word [ebp - 0xcc], ax
cmp ecx, 8
jb 0x51a3d0
mov edx, dword [ebp - 0xe4]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x51a3c6
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x51a70e
push ecx
push edx
call fcn.00583877
add esp, 8
cmp dword [ebp - 0x34], 8
lea eax, [ebp - 0x48]
cmovae eax, dword [ebp - 0x48]
push eax
call dword [sym.imp.KERNEL32.dll_GetFileAttributesW]
cmp eax, 0xffffffff
je 0x51a3ef
test al, 0x10
jne 0x51a532
mov ecx, dword [ebp - 0x34]
cmp ecx, 8
jb 0x51a429
mov edx, dword [ebp - 0x48]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x51a41f
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x51a70e
push ecx
push edx
call fcn.00583877
add esp, 8
mov eax, dword [esi + 8]
cmp byte [eax + 0xd], 0
je 0x51a454
mov eax, dword [esi + 4]
cmp byte [eax + 0xd], 0
jne 0x51a450
jmp 0x51a440
cmp esi, dword [eax + 8]
jne 0x51a450
mov esi, eax
mov eax, dword [eax + 4]
cmp byte [eax + 0xd], 0
je 0x51a440
mov esi, eax
jmp 0x51a46c
mov esi, eax
mov ecx, dword [esi]
cmp byte [ecx + 0xd], 0
jne 0x51a46c
mov edi, edi
mov eax, dword [ecx]
mov esi, ecx
mov ecx, eax
cmp byte [eax + 0xd], 0
je 0x51a460
cmp esi, dword [ebp - 0x14]
jne 0x51a1d0
mov byte [ebp - 4], 4
mov ecx, dword [ebp - 0x68]
cmp ecx, 8
jb 0x51a4b3
mov edx, dword [ebp - 0x7c]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x51a4a9
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x51a70e
push ecx
push edx
call fcn.00583877
add esp, 8
mov byte [ebp - 4], 3
mov ecx, dword [ebp - 0x4c]
cmp ecx, 8
jb 0x51a4f1
mov edx, dword [ebp - 0x60]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x51a4e7
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x51a70e
push ecx
push edx
call fcn.00583877
add esp, 8
mov byte [ebp - 4], 0
mov ecx, dword [ebp - 0x18]
cmp ecx, 8
jb 0x51a688
mov edx, dword [ebp - 0x2c]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x51a67e
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x51a70e
jmp 0x51a67e
lea eax, [ebp - 0x48]
mov ecx, ebx
push eax
call fcn.00437a90
mov ecx, dword [ebp - 0x34]
cmp ecx, 8
jb 0x51a577
mov edx, dword [ebp - 0x48]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x51a56d
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x51a70e
push ecx
push edx
call fcn.00583877
add esp, 8
mov ecx, dword [ebp - 0x68]
xor eax, eax
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x34], 7
mov word [ebp - 0x48], ax
cmp ecx, 8
jb 0x51a5c5
mov edx, dword [ebp - 0x7c]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x51a5bb
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x51a70e
push ecx
push edx
call fcn.00583877
add esp, 8
mov ecx, dword [ebp - 0x4c]
cmp ecx, 8
jb 0x51a5ff
mov edx, dword [ebp - 0x60]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x51a5f5
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x51a70e
push ecx
push edx
call fcn.00583877
add esp, 8
mov ecx, dword [ebp - 0x18]
cmp ecx, 8
jb 0x51a639
mov edx, dword [ebp - 0x2c]
lea ecx, [ecx*2 + 2]
mov eax, edx
cmp ecx, 0x1000
jb 0x51a62f
mov edx, dword [eax - 4]
add ecx, 0x23
sub eax, edx
add eax, 0xfffffffc
cmp eax, 0x1f
ja 0x51a70e
push ecx
push edx
call fcn.00583877
add esp, 8
xor eax, eax
mov dword [ebp - 0x1c], 0
mov word [ebp - 0x2c], ax
mov eax, dword [ebp - 0x14]
mov dword [ebp - 0x18], 7
push dword [eax + 4]
lea eax, [ebp - 0x14]
push eax
mov ecx, eax
call fcn.00525590
push 0x28
push dword [ebp - 0x14]
call fcn.00583877
add esp, 8
mov eax, ebx
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop edi
pop esi
pop ebx
mov esp, ebp
pop ebp
ret
push ecx
push edx
call fcn.00583877
add esp, 8
xor eax, eax
mov dword [ebp - 0x1c], 0
mov dword [ebp - 0x18], 7
mov word [ebp - 0x2c], ax
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x14]
push dword [eax + 4]
lea eax, [ebp - 0x14]
push eax
mov ecx, eax
call fcn.00525590
push 0x28
push dword [ebp - 0x14]
call fcn.00583877
add esp, 8
mov dword [ebx + 0x10], 0
xor eax, eax
mov dword [ebx + 0x14], 0
push 3
mov dword [ebx], 0
mov dword [ebx + 0x10], 0
mov dword [ebx + 0x14], 7
mov word [ebx], ax
push 0x5f2e18
mov ecx, ebx
call fcn.004496e0
mov ecx, dword [ebp - 0xc]
mov eax, ebx
pop edi
pop esi
mov dword fs:[0], ecx
pop ebx
mov esp, ebp
pop ebp
ret
call fcn.0044c480
call fcn.00591c98
call fcn.004353d0
int3