Function at 0x1001ea50
Capabilities:
Get common file path
Get hostname
Query environment variable
Set environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xc40
mov dword [ebp - 0x18], 0
mov dword [ebp - 0x10], 0
mov dword [ebp - 0x14], 0
mov dword [ebp - 0xc], 0
mov dword [ebp - 4], 0
push 0x1ed8
push 0
mov eax, dword [ebp + 8]
push eax
call fcn.10013ba0
add esp, 0xc
call dword [sym.imp.KERNEL32.dll_GetCurrentProcessId]
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x1a54], eax
mov edx, dword [ebp + 8]
add edx, 0xa5c
push edx
call dword [sym.imp.KERNEL32.dll_GetTickCount]
mov ecx, dword [ebp + 8]
add eax, dword [ecx + 0x1a54]
push eax
call fcn.10015480
add esp, 8
push 0x105
mov edx, dword [ebp + 8]
add edx, 0x1a58
push edx
push 0
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
test eax, eax
jne 0x1001eae3
xor eax, eax
je 0x1001eae1
jmp 0x1001eadb
jmp 0x1001eb00
push 0x5c
mov ecx, dword [ebp + 8]
add ecx, 0x1a58
push ecx
call fcn.100168d0
add esp, 8
mov edx, dword [ebp + 8]
mov dword [edx + 0x1c64], eax
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call fcn.1001d770
add esp, 4
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x104], eax
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x104]
mov ecx, dword [eax]
push ecx
call fcn.1001d920
add esp, 4
test eax, eax
je 0x1001eb45
mov edx, dword [ebp + 8]
mov dword [edx + 0x408], 3
xor eax, eax
je 0x1001eb43
jmp 0x1001eb3d
jmp 0x1001eb76
call fcn.1001d810
test eax, eax
jle 0x1001eb63
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x408], 2
xor edx, edx
je 0x1001eb61
jmp 0x1001eb5b
jmp 0x1001eb76
mov eax, dword [ebp + 8]
mov dword [eax + 0x408], 1
xor ecx, ecx
je 0x1001eb76
jmp 0x1001eb70
mov edx, dword [ebp + 8]
mov eax, dword [ebp + 0xc]
mov dword [edx + 0x40c], eax
xor ecx, ecx
je 0x1001eb88
jmp 0x1001eb82
mov dword [ebp - 0x18], 0x80
mov dword [ebp - 0x10], 0x80
lea edx, [ebp - 8]
push edx
lea eax, [ebp - 0x10]
push eax
mov ecx, dword [ebp + 8]
add ecx, 0x308
push ecx
lea edx, [ebp - 0x18]
push edx
mov eax, dword [ebp + 8]
add eax, 0x208
push eax
mov ecx, dword [ebp + 8]
mov edx, dword [ecx + 0x104]
mov eax, dword [edx]
push eax
push 0
call dword [sym.imp.ADVAPI32.dll_LookupAccountSidW]
test eax, eax
jne 0x1001ebfc
call dword [sym.imp.KERNEL32.dll_GetLastError]
mov dword [ebp - 0x1c], eax
mov ecx, dword [ebp - 0x1c]
push ecx
push str.LookupAccountSidW___err__u
push 0x80
mov edx, dword [ebp + 8]
add edx, 0x308
push edx
call fcn.10013ca0
add esp, 0x10
xor eax, eax
je 0x1001ebfc
jmp 0x1001ebf6
mov ecx, dword [ebp + 0x14]
and ecx, 2
je 0x1001ec2e
mov edx, dword [ebp + 0x10]
mov dword [ebp - 4], edx
xor eax, eax
je 0x1001ec10
jmp 0x1001ec0a
push 0x20a
mov ecx, dword [ebp - 4]
push ecx
mov edx, dword [ebp + 8]
add edx, 0x410
push edx
call dword [sym.imp.KERNEL32.dll_lstrcpynW]
jmp 0x1001ed12
mov eax, dword [ebp + 0x14]
and eax, 4
je 0x1001ecf3
mov ecx, dword [ebp + 0x10]
mov dword [ebp - 0xc], ecx
xor edx, edx
je 0x1001ec46
jmp 0x1001ec40
push 0x105
mov eax, dword [ebp - 0xc]
push eax
mov ecx, dword [ebp + 8]
add ecx, 0x410
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpynW]
mov edx, dword [ebp - 0xc]
mov eax, dword [edx + 0x2ff]
mov dword [0x1003a950], eax
mov ecx, dword [ebp - 0xc]
mov edx, dword [ecx + 0x307]
mov dword [0x1003a954], edx
mov eax, dword [ebp - 0xc]
mov ecx, dword [eax + 0x30b]
mov dword [0x1003a958], ecx
mov edx, dword [ebp - 0xc]
mov eax, dword [edx + 0x313]
mov dword [0x1003a95c], eax
mov ecx, dword [ebp - 0xc]
mov edx, dword [ecx + 0x317]
mov dword [0x1003a960], edx
mov eax, dword [ebp - 0xc]
mov ecx, dword [eax + 0x31f]
mov dword [0x1003a964], ecx
mov edx, dword [ebp - 0xc]
mov eax, dword [edx + 0x323]
mov dword [0x1003a968], eax
mov ecx, dword [ebp - 0xc]
mov edx, dword [ecx + 0x32b]
mov dword [0x1003a96c], edx
mov eax, dword [ebp - 0xc]
mov ecx, dword [eax + 0x32f]
mov dword [0x1003a970], ecx
mov edx, dword [ebp - 0xc]
mov eax, dword [edx + 0x337]
mov dword [0x1003a974], eax
jmp 0x1001ed12
push 0x20a
mov ecx, dword [ebp + 8]
add ecx, 0x410
push ecx
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0x40c]
push eax
call dword [sym.imp.KERNEL32.dll_GetModuleFileNameW]
push 0x5c
mov ecx, dword [ebp + 8]
add ecx, 0x410
push ecx
call fcn.100168d0
add esp, 8
mov edx, dword [ebp + 8]
mov dword [edx + 0x61c], eax
push 0x40
push 0x5c
mov eax, dword [ebp + 8]
add eax, 0x410
push eax
call fcn.100168d0
add esp, 8
push eax
mov ecx, dword [ebp + 8]
add ecx, 0xc4
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcpynW]
mov edx, dword [ebp + 8]
add edx, 0xc4
push edx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
xor ecx, ecx
mov edx, dword [ebp + 8]
mov word [edx + eax*2 + 0xbc], cx
push 0x20
mov eax, dword [ebp + 8]
add eax, 0xa4
push eax
mov ecx, dword [ebp + 8]
add ecx, 0xc4
push ecx
call fcn.10016e30
add esp, 0xc
mov edx, dword [ebp + 8]
add edx, 0x620
push edx
mov eax, dword [ebp + 8]
add eax, 0x410
push eax
call fcn.10016920
add esp, 8
push 0x105
mov ecx, dword [ebp + 8]
add ecx, 0x620
push ecx
mov edx, dword [ebp + 8]
add edx, 0x850
push edx
call dword [sym.imp.KERNEL32.dll_lstrcpynW]
push 0x1002a3bc
mov eax, dword [ebp + 8]
add eax, 0x850
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
mov ecx, dword [ebp + 8]
add ecx, 0xc4
push ecx
mov edx, dword [ebp + 8]
add edx, 0x850
push edx
call dword [sym.imp.KERNEL32.dll_lstrcatW]
push 0x188c
call fcn.10015230
add esp, 4
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x20]
push eax
mov ecx, dword [ebp + 8]
add ecx, 0x850
push ecx
call dword [sym.imp.KERNEL32.dll_lstrcatW]
lea edx, [ebp - 0x20]
push edx
call fcn.10015460
add esp, 4
mov eax, dword [ebp + 8]
add eax, 0xa5c
push eax
push 0xf
push 0xa
mov ecx, dword [ebp + 8]
add ecx, 0x82a
push ecx
call fcn.100169c0
add esp, 0x10
mov edx, dword [ebp + 8]
add edx, 0x1420
push edx
push 0
mov eax, dword [ebp + 8]
add eax, 0xa4
push eax
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
mov ecx, dword [ebp + 8]
add ecx, 0xa4
push ecx
call fcn.1001c990
add esp, 0xc
push eax
call fcn.1001f880
add esp, 8
call dword [sym.imp.KERNEL32.dll_GetCurrentProcess]
push eax
call fcn.1001d9a0
add esp, 4
movsx edx, al
mov eax, dword [ebp + 8]
mov dword [eax + 0x1430], edx
xor ecx, ecx
je 0x1001ee9e
jmp 0x1001ee98
push 0x9c
push 0
mov edx, dword [ebp + 8]
push edx
call fcn.10013ba0
add esp, 0xc
mov eax, dword [ebp + 8]
mov dword [eax], 0x9c
mov ecx, dword [ebp + 8]
push ecx
call dword [sym.imp.KERNEL32.dll_GetVersionExA]
push str.IsWow64Process
push str.kernel32
call dword [sym.imp.KERNEL32.dll_GetModuleHandleA]
push eax
call dword [sym.imp.KERNEL32.dll_GetProcAddress]
mov edx, dword [ebp + 8]
mov dword [edx + 0x1dac], eax
call fcn.1001e8d0
mov ecx, dword [ebp + 8]
mov dword [ecx + 0xa0], eax
mov edx, dword [ebp + 8]
mov eax, dword [edx + 0xa0]
push eax
call fcn.1001e900
add esp, 4
mov ecx, dword [ebp + 8]
mov word [ecx + 0x9c], ax
xor edx, edx
je 0x1001ef14
jmp 0x1001ef0e
push 0x104
mov eax, dword [ebp + 8]
add eax, 0x1434
push eax
call dword [sym.imp.KERNEL32.dll_GetWindowsDirectoryW]
test eax, eax
jne 0x1001ef34
xor ecx, ecx
je 0x1001ef32
jmp 0x1001ef2c
jmp 0x1001ef3a
xor edx, edx
je 0x1001ef3a
jmp 0x1001ef34
push 0x104
lea eax, [ebp - 0x230]
push eax
push str.SystemRoot
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
jne 0x1001ef70
xor ecx, ecx
je 0x1001ef5b
jmp 0x1001ef55
mov edx, dword [ebp + 8]
add edx, 0x1434
push edx
push str.SystemRoot
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
push 0x209
mov eax, dword [ebp + 8]
add eax, 0x1848
push eax
push str.USERPROFILE
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
jne 0x1001efd2
xor ecx, ecx
je 0x1001ef93
jmp 0x1001ef8d
push str.TEMP
mov edx, dword [ebp + 8]
add edx, 0x1434
push edx
push str._s_s
push 0x20a
mov eax, dword [ebp + 8]
add eax, 0x1848
push eax
call fcn.10013ca0
add esp, 0x14
mov ecx, dword [ebp + 8]
add ecx, 0x1848
push ecx
push str.USERPROFILE
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
push 0x20a
mov edx, dword [ebp + 8]
add edx, 0x163e
push edx
push 0x1002faa8
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
test eax, eax
jne 0x1001f00b
xor eax, eax
je 0x1001eff6
jmp 0x1001eff0
mov ecx, dword [ebp + 8]
add ecx, 0x1848
push ecx
push 0x1002faa8
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableW]
push 0x3f
lea edx, [ebp - 0x270]
push edx
push str.SystemDrive
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableA]
test eax, eax
jne 0x1001f039
xor eax, eax
je 0x1001f029
jmp 0x1001f023
push 0x1002fa98
push str.SystemDrive
call dword [sym.imp.KERNEL32.dll_SetEnvironmentVariableA]
mov dword [ebp - 0x274], 0x7f
lea ecx, [ebp - 0x274]
push ecx
mov edx, dword [ebp + 8]
add edx, 0x1db0
push edx
call dword [sym.imp.KERNEL32.dll_GetComputerNameW]
lea eax, [ebp - 0xc40]
push eax
push 0
mov ecx, dword [ebp + 8]
add ecx, 0x1420
push ecx
call dword [sym.imp.KERNEL32.dll_lstrlenA]
push eax
mov edx, dword [ebp + 8]
add edx, 0x1420
push edx
call fcn.1001c990
add esp, 0xc
push eax
call fcn.10015480
add esp, 8
push 0x20
mov eax, dword [ebp + 8]
add eax, 0x1c68
push eax
lea ecx, [ebp - 0xc40]
push ecx
call fcn.10015730
add esp, 0xc
xor edx, edx
je 0x1001f0af
jmp 0x1001f0a9
lea eax, [ebp - 0xc40]
push eax
push 0x1e
push 0x14
mov ecx, dword [ebp + 8]
add ecx, 0x1c88
push ecx
call fcn.100169c0
add esp, 0x10
xor edx, edx
je 0x1001f0d2
jmp 0x1001f0cc
mov eax, dword [ebp + 0x14]
and eax, 1
jne 0x1001f0ee
call fcn.1001e5c0
mov ecx, dword [ebp + 8]
mov dword [ecx + 0x1ca8], eax
xor edx, edx
je 0x1001f0ee
jmp 0x1001f0e8
mov eax, 1
mov esp, ebp
pop ebp
ret