Function at 0x1003fc3
Capabilities:
Get common file path
Query or enumerate registry value

Disassembly:
mov edi, edi
push ebp
mov ebp, esp
sub esp, 0x530
mov eax, dword [0x1010368]
push esi
push edi
mov esi, ecx
xor edi, edi
mov dword [ebp - 4], eax
mov eax, dword [esi + 0x1720]
mov dword [ebp - 0x51c], edi
cmp byte [eax + 0x38b2], 0
mov byte [ebp - 0x51d], 1
jne 0x1004000
or eax, 0xffffffff
jmp 0x1004494
push ebx
mov word [eax + 0x3bc2], di
mov eax, dword [esi + 0x1720]
push 0x80
push dword [eax + 0x401c]
add eax, 0x3dcc
push eax
call dword [sym.imp.msvcrt.dll_wcsncpy]
mov eax, dword [esi + 0x1720]
mov word [eax + 0x3ecc], di
mov eax, dword [esi + 0x1720]
add esp, 0xc
lea ecx, [eax + 0x3bc2]
push ecx
add eax, 0x38b2
push eax
call fcn.0100d1c1
mov eax, dword [esi + 0x1720]
mov ebx, dword [sym.imp.msvcrt.dll_strchr]
mov edi, 0x38b2
add eax, edi
push 0x5c
push eax
call ebx
test eax, eax
pop ecx
pop ecx
mov dword [ebp - 0x524], eax
je 0x1004115
mov ecx, dword [esi + 0x1720]
add ecx, edi
cmp eax, ecx
jne 0x1004089
push 0xfffffffffffffffe
pop eax
jmp 0x1004493
inc eax
push 0x5c
push eax
mov dword [ebp - 0x528], eax
call ebx
test eax, eax
pop ecx
pop ecx
jne 0x1004081
mov eax, dword [ebp - 0x524]
mov ebx, dword [ebp - 0x528]
mov byte [eax], 0
cmp byte [ebx], 0
je 0x1004081
mov eax, dword [esi + 0x1720]
lea ecx, [eax + 0x38b2]
mov byte [ebp - 0x51d], 0
add eax, 0x3abc
mov dl, byte [ecx]
inc ecx
mov byte [eax], dl
inc eax
test dl, dl
jne 0x10040c7
mov eax, dword [esi + 0x1720]
mov edx, ebx
add eax, edi
mov cl, byte [edx]
inc edx
mov byte [eax], cl
inc eax
test cl, cl
jne 0x10040db
mov eax, dword [esi + 0x1720]
lea ecx, [eax + 0x3bc2]
push ecx
add eax, 0x38b2
push eax
call fcn.0100d1c1
mov eax, dword [esi + 0x1720]
lea ecx, [eax + 0x3dcc]
push ecx
add eax, 0x3abc
push eax
call fcn.0100d1c1
lea eax, [ebp - 0x108]
push eax
call fcn.0100cfc9
test al, al
je 0x1004395
mov eax, dword [esi + 0x1720]
mov edi, dword [sym.imp.msvcrt.dll__wcsicmp]
mov ebx, 0x3dcc
add eax, ebx
push 0x10014c0
push eax
call edi
test eax, eax
pop ecx
pop ecx
je 0x1004399
mov eax, dword [esi + 0x1720]
add eax, ebx
push 0x10018e0
push eax
call edi
test eax, eax
pop ecx
pop ecx
je 0x1004399
lea eax, [ebp - 0x108]
push eax
mov eax, dword [esi + 0x1720]
add eax, ebx
push eax
call edi
test eax, eax
pop ecx
pop ecx
je 0x1004399
mov eax, dword [esi + 0x1720]
cmp dword [eax + 0x4014], 0
jne 0x10043b1
and word [ebp - 0x518], 0
and dword [ebp - 0x524], 0
xor eax, eax
mov ecx, 0x103
lea edi, [ebp - 0x516]
rep stosd dword es:[edi], eax
stosw word es:[edi], ax
mov edi, 0x207
push edi
lea eax, [ebp - 0x518]
push eax
call dword [sym.imp.KERNEL32.dll_GetSystemDirectoryW]
test eax, eax
je 0x1004395
cmp eax, 0x208
jae 0x1004395
sub edi, eax
push edi
lea eax, [ebp + eax*2 - 0x518]
push 0x10018c4
push eax
call dword [sym.imp.msvcrt.dll_wcsncpy]
add esp, 0xc
lea eax, [ebp - 0x518]
push eax
call dword [sym.imp.KERNEL32.dll_LoadLibraryW]
xor edi, edi
cmp eax, edi
je 0x1004395
push 0x10018ac
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
cmp eax, edi
je 0x1004266
lea ecx, [ebp - 0x528]
push ecx
lea ecx, [ebp - 0x51c]
push ecx
push edi
call eax
test eax, eax
jne 0x100425b
cmp dword [ebp - 0x528], 3
je 0x100424c
push dword [ebp - 0x51c]
call sub.NETAPI32.dll_NetApiBufferFree
mov dword [ebp - 0x51c], edi
mov dword [ebp - 0x524], 1
jmp 0x1004315
mov dword [ebp - 0x51c], edi
jmp 0x1004315
lea eax, [ebp - 0x52c]
push eax
push 0x2000001
push edi
push 0x1001840
push getpeername
mov dword [ebp - 0x530], edi
mov dword [ebp - 0x528], 1
call dword [sym.imp.ADVAPI32.dll_RegOpenKeyExW]
test eax, eax
jne 0x1004315
lea eax, [ebp - 0x530]
push eax
push edi
lea eax, [ebp - 0x528]
push eax
push edi
mov edi, dword [sym.imp.ADVAPI32.dll_RegQueryValueExW]
push 0x1001818
push dword [ebp - 0x52c]
call edi
push dword [ebp - 0x530]
push 0x40
call dword [sym.imp.KERNEL32.dll_GlobalAlloc]
test eax, eax
mov dword [ebp - 0x51c], eax
je 0x1004307
lea ecx, [ebp - 0x530]
push ecx
push eax
lea eax, [ebp - 0x528]
push eax
push 0
push 0x1001818
push dword [ebp - 0x52c]
call edi
test eax, eax
je 0x1004307
push dword [ebp - 0x51c]
call dword [sym.imp.KERNEL32.dll_GlobalFree]
and dword [ebp - 0x51c], 0
push dword [ebp - 0x52c]
call dword [sym.imp.ADVAPI32.dll_RegCloseKey]
xor edi, edi
cmp dword [ebp - 0x51c], edi
je 0x1004338
mov eax, dword [esi + 0x1720]
push dword [ebp - 0x51c]
add eax, ebx
push eax
call dword [sym.imp.msvcrt.dll__wcsicmp]
test eax, eax
pop ecx
pop ecx
je 0x1004362
cmp byte [ebp - 0x51d], 0
je 0x100435b
lea eax, [ebp - 0x108]
push eax
mov eax, dword [esi + 0x1720]
add eax, ebx
push eax
call dword [sym.imp.msvcrt.dll_wcscpy]
pop ecx
pop ecx
jmp 0x1004362
mov byte [esi + 0x1728], 1
cmp dword [ebp - 0x51c], edi
je 0x1004385
cmp dword [ebp - 0x524], edi
push dword [ebp - 0x51c]
je 0x100437f
call sub.NETAPI32.dll_NetApiBufferFree
jmp 0x1004385
call dword [sym.imp.KERNEL32.dll_GlobalFree]
cmp byte [esi + 0x1728], 0
je 0x10043b1
push 0xfffffffffffffffb
jmp 0x1004083
push 0xfffffffffffffffa
jmp 0x10043fa
lea eax, [ebp - 0x108]
push eax
mov eax, dword [esi + 0x1720]
add eax, ebx
push eax
call dword [sym.imp.msvcrt.dll_wcscpy]
pop ecx
pop ecx
mov eax, dword [esi + 0x1720]
mov edi, dword [sym.imp.msvcrt.dll_wcslen]
add eax, 0x3bc2
push eax
call edi
mov ecx, dword [esi + 0x1720]
add ecx, ebx
push ecx
mov dword [ebp - 0x524], eax
call edi
mov ecx, dword [ebp - 0x524]
lea ebx, [ecx + eax + 2]
lea eax, [ebx + ebx]
push eax
mov dword [ebp - 0x524], eax
call sub.msvcrt.dll_void____cdecl_operator_new_unsigned_int_
mov edi, eax
add esp, 0xc
test edi, edi
jne 0x1004419
push 0xfffffffffffffffc
mov ecx, dword [esi + 0x1720]
and word [ecx + 0x3dcc], 0
mov ecx, dword [esi + 0x1720]
and word [ecx + 0x3bc2], 0
pop eax
jmp 0x1004493
mov eax, dword [esi + 0x1720]
lea ecx, [eax + 0x3bc2]
push ecx
add eax, 0x3dcc
push eax
push 0x100180c
dec ebx
push ebx
push edi
call dword [sym.imp.msvcrt.dll__snwprintf]
mov eax, dword [ebp - 0x524]
and word [eax + edi - 2], 0
add esp, 0x14
push 0x1f5
push edi
call fcn.01003a95
mov esi, dword [esi + 0x1720]
mov bl, al
xor eax, eax
push eax
push eax
push 0x104
lea ecx, [esi + 0x3abc]
push ecx
push 0xffffffffffffffff
add esi, 0x3dcc
push esi
push eax
call dword [sym.imp.KERNEL32.dll_GetConsoleCP]
push eax
call dword [sym.imp.KERNEL32.dll_WideCharToMultiByte]
push edi
call sub.msvcrt.dll_void___cdecl_operator_delete_void__
neg bl
pop ecx
sbb ebx, ebx
and ebx, 0xfffffffd
mov eax, ebx
pop ebx
mov ecx, dword [ebp - 4]
pop edi
pop esi
call fcn.0100cc0e
leave
ret