Function at 0x4b6200
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x55d36c
mov eax, dword fs:[0]
push eax
sub esp, 0x42c
mov eax, dword [0x5d0074]
xor eax, ebp
mov dword [ebp - 0x10], eax
push ebx
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov byte [ebp - 0x422], dl
mov edi, ecx
mov esi, dword [edi]
mov ecx, str.ProgramFiles64Folder
mov eax, esi
nop
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x4b6266
test dx, dx
je 0x4b6262
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x4b6266
add eax, 4
add ecx, 4
test dx, dx
jne 0x4b6240
xor eax, eax
jmp 0x4b626b
sbb eax, eax
or eax, 1
or ebx, 0xffffffff
test eax, eax
jne 0x4b6391
lea ecx, [esi - 0x10]
call fcn.0040a1d0
add eax, 0x10
mov dword [ebp - 0x428], eax
mov dword [ebp - 4], 1
lea ecx, [ebp - 0x428]
push str.ProgramW6432
call fcn.00495370
test eax, eax
je 0x4b636d
mov eax, dword [ebp - 0x428]
or esi, 0xffffffff
mov ecx, dword [edi]
lea ebx, [eax - 0x10]
lea edx, [ecx - 0x10]
mov dword [ebp - 0x434], edx
cmp ebx, edx
je 0x4b6323
cmp dword [edx + 0xc], 0
lea ecx, [edx + 0xc]
mov dword [ebp - 0x430], ecx
jl 0x4b6316
mov ecx, dword [ebx]
cmp ecx, dword [edx]
jne 0x4b6316
mov ecx, ebx
call fcn.0040a1d0
mov edx, dword [ebp - 0x430]
mov ecx, esi
mov dword [ebp - 0x438], eax
lock xadd dword [edx], ecx
dec ecx
test ecx, ecx
jg 0x4b630f
mov eax, dword [ebp - 0x434]
push eax
mov esi, dword [eax]
mov ecx, dword [esi]
mov edx, dword [ecx + 4]
mov ecx, esi
call edx
mov eax, dword [ebp - 0x438]
or esi, 0xffffffff
lea ecx, [eax + 0x10]
mov dword [edi], ecx
jmp 0x4b6323
push dword [eax - 0xc]
mov ecx, edi
push eax
call fcn.004126c0
mov ecx, dword [edi]
mov eax, dword [ecx - 0xc]
test eax, eax
jle 0x4b634d
lea edx, [eax - 1]
test edx, edx
js 0x4b6afa
cmp edx, eax
jg 0x4b6afa
cmp word [ecx + edx*2], 0x5c
je 0x4b634d
push 0x5c
mov ecx, edi
call fcn.00492b30
mov dword [ebp - 4], 0xffffffff
lock xadd dword [ebx + 0xc], esi
dec esi
test esi, esi
jg 0x4b6366
mov ecx, dword [ebx]
push ebx
mov eax, dword [ecx]
call dword [eax + 4]
mov al, 1
jmp 0x4b64b0
mov dword [ebp - 4], 0xffffffff
mov eax, ebx
mov edx, dword [ebp - 0x428]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], eax
dec eax
test eax, eax
jg 0x4b6391
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov byte [ebp - 0x421], 1
call fcn.00411fd0
mov ecx, eax
test ecx, ecx
je 0x4b6b04
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x428], eax
mov dword [ebp - 4], 4
mov eax, str.SystemFolder
lea ecx, [ebp - 0x428]
test eax, 0xffff0000
jne 0x4b63d9
movzx eax, ax
push eax
call fcn.00412350
jmp 0x4b63e5
push 0xc
push str.SystemFolder
call fcn.004126c0
mov dword [ebp - 4], 5
lea edx, [ebp - 0x428]
mov ecx, edi
call fcn.00409d00
mov byte [ebp - 0x429], al
mov dword [ebp - 4], 0xffffffff
mov ecx, ebx
mov edx, dword [ebp - 0x428]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], ecx
dec ecx
test ecx, ecx
jg 0x4b6429
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov al, byte [ebp - 0x429]
test al, al
je 0x4b64cc
lea eax, [ebp - 0x218]
push eax
movzx eax, byte [ebp - 0x422]
xor eax, 1
push 0
push 0
lea eax, [eax*4 + 0x25]
push eax
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
lea ecx, [ebp - 0x218]
lea edx, [ecx + 2]
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4b6460
sub ecx, edx
lea eax, [ebp - 0x218]
sar ecx, 1
push ecx
push eax
mov ecx, edi
call fcn.004126c0
mov edx, dword [edi]
mov ecx, dword [edx - 0xc]
test ecx, ecx
jle 0x4b64aa
lea eax, [ecx - 1]
test eax, eax
js 0x4b6afa
cmp eax, ecx
jg 0x4b6afa
cmp word [edx + eax*2], 0x5c
je 0x4b64aa
push 0x5c
mov ecx, edi
call fcn.00492b30
mov al, byte [ebp - 0x421]
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
pop ebx
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.005214e1
mov esp, ebp
pop ebp
ret
call fcn.00411fd0
mov ecx, eax
test ecx, ecx
je 0x4b6b0e
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x428], eax
mov dword [ebp - 4], 7
mov eax, str.System32Folder
lea ecx, [ebp - 0x428]
test eax, 0xffff0000
jne 0x4b650d
movzx eax, ax
push eax
call fcn.00412350
jmp 0x4b6519
push 0xe
push str.System32Folder
call fcn.004126c0
mov dword [ebp - 4], 8
lea edx, [ebp - 0x428]
mov ecx, edi
call fcn.00409d00
mov byte [ebp - 0x422], al
mov dword [ebp - 4], 0xffffffff
mov ecx, ebx
mov edx, dword [ebp - 0x428]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], ecx
dec ecx
test ecx, ecx
jg 0x4b655d
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov al, byte [ebp - 0x422]
test al, al
je 0x4b65c8
push 0x104
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
mov ecx, 0x5c
mov word [ebp + eax*2 - 0x218], cx
lea eax, [eax*2 + 2]
cmp eax, 0x208
jae 0x4b6b18
xor ecx, ecx
mov word [ebp + eax - 0x218], cx
lea ecx, [ebp - 0x218]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4b65a5
sub ecx, edx
lea eax, [ebp - 0x218]
sar ecx, 1
push ecx
push eax
mov ecx, edi
call fcn.004126c0
jmp 0x4b64aa
call fcn.00411fd0
mov ecx, eax
test ecx, ecx
je 0x4b6b1d
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x428], eax
mov dword [ebp - 4], 0xa
mov eax, str.WindowsFolder
lea ecx, [ebp - 0x428]
test eax, 0xffff0000
jne 0x4b6609
movzx eax, ax
push eax
call fcn.00412350
jmp 0x4b6615
push 0xd
push str.WindowsFolder
call fcn.004126c0
mov dword [ebp - 4], 0xb
lea edx, [ebp - 0x428]
mov ecx, edi
call fcn.00409d00
mov byte [ebp - 0x422], al
mov dword [ebp - 4], 0xffffffff
mov ecx, ebx
mov edx, dword [ebp - 0x428]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], ecx
dec ecx
test ecx, ecx
jg 0x4b6659
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov al, byte [ebp - 0x422]
test al, al
je 0x4b66b1
push 0x104
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
mov ecx, 0x5c
mov word [ebp + eax*2 - 0x218], cx
lea eax, [eax*2 + 2]
cmp eax, 0x208
jae 0x4b6b18
xor ecx, ecx
mov word [ebp + eax - 0x218], cx
lea ecx, [ebp - 0x218]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4b66a1
jmp 0x4b65b0
call fcn.00411fd0
mov ecx, eax
test ecx, ecx
je 0x4b6b27
mov eax, dword [ecx]
call dword [eax + 0xc]
add eax, 0x10
mov dword [ebp - 0x428], eax
mov dword [ebp - 4], 0xd
mov eax, str.WindowsVolume
lea ecx, [ebp - 0x428]
test eax, 0xffff0000
jne 0x4b66f2
movzx eax, ax
push eax
call fcn.00412350
jmp 0x4b66fe
push 0xd
push str.WindowsVolume
call fcn.004126c0
mov dword [ebp - 4], 0xe
lea edx, [ebp - 0x428]
mov ecx, edi
call fcn.00409d00
mov byte [ebp - 0x422], al
mov dword [ebp - 4], 0xffffffff
mov ecx, ebx
mov edx, dword [ebp - 0x428]
add edx, 0xfffffff0
lock xadd dword [edx + 0xc], ecx
dec ecx
test ecx, ecx
jg 0x4b6742
mov ecx, dword [edx]
push edx
mov eax, dword [ecx]
call dword [eax + 4]
mov al, byte [ebp - 0x422]
test al, al
je 0x4b6780
push 0x104
lea eax, [ebp - 0x218]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
xor eax, eax
lea ecx, [ebp - 0x218]
mov word [ebp - 0x212], ax
lea edx, [ecx + 2]
nop word [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4b6770
jmp 0x4b65b0
mov eax, dword [edi]
mov ecx, str.TempFolder
mov dx, word [eax]
cmp dx, word [ecx]
jne 0x4b67ad
test dx, dx
je 0x4b67a9
mov dx, word [eax + 2]
cmp dx, word [ecx + 2]
jne 0x4b67ad
add eax, 4
add ecx, 4
test dx, dx
jne 0x4b6787
xor eax, eax
jmp 0x4b67b2
sbb eax, eax
or eax, 1
test eax, eax
jne 0x4b6800
lea eax, [ebp - 0x218]
push eax
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
add eax, eax
cmp eax, 0x208
jae 0x4b6b18
xor ecx, ecx
mov word [ebp + eax - 0x218], cx
lea ecx, [ebp - 0x218]
lea edx, [ecx + 2]
nop dword [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4b67f0
jmp 0x4b65b0
mov edx, str.SETUPEXEDIR
mov ecx, edi
call fcn.00409c70
test al, al
je 0x4b6902
mov eax, dword [0x5d655c]
cmp dword [eax - 0xc], 0
jne 0x4b689b
push 0x104
lea eax, [ebp - 0x218]
push eax
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
sub eax, 1
je 0x4b6850
nop dword [eax + eax]
cmp word [ebp + eax*2 - 0x218], 0x5c
je 0x4b6850
sub eax, 1
jne 0x4b6840
lea eax, [eax*2 + 2]
cmp eax, 0x208
jae 0x4b6b18
xor ecx, ecx
mov word [ebp + eax - 0x218], cx
lea ecx, [ebp - 0x218]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4b6875
sub ecx, edx
lea eax, [ebp - 0x218]
sar ecx, 1
push ecx
push eax
mov ecx, 0x5d655c
call fcn.004126c0
mov eax, dword [0x5d655c]
mov esi, dword [edi]
lea ecx, [eax - 0x10]
sub esi, 0x10
cmp ecx, esi
je 0x4b64aa
cmp dword [esi + 0xc], 0
lea edx, [esi + 0xc]
mov dword [ebp - 0x438], edx
jl 0x4b68f2
mov edx, dword [ecx]
cmp edx, dword [esi]
jne 0x4b68f2
call fcn.0040a1d0
mov ecx, dword [ebp - 0x438]
mov dword [ebp - 0x434], eax
lock xadd dword [ecx], ebx
dec ebx
test ebx, ebx
jg 0x4b68e8
mov ecx, dword [esi]
push esi
mov edx, dword [ecx]
call dword [edx + 4]
mov eax, dword [ebp - 0x434]
add eax, 0x10
mov dword [edi], eax
jmp 0x4b64aa
push dword [eax - 0xc]
mov ecx, edi
push eax
call fcn.004126c0
jmp 0x4b64aa
xor esi, esi
nop dword [eax]
nop dword [eax + eax]
mov edx, dword [esi*4 + 0x58e6a4]
mov ecx, edi
call fcn.00409c70
test al, al
jne 0x4b692f
inc esi
cmp esi, 0xe
jb 0x4b6910
xor al, al
jmp 0x4b64b0
cmp esi, 0xe
jae 0x4b6928
lea eax, [ebp - 0x430]
push eax
push dword [esi*4 + 0x58e66c]
push 0
call dword [sym.imp.SHELL32.dll_SHGetSpecialFolderLocation]
test eax, eax
je 0x4b6a7c
mov eax, dword fs:[0x2c]
mov ebx, dword [esi*4 + 0x58e66c]
mov ecx, dword [eax]
mov eax, dword [0x5d6fe4]
cmp eax, dword [ecx + 4]
jle 0x4b69c0
push 0x5d6fe4
call fcn.0052198d
add esp, 4
cmp dword [0x5d6fe4], 0xffffffff
jne 0x4b69c0
mov dword [ebp - 4], 0x10
push 0x570210
mov dword [0x5d6fe8], 0x5849b4
mov dword [0x5d6fec], 0
call fcn.005217b5
add esp, 4
mov dword [ebp - 4], 0xffffffff
push 0x5d6fe4
call fcn.00521943
add esp, 4
cmp dword [0x5d6fec], 0
jne 0x4b6a1b
push str.shfolder.dll
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
mov ecx, dword [0x5d6fec]
mov esi, eax
cmp esi, ecx
je 0x4b69f6
mov edx, dword [0x5d6fe8]
mov ecx, 0x5d6fe8
call dword [edx + 4]
mov ecx, esi
mov dword [0x5d6fec], ecx
test ecx, ecx
je 0x4b6a70
push 0x58e62c
push ecx
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov dword [0x5d664c], eax
test eax, eax
jne 0x4b6a24
mov ecx, edi
call fcn.004b6b40
jmp 0x4b64b0
mov eax, dword [0x5d664c]
test eax, eax
je 0x4b6a70
lea ecx, [ebp - 0x420]
push ecx
push 0
push 0
push ebx
push 0
call eax
mov esi, eax
test esi, esi
jne 0x4b6a70
lea ecx, [ebp - 0x420]
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4b6a43
sub ecx, edx
lea eax, [ebp - 0x420]
sar ecx, 1
push ecx
push eax
mov ecx, edi
call fcn.004126c0
mov ecx, edi
call fcn.00493620
test esi, esi
je 0x4b64aa
mov ecx, edi
call fcn.004b6b40
jmp 0x4b64b0
lea eax, [ebp - 0x218]
push eax
push dword [ebp - 0x430]
call dword [sym.imp.SHELL32.dll_SHGetPathFromIDListW]
mov esi, eax
mov dword [ebp - 0x428], 0
lea eax, [ebp - 0x428]
push eax
call dword [sym.imp.SHELL32.dll_SHGetMalloc]
mov ecx, dword [ebp - 0x428]
push dword [ebp - 0x430]
push ecx
mov edx, dword [ecx]
call dword [edx + 0x14]
test esi, esi
je 0x4b6928
lea ecx, [ebp - 0x218]
lea edx, [ecx + 2]
nop dword [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4b6ad0
sub ecx, edx
lea eax, [ebp - 0x218]
sar ecx, 1
push ecx
push eax
mov ecx, edi
call fcn.004126c0
mov ecx, edi
call fcn.00493620
jmp 0x4b64aa
push 0x80070057
call fcn.004126a0
push 0x80004005
call fcn.004126a0
push 0x80004005
call fcn.004126a0
call fcn.00521d89
push 0x80004005
call fcn.004126a0
push 0x80004005
call fcn.004126a0
int3