Function at 0x100053d3
Capabilities:
Get common file path

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc14
mov eax, dword [0x1009f1f4]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
mov ebx, dword [ebp + 8]
push esi
push edi
mov dword [ebp - 0xc10], eax
xor esi, esi
mov eax, dword [ebp + 0x10]
push 0x800
mov dword [ebp - 0xc0c], eax
lea eax, [ebp - 0x804]
push esi
push eax
mov dword [ebp - 0xc14], esi
call fcn.1003ac70
mov edi, ebx
add esp, 0xc
xor edx, edx
lea ecx, [edi + 2]
mov ax, word [edi]
add edi, 2
cmp ax, dx
jne 0x10005422
sub edi, ecx
push 0x5c
pop eax
sar edi, 1
cmp word [ebx], ax
je 0x10005440
mov ecx, edi
jmp 0x1000554b
push 0xc
push str.SystemRoot_
push ebx
call fcn.10053413
add esp, 0xc
test eax, eax
jne 0x10005494
push 0x400
lea eax, [ebp - 0x804]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
test eax, eax
jne 0x10005472
push 0xfffffffffffffff2
pop eax
jmp 0x10005634
lea esi, [ebp - 0x804]
xor edx, edx
lea ecx, [esi + 2]
mov ax, word [esi]
add esi, 2
cmp ax, dx
jne 0x1000547d
sub esi, ecx
lea ecx, [edi - 0xb]
sar esi, 1
jmp 0x1000554b
push 4
push 0x10082610
push ebx
call fcn.10053413
add esp, 0xc
test eax, eax
jne 0x100054b0
lea ecx, [edi - 4]
jmp 0x1000554b
push 0x400
lea eax, [ebp - 0x804]
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
mov esi, eax
test esi, esi
je 0x1000561f
push 0x5c
pop eax
cmp word [ebp + esi*2 - 0x806], ax
jne 0x100054da
dec esi
cmp esi, 3
jb 0x1000561f
mov ecx, ebx
lea edx, [ecx + 2]
mov ax, word [ecx]
add ecx, 2
cmp ax, word [ebp - 0xc14]
jne 0x100054e8
sub ecx, edx
sar ecx, 1
lea eax, [ecx + 2]
cmp esi, eax
ja 0x1000561f
cmp esi, 0x400
jae 0x1000561f
lea eax, [esi - 2]
push eax
lea eax, [ebp - 0x800]
push eax
push ebx
call fcn.10053413
add esp, 0xc
test eax, eax
jne 0x1000561f
movzx eax, word [ebx + esi*2 - 4]
push 0x5c
pop ecx
cmp ax, cx
je 0x10005544
test ax, ax
jne 0x1000561f
mov ecx, edi
sub ecx, esi
add ecx, 2
lea eax, [ecx + esi]
cmp dword [ebp - 0xc0c], eax
jge 0x1000555d
push 0xffffffffffffffe4
jmp 0x1000546c
mov esi, dword [ebp - 0xc10]
lea edx, [ebp - 0x804]
mov eax, edx
sub esi, eax
movzx eax, word [edx]
mov word [esi + edx], ax
lea edx, [edx + 2]
test ax, ax
jne 0x1000556d
sub edi, ecx
xor ecx, ecx
lea edx, [ebx + edi*2]
mov esi, edx
mov ax, word [edx]
add edx, 2
cmp ax, cx
jne 0x10005585
mov ebx, dword [ebp - 0xc10]
sub edx, esi
lea edi, [ebx - 2]
mov ax, word [edi + 2]
add edi, 2
cmp ax, cx
jne 0x1000559b
mov ecx, edx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
push 0x7e
rep movsb byte es:[edi], byte [esi]
push ebx
call fcn.1003ab04
pop ecx
pop ecx
test eax, eax
je 0x1000561b
xor eax, eax
push 0x402
push eax
lea eax, [ebp - 0xc08]
push eax
call fcn.1003ac70
add esp, 0xc
lea eax, [ebp - 0xc08]
mov edi, 0x200
push edi
push eax
push ebx
call dword [sym.imp.KERNEL32.dll_GetLongPathNameW]
test eax, eax
je 0x1000561b
mov esi, dword [ebp - 0xc0c]
lea eax, [esi - 1]
cmp eax, edi
lea ecx, [esi - 1]
lea eax, [ebp - 0xc08]
cmovg ecx, edi
push ecx
push eax
push ebx
call fcn.1004eca0
add esp, 0xc
xor eax, eax
mov word [ebx + esi*2 - 2], ax
xor eax, eax
jmp 0x10005634
push dword [ebp - 0xc0c]
push dword [ebp - 0xc10]
push ebx
call fcn.10004a6f
add esp, 0xc
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1001fe6c
leave
ret