Function at 0x1018ea30
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x74
mov eax, dword [0x101db014]
xor eax, ebp
mov dword [ebp - 0x10], eax
push 8
call dword [sym.imp.mozglue.dll_malloc]
add esp, 4
test eax, eax
je 0x1018eb7a
mov dword [ebp - 0x7c], eax
mov eax, dword [ebp + 0xc]
mov esi, dword [eax]
test esi, esi
je 0x1018eb8b
lea ebx, [eax + 4]
xor edi, edi
mov eax, esi
push eax
call sub.api_ms_win_crt_string_l1_1_0.dll_strlen
add esp, 4
lea edi, [edi + eax*2]
add edi, 3
mov eax, dword [ebx]
add ebx, 4
test eax, eax
jne 0x1018ea6d
push edi
call dword [sym.imp.mozglue.dll_malloc]
add esp, 4
mov dword [ebp - 0x74], eax
test eax, eax
je 0x1018ebca
mov edi, dword [ebp - 0x74]
mov eax, dword [ebp + 0xc]
mov ebx, eax
cmp ebx, eax
je 0x1018eaac
mov byte [edi], 0x20
inc edi
mov esi, dword [ebx]
cmp byte [esi], 0
mov dword [ebp - 0x68], ebx
je 0x1018eacb
push str.__f_n_r_t_v
push esi
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strpbrk]
add esp, 8
test eax, eax
je 0x1018eb70
mov byte [edi], 0x22
inc edi
mov dword [ebp - 0x6c], 0
xor ebx, ebx
mov al, byte [esi]
cmp al, 0x22
je 0x1018eaff
cmp al, 0x5c
je 0x1018eb2d
test al, al
je 0x1018eb30
test ebx, ebx
jle 0x1018eafa
push ebx
push 0x5c
push edi
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
add edi, ebx
mov al, byte [esi]
mov byte [edi], al
inc edi
jmp 0x1018eb28
test ebx, ebx
jle 0x1018eb1d
add ebx, ebx
test ebx, ebx
mov eax, 1
cmovle ebx, eax
push ebx
push 0x5c
push edi
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
add edi, ebx
mov byte [edi], 0x5c
mov al, byte [esi]
mov byte [edi + 1], al
add edi, 2
xor ebx, ebx
inc esi
jmp 0x1018ead8
inc ebx
jmp 0x1018eb2a
test ebx, ebx
je 0x1018eb50
mov eax, dword [ebp - 0x6c]
mov ecx, eax
xor cl, 1
shl ebx, cl
test ebx, ebx
jle 0x1018eb50
push ebx
push 0x5c
push edi
call sub.VCRUNTIME140.dll_memset
add esp, 0xc
add edi, ebx
mov eax, dword [ebp + 0xc]
mov ebx, dword [ebp - 0x68]
cmp byte [ebp - 0x6c], 0
jne 0x1018eb60
mov byte [edi], 0x22
inc edi
mov esi, dword [ebx + 4]
add ebx, 4
test esi, esi
jne 0x1018eaa2
jmp 0x1018eb9f
mov al, 1
mov dword [ebp - 0x6c], eax
jmp 0x1018ead6
push 0
push 0xffffe890
call sym.nss3.dll_PR_SetError
add esp, 8
jmp 0x1018ebe6
push 0
call dword [sym.imp.mozglue.dll_malloc]
add esp, 4
mov edi, eax
mov dword [ebp - 0x74], eax
test eax, eax
je 0x1018ebca
mov eax, dword [ebp + 0x14]
mov ecx, dword [ebp + 0x10]
mov byte [edi], 0
mov edi, eax
test eax, eax
je 0x1018ebfc
mov eax, dword [edi + 0x10]
test eax, eax
setne bl
test ecx, ecx
jne 0x1018ebfe
test eax, eax
je 0x1018ebfe
call dword [sym.imp.api_ms_win_crt_environment_l1_1_0.dll___p__environ]
mov ecx, dword [eax]
mov bl, 1
jmp 0x1018ebfe
push 0
push 0xffffe890
call sym.nss3.dll_PR_SetError
add esp, 8
mov esi, dword [ebp - 0x7c]
push esi
call dword [sym.imp.mozglue.dll_free]
add esp, 4
xor esi, esi
mov ecx, dword [ebp - 0x10]
xor ecx, ebp
call fcn.1014dc80
mov eax, esi
add esp, 0x74
pop esi
pop edi
pop ebx
pop ebp
ret
xor ebx, ebx
test ecx, ecx
mov dword [ebp - 0x80], ecx
je 0x1018ed94
xor esi, esi
mov edi, 4
dec esi
cmp dword [ecx + edi - 4], 0
lea edi, [edi + 4]
jne 0x1018ec10
push edi
call dword [sym.imp.mozglue.dll_malloc]
add esp, 4
mov ecx, esi
not ecx
mov dword [ebp - 0x68], ecx
cmp esi, 0xffffffff
mov dword [ebp - 0x6c], eax
mov dword [ebp - 0x70], ebx
je 0x1018eda4
xor ecx, ecx
mov eax, ebx
xor al, 1
mov byte [ebp - 0x78], al
xor ebx, ebx
test ecx, ecx
setne al
or al, byte [ebp - 0x78]
mov eax, dword [ebp - 0x80]
mov eax, dword [eax + ebx*4]
mov edx, dword [ebp - 0x6c]
mov dword [edx + ebx*4], eax
jne 0x1018ec82
push 0x11
push str.NSPR_INHERIT_FDS
push eax
call dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_strncmp]
add esp, 0xc
xor ecx, ecx
test eax, eax
jne 0x1018ec82
mov eax, dword [ebp + 0x14]
mov eax, dword [eax + 0x10]
mov ecx, dword [ebp - 0x6c]
mov dword [ecx + ebx*4], eax
xor ecx, ecx
inc ecx
inc ebx
cmp dword [ebp - 0x68], ebx
jne 0x1018ec46
test ecx, ecx
setne al
mov ecx, dword [ebp - 0x70]
xor cl, 1
or cl, al
mov ebx, dword [ebp - 0x6c]
jne 0x1018eca9
neg esi
mov eax, dword [ebp + 0x14]
mov eax, dword [eax + 0x10]
mov dword [ebx + edi - 8], eax
mov dword [ebp - 0x68], esi
mov eax, dword [ebp - 0x68]
mov dword [ebx + eax*4], 0
push 0x10199a30
push 4
push eax
push ebx
call dword [sym.imp.api_ms_win_crt_utility_l1_1_0.dll_qsort]
add esp, 0x10
call dword [sym.imp.kernel32.dll_GetEnvironmentStrings]
mov edi, eax
mov dword [ebp - 0x78], eax
mov al, byte [edi]
cmp al, 0x3d
je 0x1018ece8
test al, al
je 0x1018ed3f
push edi
call sub.api_ms_win_crt_string_l1_1_0.dll_strlen
add esp, 4
add edi, eax
inc edi
jmp 0x1018ecd0
cmp byte [edi + 1], 0
je 0x1018ecda
cmp byte [edi + 2], 0x3a
jne 0x1018ecda
cmp byte [edi + 3], 0x3d
jne 0x1018ecda
push edi
call sub.api_ms_win_crt_string_l1_1_0.dll_strlen
add esp, 4
lea esi, [eax + 1]
mov byte [ebp - 0x70], 0x3d
cmp byte [edi + eax + 1], 0x3d
jne 0x1018ed44
cmp byte [edi + esi + 1], 0
je 0x1018ed44
lea eax, [edi + esi]
cmp byte [eax + 2], 0x3a
jne 0x1018ed44
cmp byte [eax + 3], 0x3d
jne 0x1018ed44
push eax
call sub.api_ms_win_crt_string_l1_1_0.dll_strlen
add esp, 4
lea ecx, [eax + esi]
add esi, eax
inc esi
cmp byte [edi + ecx + 1], 0x3d
je 0x1018ed11
jmp 0x1018ed44
mov byte [ebp - 0x70], al
xor esi, esi
mov eax, dword [ebx]
mov dword [ebp - 0x68], esi
test eax, eax
je 0x1018ed6b
mov ebx, dword [ebp - 0x6c]
add ebx, 4
mov esi, dword [ebp - 0x68]
push eax
call sub.api_ms_win_crt_string_l1_1_0.dll_strlen
add esp, 4
add esi, eax
inc esi
mov eax, dword [ebx]
add ebx, 4
test eax, eax
jne 0x1018ed56
inc esi
push esi
call dword [sym.imp.mozglue.dll_malloc]
add esp, 4
test eax, eax
je 0x1018edab
mov ebx, eax
mov esi, eax
mov edx, dword [ebp - 0x68]
test edx, edx
jle 0x1018eddf
mov al, byte [ebp - 0x70]
mov byte [ebx], al
cmp edx, 1
jne 0x1018edcd
mov esi, ebx
inc esi
jmp 0x1018eddf
mov dword [ebp - 0x68], 0
mov dword [ebp - 0x6c], 0
jmp 0x1018ee17
xor ecx, ecx
jmp 0x1018ec88
push dword [ebp - 0x78]
call dword [sym.imp.kernel32.dll_FreeEnvironmentStringsA]
push 0
push 0xffffe890
call sym.nss3.dll_PR_SetError
add esp, 8
xor ebx, ebx
mov edi, dword [ebp - 0x74]
jmp 0x1018ef2e
xor eax, eax
inc eax
mov cl, byte [edi + eax]
mov byte [ebx + eax], cl
inc eax
cmp edx, eax
jne 0x1018edd0
mov esi, ebx
add esi, eax
push dword [ebp - 0x78]
call dword [sym.imp.kernel32.dll_FreeEnvironmentStringsA]
mov eax, dword [ebp - 0x6c]
mov ecx, dword [eax]
mov edi, dword [ebp + 0x14]
test ecx, ecx
je 0x1018ee11
mov dl, byte [ecx]
test dl, dl
je 0x1018ee05
inc ecx
mov byte [esi], dl
inc esi
mov dl, byte [ecx]
inc ecx
test dl, dl
jne 0x1018edfb
mov byte [esi], 0
inc esi
mov ecx, dword [eax + 4]
add eax, 4
jmp 0x1018edf0
mov dword [ebp - 0x68], ebx
mov byte [esi], 0
xor esi, esi
xorps xmm0, xmm0
movups xmmword [ebp - 0x20], xmm0
movups xmmword [ebp - 0x30], xmm0
movups xmmword [ebp - 0x40], xmm0
movups xmmword [ebp - 0x50], xmm0
mov dword [ebp - 0x54], 0x44
test edi, edi
je 0x1018ee86
mov ebx, edi
mov edi, dword [sym.imp.kernel32.dll_GetStdHandle]
push 0xfffffffffffffff6
call edi
mov dword [ebp - 0x1c], eax
push 0xfffffffffffffff5
call edi
mov dword [ebp - 0x18], eax
push 0xfffffffffffffff4
call edi
mov edi, ebx
mov dword [ebp - 0x14], eax
mov ecx, dword [ebx]
test ecx, ecx
je 0x1018ee65
mov eax, dword [ecx + 4]
mov eax, dword [eax + 0x18]
mov dword [ebp - 0x1c], eax
mov eax, dword [edi + 4]
test eax, eax
je 0x1018ee8f
mov eax, dword [eax + 4]
mov eax, dword [eax + 0x18]
mov dword [ebp - 0x18], eax
mov edx, dword [edi + 8]
mov eax, 0x8000000
test edx, edx
mov ebx, dword [ebp - 0x68]
jne 0x1018ee9f
jmp 0x1018eea8
xor eax, eax
xor ecx, ecx
mov ebx, dword [ebp - 0x68]
jmp 0x1018eeb2
mov edx, dword [edi + 8]
xor eax, eax
test edx, edx
mov ebx, dword [ebp - 0x68]
je 0x1018ef63
mov ecx, dword [edx + 4]
mov ecx, dword [ecx + 0x18]
mov dword [ebp - 0x14], ecx
mov dword [ebp - 0x28], 0x100
mov ecx, dword [edi + 0xc]
lea edx, [ebp - 0x64]
lea edi, [ebp - 0x54]
push edx
push edi
push ecx
push ebx
push eax
push 1
push esi
push esi
mov edi, dword [ebp - 0x74]
push edi
push esi
call dword [sym.imp.kernel32.dll_CreateProcessA]
test eax, eax
je 0x1018ef1a
push dword [ebp - 0x60]
call dword [sym.imp.kernel32.dll_CloseHandle]
mov eax, dword [ebp - 0x64]
mov esi, dword [ebp - 0x7c]
mov dword [esi], eax
mov eax, dword [ebp - 0x5c]
mov dword [esi + 4], eax
push edi
call dword [sym.imp.mozglue.dll_free]
add esp, 4
cmp dword [ebp - 0x80], 0
je 0x1018ef03
push dword [ebp - 0x6c]
call dword [sym.imp.mozglue.dll_free]
add esp, 4
test ebx, ebx
je 0x1018ebe8
push ebx
call dword [sym.imp.mozglue.dll_free]
add esp, 4
jmp 0x1018ebe8
call dword [sym.imp.kernel32.dll_GetLastError]
push eax
push 0xffffe896
call sym.nss3.dll_PR_SetError
add esp, 8
mov esi, dword [ebp - 0x6c]
push edi
call dword [sym.imp.mozglue.dll_free]
add esp, 4
test esi, esi
je 0x1018ef49
push esi
call dword [sym.imp.mozglue.dll_free]
add esp, 4
test ebx, ebx
mov esi, dword [ebp - 0x7c]
je 0x1018ebdc
push ebx
call dword [sym.imp.mozglue.dll_free]
add esp, 4
jmp 0x1018ebdc
xor eax, eax
test ecx, ecx
jne 0x1018eea8
jmp 0x1018eeaf