Function at 0x100bc180
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x22c
mov eax, dword [0x101a0040]
xor eax, ebp
mov dword [ebp - 4], eax
mov eax, dword [ebp + 0xc]
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
mov esi, ecx
push str._5_4
push edi
push str._s_s
push esi
mov dword [ebp - 0x22c], edx
mov dword [ebp - 0x220], eax
call fcn.100a6230
push eax
call dword [sym.imp.api_ms_win_crt_environment_l1_1_0.dll_getenv]
mov ebx, eax
add esp, 0x14
mov dword [ebp - 0x228], ebx
test ebx, ebx
jne 0x100bc1eb
push edi
call dword [sym.imp.api_ms_win_crt_environment_l1_1_0.dll_getenv]
mov ebx, eax
mov dword [ebp - 0x228], eax
add esp, 4
test ebx, ebx
je 0x100bc482
mov edx, dword [esi + 0x10]
mov ecx, esi
add edx, 0x28
push str.LUA_NOENV
call fcn.100a6330
mov edx, dword [esi + 0xc]
add esp, 4
mov ecx, dword [esi + 0x14]
add edx, 0xfffffff0
mov al, byte [edx + 8]
cmp al, 1
je 0x100bc21b
test al, 0xf
je 0x100bc21b
mov edi, 1
jmp 0x100bc21d
xor edi, edi
cmp word [ecx + 0x20], 0xffff
jge 0x100bc230
push 0
mov ecx, esi
call fcn.100b4250
add esp, 4
add dword [esi + 0xc], 0xfffffff0
test edi, edi
jne 0x100bc482
push 0x10180330
push ebx
call dword [sym.imp.VCRUNTIME140.dll_strstr]
mov edx, eax
add esp, 8
mov dword [ebp - 0x21c], edx
test edx, edx
jne 0x100bc26d
test ebx, ebx
jne 0x100bc266
mov eax, dword [esi + 0xc]
mov byte [eax + 8], bl
jmp 0x100bc4ab
mov edx, ebx
jmp 0x100bc497
mov edi, ebx
lea ecx, [edi + 1]
mov al, byte [edi]
inc edi
test al, al
jne 0x100bc272
sub edi, ecx
mov dword [ebp - 0x20c], esi
xor ecx, ecx
mov dword [ebp - 0x214], 0x200
mov dword [ebp - 0x210], ecx
lea eax, [ebp - 0x208]
mov dword [ebp - 0x218], eax
cmp ebx, edx
jae 0x100bc31d
mov eax, edx
sub eax, ebx
mov dword [ebp - 0x224], eax
je 0x100bc306
push 0xffffffffffffffff
mov edx, eax
lea ecx, [ebp - 0x218]
call fcn.100a85d0
add esp, 4
push dword [ebp - 0x224]
push ebx
push eax
call sub.VCRUNTIME140.dll_memcpy
mov ecx, dword [ebp - 0x210]
add esp, 0xc
add ecx, dword [ebp - 0x224]
mov dword [ebp - 0x210], ecx
cmp ecx, dword [ebp - 0x214]
jb 0x100bc306
push 0xffffffffffffffff
mov edx, 1
lea ecx, [ebp - 0x218]
call fcn.100a85d0
mov ecx, dword [ebp - 0x210]
add esp, 4
mov eax, dword [ebp - 0x218]
mov byte [eax + ecx], 0x3b
mov ecx, dword [ebp - 0x210]
inc ecx
mov dword [ebp - 0x210], ecx
mov ebx, dword [ebp - 0x220]
lea edx, [ebx + 1]
mov al, byte [ebx]
inc ebx
test al, al
jne 0x100bc326
sub ebx, edx
je 0x100bc361
push 0xffffffffffffffff
mov edx, ebx
lea ecx, [ebp - 0x218]
call fcn.100a85d0
add esp, 4
push ebx
push dword [ebp - 0x220]
push eax
call sub.VCRUNTIME140.dll_memcpy
mov ecx, dword [ebp - 0x210]
add esp, 0xc
add ecx, ebx
mov dword [ebp - 0x210], ecx
mov ebx, dword [ebp - 0x228]
lea eax, [ebx - 2]
add eax, edi
cmp dword [ebp - 0x21c], eax
jae 0x100bc3ef
cmp ecx, dword [ebp - 0x214]
jb 0x100bc397
push 0xffffffffffffffff
mov edx, 1
lea ecx, [ebp - 0x218]
call fcn.100a85d0
mov ecx, dword [ebp - 0x210]
add esp, 4
mov eax, dword [ebp - 0x218]
sub edi, dword [ebp - 0x21c]
add edi, 0xfffffffe
mov byte [eax + ecx], 0x3b
mov ecx, dword [ebp - 0x210]
inc ecx
mov dword [ebp - 0x210], ecx
add edi, ebx
je 0x100bc3ef
push 0xffffffffffffffff
mov edx, edi
lea ecx, [ebp - 0x218]
call fcn.100a85d0
mov ecx, dword [ebp - 0x21c]
add esp, 4
add ecx, 2
push edi
push ecx
push eax
call sub.VCRUNTIME140.dll_memcpy
mov ecx, dword [ebp - 0x210]
add esp, 0xc
add ecx, edi
mov dword [ebp - 0x210], ecx
mov edi, dword [ebp - 0x20c]
test ecx, ecx
jne 0x100bc407
mov edx, 0x10170b03
mov ecx, edi
call fcn.100c69e0
jmp 0x100bc41c
mov edx, dword [ebp - 0x218]
push ecx
mov ecx, dword [ebp - 0x20c]
call fcn.100c6950
add esp, 4
mov ecx, dword [edi + 0xc]
mov dword [ecx], eax
mov al, byte [eax + 4]
or al, 0x40
mov byte [ecx + 8], al
mov eax, dword [edi + 0x10]
add dword [edi + 0xc], 0x10
cmp dword [eax + 0xc], 0
jle 0x100bc43d
mov ecx, edi
call fcn.100b6310
lea eax, [ebp - 0x208]
cmp dword [ebp - 0x218], eax
je 0x100bc4bf
mov edx, dword [edi + 0xc]
mov eax, dword [edx - 0x10]
mov ecx, dword [edx - 0xc]
mov dword [edx - 0x30], eax
mov dword [edx - 0x2c], ecx
mov al, byte [edx - 8]
mov byte [edx - 0x28], al
mov eax, dword [edi + 0x14]
cmp word [eax + 0x20], 0xffff
jge 0x100bc47c
mov edx, dword [edi + 0xc]
mov ecx, edi
push 0
sub edx, 0x20
call fcn.100b4250
add esp, 4
add dword [edi + 0xc], 0xffffffe0
jmp 0x100bc4bf
mov eax, dword [ebp - 0x220]
test eax, eax
jne 0x100bc495
mov eax, dword [esi + 0xc]
mov byte [eax + 8], 0
jmp 0x100bc4ab
mov edx, eax
mov ecx, esi
call fcn.100c69e0
mov ecx, dword [esi + 0xc]
mov dword [ecx], eax
mov al, byte [eax + 4]
or al, 0x40
mov byte [ecx + 8], al
mov eax, dword [esi + 0x10]
add dword [esi + 0xc], 0x10
cmp dword [eax + 0xc], 0
jle 0x100bc4bf
mov ecx, esi
call fcn.100b6310
mov edx, dword [esi + 0xc]
mov ecx, esi
push dword [ebp - 0x22c]
sub edx, 0x30
call fcn.100a6540
mov eax, dword [esi + 0x14]
add esp, 4
cmp word [eax + 0x20], 0xffff
jge 0x100bc4f1
mov edx, dword [esi + 0xc]
mov ecx, esi
push 0
sub edx, 0x10
call fcn.100b4250
add esp, 4
add dword [esi + 0xc], 0xfffffff0
mov ecx, dword [ebp - 4]
pop edi
pop esi
xor ecx, ebp
pop ebx
call fcn.1013c175
mov esp, ebp
pop ebp
ret