Function at 0x49a520
Capabilities:
Get hostname
Query environment variable
Resolve function by parsing pe exports

Disassembly:
sub esp, 0x14
call fcn.0049a470
test eax, eax
je 0x49a535
mov eax, 0x15
add esp, 0x14
ret
push esi
push 0x91c8
call dword [0x6127b4]
mov esi, eax
add esp, 4
mov dword [esp + 0x14], esi
test esi, esi
jne 0x49a55c
mov eax, dword [esp + 0x1c]
mov dword [eax], esi
lea eax, [esi + 0xf]
pop esi
add esp, 0x14
ret
push ebx
push edi
call fcn.0049ffb0
mov dword [esp + 0x18], edx
xorps xmm0, xmm0
cdq
mov dword [esi + 0x188], eax
lea eax, [esi + 0x194]
mov dword [esi], 0xffffffff
mov dword [esi + 4], 0xffffffff
mov dword [esi + 8], 0xffffffff
mov dword [esi + 0xc], 0xffffffff
mov dword [esi + 0x10], 0xffffffff
mov dword [esi + 0x14], 0xffffffff
mov dword [esi + 0x18], 0xffffffff
mov dword [esi + 0x38], 0xffffffff
mov dword [esi + 0x1c], 0xffffffff
mov dword [esi + 0x20], 0xffffffff
mov dword [esi + 0x78], 0xffffffff
mov dword [esi + 0x28], 0xffffffff
mov dword [esi + 0x30], 0xffffffff
mov dword [esi + 0x180], 0
mov dword [esi + 0x34], 0
mov dword [esi + 0x24], 0
mov dword [esi + 0x2c], 0
mov dword [esi + 0x74], 0
mov dword [esi + 0x91a0], 0
mov dword [esi + 0x91a4], 0
mov dword [esi + 0x91a8], 0
mov dword [esi + 0x91ac], 0
mov dword [esi + 0x91b0], 0
mov dword [esi + 0x91b4], 0
mov dword [esi + 0x91b8], 0
mov dword [esi + 0x91bc], 0
mov dword [esi + 0x91c0], 0
mov dword [esi + 0x190], 0
mov dword [esi + 0x18c], edx
movups xmmword [esi + 0x3c], xmm0
push eax
movups xmmword [esi + 0x4c], xmm0
mov dword [esi + 0x5c], 0
movups xmmword [esi + 0x60], xmm0
call fcn.0049f8e0
add esp, 4
lea edi, [esi + 0x1a0]
mov ebx, 0x800
push edi
call fcn.0049f8e0
add esp, 4
add edi, 0xc
sub ebx, 1
jne 0x49a688
lea edi, [esi + 0x61a0]
mov ebx, 0x400
push edi
call fcn.0049f8e0
add esp, 4
add edi, 0xc
sub ebx, 1
jne 0x49a6a4
push ebp
push dword [esp + 0x30]
push dword [esp + 0x30]
push esi
call fcn.0049bda0
mov ebp, eax
add esp, 0xc
test ebp, ebp
jne 0x49a98a
push str.LOCALDOMAIN
call sub.api_ms_win_crt_environment_l1_1_0.dll_getenv
add esp, 4
test eax, eax
je 0x49a71d
cmp dword [esi + 0x28], 0xffffffff
jne 0x49a71d
lea ecx, [esp + 0x18]
push ecx
push 1
push 0x4b2ed4
push eax
call fcn.0049f9e0
mov ecx, dword [esp + 0x28]
add esp, 0x10
mov dword [esi + 0x24], eax
mov dword [esi + 0x28], ecx
test eax, eax
je 0x49a70f
test ecx, ecx
jne 0x49a71d
mov dword [esi + 0x24], 0
mov dword [esi + 0x28], 0xffffffff
push str.RES_OPTIONS
call sub.api_ms_win_crt_environment_l1_1_0.dll_getenv
add esp, 4
test eax, eax
je 0x49a73c
push eax
push esi
call fcn.0049c380
add esp, 8
test eax, eax
jne 0x49a745
push esi
call fcn.0049c080
add esp, 4
xor ebx, ebx
cmp dword [esi], 0xffffffff
mov dword [esp + 0x14], ebx
jne 0x49a752
mov dword [esi], ebx
cmp dword [esi + 4], 0xffffffff
jne 0x49a75f
mov dword [esi + 4], 0x1388
cmp dword [esi + 8], 0xffffffff
jne 0x49a76c
mov dword [esi + 8], 4
cmp dword [esi + 0xc], 0xffffffff
jne 0x49a779
mov dword [esi + 0xc], 1
cmp dword [esi + 0x10], 0xffffffff
jne 0x49a782
mov dword [esi + 0x10], ebx
cmp dword [esi + 0x14], 0xffffffff
mov edi, dword [sym.imp.WS2_32.dll_htons]
jne 0x49a798
push 0x35
call edi
movzx eax, ax
mov dword [esi + 0x14], eax
cmp dword [esi + 0x18], 0xffffffff
jne 0x49a7a8
push 0x35
call edi
movzx eax, ax
mov dword [esi + 0x18], eax
cmp dword [esi + 0x38], 0xffffffff
jne 0x49a7b5
mov dword [esi + 0x38], 0x500
cmp dword [esi + 0x78], 0xffffffff
jne 0x49a7fb
push 0x58
call dword [0x6127b4]
add esp, 4
mov dword [esi + 0x74], eax
test eax, eax
je 0x49a8d7
push 0x7f000001
mov dword [eax], 2
call dword [sym.imp.WS2_32.dll_htonl]
mov ecx, dword [esi + 0x74]
mov dword [ecx + 4], eax
mov eax, dword [esi + 0x74]
mov dword [eax + 0x14], ebx
mov eax, dword [esi + 0x74]
mov dword [eax + 0x18], ebx
mov dword [esi + 0x78], 1
cmp dword [esi + 0x28], 0xffffffff
jne 0x49a8a1
mov edi, 0x40
mov dword [esi + 0x28], ebx
push edi
mov ebp, edi
call dword [0x6127b4]
mov ebx, eax
add esp, 4
test ebx, ebx
je 0x49a8d7
push edi
push ebx
call dword [sym.imp.WS2_32.dll_gethostname]
cmp eax, 0xffffffff
jne 0x49a858
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x271e
jne 0x49a85c
add ebp, ebp
add edi, edi
push ebp
push ebx
call dword [0x6127b8]
add esp, 8
test eax, eax
je 0x49a8d7
mov ebx, eax
jmp 0x49a823
test eax, eax
je 0x49a85f
mov byte [ebx], 0
push 0x2e
push ebx
call sub.VCRUNTIME140.dll_strchr
mov ebp, eax
add esp, 8
test ebp, ebp
je 0x49a8a1
push 4
call dword [0x6127b4]
add esp, 4
mov dword [esi + 0x24], eax
test eax, eax
je 0x49a8d7
mov edi, eax
lea eax, [ebp + 1]
push eax
call fcn.0049f990
mov dword [edi], eax
add esp, 4
mov eax, dword [esi + 0x24]
cmp dword [eax], 0
je 0x49a8d7
mov dword [esi + 0x28], 1
cmp dword [esi + 0x30], 0xffffffff
jne 0x49a8b5
mov dword [esi + 0x2c], 0
mov dword [esi + 0x30], 0
cmp dword [esi + 0x34], 0
jne 0x49a95b
push 0x5fe050
call fcn.0049f990
add esp, 4
mov dword [esi + 0x34], eax
test eax, eax
jne 0x49a95b
mov eax, dword [esi + 0x74]
test eax, eax
je 0x49a8ef
push eax
call dword [0x6127bc]
add esp, 4
mov dword [esi + 0x74], 0
mov eax, dword [esi + 0x24]
test eax, eax
je 0x49a91e
mov ecx, dword [eax]
test ecx, ecx
je 0x49a90d
push ecx
call dword [0x6127bc]
mov eax, dword [esi + 0x24]
add esp, 4
test eax, eax
je 0x49a91e
push eax
call dword [0x6127bc]
add esp, 4
mov dword [esi + 0x24], 0
mov eax, dword [esi + 0x34]
test eax, eax
je 0x49a936
push eax
call dword [0x6127bc]
add esp, 4
mov dword [esi + 0x34], 0
mov eax, dword [esi + 0x91c0]
mov ebp, 0xf
test eax, eax
je 0x49a95f
push eax
call dword [0x6127bc]
add esp, 4
mov dword [esi + 0x91c0], 0
jmp 0x49a95f
mov ebp, dword [esp + 0x14]
test ebx, ebx
je 0x49a96d
push ebx
call dword [0x6127bc]
add esp, 4
test ebp, ebp
jne 0x49a98a
push 0x1f
lea ebx, [esi + 0x7e]
call dword [0x6127b4]
add esp, 4
mov dword [esp + 0x18], eax
test eax, eax
jne 0x49a9f9
lea ebp, [eax + 0xf]
mov eax, dword [esi + 0x74]
test eax, eax
je 0x49a99b
push eax
call dword [0x6127bc]
add esp, 4
mov eax, dword [esi + 0x28]
cmp eax, 0xffffffff
je 0x49a9af
push eax
push dword [esi + 0x24]
call fcn.0049fc40
add esp, 8
mov eax, dword [esi + 0x2c]
test eax, eax
je 0x49a9c0
push eax
call dword [0x6127bc]
add esp, 4
mov eax, dword [esi + 0x34]
test eax, eax
je 0x49a9d1
push eax
call dword [0x6127bc]
add esp, 4
mov eax, dword [esi + 0x91c0]
test eax, eax
je 0x49a9e5
push eax
call dword [0x6127bc]
add esp, 4
push esi
call dword [0x6127bc]
add esp, 4
mov eax, ebp
pop ebp
pop edi
pop ebx
pop esi
add esp, 0x14
ret
xorps xmm0, xmm0
mov ecx, ebx
movups xmmword [eax], xmm0
mov edx, 0x100
movq qword [eax + 0x10], xmm0
mov dword [eax + 0x18], 0
mov word [eax + 0x1c], 0
mov byte [eax + 0x1e], 0
xor eax, eax
nop
mov byte [ecx], al
inc eax
inc ecx
cmp ax, dx
jl 0x49aa20
mov eax, dword [0x915cbc]
xor edi, edi
test eax, eax
je 0x49aa40
push 0x1f
push ebx
call eax
test al, al
jne 0x49aa5c
nop dword [eax]
call sub.api_ms_win_crt_utility_l1_1_0.dll_rand
and eax, 0x800000ff
jns 0x49aa53
dec eax
or eax, 0xffffff00
inc eax
mov byte [edi + ebx], al
inc edi
cmp edi, 0x1f
jl 0x49aa40
mov esi, dword [esp + 0x18]
xor al, al
mov word [ebx + 0x100], 0
xor cl, cl
mov ebp, ebx
mov dword [esp + 0x14], 0x100
mov dl, byte [ebp]
lea ebp, [ebp + 1]
movzx edi, al
mov al, byte [edi + esi]
add al, dl
add cl, al
mov byte [esp + 0x13], cl
movzx ecx, cl
mov al, byte [ecx + ebx]
mov byte [ebp - 1], al
lea eax, [edi + 1]
mov byte [ecx + ebx], dl
xor edx, edx
mov ecx, 0x1f
div ecx
sub dword [esp + 0x14], 1
mov cl, byte [esp + 0x13]
mov al, dl
jne 0x49aa77
push dword [esp + 0x18]
call dword [0x6127bc]
push ebx
call fcn.0049fc80
mov esi, dword [esp + 0x28]
add esp, 8
mov word [esi + 0x7c], ax
test byte [esi], 2
je 0x49aadd
cmp dword [esi + 0x78], 1
jle 0x49aadd
mov dword [esi + 0x78], 1
xor ebx, ebx
cmp dword [esi + 0x78], ebx
jle 0x49ab5b
xor ebp, ebp
nop word [eax + eax]
mov edi, dword [esi + 0x74]
add edi, ebp
mov dword [edi + 0x1c], 0xffffffff
mov dword [edi + 0x20], 0xffffffff
inc dword [esi + 0x180]
mov eax, dword [esi + 0x180]
mov dword [edi + 0x40], eax
lea eax, [edi + 0x44]
push eax
mov dword [edi + 0x28], 0
mov dword [edi + 0x34], 0
mov dword [edi + 0x30], 0
mov dword [edi + 0x2c], 0
mov dword [edi + 0x38], 0
mov dword [edi + 0x3c], 0
call fcn.0049f8e0
inc ebx
mov dword [edi + 0x50], esi
add esp, 4
mov dword [edi + 0x54], 0
add ebp, 0x58
cmp ebx, dword [esi + 0x78]
jl 0x49aaf0
mov eax, dword [esp + 0x28]
pop ebp
pop edi
pop ebx
mov dword [eax], esi
xor eax, eax
pop esi
add esp, 0x14
ret