Function at 0x40a130
Capabilities:
Get common file path
Read file on windows

Disassembly:
push ebp
mov ebp, esp
push 0xffffffffffffffff
push 0x535716
mov eax, dword fs:[0]
push eax
sub esp, 0x51c
mov eax, dword [0x586f40]
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 edi, ecx
call fcn.004133ab
xor ecx, ecx
xor ebx, ebx
cmp eax, ebx
setne cl
cmp ecx, ebx
jne 0x40a17c
push 0x80004005
call fcn.00406890
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [ebp - 0x520], eax
mov dword [ebp - 4], ebx
call fcn.004133ab
xor ecx, ecx
cmp eax, ebx
setne cl
cmp ecx, ebx
jne 0x40a1ab
push 0x80004005
call fcn.00406890
mov edx, dword [eax]
mov ecx, eax
mov eax, dword [edx + 0xc]
call eax
add eax, 0x10
mov dword [ebp - 0x51c], eax
push 0x206
lea edx, [ebp - 0x316]
mov byte [ebp - 4], 1
xor ecx, ecx
push ebx
push edx
mov dword [ebp - 0x524], ebx
mov word [ebp - 0x318], cx
call fcn.005121a0
add esp, 0xc
cmp dword [edi + 0xa1d68], ebx
jne 0x40a2a1
lea eax, [ebp - 0x51c]
push eax
lea ecx, [ebp - 0x520]
push ecx
push ecx
mov ecx, esp
mov dword [ebp - 0x528], esp
push str.https:__sp_storage.spccinta.com_spidentifier_spidentifierstub_SPIdentifier.exe
call fcn.00405e30
call fcn.00407b20
mov eax, dword [ebp - 0x520]
mov ecx, 1
add esp, 0xc
mov dword [edi + 0xa1d68], ecx
cmp dword [eax - 4], ecx
jle 0x40a245
mov edx, dword [eax - 0xc]
push edx
lea ecx, [ebp - 0x520]
call fcn.004065e0
mov eax, dword [ebp - 0x520]
lea edx, [edi + 0xa1964]
sub edx, eax
lea ecx, [ecx]
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, 2
cmp cx, bx
jne 0x40a250
mov esi, dword [ebp - 0x51c]
cmp dword [esi - 4], 1
jle 0x40a280
mov eax, dword [esi - 0xc]
push eax
lea ecx, [ebp - 0x51c]
call fcn.004065e0
mov esi, dword [ebp - 0x51c]
lea edx, [edi + 0xa1b64]
mov eax, esi
sub edx, esi
lea ebx, [ebx]
movzx ecx, word [eax]
mov word [edx + eax], cx
add eax, 2
cmp cx, bx
jne 0x40a290
jmp 0x40a305
lea edx, [edi + 0xa1964]
cmp edx, ebx
jne 0x40a2af
xor eax, eax
jmp 0x40a2c3
mov eax, edx
lea esi, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x40a2b4
sub eax, esi
sar eax, 1
push eax
push edx
lea ecx, [ebp - 0x520]
call fcn.00406780
lea edx, [edi + 0xa1b64]
cmp edx, ebx
jne 0x40a2de
xor eax, eax
jmp 0x40a2f2
mov eax, edx
lea esi, [eax + 2]
mov cx, word [eax]
add eax, 2
cmp cx, bx
jne 0x40a2e3
sub eax, esi
sar eax, 1
push eax
push edx
lea ecx, [ebp - 0x51c]
call fcn.00406780
mov esi, dword [ebp - 0x51c]
push 0x1fe
lea edx, [ebp - 0x516]
xor ecx, ecx
push ebx
push edx
mov word [ebp - 0x518], cx
call fcn.005121a0
mov eax, dword [ebp - 0x520]
add esp, 0xc
push 0x564d10
push eax
lea ecx, [ebp - 0x518]
push str._s__s
push ecx
call dword [sym.imp.USER32.dll_wsprintfW]
push 5
xor edi, edi
lea eax, [ebp - 0x518]
call fcn.004072e0
add esp, 0x14
cmp eax, ebx
je 0x40a4bd
mov edi, dword [sym.imp.KERNEL32.dll_Sleep]
push 0x3e8
call edi
cmp dword [esi - 4], 1
jle 0x40a383
mov edx, dword [esi - 0xc]
push edx
lea ecx, [ebp - 0x51c]
call fcn.004065e0
mov esi, dword [ebp - 0x51c]
push esi
call fcn.004073a0
movzx eax, al
add esp, 4
cmp eax, ebx
jne 0x40a361
push 0xff
lea eax, [ebp - 0x10f]
push ebx
push eax
mov byte [ebp - 0x110], bl
call fcn.005121a0
add esp, 0xc
lea ecx, [ebp - 0x318]
push ecx
push 0x104
call dword [sym.imp.KERNEL32.dll_GetTempPathW]
lea eax, [ebp - 0x318]
add eax, 0xfffffffe
lea esp, [esp]
mov cx, word [eax + 2]
add eax, 2
cmp cx, bx
jne 0x40a3d0
mov edx, dword [str.amitest.txt]
mov ecx, dword [0x564d34]
push ebx
mov dword [eax], edx
mov edx, dword [0x564d38]
push ebx
mov dword [eax + 4], ecx
mov ecx, dword [0x564d3c]
push 3
mov dword [eax + 8], edx
mov edx, dword [0x564d40]
push ebx
mov dword [eax + 0xc], ecx
mov ecx, dword [0x564d44]
push ebx
mov dword [eax + 0x10], edx
push SysReAllocStringLen
lea edx, [ebp - 0x318]
push edx
mov dword [eax + 0x14], ecx
call dword [sym.imp.KERNEL32.dll_CreateFileW]
mov edi, eax
cmp edi, 0xffffffff
je 0x40a4bd
push ebx
lea eax, [ebp - 0x524]
push eax
push 0x100
lea ecx, [ebp - 0x110]
push ecx
push edi
call dword [sym.imp.KERNEL32.dll_ReadFile]
push edi
call dword [sym.imp.KERNEL32.dll_CloseHandle]
lea edx, [ebp - 0x110]
push str.BingHpI
push edx
call fcn.00510ca0
add esp, 8
cmp eax, ebx
je 0x40a4bd
lea eax, [esi - 0x10]
mov byte [ebp - 4], bl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40a48d
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x520]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40a4b6
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov eax, 1
jmp 0x40a507
lea eax, [esi - 0x10]
mov byte [ebp - 4], bl
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40a4dc
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
mov dword [ebp - 4], 0xffffffff
mov eax, dword [ebp - 0x520]
add eax, 0xfffffff0
lea ecx, [eax + 0xc]
or edx, 0xffffffff
lock xadd dword [ecx], edx
dec edx
test edx, edx
jg 0x40a505
mov ecx, dword [eax]
mov edx, dword [ecx]
push eax
mov eax, dword [edx + 4]
call eax
xor eax, eax
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.0051026e
mov esp, ebp
pop ebp
ret