Function at 0x4f8d20
Capabilities:
Create directory
Get common file path

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x54774b
mov eax, dword fs:[0]
push eax
sub esp, 0x828
mov eax, dword [0x5b1fe4]
xor eax, ebp
mov dword [ebp - 0x10], eax
push esi
push edi
push eax
lea eax, [ebp - 0xc]
mov dword fs:[0], eax
mov esi, dword [ebp + 8]
mov eax, dword [ebp + 0xc]
push 0x800
mov dword [ebp - 0x82c], esi
mov dword [ebp - 0x82c], eax
lea eax, [ebp - 0x810]
push 0
push eax
call fcn.005205c0
add esp, 0xc
call dword [sym.imp.KERNEL32.dll_WTSGetActiveConsoleSessionId]
lea ecx, [ebp - 0x830]
push ecx
push eax
call sub.WTSAPI32.dll_WTSQueryUserToken
test eax, eax
lea eax, [ebp - 0x810]
push eax
push 0
je 0x4f8db5
push dword [ebp - 0x830]
push 0x1a
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
push dword [ebp - 0x830]
mov edi, eax
call dword [sym.imp.KERNEL32.dll_CloseHandle]
jmp 0x4f8dc3
push 0
push 0x1a
push 0
call dword [sym.imp.SHELL32.dll_SHGetFolderPathW]
mov edi, eax
test edi, edi
js 0x4f8e19
push 0x54c624
lea eax, [ebp - 0x810]
push eax
call dword [sym.imp.SHLWAPI.dll_PathAppendW]
xor eax, eax
mov dword [ebp - 0x818], 0
lea ecx, [ebp - 0x810]
mov dword [ebp - 0x814], 7
mov word [ebp - 0x828], ax
lea edx, [ecx + 2]
nop
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4f8e00
sub ecx, edx
lea eax, [ebp - 0x810]
sar ecx, 1
push ecx
push eax
jmp 0x4f8e3c
xor eax, eax
mov dword [ebp - 0x818], 0
push eax
mov dword [ebp - 0x814], 7
mov word [ebp - 0x828], ax
push 0x54a560
lea ecx, [ebp - 0x828]
call fcn.004e7750
cmp dword [ebp - 0x818], 0
mov dword [ebp - 4], 0
jne 0x4f8e7c
xor eax, eax
mov dword [esi + 0x10], 0
push eax
mov dword [esi + 0x14], 7
mov ecx, esi
push 0x54a560
mov word [esi], ax
call fcn.004e7750
jmp 0x4f8f8e
cmp dword [ebp - 0x814], 8
lea eax, [ebp - 0x828]
cmovae eax, dword [ebp - 0x828]
push eax
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
test eax, eax
jne 0x4f8eef
call fcn.004f8fc0
cmp dword [ebp - 0x814], 8
lea edi, [ebp - 0x828]
mov dword [ebp - 0x834], eax
cmovae edi, dword [ebp - 0x828]
push edi
call dword [sym.imp.SHLWAPI.dll_PathIsDirectoryW]
test eax, eax
jne 0x4f8eef
push dword [ebp - 0x834]
push edi
push eax
call dword [sym.imp.SHELL32.dll_SHCreateDirectoryExW]
test eax, eax
je 0x4f8eef
cmp eax, 0xb7
je 0x4f8eef
push 0x54a560
mov ecx, esi
call fcn.004f8960
jmp 0x4f8f8e
mov edi, dword [ebp - 0x82c]
mov ecx, edi
lea edx, [ecx + 2]
nop word [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4f8f00
sub ecx, edx
sar ecx, 1
je 0x4f8f4c
push 1
push 0x54c4e0
lea ecx, [ebp - 0x828]
call fcn.004e74e0
mov ecx, edi
lea edx, [ecx + 2]
nop dword [eax + eax]
mov ax, word [ecx]
add ecx, 2
test ax, ax
jne 0x4f8f30
sub ecx, edx
sar ecx, 1
push ecx
push edi
lea ecx, [ebp - 0x828]
call fcn.004e74e0
movups xmm0, xmmword [ebp - 0x828]
mov dword [esi + 0x10], 0
xor eax, eax
mov dword [esi + 0x14], 0
movups xmmword [esi], xmm0
mov word [ebp - 0x828], ax
movq xmm0, qword [ebp - 0x818]
movq qword [esi + 0x10], xmm0
mov dword [ebp - 0x818], 0
mov dword [ebp - 0x814], 7
lea ecx, [ebp - 0x828]
call fcn.004e6be0
mov eax, esi
mov ecx, dword [ebp - 0xc]
mov dword fs:[0], ecx
pop ecx
pop edi
pop esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.0050804f
mov esp, ebp
pop ebp
ret