Function at 0x61ec47b0
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
sub esp, 0x5c
mov eax, dword [ebp + 0xc]
test eax, eax
je 0x61ec4ea0
mov eax, dword [sym.imp.msvcrt.dll__errno]
mov dword [ebp - 0x3c], eax
call eax
mov eax, dword [eax]
mov dword [esp], sym.libintl_8.dll__nl_state_lock
mov dword [ebp - 0x40], eax
call sym.libintl_8.dll_libintl_rwlock_rdlock_func
test eax, eax
jne 0x61ec4eae
mov edi, dword [ebp + 8]
mov eax, dword [ebp + 8]
test edi, edi
cmove eax, dword [sym.libintl_8.dll_libintl_nl_current_default_domain]
mov dword [ebp + 8], eax
mov eax, dword [0x61ede034]
test eax, eax
je 0x61ec4b60
mov eax, dword [sym.libintl_8.dll_libintl_nl_domain_bindings]
test eax, eax
mov dword [ebp - 0x30], eax
je 0x61ec4dd7
mov ebx, eax
mov esi, dword [ebp + 8]
jmp 0x61ec4830
js 0x61ec4dd0
mov ebx, dword [ebx]
test ebx, ebx
je 0x61ec4df2
lea eax, [ebx + 0xc]
mov dword [esp], esi
mov dword [esp + 4], eax
call sub.msvcrt.dll_strcmp
test eax, eax
jne 0x61ec4820
mov eax, dword [ebx + 4]
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x34], eax
movzx eax, byte [eax]
cmp al, 0x2f
je 0x61ec4924
cmp al, 0x5c
je 0x61ec4924
and eax, 0xffffffdf
sub eax, 0x41
cmp al, 0x19
ja 0x61ec4876
mov eax, dword [ebp - 0x34]
cmp byte [eax + 1], 0x3a
je 0x61ec4924
mov eax, dword [ebp - 0x34]
mov ebx, 0x106
mov dword [esp], eax
call sub.msvcrt.dll_strlen
lea edi, [eax + 1]
mov dword [ebp - 0x2c], edi
mov edi, dword [ebp - 0x3c]
jmp 0x61ec48a4
call edi
cmp dword [eax], 0x22
jne 0x61ec4afa
mov eax, ebx
shr eax, 1
lea ebx, [ebx + eax + 0x20]
mov eax, dword [ebp - 0x2c]
lea eax, [ebx + eax + 0x1e]
shr eax, 4
shl eax, 4
call fcn.61ed0290
sub esp, eax
lea esi, [esp + 0x23]
call edi
and esi, 0xfffffff0
mov dword [eax], 0
mov dword [esp + 4], ebx
mov dword [esp], esi
call sub.msvcrt.dll__getcwd
test eax, eax
je 0x61ec4891
mov dword [esp + 4], 0
mov dword [esp], esi
call sub.msvcrt.dll_strchr
mov ecx, 0x61ed90e9
lea esi, [esi]
add ecx, 1
movzx edx, byte [ecx - 1]
add eax, 1
test dl, dl
mov byte [eax - 1], dl
jne 0x61ec48f0
mov edx, dword [ebp - 0x34]
jmp 0x61ec4913
add eax, 1
add edx, 1
movzx ecx, byte [edx - 1]
test cl, cl
mov byte [eax - 1], cl
jne 0x61ec4910
mov dword [ebp - 0x34], esi
cmp dword [ebp + 0x1c], 3
je 0x61ec4de8
jle 0x61ec4b70
cmp dword [ebp + 0x1c], 5
mov ebx, 0x61ed9116
je 0x61ec4960
mov ebx, 0x61ed910b
jl 0x61ec4960
cmp dword [ebp + 0x1c], 0x6c1
mov ebx, 0x61ed911e
je 0x61ec4960
mov ebx, 0x61ed9131
lea esi, [esi]
mov eax, dword [ebp + 0x1c]
mov dword [esp + 4], ebx
mov dword [esp], eax
call sym.libintl_8.dll__nl_locale_name_posix
test eax, eax
mov edx, eax
mov dword [ebp - 0x2c], 0
je 0x61ec4e44
mov ecx, 2
mov esi, edx
mov edi, 0x61ed913c
repe cmpsb byte [esi], byte es:[edi]
jne 0x61ec4d91
mov eax, dword [ebp + 8]
mov dword [ebp - 0x2c], edx
mov dword [esp], eax
call sub.msvcrt.dll_strlen
mov dword [esp], ebx
mov edi, eax
mov dword [ebp - 0x44], eax
call sub.msvcrt.dll_strlen
lea eax, [edi + eax + 0x23]
shr eax, 4
shl eax, 4
call fcn.61ed0290
mov edx, dword [ebp - 0x2c]
sub esp, eax
lea eax, [esp + 0x23]
and eax, 0xfffffff0
mov dword [ebp - 0x38], eax
mov esi, eax
jmp 0x61ec49d3
mov esi, eax
add ebx, 1
movzx ecx, byte [ebx - 1]
lea eax, [esi + 1]
test cl, cl
mov byte [eax - 1], cl
jne 0x61ec49d1
mov ebx, 0x61ed90e9
jmp 0x61ec49f5
mov esi, eax
add eax, 1
add ebx, 1
movzx ecx, byte [ebx - 1]
test cl, cl
mov byte [eax - 1], cl
jne 0x61ec49f0
mov eax, dword [ebp - 0x44]
mov dword [esp], esi
mov dword [ebp - 0x2c], edx
mov dword [esp + 8], eax
mov eax, dword [ebp + 8]
mov dword [esp + 4], eax
call fcn.61ed0670
mov edx, dword [ebp - 0x2c]
mov ecx, 0x61ed9138
add ecx, 1
movzx ebx, byte [ecx - 1]
add eax, 1
test bl, bl
mov byte [eax - 1], bl
jne 0x61ec4a24
mov dword [esp], edx
mov dword [ebp - 0x48], edx
call sub.msvcrt.dll_strlen
add eax, 0x1f
shr eax, 4
shl eax, 4
call fcn.61ed0290
mov edx, dword [ebp - 0x48]
sub esp, eax
lea ebx, [esp + 0x23]
and ebx, 0xfffffff0
mov dword [ebp - 0x2c], ebx
mov ebx, edx
nop
movzx eax, byte [ebx]
cmp al, 0x3a
je 0x61ec4c25
test al, al
jne 0x61ec4ba0
mov eax, dword [ebp - 0x2c]
mov byte [eax], 0x43
mov byte [eax + 1], 0
mov esi, dword [ebp - 0x2c]
mov ecx, 2
mov edi, 0x61ed913c
repe cmpsb byte [esi], byte es:[edi]
je 0x61ec4afa
mov esi, dword [ebp - 0x2c]
mov edi, str.POSIX
mov ecx, 6
repe cmpsb byte [esi], byte es:[edi]
je 0x61ec4afa
mov eax, dword [ebp - 0x38]
mov esi, dword [ebp - 0x30]
mov dword [esp + 8], eax
mov eax, dword [ebp - 0x2c]
mov dword [esp + 0xc], esi
mov dword [esp + 4], eax
mov eax, dword [ebp - 0x34]
mov dword [esp], eax
call sym.libintl_8.dll__nl_find_domain
test eax, eax
mov edi, eax
je 0x61ec4a60
lea eax, [ebp - 0x1c]
mov dword [esp + 0xc], 1
mov dword [esp + 4], esi
mov dword [esp], edi
mov dword [esp + 0x10], eax
mov eax, dword [ebp + 0xc]
mov dword [esp + 8], eax
call sym.libintl_8.dll__nl_find_msg
test eax, eax
je 0x61ec4c30
cmp eax, 0xffffffff
mov esi, eax
jne 0x61ec4c8b
mov dword [esp], sym.libintl_8.dll__nl_state_lock
call sym.libintl_8.dll_libintl_rwlock_unlock_func
test eax, eax
jne 0x61ec4eae
cmp dword [0x61ede034], 1
je 0x61ec4b30
mov dword [esp], str.GETTEXT_LOG_UNTRANSLATED
call sub.msvcrt.dll_getenv
test eax, eax
je 0x61ec4b30
cmp byte [eax], 0
jne 0x61ec4e13
mov eax, dword [ebp - 0x3c]
call eax
mov edi, dword [ebp - 0x40]
mov dword [eax], edi
mov eax, dword [ebp + 0x14]
test eax, eax
je 0x61ec4e08
cmp dword [ebp + 0x18], 1
je 0x61ec4e08
mov eax, dword [ebp + 0x10]
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov dword [0x61ede034], 0xffffffff
jmp 0x61ec4806
cmp dword [ebp + 0x1c], 1
mov ebx, 0x61ed90eb
je 0x61ec4960
mov ebx, 0x61ed90f6
jg 0x61ec4960
mov esi, dword [ebp + 0x1c]
mov ebx, str.LC_ALL
test esi, esi
je 0x61ec4960
jmp 0x61ec4954
mov edx, dword [ebp - 0x2c]
jmp 0x61ec4ba9
cmp al, 0x3a
je 0x61ec4bb9
add edx, 1
add ebx, 1
mov byte [edx - 1], al
movzx eax, byte [ebx]
test al, al
jne 0x61ec4ba5
cmp dword [0x61ede034], 1
mov byte [edx], 0
jne 0x61ec4a7d
mov eax, dword [ebp - 0x2c]
mov dword [esp + 4], 0x2f
mov dword [esp], eax
call sub.msvcrt.dll_strchr
test eax, eax
jne 0x61ec4a60
mov eax, dword [ebp - 0x2c]
mov dword [esp + 4], 0x5c
mov dword [esp], eax
call sub.msvcrt.dll_strchr
test eax, eax
jne 0x61ec4a60
mov edi, dword [ebp - 0x2c]
movzx eax, byte [edi]
mov byte [ebp - 0x48], al
and eax, 0xffffffdf
sub eax, 0x41
cmp al, 0x19
ja 0x61ec4a7d
cmp byte [edi + 1], 0x3a
jne 0x61ec4a7d
jmp 0x61ec4a60
add ebx, 1
jmp 0x61ec4a60
mov eax, dword [edi + 0x10]
test eax, eax
je 0x61ec4a60
mov dword [ebp - 0x48], ebx
xor esi, esi
mov ebx, dword [ebp - 0x30]
jmp 0x61ec4c54
add esi, 1
mov eax, dword [edi + esi*4 + 0x10]
test eax, eax
je 0x61ec4e3c
lea ecx, [ebp - 0x1c]
mov dword [esp + 0xc], 1
mov dword [esp + 4], ebx
mov dword [esp], eax
mov dword [esp + 0x10], ecx
mov ecx, dword [ebp + 0xc]
mov dword [esp + 8], ecx
call sym.libintl_8.dll__nl_find_msg
cmp eax, 0xffffffff
je 0x61ec4afa
test eax, eax
je 0x61ec4c45
mov ecx, esi
mov esi, eax
mov edi, dword [edi + ecx*4 + 0x10]
mov eax, dword [ebp + 0xc]
mov dword [esp], eax
call sub.msvcrt.dll_strlen
lea edx, [eax + 1]
mov eax, dword [ebp - 0x44]
mov dword [ebp - 0x2c], edx
lea eax, [edx + eax + 0x19]
mov dword [esp], eax
call sub.msvcrt.dll_malloc
test eax, eax
mov ebx, eax
je 0x61ec4d61
mov ecx, dword [ebp + 0xc]
mov edx, dword [ebp - 0x2c]
lea eax, [eax + 0x18]
mov dword [esp], eax
mov dword [esp + 4], ecx
mov dword [esp + 8], edx
call fcn.61ed0670
mov edx, eax
mov eax, dword [ebp - 0x44]
mov dword [esp], edx
mov dword [ebp - 0x2c], edx
add eax, 1
mov dword [esp + 8], eax
mov eax, dword [ebp + 8]
mov dword [esp + 4], eax
call sub.msvcrt.dll_memcpy
mov eax, dword [ebp + 0x1c]
mov edx, dword [ebp - 0x2c]
mov dword [ebx + 0xc], edi
mov dword [ebx + 0x10], esi
mov dword [ebx + 4], eax
mov eax, dword [sym.libintl_8.dll__nl_msg_cat_cntr]
mov dword [ebx], edx
mov dword [ebx + 8], eax
mov eax, dword [ebp - 0x1c]
mov dword [ebx + 0x14], eax
mov dword [esp], 0x61ed8140
call sym.libintl_8.dll_libintl_rwlock_wrlock_func
test eax, eax
jne 0x61ec4eae
mov dword [esp + 8], 0x61ec3fa0
mov dword [esp + 4], 0x61ede038
mov dword [esp], ebx
call fcn.61ed06e0
mov dword [esp], 0x61ed8140
mov dword [ebp - 0x2c], eax
call sym.libintl_8.dll_libintl_rwlock_unlock_func
test eax, eax
jne 0x61ec4eae
mov edx, dword [ebp - 0x2c]
test edx, edx
je 0x61ec4d59
cmp ebx, dword [edx]
je 0x61ec4d61
mov dword [esp], ebx
call sub.msvcrt.dll_free
mov eax, dword [ebp - 0x3c]
call eax
mov edx, dword [ebp + 0x14]
mov ecx, dword [ebp - 0x40]
test edx, edx
mov dword [eax], ecx
jne 0x61ec4e57
mov dword [esp], sym.libintl_8.dll__nl_state_lock
call sym.libintl_8.dll_libintl_rwlock_unlock_func
test eax, eax
jne 0x61ec4eae
mov eax, esi
jmp 0x61ec4b52
mov dword [esp], str.LANGUAGE
mov dword [ebp - 0x38], edx
call sub.msvcrt.dll_getenv
test eax, eax
mov edx, dword [ebp - 0x38]
je 0x61ec4dac
cmp byte [eax], 0
jne 0x61ec4e01
mov ecx, dword [ebp - 0x2c]
test ecx, ecx
je 0x61ec4994
mov dword [ebp - 0x2c], edx
call sym.libintl_8.dll__nl_language_preferences_default
mov edx, dword [ebp - 0x2c]
test eax, eax
cmovne edx, eax
jmp 0x61ec4994
mov dword [ebp - 0x30], 0
cmp dword [ebp + 0x1c], 3
mov dword [ebp - 0x34], sym.libintl_8.dll_libintl_nl_default_dirname
jne 0x61ec492e
mov ebx, 0x61ed90ff
jmp 0x61ec4960
mov dword [ebp - 0x30], ebx
mov dword [ebp - 0x34], sym.libintl_8.dll_libintl_nl_default_dirname
jmp 0x61ec4924
mov edx, eax
jmp 0x61ec4994
mov eax, dword [ebp + 0xc]
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
mov edi, dword [ebp + 0x14]
mov dword [esp], eax
mov dword [esp + 0x10], edi
mov edi, dword [ebp + 0x10]
mov dword [esp + 0xc], edi
mov edi, dword [ebp + 0xc]
mov dword [esp + 8], edi
mov edi, dword [ebp + 8]
mov dword [esp + 4], edi
call sym.libintl_8.dll__nl_log_untranslated
jmp 0x61ec4b30
mov ebx, dword [ebp - 0x48]
jmp 0x61ec4a60
call sym.libintl_8.dll__nl_locale_name_default
mov dword [ebp - 0x2c], 1
mov edx, eax
jmp 0x61ec4980
mov ebx, dword [edi + 8]
mov edx, dword [ebp + 0x18]
mov eax, dword [ebx + 0x84]
call fcn.61ec3e30
cmp eax, dword [ebx + 0x88]
jae 0x61ec4d76
mov ebx, dword [ebp - 0x1c]
mov edi, eax
mov eax, esi
add ebx, esi
test edi, edi
je 0x61ec4ea7
mov dword [esp + 4], 0
mov dword [esp], eax
sub edi, 1
call sub.msvcrt.dll_strchr
add eax, 1
cmp eax, ebx
jb 0x61ec4e7d
jmp 0x61ec4d76
xor eax, eax
jmp 0x61ec4b52
mov esi, eax
jmp 0x61ec4d76
call sub.msvcrt.dll_abort
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop
nop