Function at 0x408bd0
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push edi
push esi
push ebx
lea eax, [ebp - 0x18]
sub esp, 0x9c
mov dword [ebp - 0x48], eax
mov dword [ebp - 0x40], esp
lea eax, [ebp - 0x68]
sub esp, 0xc
mov dword [ebp - 0x50], sym.___gxx_personality_sj0
push eax
mov dword [ebp - 0x4c], 0x437ed5
mov dword [ebp - 0x44], 0x4093c2
call sym.__Unwind_SjLj_Register
mov edi, dword [ebp + 0xc]
add esp, 0x10
test edi, edi
je 0x409337
mov esi, dword [0x43f750]
test esi, esi
je 0x409326
cld
mov esi, dword [ebp + 0xc]
mov edi, 0x408b7d
mov ecx, 2
repe cmpsb byte [esi], byte es:[edi]
je 0x408ce0
mov esi, dword [ebp + 0xc]
mov edi, 0x408b7f
mov ecx, 6
repe cmpsb byte [esi], byte es:[edi]
je 0x408ce0
mov eax, dword [ebp + 0xc]
cmp byte [eax], 0
je 0x408ca1
sub esp, 0xc
mov dword [ebp - 0x64], 0xffffffff
push 0x24
call sym.operator_new_unsigned_int_
mov ebx, dword [ebp + 0xc]
add esp, 0xc
mov dword [ebp - 0x70], eax
push 1
push ebx
push eax
mov dword [ebp - 0x64], 5
call sym.std::locale::_Impl::_Impl_char_const__unsigned_int_
mov edx, dword [ebp + 8]
mov eax, dword [ebp - 0x70]
mov dword [edx], eax
add esp, 0x10
sub esp, 0xc
lea eax, [ebp - 0x68]
push eax
call sym.__Unwind_SjLj_Unregister
add esp, 0x10
lea esp, [ebp - 0xc]
pop ebx
pop esi
pop edi
pop ebp
ret
sub esp, 0xc
push 0x408b85
call sym._getenv
add esp, 0x10
test eax, eax
mov dword [ebp - 0x74], eax
je 0x408d30
cmp byte [eax], 0
je 0x408d30
cld
mov esi, eax
mov edi, 0x408b7d
mov ecx, 2
repe cmpsb byte [esi], byte es:[edi]
je 0x408ce0
mov esi, dword [ebp - 0x74]
mov edi, 0x408b7f
mov ecx, 6
repe cmpsb byte [esi], byte es:[edi]
jne 0x408cf4
nop
mov edx, dword [ebp + 8]
mov eax, dword [0x43f750]
mov dword [edx], eax
mov edx, 1
lock add dword [eax], edx
jmp 0x408c8a
sub esp, 0xc
mov dword [ebp - 0x64], 0xffffffff
push 0x24
call sym.operator_new_unsigned_int_
mov edx, dword [ebp - 0x74]
add esp, 0xc
mov dword [ebp - 0x78], eax
push 1
push edx
push eax
mov dword [ebp - 0x64], 4
call sym.std::locale::_Impl::_Impl_char_const__unsigned_int_
mov eax, dword [ebp + 8]
mov edx, dword [ebp - 0x78]
mov dword [eax], edx
jmp 0x408c87
sub esp, 0xc
push 0x408b8c
call sym._getenv
add esp, 0x10
test eax, eax
mov dword [ebp - 0x80], eax
je 0x408d72
cmp byte [eax], 0
je 0x408d72
cld
mov esi, eax
mov edi, 0x408b7d
mov ecx, 2
repe cmpsb byte [esi], byte es:[edi]
je 0x408d72
mov esi, dword [ebp - 0x80]
mov edi, 0x408b7f
mov ecx, 6
repe cmpsb byte [esi], byte es:[edi]
jne 0x40931a
sub esp, 0xc
push 0x408b7d
mov dword [ebp - 0x64], 0xffffffff
mov edi, 0x408b7d
call sym._strdup
cld
mov dword [ebp - 0x7c], eax
mov ecx, 2
mov dword [ebp - 0x84], 0
mov esi, dword [ebp - 0x7c]
add esp, 0x10
repe cmpsb byte [esi], byte es:[edi]
jne 0x4092b8
lea esi, [esi]
mov eax, dword [ebp - 0x84]
sub esp, 0xc
mov eax, dword [eax*4 + 0x4390a0]
push eax
call sym._getenv
add esp, 0x10
test eax, eax
mov dword [ebp - 0x80], eax
je 0x408dfb
cmp byte [eax], 0
je 0x408dfb
cld
mov esi, eax
mov edi, 0x408b7d
mov ecx, 2
repe cmpsb byte [esi], byte es:[edi]
je 0x408dfb
mov esi, dword [ebp - 0x80]
mov edi, 0x408b7f
mov ecx, 6
repe cmpsb byte [esi], byte es:[edi]
jne 0x408e83
mov eax, dword [ebp - 0x84]
inc eax
mov dword [ebp - 0x84], eax
cmp dword [ebp - 0x84], 5
jbe 0x408db0
cld
mov esi, dword [ebp - 0x7c]
mov edi, 0x408b7d
mov ecx, 2
repe cmpsb byte [esi], byte es:[edi]
jne 0x408e46
mov edx, dword [ebp + 8]
mov eax, dword [0x43f750]
mov dword [edx], eax
mov edx, 1
lock add dword [eax], edx
sub esp, 0xc
mov ecx, dword [ebp - 0x7c]
push ecx
call sym._free
jmp 0x408c87
sub esp, 0xc
mov dword [ebp - 0x64], 0xffffffff
push 0x24
call sym.operator_new_unsigned_int_
mov edi, dword [ebp - 0x7c]
add esp, 0xc
mov dword [ebp - 0xa4], eax
push 1
push edi
push eax
mov dword [ebp - 0x64], 1
call sym.std::locale::_Impl::_Impl_char_const__unsigned_int_
mov eax, dword [ebp + 8]
mov edx, dword [ebp - 0xa4]
mov dword [eax], edx
add esp, 0x10
jmp 0x408e35
cmp dword [ebp - 0x84], 5
ja 0x408e11
mov eax, 1
lock add dword [0x43f7f8], eax
mov dword [ebp - 0x88], 0
mov eax, dword [ebp - 0x84]
mov dword [ebp - 0x28], 0x43f7fc
cmp dword [ebp - 0x88], eax
jae 0x408f6b
mov edx, dword [ebp - 0x88]
sub esp, 0xc
mov edx, dword [edx*4 + 0x4390a0]
push edx
mov dword [ebp - 0x8c], edx
call sym._strlen
mov ecx, dword [ebp - 0x8c]
add esp, 0xc
mov dword [ebp - 0x64], 3
push eax
lea eax, [ebp - 0x28]
push ecx
push eax
call method.std::string.append_char_const__unsigned_int_
mov dword [esp], 0x408b91
call sym._strlen
add esp, 0xc
lea edx, [ebp - 0x28]
push eax
push 0x408b91
push edx
call method.std::string.append_char_const__unsigned_int_
pop edx
mov eax, dword [ebp - 0x7c]
push eax
call sym._strlen
add esp, 0xc
push eax
mov eax, dword [ebp - 0x7c]
push eax
lea eax, [ebp - 0x28]
push eax
call method.std::string.append_char_const__unsigned_int_
mov dword [esp], 0x408b93
call sym._strlen
add esp, 0xc
lea edx, [ebp - 0x28]
push eax
push 0x408b93
push edx
call method.std::string.append_char_const__unsigned_int_
mov eax, dword [ebp - 0x88]
add esp, 0x10
inc eax
mov dword [ebp - 0x88], eax
mov eax, dword [ebp - 0x84]
cmp dword [ebp - 0x88], eax
jb 0x408ebb
mov edx, dword [ebp - 0x84]
sub esp, 0xc
mov edx, dword [edx*4 + 0x4390a0]
push edx
mov dword [ebp - 0x90], edx
call sym._strlen
add esp, 0xc
mov dword [ebp - 0x64], 3
push eax
mov eax, dword [ebp - 0x90]
push eax
lea eax, [ebp - 0x28]
push eax
call method.std::string.append_char_const__unsigned_int_
mov dword [esp], 0x408b91
call sym._strlen
add esp, 0xc
lea edx, [ebp - 0x28]
push eax
push 0x408b91
push edx
call method.std::string.append_char_const__unsigned_int_
pop eax
mov eax, dword [ebp - 0x80]
push eax
call sym._strlen
mov edi, dword [ebp - 0x80]
add esp, 0xc
push eax
lea eax, [ebp - 0x28]
push edi
push eax
call method.std::string.append_char_const__unsigned_int_
mov dword [esp], 0x408b93
call sym._strlen
add esp, 0xc
lea edx, [ebp - 0x28]
push eax
push 0x408b93
push edx
call method.std::string.append_char_const__unsigned_int_
mov esi, dword [ebp - 0x84]
add esp, 0x10
inc esi
mov dword [ebp - 0x84], esi
cmp dword [ebp - 0x84], 5
ja 0x4090d0
mov eax, dword [ebp - 0x84]
mov edx, 0x4390a0
sub esp, 0xc
mov ebx, dword [edx + eax*4]
push ebx
call sym._getenv
add esp, 0x10
test eax, eax
mov dword [ebp - 0x80], eax
je 0x409040
cmp byte [eax], 0
jne 0x4091ab
mov edx, 0x4390a0
mov eax, dword [ebp - 0x84]
sub esp, 0xc
mov eax, dword [edx + eax*4]
push eax
mov dword [ebp - 0x94], eax
call sym._strlen
lea edx, [ebp - 0x28]
add esp, 0xc
mov ecx, dword [ebp - 0x94]
mov dword [ebp - 0x64], 3
push eax
push ecx
push edx
call method.std::string.append_char_const__unsigned_int_
add esp, 0xc
lea eax, [ebp - 0x28]
push 0x3d
push 1
push eax
call method.std::string.append_unsigned_int__char_
pop edx
mov eax, dword [ebp - 0x7c]
push eax
call sym._strlen
lea edx, [ebp - 0x28]
add esp, 0xc
push eax
mov eax, dword [ebp - 0x7c]
push eax
push edx
call method.std::string.append_char_const__unsigned_int_
add esp, 0xc
lea eax, [ebp - 0x28]
push 0x3b
push 1
push eax
call method.std::string.append_unsigned_int__char_
mov esi, dword [ebp - 0x84]
add esp, 0x10
inc esi
mov dword [ebp - 0x84], esi
cmp dword [ebp - 0x84], 5
jbe 0x409016
mov eax, dword [ebp - 0x28]
sub eax, 0xc
mov eax, dword [eax + 8]
shr eax, 0x1f
test al, al
je 0x409190
mov edx, dword [ebp - 0x28]
sub esp, 0xc
mov ecx, edx
mov ebx, dword [edx - 0xc]
push 0
add ecx, ebx
push edx
mov dword [ebp - 0x64], 3
lea eax, [ecx - 1]
mov ebx, eax
sub ecx, eax
push ecx
sub ebx, edx
push ebx
lea eax, [ebp - 0x28]
push eax
call method.std::string.replace_unsigned_int__unsigned_int__char_const__unsigned_int_
mov eax, dword [ebp - 0x28]
add esp, 0x14
sub eax, 0xc
mov dword [eax + 8], 0xffffffff
push 0x24
call sym.operator_new_unsigned_int_
mov dword [ebp - 0xa0], eax
add esp, 0xc
mov eax, dword [ebp - 0x28]
mov edx, dword [eax - 0xc]
add eax, edx
mov dl, byte [0x42b584]
mov byte [eax], dl
push 1
mov eax, dword [ebp - 0x28]
push eax
mov eax, dword [ebp - 0xa0]
push eax
mov dword [ebp - 0x64], 2
call sym.std::locale::_Impl::_Impl_char_const__unsigned_int_
mov edx, dword [ebp + 8]
mov eax, dword [ebp - 0xa0]
add esp, 0x10
lea ebx, [ebp - 0x38]
mov dword [edx], eax
or eax, 0xffffffff
mov edx, dword [ebp - 0x28]
lea ecx, [edx - 0xc]
lock xadd dword [edx - 4], eax
mov dword [ebp - 0x3c], eax
test eax, eax
jg 0x408e35
push eax
push eax
push ebx
push ecx
call method.std::string::_Rep._M_destroy_std::allocator_char__const_
jmp 0x408e7e
sub esp, 0xc
lea edx, [ebp - 0x28]
mov dword [ebp - 0x64], 3
push edx
call fcn.0042adf0
add esp, 0x10
jmp 0x4090e4
cld
mov esi, dword [ebp - 0x80]
mov edi, 0x408b7d
mov ecx, 2
repe cmpsb byte [esi], byte es:[edi]
je 0x4091ce
mov esi, dword [ebp - 0x80]
mov edi, 0x408b7f
mov ecx, 6
repe cmpsb byte [esi], byte es:[edi]
jne 0x409229
mov edx, dword [ebp - 0x84]
mov eax, 0x4390a0
sub esp, 0xc
mov edx, dword [eax + edx*4]
push edx
mov dword [ebp - 0x98], edx
call sym._strlen
add esp, 0xc
mov dword [ebp - 0x64], 3
push eax
mov eax, dword [ebp - 0x98]
push eax
lea eax, [ebp - 0x28]
push eax
call method.std::string.append_char_const__unsigned_int_
mov dword [esp], 0x408b95
call sym._strlen
add esp, 0xc
lea edx, [ebp - 0x28]
push eax
push 0x408b95
push edx
call method.std::string.append_char_const__unsigned_int_
jmp 0x4090b3
mov edx, 0x4390a0
mov eax, dword [ebp - 0x84]
sub esp, 0xc
mov eax, dword [edx + eax*4]
push eax
mov dword [ebp - 0x9c], eax
call sym._strlen
lea edx, [ebp - 0x28]
add esp, 0xc
mov dword [ebp - 0x64], 3
push eax
mov eax, dword [ebp - 0x9c]
push eax
push edx
call method.std::string.append_char_const__unsigned_int_
mov dword [esp], 0x408b91
call sym._strlen
add esp, 0xc
push eax
lea eax, [ebp - 0x28]
push 0x408b91
push eax
call method.std::string.append_char_const__unsigned_int_
pop eax
mov eax, dword [ebp - 0x80]
push eax
call sym._strlen
lea edx, [ebp - 0x28]
add esp, 0xc
mov edi, dword [ebp - 0x80]
push eax
push edi
push edx
call method.std::string.append_char_const__unsigned_int_
mov dword [esp], 0x408b93
call sym._strlen
add esp, 0xc
push eax
lea eax, [ebp - 0x28]
push 0x408b93
push eax
jmp 0x40921f
mov dword [ebp - 0x84], 0
mov edx, dword [ebp - 0x84]
sub esp, 0xc
mov eax, dword [edx*4 + 0x4390a0]
push eax
call sym._getenv
add esp, 0x10
test eax, eax
mov dword [ebp - 0x80], eax
je 0x4092e7
cmp byte [eax], 0
jne 0x409302
mov ebx, dword [ebp - 0x84]
inc ebx
mov dword [ebp - 0x84], ebx
cmp dword [ebp - 0x84], 5
jbe 0x4092c2
jmp 0x408e11
mov esi, dword [ebp - 0x7c]
push edi
push edi
push esi
push eax
call sym._strcmp
add esp, 0x10
test eax, eax
je 0x4092e7
jmp 0x408e83
sub esp, 0xc
mov eax, dword [ebp - 0x80]
push eax
jmp 0x408d7a
mov dword [ebp - 0x64], 0xffffffff
call method.std::locale.classic__
jmp 0x408c22
sub esp, 0xc
mov dword [ebp - 0x64], 0xffffffff
push 0x408ba0
call method.std.__throw_runtime_error_char_const_
jmp 0x408c87