Function at 0x1004227a
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0xa4
movzx eax, byte [ebp + 0x24]
test eax, eax
je 0x1004233a
lea eax, [ebp + 0xc]
mov dword [ebp - 0x98], eax
lea eax, [ebp + 0x18]
mov dword [ebp - 0x58], eax
mov eax, dword [ebp + 0x30]
mov dword [ebp - 0x40], eax
mov eax, dword [ebp - 0x58]
movzx eax, byte [eax]
test eax, eax
je 0x100422b8
push 0
call dword [sym.imp.ADVAPI32.dll_CloseServiceHandle]
jmp 0x10042335
mov eax, dword [ebp - 0x40]
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x98]
mov dword [ebp - 0x78], eax
mov eax, dword [ebp - 0x20]
mov eax, dword [eax + 4]
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x20]
mov eax, dword [eax]
push 8
pop ecx
imul ecx, ecx, 5
lea eax, [eax + ecx + 0x78]
mov dword [ebp - 0x30], eax
mov eax, dword [ebp - 0x30]
cmp dword [eax + 4], 0
jbe 0x10042335
mov eax, dword [ebp - 0x30]
mov ecx, dword [ebp - 0x18]
add ecx, dword [eax]
mov dword [ebp - 0x48], ecx
push 0x5e26
lea eax, [ebp - 0x48]
push eax
push 0x1bca
push 0x6c92
push 0x63f5
push 0x4fad
push 0x581c
push 1
push 0x3a01
push dword [ebp - 0x78]
push 0x4cb9
push 1
lea eax, [ebp - 0x18]
push eax
call fcn.1003167c
add esp, 0x34
jmp 0x10042518
mov eax, dword [ebp + 0x28]
mov dword [ebp - 0x60], eax
mov eax, dword [ebp + 0x34]
mov dword [ebp - 0x68], eax
mov eax, dword [ebp + 0x10]
mov dword [ebp - 0x88], eax
mov eax, dword [ebp + 0x20]
mov dword [ebp - 0x70], eax
mov eax, dword [ebp + 0x14]
mov dword [ebp - 0x90], eax
mov eax, dword [ebp + 8]
mov dword [ebp - 0x3c], eax
lea eax, [ebp + 0x2c]
mov dword [ebp - 0x50], eax
mov eax, dword [ebp + 0x1c]
mov dword [ebp - 0x9c], eax
mov eax, dword [ebp - 0x50]
movzx eax, byte [eax]
test eax, eax
je 0x100423aa
mov eax, dword [ebp - 0x90]
mov dword [ebp - 0x38], eax
mov eax, dword [ebp - 0x38]
mov dword [ebp - 0x80], eax
mov eax, dword [ebp - 0x80]
movzx eax, byte [eax]
test eax, eax
je 0x100423a5
push 0x224d
push 0
push 0
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
jmp 0x10042518
mov eax, dword [ebp - 0x60]
mov dword [ebp - 0x44], eax
mov eax, dword [ebp - 0x9c]
mov dword [ebp - 0x4c], eax
mov eax, dword [ebp - 0x68]
mov dword [ebp - 0x54], eax
mov eax, dword [ebp - 0x88]
mov dword [ebp - 0x5c], eax
mov eax, dword [ebp - 0x70]
mov dword [ebp - 0x64], eax
mov eax, dword [ebp - 0x3c]
mov dword [ebp - 0x6c], eax
mov eax, dword [ebp - 0x44]
mov dword [ebp - 4], eax
mov eax, dword [ebp - 0x4c]
mov dword [ebp - 0x74], eax
mov eax, dword [ebp - 0x54]
mov dword [ebp - 0x7c], eax
mov eax, dword [ebp - 0x5c]
mov dword [ebp - 0x84], eax
mov eax, dword [ebp - 0x64]
mov dword [ebp - 8], eax
mov eax, dword [ebp - 0x6c]
mov dword [ebp - 0x94], eax
mov eax, dword [ebp - 0x74]
cmp dword [eax], 0
je 0x1004240f
mov dword [ebp - 0x24], 1
jmp 0x10042413
and dword [ebp - 0x24], 0
mov eax, dword [ebp - 0x7c]
mov ecx, dword [ebp - 4]
mov ecx, dword [ecx]
cmp dword [eax], ecx
jge 0x10042428
mov dword [ebp - 0xc], 1
jmp 0x1004242c
and dword [ebp - 0xc], 0
mov eax, dword [ebp - 0x84]
mov dword [eax], 0x5eec0db1
mov eax, 0x5eec0db1
cmp eax, 4
jg 0x10042450
mov eax, dword [ebp - 4]
cmp dword [eax], 0
jne 0x10042450
and dword [ebp - 0x28], 0
jmp 0x10042457
mov dword [ebp - 0x28], 1
mov eax, dword [ebp - 8]
mov eax, dword [eax]
cmp dword [ebp - 0x28], eax
jl 0x1004246a
mov dword [ebp - 0x10], 1
jmp 0x1004246e
and dword [ebp - 0x10], 0
mov eax, dword [ebp - 0xc]
cmp eax, dword [ebp - 0x10]
je 0x10042484
xor eax, eax
inc eax
je 0x10042484
mov dword [ebp - 0x14], 1
jmp 0x10042488
and dword [ebp - 0x14], 0
cmp dword [ebp - 0x14], 0xffffffff
je 0x10042497
mov dword [ebp - 0x1c], 1
jmp 0x1004249b
and dword [ebp - 0x1c], 0
mov eax, dword [ebp - 8]
mov eax, dword [eax]
imul eax, dword [ebp - 0x1c]
mov ecx, dword [ebp - 8]
sub eax, dword [ecx]
mov ecx, dword [ebp - 0x24]
sub ecx, eax
cmp ecx, 4
ja 0x100424bc
mov dword [ebp - 0x2c], 1
jmp 0x100424c0
and dword [ebp - 0x2c], 0
mov eax, dword [ebp - 0x2c]
inc eax
inc eax
cmp eax, 0xffffffff
jl 0x100424d6
mov dword [ebp - 0x8c], 1
jmp 0x100424dd
and dword [ebp - 0x8c], 0
mov eax, dword [ebp - 4]
mov eax, dword [eax]
mov dword [ebp - 0xa0], eax
mov eax, dword [ebp - 4]
mov eax, dword [eax]
mov dword [ebp - 0xa4], eax
mov eax, dword [ebp - 0x94]
mov eax, dword [eax]
dec eax
mov ecx, dword [ebp - 4]
cmp eax, dword [ecx]
jge 0x1004250c
mov dword [ebp - 0x34], 1
jmp 0x10042510
and dword [ebp - 0x34], 0
mov eax, dword [ebp - 4]
mov ecx, dword [ebp - 0x34]
mov dword [eax], ecx
mov esp, ebp
pop ebp
ret