Function at 0x10018ff0
Capabilities:
Convert ip address from string
Get local ipv4 addresses
Get socket information

Disassembly:
push ebp
mov ebp, esp
sub esp, 0x654
push ebx
push esi
push edi
mov edi, dword [ebp + 8]
push 0x2e
push 0
mov dword [ebp - 0x1c], 0xffffffff
mov ebx, dword [edi + 0x18]
mov dword [ebp - 8], ebx
mov byte [ebp - 0xd8], 0
lea eax, [ebx + 0x2d0]
mov dword [ebp - 0x28], eax
lea eax, [ebp - 0xd7]
push eax
call fcn.10051710
mov edx, dword [edi + 0x55c]
xor eax, eax
add esp, 0xc
mov dword [ebp - 0x24], edx
xor esi, esi
mov dword [ebp - 0x20], 0
mov dword [ebp - 0x14], 0
mov dword [ebp - 0xc], 0
mov byte [ebp - 1], 1
mov dword [ebp - 0x10], eax
test edx, edx
je 0x100191fc
mov ecx, edx
lea ebx, [ecx + 1]
mov al, byte [ecx]
inc ecx
test al, al
jne 0x10019065
sub ecx, ebx
cmp ecx, 1
jbe 0x100191f9
mov al, byte [edx]
cmp al, 0x5b
jne 0x1001909f
lea eax, [edx + 1]
push 0x5d
push eax
mov dword [ebp - 0x10], eax
call fcn.10051a80
mov ebx, eax
add esp, 8
test ebx, ebx
je 0x100191f9
mov esi, ebx
sub esi, dword [ebp - 0x10]
jmp 0x100190dd
cmp al, 0x3a
jne 0x100190a7
mov ebx, edx
jmp 0x100190dd
push 0x3a
push edx
call fcn.10051a80
mov ebx, eax
add esp, 8
mov eax, dword [ebp - 0x24]
mov ecx, eax
mov dword [ebp - 0x10], ecx
test ebx, ebx
je 0x100191d6
lea ecx, [ebp - 0xa0]
mov esi, ebx
push ecx
push eax
push 0x17
sub esi, eax
call dword [sym.imp.WS2_32.dll_inet_pton]
cmp eax, 1
je 0x10019140
test ebx, ebx
je 0x1001914e
push 0x3a
push ebx
call fcn.10051a80
mov ebx, eax
add esp, 8
test ebx, ebx
je 0x1001914e
push 0xa
lea eax, [ebx + 1]
push 0
push eax
call fcn.10051694
push eax
call fcn.1004d9c0
movzx eax, ax
push 0x2d
push ebx
mov dword [ebp - 0x14], eax
call fcn.10051a80
add esp, 0x18
test eax, eax
je 0x100191c8
push 0xa
inc eax
push 0
push eax
call fcn.10051694
push eax
call fcn.1004d9c0
mov ecx, dword [ebp - 0x14]
add esp, 0x10
movzx eax, ax
mov dword [ebp - 0xc], eax
cmp cx, ax
jbe 0x1001914e
mov dword [ebp - 0xc], 0
mov dword [ebp - 0x14], 0
mov ecx, dword [ebp - 0x10]
test esi, esi
je 0x100191f9
cmp esi, 0x32
jae 0x1001970f
push esi
push ecx
lea eax, [ebp - 0x10c]
push eax
call fcn.10050b30
mov ebx, dword [ebp - 8]
lea eax, [ebp - 0x654]
add esp, 0xc
mov byte [ebp + esi - 0x10c], 0
push 0x401
push eax
lea eax, [ebp - 0x10c]
push eax
mov eax, dword [ebx + 0x24]
push dword [ebx + 0x3a4]
add eax, 0x10
push eax
call fcn.10026650
add esp, 4
push eax
mov eax, dword [ebx + 0x24]
push dword [eax]
call sym.libcurl.dll_curl_pushheader_byname
add esp, 0x18
sub eax, 0
je 0x100191ee
dec eax
je 0x1001970f
dec eax
jne 0x100191fc
jmp 0x10019291
mov ecx, dword [ebp - 0x14]
movzx eax, cx
mov dword [ebp - 0xc], eax
jmp 0x1001914e
mov esi, eax
lea edx, [esi + 1]
jmp 0x100191e0
mov al, byte [esi]
inc esi
test al, al
jne 0x100191e0
sub esi, edx
jmp 0x10019151
lea esi, [ebp - 0x10c]
jmp 0x10019297
mov ebx, dword [ebp - 8]
lea eax, [ebp - 0x18]
mov dword [ebp - 0x18], 0x80
push eax
lea eax, [ebp - 0xa8]
push eax
push dword [ebx + 0x1a0]
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
je 0x1001924a
push pe_nt_image_headers32
lea eax, [ebp - 0x250]
push eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
call fcn.100419a0
push eax
push 0x10070710
push edi
call fcn.1000ff00
add esp, 0x18
jmp 0x1001970f
mov ax, word [ebp - 0xa8]
push 0x401
cmp ax, 0x17
je 0x10019270
lea ecx, [ebp - 0x654]
movzx eax, ax
push ecx
lea ecx, [ebp - 0xa4]
push ecx
push eax
jmp 0x10019280
lea eax, [ebp - 0x654]
push eax
lea eax, [ebp - 0xa0]
push eax
push 0x17
call sub.WS2_32.dll_inet_ntop
test eax, eax
je 0x1001970f
mov byte [ebp - 1], 0
lea esi, [ebp - 0x654]
lea eax, [ebp - 0x20]
push eax
push 0
push 0
push esi
push edi
call fcn.1001dca0
add esp, 0x14
cmp eax, 1
jne 0x100192bb
lea eax, [ebp - 0x20]
push eax
push edi
call fcn.10002d50
add esp, 8
mov eax, dword [ebp - 0x20]
test eax, eax
je 0x10019700
mov ebx, dword [eax]
push eax
push edi
call fcn.1001e030
add esp, 8
test ebx, ebx
je 0x10019700
xor esi, esi
lea esp, [esp]
lea eax, [ebp - 0x1c]
push eax
mov eax, dword [ebp - 8]
movzx eax, byte [eax + 0x3ae]
push eax
push 0
push ebx
push edi
call fcn.10006e30
add esp, 0x14
test eax, eax
je 0x10019310
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
mov ebx, dword [ebx + 0x1c]
mov esi, eax
test ebx, ebx
jne 0x100192e0
jmp 0x10019314
test ebx, ebx
jne 0x1001933a
push pe_nt_image_headers32
lea eax, [ebp - 0x250]
push eax
push esi
call fcn.100419a0
push eax
push 0x10070760
push edi
call fcn.1000ff00
add esp, 0x18
jmp 0x1001970f
mov eax, dword [edi + 0x18]
test eax, eax
je 0x10019351
movzx eax, byte [eax + 0x37e]
mov eax, dword [eax*4 + 0x100702a8]
jmp 0x10019356
mov eax, 0x1007046c
push eax
push 0x10070774
push edi
call fcn.100100f0
push dword [ebx + 0x10]
lea eax, [ebp - 0xa8]
push dword [ebx + 0x18]
push eax
call fcn.10050b30
mov eax, dword [ebx + 0x10]
add esp, 0x18
mov dword [ebp - 0x18], eax
mov eax, dword [ebp - 0x14]
cmp ax, word [ebp - 0xc]
movzx esi, ax
ja 0x100196f0
mov eax, dword [sym.imp.WS2_32.dll_htons]
push esi
call eax
push dword [ebp - 0x18]
mov word [ebp - 0xa6], ax
lea eax, [ebp - 0xa8]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.WS2_32.dll_bind]
test eax, eax
je 0x1001946f
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp byte [ebp - 1], 0
je 0x1001942f
cmp eax, 0x2741
jne 0x1001942f
push pe_nt_image_headers32
lea eax, [ebp - 0x250]
push eax
push 0x2741
call fcn.100419a0
push eax
movzx eax, si
push eax
push 0x100707a0
push edi
call fcn.1000ffa0
add esp, 0x1c
mov dword [ebp - 0x18], 0x80
lea eax, [ebp - 0x18]
push eax
lea eax, [ebp - 0xa8]
push eax
mov eax, dword [ebp - 8]
push dword [eax + 0x1a0]
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x1001921e
mov eax, dword [ebp - 0x14]
movzx esi, ax
cmp si, word [ebp - 0xc]
mov byte [ebp - 1], 0
jmp 0x10019387
cmp eax, 0x2740
je 0x1001943b
cmp eax, 0xd
jne 0x10019445
inc esi
cmp si, word [ebp - 0xc]
jmp 0x10019387
push pe_nt_image_headers32
lea ecx, [ebp - 0x250]
push ecx
push eax
call fcn.100419a0
push eax
movzx eax, si
push eax
push 0x100707d0
push edi
call fcn.1000ff00
add esp, 0x1c
jmp 0x1001970f
cmp si, word [ebp - 0xc]
ja 0x100196f0
lea eax, [ebp - 0x18]
mov dword [ebp - 0x18], 0x80
push eax
lea eax, [ebp - 0xa8]
push eax
push dword [ebp - 0x1c]
call dword [sym.imp.WS2_32.dll_getsockname]
test eax, eax
jne 0x1001921e
mov eax, dword [edi + 0x18]
test eax, eax
je 0x100194b3
movzx eax, byte [eax + 0x37e]
mov eax, dword [eax*4 + 0x100702a8]
jmp 0x100194b8
mov eax, 0x1007046c
movzx esi, si
push esi
push eax
push 0x10070810
push edi
call fcn.100100f0
add esp, 0x10
push 1
push dword [ebp - 0x1c]
call dword [sym.imp.WS2_32.dll_listen]
test eax, eax
je 0x10019506
push pe_nt_image_headers32
lea eax, [ebp - 0x250]
push eax
call dword [sym.imp.WS2_32.dll_WSAGetLastError]
push eax
call fcn.100419a0
push eax
push 0x10070760
push edi
call fcn.1000ff00
add esp, 0x18
jmp 0x1001970f
mov eax, dword [edi + 0x18]
test eax, eax
je 0x1001951d
movzx eax, byte [eax + 0x37e]
mov eax, dword [eax*4 + 0x100702a8]
jmp 0x10019522
mov eax, 0x1007046c
push esi
push eax
push 0x10070844
push edi
call fcn.100100f0
push 0x2f
lea eax, [ebp - 0xd8]
push eax
push ebx
call fcn.1001dc50
mov ebx, dword [ebp - 8]
add esp, 0x1c
cmp byte [ebx + 0x251], 0
jne 0x1001955d
cmp byte [ebx + 0x24c], 0
je 0x1001955d
mov byte [ebx + 0x251], 1
lea eax, [ebp - 0x1c]
push eax
push 1
push ebx
push edi
call fcn.10006bf0
mov ebx, eax
add esp, 0x10
mov dword [ebp - 0x24], ebx
test ebx, ebx
jne 0x10019714
mov esi, dword [ebp + 0xc]
mov dword [ebp - 0x1c], 0xffffffff
cmp esi, 2
je 0x100195f3
mov ebx, dword [sym.imp.WS2_32.dll_ntohs]
mov cx, word [ebp - 0xa8]
mov eax, dword [ebp - 8]
lea esp, [esp]
cmp byte [eax + 0x251], 0
jne 0x100195ad
test esi, esi
je 0x100195ea
cmp esi, 1
jne 0x100195b8
cmp cx, 2
jne 0x100195ea
movzx eax, cx
sub eax, 2
je 0x100195c5
sub eax, 0x15
jne 0x100195e7
push dword [ebp - 0xa6]
call ebx
movzx eax, ax
mov dword [ebp - 0xc], eax
test esi, esi
je 0x1001969c
cmp esi, 1
je 0x10019614
mov cx, word [ebp - 0xa8]
mov eax, dword [ebp - 8]
inc esi
cmp esi, 2
jne 0x100195a0
mov ebx, dword [ebp - 0x24]
mov eax, dword [ebp - 0x28]
push 0x1c
push edi
mov dword [eax + 0xa0], esi
call fcn.10016760
add esp, 8
test ebx, ebx
je 0x10019755
jmp 0x10019714
lea edx, [ebp - 0x150]
mov edi, 0x2c
lea ebx, [ebp - 0xd8]
mov cl, byte [ebx]
test cl, cl
je 0x1001963a
cmp cl, 0x2e
movzx eax, cl
cmove eax, edi
mov byte [edx], al
inc edx
inc ebx
jne 0x10019625
mov eax, dword [ebp - 0xc]
movzx ecx, ax
movzx eax, cl
push eax
shr ecx, 8
push ecx
push 0x100708a4
push 0x14
push edx
mov byte [edx], 0
call sym.libcurl.dll_curl_msnprintf
mov edi, dword [ebp + 8]
lea eax, [ebp - 0x150]
push eax
push 0x10070341
push 0x100708ac
push dword [ebp - 0x28]
push edi
call fcn.100336f0
mov ebx, eax
add esp, 0x28
test ebx, ebx
je 0x100195f3
push ebx
call sym.libcurl.dll_curl_easy_strerror
push eax
push 0x100708b4
push edi
call fcn.1000ff00
add esp, 0x10
jmp 0x10019607
movzx eax, ax
push eax
lea eax, [ebp - 0xd8]
push eax
xor eax, eax
cmp word [ebp - 0xa8], 2
setne al
inc eax
push eax
push 0x1007033c
push 0x10070870
push dword [ebp - 0x28]
push edi
call fcn.100336f0
mov ebx, eax
add esp, 0x1c
test ebx, ebx
je 0x100195f3
push ebx
call sym.libcurl.dll_curl_easy_strerror
push eax
push 0x10070880
push edi
call fcn.1000ff00
add esp, 0x10
jmp 0x10019607
push 0x100707ec
push edi
call fcn.1000ff00
add esp, 8
jmp 0x1001970f
push esi
push 0x1007072c
push edi
call fcn.1000ff00
add esp, 0xc
mov ebx, 0x1e
mov esi, dword [edi + 0x18]
cmp byte [esi + 0x37e], 0
je 0x1001974e
test esi, esi
je 0x10019734
movzx eax, byte [esi + 0x37e]
mov eax, dword [eax*4 + 0x100702a8]
jmp 0x10019739
mov eax, 0x1007046c
push dword [0x100702a8]
push eax
push 0x10070470
push edi
call fcn.100100f0
add esp, 0x10
mov byte [esi + 0x37e], 0
mov eax, dword [ebp - 0x1c]
cmp eax, 0xffffffff
je 0x1001976a
push eax
push dword [ebp - 8]
push edi
call fcn.10006e00
add esp, 0xc
pop edi
pop esi
mov eax, ebx
pop ebx
mov esp, ebp
pop ebp
ret