Function at 0x403860
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x23c
mov eax, dword [0x421018]
xor eax, ebp
mov dword [ebp - 4], eax
push ebx
mov ebx, ecx
xor eax, eax
push esi
push edi
mov word [ebp - 0x230], ax
cmp byte [ebx + 5], al
je 0x4038fc
lea esi, [ebx + 0xc]
push esi
call dword [sym.imp.SHLWAPI.dll_PathUnquoteSpacesW]
push esi
call dword [sym.imp.SHLWAPI.dll_PathRemoveBlanksW]
push 0x104
lea eax, [ebp - 0x230]
push eax
push esi
call dword [sym.imp.KERNEL32.dll_ExpandEnvironmentStringsW]
lea edx, [ebp - 0x230]
call fcn.00407500
cmp dword [ebx + 8], 0
mov edi, dword [sym.imp.KERNEL32.dll_lstrcpyW]
je 0x4038e8
lea ecx, [ebp - 0x230]
call fcn.00407660
test eax, eax
jne 0x4038e8
mov ecx, dword [ebx + 8]
push esi
lea edx, [ebp - 0x230]
call fcn.00407750
add esp, 4
test eax, eax
je 0x4038f2
jmp 0x4038fc
lea eax, [ebp - 0x230]
push eax
push esi
call edi
push esi
lea eax, [ebx + 0x1aa4]
push eax
call edi
lea eax, [ebx + 0x1aa4]
push eax
mov ecx, ebx
call fcn.004045e0
mov esi, eax
lea eax, [ebx + 0x20c8]
push eax
mov dword [ebp - 0x238], eax
call dword [sym.imp.KERNEL32.dll_lstrlenW]
mov ecx, dword [sym.imp.KERNEL32.dll_lstrcatW]
mov edi, 0x208
sub edi, eax
cmp byte [ebx + 4], 0
mov eax, 0x21000115
je 0x40396c
cmp edi, 0xa
jbe 0x403967
cmp byte [ebx + 3], 0
lea eax, [ebx + 0x20c8]
je 0x40394f
push str.__test
jmp 0x403954
push str.__testonly
push eax
call ecx
mov ecx, dword [sym.imp.KERNEL32.dll_lstrcatW]
sub edi, 0xa
mov eax, 0x21000115
jmp 0x40396c
test esi, esi
cmove esi, eax
mov edx, dword [ebx + 0x126c]
test edx, edx
je 0x4039a8
cmp edi, 4
jbe 0x4039a3
cmp edx, 1
mov eax, str.__g1
mov dword [ebp - 0x234], str.__g0
cmovne eax, dword [ebp - 0x234]
push eax
lea eax, [ebx + 0x20c8]
push eax
call ecx
sub edi, 3
jmp 0x4039a8
test esi, esi
cmove esi, eax
mov ecx, dword [ebx + 0x1268]
test ecx, ecx
je 0x4039e4
cmp edi, 4
jbe 0x4039da
mov edx, str.__h0
cmp ecx, 1
mov eax, str.__h1
cmovne eax, edx
push eax
lea eax, [ebx + 0x20c8]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
sub edi, 4
jmp 0x4039e4
test esi, esi
mov eax, 0x21000115
cmove esi, eax
mov eax, dword [ebx + 0x1270]
test eax, eax
je 0x403a20
cmp edi, 0x10
jbe 0x403a4a
push eax
lea eax, [ebp - 0x230]
push str.__wait__d
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
lea eax, [ebp - 0x230]
push eax
lea eax, [ebx + 0x20c8]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
sub edi, 0x10
mov eax, 0x21000115
cmp byte [ebx + 0x1aa1], 0
je 0x403a5b
cmp edi, 3
jbe 0x403a56
push 0x41f484
lea eax, [ebx + 0x20c8]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
sub edi, 3
jmp 0x403a5b
test esi, esi
mov eax, 0x21000115
cmove esi, eax
jmp 0x403a25
test esi, esi
cmove esi, eax
cmp byte [ebx + 0x1aa0], 0
je 0x403a7e
cmp edi, 3
jbe 0x403aa8
push 0x41f48c
lea eax, [ebx + 0x20c8]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
sub edi, 3
mov eax, 0x21000115
cmp byte [ebx + 0x216], 0
je 0x403ab9
cmp edi, 5
jbe 0x403ab4
push str.__scm
lea eax, [ebx + 0x20c8]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
sub edi, 5
jmp 0x403ab9
test esi, esi
mov eax, 0x21000115
cmove esi, eax
jmp 0x403a83
test esi, esi
cmove esi, eax
cmp byte [ebx + 0x1274], 0
je 0x403aff
cmp edi, 0xc
jbe 0x403af5
push dword [ebx + 0x1278]
lea eax, [ebp - 0x24]
push str.__lng__u
push eax
call dword [sym.imp.USER32.dll_wsprintfW]
add esp, 0xc
lea eax, [ebp - 0x24]
push eax
lea eax, [ebx + 0x20c8]
push eax
call dword [sym.imp.KERNEL32.dll_lstrcatW]
sub edi, 0xc
jmp 0x403aff
test esi, esi
mov eax, 0x21000115
cmove esi, eax
cmp byte [ebx + 0x217], 0
je 0x403b27
mov ecx, ebx
call fcn.00404450
test eax, eax
je 0x403b27
xor ecx, ecx
test esi, esi
mov word [ebx + 0x218], cx
mov byte [ebx + 0x217], cl
cmove esi, eax
xor eax, eax
mov dword [ebp - 0x24], str.__log__
mov dword [ebp - 0x20], str.__model__
mov dword [ebp - 0x1c], str.__pn__
mov dword [ebp - 0x18], str.__id__
mov dword [ebp - 0x14], str.__is__
mov dword [ebp - 0x10], str.__wbt__
mov dword [ebp - 0xc], str.__setup__
mov dword [ebp - 8], str.__setupr__
mov dword [ebp - 0x234], eax
add ebx, 0x218
lea ecx, [ecx]
test ebx, ebx
je 0x403bcf
xor ecx, ecx
cmp cx, word [ebx]
je 0x403bcf
push ebx
call dword [sym.imp.KERNEL32.dll_lstrlenW]
add eax, 0xa
mov dword [ebp - 0x23c], eax
cmp edi, eax
jb 0x403c04
mov ecx, dword [ebp - 0x234]
push dword [ebp + ecx*4 - 0x24]
push dword [ebp - 0x238]
call dword [sym.imp.KERNEL32.dll_lstrcatW]
push ebx
push dword [ebp - 0x238]
call dword [sym.imp.KERNEL32.dll_lstrcatW]
push 0x41f544
push dword [ebp - 0x238]
call dword [sym.imp.KERNEL32.dll_lstrcatW]
sub edi, dword [ebp - 0x23c]
mov eax, dword [ebp - 0x234]
inc eax
add ebx, 0x20a
mov dword [ebp - 0x234], eax
cmp eax, 8
jl 0x403b70
test esi, esi
jne 0x403bf1
push dword [ebp - 0x238]
call dword [sym.imp.SHLWAPI.dll_PathRemoveBlanksW]
pop edi
mov eax, esi
pop esi
pop ebx
mov ecx, dword [ebp - 4]
xor ecx, ebp
call fcn.0040939c
mov esp, ebp
pop ebp
ret
test esi, esi
jne 0x403bf1
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
mov eax, 0x21000115
pop ebx
call fcn.0040939c
mov esp, ebp
pop ebp
ret