Function at 0x104f56a
Capabilities:
Query environment variable

Disassembly:
mov eax, 0x10d5459
call fcn.0107a498
sub esp, 0x45c
mov eax, dword [0x10e607c]
push ebx
push esi
mov esi, ecx
cmp dword [esi + 0x74], 0
mov dword [ebp - 0x10], eax
push edi
je 0x104ff94
mov eax, dword [0x10e5378]
mov dword [ebp - 0x458], eax
mov eax, dword [0x10e537c]
mov dword [ebp - 0x45c], eax
mov eax, dword [0x10e5380]
mov dword [ebp - 0x434], eax
mov eax, dword [0x10e5388]
mov dword [ebp - 0x43c], eax
mov eax, dword [0x10e538c]
mov dword [ebp - 0x464], eax
mov eax, dword [0x10e5390]
mov dword [ebp - 0x460], eax
mov eax, dword [0x10e53d0]
mov dword [ebp - 0x468], eax
xor eax, eax
mov dword [ebp - 0x448], eax
mov dword [ebp - 0x444], eax
mov byte [ebp - 0x438], 0xff
mov dword [ebp - 0x430], eax
mov dword [ebp - 0x44c], eax
mov dword [ebp - 0x450], eax
call fcn.01022d6e
push dword [esi + 0x74]
mov edi, dword [sym.imp.msvcrt.dll_wcslen]
mov dword [ebp - 0x428], eax
call edi
mov ebx, dword [sym.imp.msvcrt.dll_malloc]
lea eax, [eax + eax + 2]
push eax
call ebx
test eax, eax
pop ecx
pop ecx
mov dword [ebp - 0x42c], eax
je 0x104ffca
push dword [esi + 0x74]
call edi
lea eax, [eax + eax + 2]
push eax
call ebx
mov ebx, eax
test ebx, ebx
pop ecx
pop ecx
mov dword [ebp - 0x440], ebx
jne 0x104f663
push dword [ebp - 0x42c]
call dword [sym.imp.msvcrt.dll_free]
jmp 0x104ffc9
push dword [esi + 0x74]
mov ecx, esi
call fcn.0104ebaf
sub eax, 0
je 0x104ffad
dec eax
dec eax
je 0x104ff81
push dword [esi + 0x74]
push dword [ebp - 0x42c]
call dword [sym.imp.msvcrt.dll_wcscpy]
push dword [ebp - 0x43c]
push dword [ebp - 0x42c]
call dword [sym.imp.msvcrt.dll_wcstok]
add esp, 0x10
test eax, eax
mov dword [ebp - 0x424], eax
je 0x104ff81
call fcn.01062344
test eax, eax
mov dword [ebp - 0x448], eax
je 0x104ff37
push dword [ebp - 0x424]
call edi
mov ebx, dword [sym.imp.msvcrt.dll__wcsnicmp]
push eax
push dword [ebp - 0x458]
push dword [ebp - 0x424]
call ebx
add esp, 0x10
test eax, eax
je 0x104f75b
push dword [ebp - 0x424]
call edi
push eax
push dword [ebp - 0x434]
push dword [ebp - 0x424]
call ebx
add esp, 0x10
test eax, eax
je 0x104f75b
push dword [ebp - 0x424]
call edi
push eax
push 0x1009e64
push dword [ebp - 0x424]
call ebx
add esp, 0x10
test eax, eax
je 0x104f75b
push 0x1009e50
push dword [ebp - 0x424]
call dword [sym.imp.msvcrt.dll__wcsicmp]
test eax, eax
pop ecx
pop ecx
je 0x104f75b
push dword [ebp - 0x424]
call edi
push eax
push dword [ebp - 0x45c]
push dword [ebp - 0x424]
call ebx
add esp, 0x10
test eax, eax
jne 0x104ff37
mov ecx, esi
call sub.MFC42u.dll_CCmdTarget::EndWaitCursor
and dword [ebp - 0x454], 0
jmp 0x104f771
push eax
call fcn.01086dd8
mov eax, dword [0x10eae7c]
mov eax, dword [eax + 4]
test eax, eax
jne 0x104f76b
and dword [0x10eae50], eax
push 0x1009e50
push dword [ebp - 0x424]
call dword [sym.imp.msvcrt.dll__wcsicmp]
xor ebx, ebx
pop ecx
inc ebx
test eax, eax
pop ecx
jne 0x104f7c1
mov eax, dword [esi + 0x20]
mov ecx, dword [eax + 0xd4]
push ebx
call fcn.0103ee2a
mov ecx, esi
call fcn.0105a7a0
mov dword [eax + 0x5c], ebx
mov dword [ebp - 0x44c], ebx
jmp 0x104fa95
push dword [ebp - 0x424]
call edi
push eax
push dword [ebp - 0x434]
push dword [ebp - 0x424]
call dword [sym.imp.msvcrt.dll__wcsnicmp]
add esp, 0x10
test eax, eax
jne 0x104fa11
mov dword [0x10eae50], ebx
mov eax, dword [esi + 0x20]
mov ecx, dword [eax + 0xd4]
push 2
call fcn.0103ee2a
push 0x104
lea eax, [ebp - 0x420]
push eax
push 0x1009f00
call dword [sym.imp.KERNEL32.dll_GetEnvironmentVariableW]
lea eax, [ebp - 0x420]
push eax
lea eax, [ebp - 0x218]
push 0x1009edc
push eax
call dword [sym.imp.msvcrt.dll_swprintf]
add esp, 0xc
push 0x10eae9c
lea eax, [ebp - 0x218]
push eax
call fcn.0103be8b
test ax, ax
je 0x104f85e
lea eax, [ebp - 0x218]
push eax
push 0xe15
call fcn.01084486
pop ecx
pop ecx
jmp 0x104ff73
mov eax, dword [0x10eae9c]
test eax, eax
mov dword [ebp - 0x450], ebx
je 0x104f937
cmp word [eax + 0x1c], 0
je 0x104f917
mov ecx, esi
call fcn.0105a7a0
test eax, eax
mov dword [ebp - 0x434], eax
jne 0x104f8ae
push 0xe27
mov dword [esi + 0x110], 0x57
call fcn.0108c10c
pop ecx
push eax
push ebx
call fcn.01064d3f
jmp 0x104ff7d
mov eax, dword [ebp - 0x434]
mov dword [eax + 0x7c], ebx
mov eax, dword [ebp - 0x428]
push 0
mov dword [eax + 0x2ac], ebx
call fcn.0107aa74
mov eax, dword [0x10eae9c]
push 0x104
push dword [eax + 0x14]
mov eax, dword [ebp - 0x428]
add eax, 0xa2
push eax
call dword [sym.imp.msvcrt.dll_wcsncpy]
mov eax, dword [ebp - 0x428]
add esp, 0xc
mov word [eax + 0xb84], bx
call fcn.01050b52
mov word [eax + 0x3c], bx
mov eax, dword [0x10eae9c]
push dword [eax + 0x14]
push dword [ebp - 0x434]
call fcn.010207ba
jmp 0x104f937
call fcn.01050b52
and word [eax + 0x3c], 0
mov word [eax + 0x3e], bx
mov eax, dword [ebp - 0x428]
mov word [eax + 0xb84], bx
call fcn.01051d4b
mov ecx, esi
call fcn.0105f09b
test eax, eax
je 0x104f9fc
and dword [ebp - 0x424], 0
mov ecx, esi
call fcn.0105a7a0
push ebx
mov ecx, eax
mov dword [ebp - 0x434], eax
mov dword [eax + 0x5c], ebx
call fcn.0102c6ac
mov eax, dword [ebp - 0x434]
mov dword [eax + 0x14], ebx
mov eax, dword [ebp - 0x428]
and word [eax + 0xad6], 0
push 2
mov ecx, esi
call fcn.0105d92f
mov eax, dword [ebp - 0x434]
mov eax, dword [eax + 0x6c]
cmp eax, ebx
jne 0x104f99a
mov dword [ebp - 0x424], ebx
jmp 0x104f9a7
push 2
pop ecx
cmp eax, ecx
jne 0x104f9a7
mov dword [ebp - 0x424], ecx
push dword [ebp - 0x424]
push dword [0x10eae84]
push dword [0x10eae78]
push dword [0x10eae80]
push dword [0x10eae9c]
call fcn.0103c6a0
test ax, ax
jne 0x104f9ea
mov eax, dword [ebp - 0x428]
mov dword [ebp - 0x430], ebx
mov dword [eax + 0xbec], ebx
mov word [eax + 0xac4], 4
mov ecx, dword [ebp - 0x434]
push 0
call fcn.0102c6ac
jmp 0x104fa95
push ebx
mov dword [esi + 0x110], 0x3e3
call fcn.0104e9c1
jmp 0x104ff7d
push dword [ebp - 0x424]
call edi
push eax
push dword [ebp - 0x458]
push dword [ebp - 0x424]
call dword [sym.imp.msvcrt.dll__wcsnicmp]
add esp, 0x10
test eax, eax
jne 0x104fa4e
mov eax, dword [esi + 0x20]
mov ecx, dword [eax + 0xd4]
push ebx
call fcn.0103ee2a
mov ecx, esi
call fcn.0105a7a0
mov dword [eax + 0x5c], ebx
jmp 0x104fa95
push dword [ebp - 0x424]
call edi
push eax
push dword [ebp - 0x45c]
push dword [ebp - 0x424]
call dword [sym.imp.msvcrt.dll__wcsnicmp]
add esp, 0x10
test eax, eax
jne 0x104fa78
mov dword [ebp - 0x454], ebx
jmp 0x104fa95
push dword [ebp - 0x424]
call edi
push eax
push 0x1009e64
push dword [ebp - 0x424]
call dword [sym.imp.msvcrt.dll__wcsnicmp]
add esp, 0x10
mov ecx, esi
call fcn.0104f4a9
test eax, eax
je 0x104ff73
xor eax, eax
push eax
push eax
push eax
call fcn.01053123
add esp, 0xc
cmp word [ebp - 0x450], 0
jne 0x104fe21
push dword [ebp - 0x43c]
push 0
call dword [sym.imp.msvcrt.dll_wcstok]
test eax, eax
pop ecx
pop ecx
mov dword [ebp - 0x424], eax
je 0x104fe21
cmp word [ebp - 0x444], 0
jne 0x104fb0b
movsx eax, word [ebp - 0x430]
push eax
push dword [ebp - 0x43c]
push dword [ebp - 0x424]
push dword [ebp - 0x448]
call fcn.01063412
cmp eax, 0xfffffffe
jne 0x104fabf
xor eax, eax
cmp word [ebp - 0x44c], ax
jne 0x104fdc6
mov ecx, dword [ebp - 0x424]
cmp word [ecx], 0x22
je 0x104fc5c
cmp word [ebp - 0x444], ax
jne 0x104fc91
push ecx
call edi
push eax
push dword [ebp - 0x464]
push dword [ebp - 0x424]
call dword [sym.imp.msvcrt.dll__wcsnicmp]
add esp, 0x10
test eax, eax
jne 0x104fb60
mov byte [ebp - 0x438], 0x1f
jmp 0x104fabf
push dword [ebp - 0x424]
call edi
push eax
push dword [ebp - 0x460]
push dword [ebp - 0x424]
call dword [sym.imp.msvcrt.dll__wcsnicmp]
add esp, 0x10
test eax, eax
jne 0x104fb8e
mov byte [ebp - 0x438], 0x1e
jmp 0x104fabf
push dword [ebp - 0x424]
call edi
push eax
push dword [ebp - 0x468]
push dword [ebp - 0x424]
call dword [sym.imp.msvcrt.dll__wcsnicmp]
add esp, 0x10
test eax, eax
jne 0x104fbbc
mov byte [ebp - 0x438], 0x26
jmp 0x104fabf
cmp byte [ebp - 0x438], 0xff
jne 0x104fc4b
push ebx
push 0
push dword [ebp - 0x424]
push dword [0x10eae78]
push dword [0x10eae7c]
call fcn.010647f5
test eax, eax
jne 0x104fabf
lea ecx, [ebp - 0x428]
call sub.MFC42u.dll_CString::CString_2
push dword [ebp - 0x424]
lea ecx, [ebp - 0x42c]
mov dword [ebp - 4], 2
call sub.MFC42u.dll_CString::CString_3
push 0x4e48
lea ecx, [ebp - 0x428]
mov byte [ebp - 4], 3
call sub.MFC42u.dll_CString::LoadStringW
push dword [ebp - 0x428]
lea ecx, [ebp - 0x42c]
call sub.MFC42u.dll_CString::FindOneOf
test eax, eax
push dword [ebp - 0x424]
jge 0x104fde2
push 0xd2b
jmp 0x104fde7
push dword [ebp - 0x438]
push dword [ebp - 0x424]
jmp 0x104fd91
cmp word [ebp - 0x444], ax
jne 0x104fc91
push 0x100210c
push dword [ebp - 0x440]
call dword [sym.imp.msvcrt.dll_wcscpy]
pop ecx
pop ecx
lea eax, [ebp - 0x444]
push eax
mov eax, dword [ebp - 0x424]
add eax, 2
mov dword [ebp - 0x444], ebx
push eax
jmp 0x104fc9e
lea eax, [ebp - 0x444]
push eax
push dword [ebp - 0x424]
push dword [ebp - 0x440]
mov ecx, esi
call fcn.0104d9d9
cmp word [ebp - 0x444], 0
jne 0x104fdae
cmp byte [ebp - 0x438], 0xff
jne 0x104fd85
push ebx
push 0
push dword [ebp - 0x440]
push dword [0x10eae78]
push dword [0x10eae7c]
call fcn.010647f5
test eax, eax
jne 0x104fabf
lea ecx, [ebp - 0x430]
call sub.MFC42u.dll_CString::CString_2
push dword [ebp - 0x424]
and dword [ebp - 4], 0
lea ecx, [ebp - 0x43c]
call sub.MFC42u.dll_CString::CString_3
push 0x4e48
lea ecx, [ebp - 0x430]
mov byte [ebp - 4], bl
call sub.MFC42u.dll_CString::LoadStringW
push dword [ebp - 0x430]
lea ecx, [ebp - 0x43c]
call sub.MFC42u.dll_CString::FindOneOf
test eax, eax
push dword [ebp - 0x424]
jge 0x104fe17
mov edi, 0xd2b
push edi
push ebx
push ebx
push 0
call fcn.01053123
push dword [ebp - 0x424]
push edi
call fcn.01084486
add esp, 0x1c
lea ecx, [ebp - 0x43c]
mov dword [esi + 0x110], 0x1f
mov byte [ebp - 4], 0
call sub.MFC42u.dll_CString::CString
lea ecx, [ebp - 0x430]
or dword [ebp - 4], 0xffffffff
call sub.MFC42u.dll_CString::CString
jmp 0x104ff7d
push dword [ebp - 0x438]
push dword [ebp - 0x440]
push dword [0x10eae78]
push dword [0x10eae7c]
call fcn.01063a59
mov byte [ebp - 0x438], 0xff
jmp 0x104fabf
push 0x10055e8
push dword [ebp - 0x440]
call dword [sym.imp.msvcrt.dll_wcscat]
pop ecx
pop ecx
jmp 0x104fabf
push dword [ebp - 0x424]
push 0xa9
push ebx
push ebx
push 0
call fcn.01053123
add esp, 0x14
jmp 0x104ff7d
push 0xd3b
push ebx
push ebx
push 0
call fcn.01053123
add esp, 0x14
lea ecx, [ebp - 0x42c]
mov dword [esi + 0x110], 0x1f
mov byte [ebp - 4], 2
call sub.MFC42u.dll_CString::CString
lea ecx, [ebp - 0x428]
jmp 0x104fd77
mov edi, 0xd3b
jmp 0x104fd3f
call fcn.01022d6e
xor edi, edi
cmp word [ebp - 0x44c], di
mov word [eax + 0xb88], 2
je 0x104fe65
mov eax, dword [ebp - 0x448]
mov eax, dword [eax + 4]
cmp eax, 0xffffffff
je 0x104fe5c
cmp eax, ebx
je 0x104fe5c
push 0xab
push ebx
push ebx
push edi
call fcn.01053123
add esp, 0x10
mov eax, dword [ebp - 0x448]
mov dword [eax + 4], ebx
cmp word [ebp - 0x430], di
jne 0x104fea4
push dword [ebp - 0x448]
push dword [0x10eae7c]
call fcn.01063b43
test eax, eax
jne 0x104fea4
push 0xe27
call fcn.0108c10c
pop ecx
push eax
push ebx
call fcn.01064d3f
mov dword [esi + 0x110], 0x1f
jmp 0x104ff7d
lea eax, [ebp - 0x448]
push eax
call fcn.01062361
call fcn.01022d6e
cmp word [ebp - 0x454], di
mov word [eax + 0xb88], 2
push ebx
je 0x104fecf
push 0x3ee
jmp 0x104fef4
cmp word [ebp - 0x430], di
je 0x104fedf
push 0x3ea
jmp 0x104fef4
cmp word [ebp - 0x44c], di
je 0x104feef
push 0x3f3
jmp 0x104fef4
push 0x3e9
mov ecx, esi
call fcn.0104f350
cmp word [0x10ea9b0], di
je 0x104ff1d
cmp word [ebp - 0x430], di
je 0x104ff13
push edi
call fcn.0104e9c1
mov dword [esi + 0x110], 0x1f
push dword [ebp - 0x42c]
mov esi, dword [sym.imp.msvcrt.dll_free]
call esi
push dword [ebp - 0x440]
call esi
pop ecx
pop ecx
jmp 0x104ff7d
xor eax, eax
push eax
push eax
push eax
call fcn.01053123
push dword [ebp - 0x424]
mov edi, 0xdc7
push edi
xor ebx, ebx
inc ebx
push ebx
push ebx
push 0
call fcn.01053123
push dword [ebp - 0x424]
push edi
call fcn.01084486
push 0
push 8
push 0
call fcn.01053123
add esp, 0x34
mov dword [esi + 0x110], 0x57
mov eax, ebx
jmp 0x104ff96
push dword [ebp - 0x42c]
mov esi, dword [sym.imp.msvcrt.dll_free]
call esi
push ebx
call esi
pop ecx
pop ecx
xor eax, eax
mov ecx, dword [ebp - 0xc]
pop edi
pop esi
mov dword fs:[0], ecx
mov ecx, dword [ebp - 0x10]
pop ebx
call fcn.01078836
leave
ret
push dword [ebp - 0x42c]
mov edi, dword [sym.imp.msvcrt.dll_free]
call edi
push ebx
call edi
pop ecx
mov dword [esi + 0x110], 0x57
pop ecx
xor eax, eax
inc eax
jmp 0x104ff96