Function at 0x10002b80
Capabilities:
Query environment variable

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
sub esp, 0x444
mov dword [ebp - 0x1c], esp
mov dword [ebp - 0x10], 0xffffffff
mov dword [ebp - 0x14], 0x1000b070
mov edi, dword [ebp + 8]
mov eax, dword [ebp + 0x10]
mov edx, dword [ebp + 0xc]
lea ecx, [ebp - 0x18]
mov esi, dword fs:[0]
mov dword [ebp - 0x18], esi
mov dword fs:[0], ecx
lea ecx, [ebp - 0x450]
push eax
call fcn.10009f00
add esp, 4
mov eax, dword [ebp - 0x450]
cmp eax, 0x80000000
jne 0x10002bec
lea ecx, [ebp - 0x450]
call fcn.10001b40
mov dword [edi], getpeername
jmp 0x10002dc4
mov ecx, dword [ebp - 0x44c]
mov esi, 0x200
mov dword [ebp - 0x40], 0
mov dword [ebp - 0x3c], 2
mov dword [ebp - 0x2c], eax
mov dword [ebp - 0x38], 0
mov dword [ebp - 0x24], 0
mov dword [ebp - 0x30], 2
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x34], ecx
cmp esi, 0x201
jae 0x10002c60
jmp 0x10002c4e
jbe 0x10002cf7
cmp esi, 0x201
jae 0x10002c60
mov dword [ebp - 0x28], 0x200
lea ebx, [ebp - 0x450]
mov edi, esi
jmp 0x10002c9b
mov edi, dword [ebp - 0x24]
mov eax, dword [ebp - 0x20]
sub esi, edi
sub eax, edi
cmp eax, esi
jae 0x10002c8c
mov dword [ebp - 0x10], 2
lea ecx, [ebp - 0x40]
mov edx, edi
push esi
call fcn.101f12c0
add esp, 4
mov edi, dword [ebp - 0x40]
mov eax, dword [ebp - 0x3c]
mov dword [ebp - 0x30], eax
mov ebx, dword [ebp - 0x30]
mov dword [ebp - 0x38], edi
mov dword [ebp - 0x20], edi
mov dword [ebp - 0x28], edi
mov dword [ebp - 0x24], edi
push 0
call dword [sym.imp.kernel32.dll_SetLastError]
push edi
push ebx
push dword [ebp - 0x34]
call dword [sym.imp.kernel32.dll_GetEnvironmentVariableW]
mov esi, eax
test eax, eax
jne 0x10002cc2
call dword [sym.imp.kernel32.dll_GetLastError]
test eax, eax
jne 0x10002dda
cmp esi, edi
jne 0x10002c40
call dword [sym.imp.kernel32.dll_GetLastError]
cmp eax, 0x7a
jne 0x10002df9
lea esi, [edi + edi]
test edi, edi
mov eax, 0xffffffff
cmovs esi, eax
cmp esi, 0x201
jb 0x10002c4e
jmp 0x10002c60
mov eax, dword [ebp - 0x28]
mov dword [ebp - 0x10], 2
cmp esi, eax
ja 0x10002e16
lea eax, [ebp - 0x50]
push esi
push ebx
push eax
call fcn.10003dc0
add esp, 0xc
mov eax, dword [ebp - 0x44]
mov esi, dword [ebp - 0x50]
mov ebx, dword [ebp - 0x4c]
mov ecx, dword [ebp - 0x48]
mov dword [ebp - 0x20], eax
mov eax, dword [ebp - 0x24]
test eax, eax
je 0x10002d41
add eax, eax
push 2
push eax
push dword [ebp - 0x30]
mov edi, ecx
call fcn.10001010
mov ecx, edi
add esp, 0xc
mov edi, dword [ebp + 8]
cmp esi, 0x80000000
jne 0x10002d9f
cmp bl, 3
mov dword [edi], getpeername
jne 0x10002dad
mov eax, dword [ecx]
mov dword [ebp - 0x20], ecx
mov ecx, dword [ecx + 4]
mov dword [ebp - 0x10], 1
mov dword [ebp - 0x28], eax
push eax
mov dword [ebp - 0x24], ecx
call dword [ecx]
add esp, 4
mov ecx, dword [ebp - 0x24]
mov eax, dword [ecx + 4]
test eax, eax
je 0x10002d8b
push dword [ecx + 8]
push eax
push dword [ebp - 0x28]
call fcn.10001010
add esp, 0xc
push 4
push 0xc
push dword [ebp - 0x20]
call fcn.10001010
add esp, 0xc
mov edi, dword [ebp + 8]
jmp 0x10002dad
mov eax, dword [ebp - 0x20]
mov dword [edi], esi
mov dword [edi + 4], ebx
mov dword [edi + 8], ecx
mov dword [edi + 0xc], eax
mov eax, dword [ebp - 0x2c]
test eax, eax
je 0x10002dc4
add eax, eax
push 2
push eax
push dword [ebp - 0x34]
call fcn.10001010
add esp, 0xc
mov eax, dword [ebp - 0x18]
mov dword fs:[0], eax
mov eax, edi
add esp, 0x444
pop esi
pop edi
pop ebx
pop ebp
ret
xor ebx, ebx
mov esi, closesocket
call dword [sym.imp.kernel32.dll_GetLastError]
mov ecx, eax
mov eax, dword [ebp - 0x24]
test eax, eax
jne 0x10002d2d
jmp 0x10002d41
mov dword [ebp - 0x10], 2
push 0x1029b6f4
push 0x28
push 0x1029a804
call fcn.101f16d0
add esp, 0xc
jmp 0x10002e25
push 0x1029b6e4
push eax
push esi
call fcn.101f1a50
add esp, 0xc
ud2