Function at 0x140040d4f
Capabilities:
Connect socket
Resolve dns

Disassembly:
push r15
push r14
push r13
push r12
push rsi
push rdi
push rbp
push rbx
sub rsp, 0x298
movdqa xmmword [rsp + 0x280], xmm6
mov rbx, r8
mov rdi, rdx
mov r13, rcx
lea rcx, [rsp + 0x40]
mov qword [rcx], rdx
mov qword [rcx + 8], r8
call fcn.1400097e0
mov r15, rax
test r15b, 1
je 0x140040e20
mov r8, qword [rsp + 0x40]
mov r9, qword [rsp + 0x48]
test r9, r9
je 0x140040e0f
xor esi, esi
cmp byte [r8], 0x3a
jne 0x140040e0f
mov qword [rsp + 0x38], r13
lea r10, [r8 + 1]
lea r11, [r9 - 1]
mov bp, 0xa
mov r14, r11
mov r12, r10
xor ecx, ecx
test r14, r14
je 0x140040de7
lea rdx, [r12 + 1]
movzx r13d, byte [r12]
add r13d, 0xffffffd0
xor eax, eax
cmp r13d, 0xa
setb al
cmovb r12, rdx
sub r14, rax
jmp 0x140040de9
xor eax, eax
cmp eax, 1
jne 0x140040e35
mov eax, ecx
mul bp
jo 0x140040e27
add ax, r13w
setb dl
cmp r13d, 0xffff
ja 0x140040e27
test dl, dl
jne 0x140040e27
inc esi
mov ecx, eax
jmp 0x140040dc2
xor eax, eax
mov qword [rsp + 0x40], r8
mov qword [rsp + 0x48], r9
test ax, ax
jne 0x140040e53
xor r15d, r15d
xor eax, eax
jmp 0x140040e77
xor eax, eax
mov qword [rsp + 0x40], r10
mov qword [rsp + 0x48], r11
jmp 0x140040e48
mov qword [rsp + 0x40], r12
mov qword [rsp + 0x48], r14
xor eax, eax
test esi, esi
setne al
je 0x140040e29
cmp ax, 1
mov r13, qword [rsp + 0x38]
jne 0x140040e11
movabs rax, 0xffffffff00
and r15, rax
shr r15, 8
movzx eax, cx
shl rax, 0x30
shl r15, 0x10
or r15, rax
mov eax, 1
movzx ecx, r15w
or rcx, rax
cmp rcx, 1
jne 0x140040e8b
mov rax, qword [rsp + 0x48]
jmp 0x140040ea1
mov qword [rsp + 0x40], rdi
mov qword [rsp + 0x48], rbx
mov rax, rbx
test rcx, rcx
je 0x1400411a0
test rax, rax
je 0x140040f1a
mov qword [rsp + 0x100], rdi
mov qword [rsp + 0x108], rbx
and qword [rsp + 0x110], 0
mov byte [rsp + 0x128], 1
movabs rax, 0x3a0000003a
mov qword [rsp + 0x120], rax
mov sil, 0x3a
mov r14, rbx
mov cl, 0x3a
mov rdx, rdi
mov r8, r14
call fcn.14000c000
cmp rax, 1
jne 0x140040f09
mov r14, rdx
cmp rdx, rbx
jae 0x140040f04
cmp byte [rdi + r14], sil
je 0x1400412b4
cmp r14, rbx
jbe 0x140040edf
lea r15, str.invalid_socket_address
mov eax, 1
jmp 0x140041313
mov esi, r15d
shr esi, 0x10
shr r15, 0x18
xor ebx, ebx
mov qword [rsp + 0x38], r13
mov al, byte [0x14005a148]
mov edx, 0x20
xor ecx, ecx
call fcn.1400378c0
test rax, rax
je 0x140041ae9
mov rdi, rax
mov word [rax], bx
mov rax, r15
shl rax, 8
movzx ecx, sil
or rcx, rax
shr r15, 0x18
mov word [rdi + 6], r15w
mov dword [rdi + 2], ecx
movq qword [rdi + 8], xmm6
pshufd xmm0, xmm6, 0xee
movd dword [rdi + 0x10], xmm0
and dword [rdi + 0x14], 0
mov dword [rdi + 0x18], r14d
mov word [rdi + 0x1c], bp
mov rbp, rdi
add rbp, 0x20
mov r15d, 1
mov qword [rsp + 0x100], rdi
mov qword [rsp + 0x108], rdi
mov qword [rsp + 0x110], r15
mov qword [rsp + 0x118], rbp
xor ebx, ebx
cmp rdi, rbp
je 0x14004117b
lea rax, [rdi + 0x20]
mov qword [rsp + 0x108], rax
movzx r14d, word [rdi]
movzx eax, word [rdi + 0x12]
mov word [rsp + 0xc0], ax
movups xmm0, xmmword [rdi + 2]
movaps xmmword [rsp + 0xb0], xmm0
cmp r14w, 2
je 0x14004117b
mov r13d, dword [rdi + 0x14]
mov ebp, dword [rdi + 0x18]
movzx esi, word [rdi + 0x1c]
movzx eax, word [rsp + 0xc0]
mov word [rsp + 0x90], ax
movdqa xmm0, xmmword [rsp + 0xb0]
movdqa xmmword [rsp + 0x80], xmm0
mov rax, qword [0x14005a128]
cmp rax, 3
jne 0x140041171
mov edi, 2
test r14w, r14w
je 0x14004103a
mov edi, 0x17
mov dword [rsp + 0x28], 0x81
and dword [rsp + 0x20], 0
mov ecx, edi
mov edx, 1
xor r8d, r8d
xor r9d, r9d
call sub.ws2_32.dll_WSASocketW
mov r15, rax
cmp rax, 0xffffffffffffffff
je 0x14004107d
test r14w, r14w
je 0x1400410de
mov r8d, 0x1c
mov ax, 0x17
movdqu xmm0, xmmword [rsp + 0x82]
jmp 0x1400410fc
call sub.ws2_32.dll_WSAGetLastError
cmp eax, 0x2739
je 0x140041097
mov r12d, eax
cmp eax, 0x2726
jne 0x14004113f
mov dword [rsp + 0x28], 1
and dword [rsp + 0x20], 0
mov ecx, edi
mov edx, 1
xor r8d, r8d
xor r9d, r9d
call sub.ws2_32.dll_WSASocketW
cmp rax, 0xffffffffffffffff
je 0x140041167
mov r15, rax
mov rcx, rax
mov edx, 1
xor r8d, r8d
call sub.KERNEL32.dll_SetHandleInformation
test eax, eax
jne 0x140041062
call sub.KERNEL32.dll_GetLastError
jmp 0x140041134
movzx esi, word [rsp + 0x84]
mov r13d, dword [rsp + 0x80]
pxor xmm0, xmm0
mov r8d, 0x10
mov ax, 2
rol si, 8
mov word [rsp + 0x40], ax
mov word [rsp + 0x42], si
mov dword [rsp + 0x44], r13d
movdqu xmmword [rsp + 0x48], xmm0
mov dword [rsp + 0x58], ebp
mov rcx, r15
lea rdx, [rsp + 0x40]
call sub.ws2_32.dll_connect
cmp eax, 0xffffffff
jne 0x1400412f4
call sub.ws2_32.dll_WSAGetLastError
mov r12d, eax
mov rcx, r15
call fcn.140043124
shl r12, 0x20
or r12, 2
mov rcx, rbx
call fcn.14003d113
mov rdi, qword [rsp + 0x108]
mov rbp, qword [rsp + 0x118]
mov rbx, r12
jmp 0x140040fb0
call sub.ws2_32.dll_WSAGetLastError
mov r12d, eax
jmp 0x14004113f
call fcn.140036e60
jmp 0x14004102a
lea rcx, [rsp + 0x100]
call fcn.14003d0f8
test rbx, rbx
lea r15, str.could_not_resolve_to_any_addresses
cmovne r15, rbx
mov eax, 1
jmp 0x14004130e
mov rax, qword [rsp + 0x48]
test rax, rax
je 0x140040ea6
mov rsi, qword [rsp + 0x40]
dec rax
mov cl, byte [rsi]
inc rsi
mov qword [rsp + 0x40], rsi
mov qword [rsp + 0x48], rax
cmp cl, 0x5b
jne 0x140040ea6
pxor xmm6, xmm6
lea rdx, [rsp + 0x100]
movdqa xmmword [rdx], xmm6
lea rcx, [rsp + 0x40]
mov r8d, 8
call fcn.140009b80
cmp rax, 8
jne 0x14004138f
movdqa xmm0, xmmword [rsp + 0x100]
movdqa xmm1, xmm0
punpckhbw xmm1, xmm6
pshuflw xmm1, xmm1, 0xb1
pshufhw xmm1, xmm1, 0xb1
punpcklbw xmm0, xmm6
pshuflw xmm0, xmm0, 0xb1
pshufhw xmm0, xmm0, 0xb1
packuswb xmm0, xmm1
mov rcx, qword [rsp + 0x40]
mov r8, qword [rsp + 0x48]
xor r12d, r12d
test r8, r8
je 0x14004152d
cmp byte [rcx], 0x25
jne 0x14004160f
lea r10, [rcx + 1]
lea rsi, [r8 - 1]
xor r14d, r14d
mov ebp, 0xa
mov qword [rsp + 0x78], rsi
mov r11, r10
xor r15d, r15d
xor r12d, r12d
mov r9, r13
test rsi, rsi
je 0x140041288
lea rdx, [r11 + 1]
movzx r13d, byte [r11]
add r13d, 0xffffffd0
xor eax, eax
cmp r13d, 0xa
setb al
cmovb r11, rdx
sub rsi, rax
jmp 0x14004128c
xor esi, esi
xor eax, eax
cmp eax, 1
jne 0x1400415e7
mov eax, r14d
mul ebp
jo 0x140041566
add eax, r13d
jb 0x140041566
inc r15d
mov r14d, eax
mov r13, r9
jmp 0x140041262
lea r12, [r14 + 1]
lea r15, str.invalid_port_value
sub rbx, r12
je 0x140040f10
lea rcx, [rdi + r14]
inc rcx
cmp rbx, 1
jne 0x140041337
movzx eax, byte [rcx]
cmp eax, 0x2b
je 0x140040f10
mov ebx, 1
cmp eax, 0x2d
je 0x140040f10
jmp 0x140041491
lea rcx, [rsp + 0x100]
call fcn.14003d0f8
mov rcx, rbx
call fcn.14003d113
mov eax, 0xa
mov r13, qword [rsp + 0x38]
mov qword [r13 + 8], r15
mov qword [r13], rax
movaps xmm6, xmmword [rsp + 0x280]
add rsp, 0x298
pop rbx
pop rbp
pop rdi
pop rsi
pop r12
pop r13
pop r14
pop r15
ret
cmp byte [rcx], 0x2b
jne 0x140041487
inc rcx
lea rax, [rbx - 1]
cmp rbx, 6
mov rbx, rax
jb 0x140041491
xor r8d, r8d
mov r9w, 0xa
xor eax, eax
mul r9w
jo 0x140040f10
movzx edx, byte [rcx + r8]
add edx, 0xffffffd0
cmp edx, 9
ja 0x140040f10
add ax, dx
jb 0x140040f10
inc r8
cmp rbx, r8
jne 0x14004135e
jmp 0x1400414b6
test dl, 1
jne 0x14004147d
mov rcx, qword [rsp + 0x48]
test rcx, rcx
je 0x14004147d
mov rdx, qword [rsp + 0x40]
cmp byte [rdx], 0x3a
jne 0x14004147d
cmp rcx, 1
je 0x14004147d
add rcx, 0xfffffffffffffffe
mov r8b, byte [rdx + 1]
add rdx, 2
mov qword [rsp + 0x40], rdx
mov qword [rsp + 0x48], rcx
cmp r8b, 0x3a
jne 0x14004147d
and qword [rsp + 0x86], 0
and qword [rsp + 0x80], 0
mov r8d, 7
sub r8, rax
jb 0x140041b32
lea rcx, [rsp + 0x40]
lea rdx, [rsp + 0x80]
call fcn.140009b80
mov ecx, 8
sub rcx, rax
jb 0x140041b49
cmp rax, 8
je 0x140041b5a
lea rcx, [rsp + rcx*2]
add rcx, 0x100
add rax, rax
lea rdx, [rsp + 0x80]
mov r8, rax
call sub.msvcrt.dll_memcpy
pxor xmm0, xmm0
movdqa xmm1, xmmword [rsp + 0x100]
movdqa xmm2, xmm1
punpckhbw xmm2, xmm0
pshuflw xmm2, xmm2, 0xb1
pshufhw xmm2, xmm2, 0xb1
punpcklbw xmm1, xmm0
pshuflw xmm0, xmm1, 0xb1
pshufhw xmm0, xmm0, 0xb1
packuswb xmm0, xmm2
jmp 0x140041225
mov qword [rsp + 0x40], rsi
jmp 0x140040ea6
cmp rbx, 5
jae 0x140041354
xor edx, edx
xor eax, eax
movzx r8d, byte [rcx + rdx]
add r8d, 0xffffffd0
cmp r8d, 9
ja 0x140040f10
imul eax, eax, 0xa
add eax, r8d
inc rdx
cmp rbx, rdx
jne 0x140041495
mov qword [rsp + 0x38], r13
mov word [rsp + 0x36], ax
mov rax, qword [0x14005a128]
cmp rax, 3
jne 0x14004176c
lea r13, [rsp + 0x36]
mov qword [rsp + 0xe0], r13
cmp r14, 0x17f
ja 0x140041776
lea rbx, [rsp + 0x100]
mov rcx, rbx
mov rdx, rdi
mov r8, r14
call sub.msvcrt.dll_memcpy
mov byte [rsp + r14 + 0x100], 0
cmp r14, 0xe
ja 0x140041532
xor ecx, ecx
cmp byte [rsp + rcx + 0x100], 0
je 0x1400416bf
inc rcx
cmp r12, rcx
jne 0x140041512
jmp 0x140041719
jmp 0x14004160f
lea rax, [rsp + 0x107]
and rax, 0xfffffffffffffff8
sub rax, rbx
je 0x140041573
xor ecx, ecx
cmp byte [rsp + rcx + 0x100], 0
je 0x1400416bf
inc rcx
cmp rax, rcx
jne 0x140041545
lea rcx, [r14 - 0xf]
cmp rax, rcx
jbe 0x140041577
jmp 0x1400415ba
mov r13, r9
mov rax, qword [rsp + 0x78]
jmp 0x140041601
lea rcx, [r14 - 0xf]
movdqa xmm0, xmmword [0x1400480d0]
movabs rdx, 0x8080808080808080
movdqu xmm1, xmmword [rsp + rax + 0x100]
movdqa xmm2, xmm1
paddq xmm2, xmm0
pandn xmm1, xmm2
pshufd xmm2, xmm1, 0xee
por xmm2, xmm1
movq r8, xmm2
test r8, rdx
jne 0x1400415ba
add rax, 0x10
cmp rax, rcx
jbe 0x140041589
sub r12, rax
je 0x140041719
lea rdx, [rsp + rax]
add rdx, 0x100
xor ecx, ecx
cmp byte [rdx + rcx], 0
je 0x1400416bc
inc rcx
cmp r12, rcx
jne 0x1400415d0
jmp 0x140041719
xor r12d, r12d
test r15d, r15d
setne r12b
mov rax, qword [rsp + 0x78]
cmovne rax, rsi
cmovne r10, r11
mov r13, r9
cmp r12d, 1
jne 0x14004160f
mov rcx, r10
mov r8, rax
jmp 0x140041616
test r12d, r12d
cmove r14d, r12d
test r8, r8
je 0x140040ea6
cmp byte [rcx], 0x5d
jne 0x140040ea6
mov r9, r8
dec r9
je 0x1400416a9
xor r11d, r11d
cmp byte [rcx + 1], 0x3a
jne 0x1400416a9
add rcx, 2
add r8, 0xfffffffffffffffe
mov si, 0xa
mov r10, r8
mov r15, rcx
xor ebp, ebp
test r10, r10
je 0x140041670
lea rdx, [r15 + 1]
movzx r12d, byte [r15]
add r12d, 0xffffffd0
xor eax, eax
cmp r12d, 0xa
setb al
cmovb r15, rdx
sub r10, rax
jmp 0x140041672
xor eax, eax
cmp eax, 1
jne 0x140041aa5
mov eax, ebp
mul si
jo 0x140041758
add ax, r12w
setb dl
cmp r12d, 0xffff
ja 0x140041758
test dl, dl
jne 0x140041758
inc r11d
mov ebp, eax
jmp 0x14004164d
xor eax, eax
mov r10, r9
test ax, ax
jne 0x140041abd
jmp 0x140040ea6
add rcx, rax
cmp rcx, r14
jne 0x140041719
pxor xmm0, xmm0
lea r8, [rsp + 0x40]
movdqa xmmword [r8], xmm0
movdqa xmmword [r8 + 0x20], xmm0
movdqa xmmword [r8 + 0x10], xmm0
mov dword [r8 + 8], 1
lea r9, [rsp + 0xb0]
and qword [r9], 0
lea rcx, [rsp + 0x100]
xor edx, edx
call sub.ws2_32.dll_getaddrinfo
test eax, eax
je 0x14004172f
call sub.ws2_32.dll_WSAGetLastError
shl rax, 0x20
or rax, 2
mov ecx, 1
jmp 0x14004174e
lea rax, str.file_name_contained_an_unexpected_NUL_byte
mov qword [rsp + 0x88], rax
mov ecx, 1
jmp 0x140041797
mov rax, qword [rsp + 0xb0]
movzx ecx, word [rsp + 0x36]
mov qword [rsp + 0x90], rax
mov word [rsp + 0x98], cx
xor ecx, ecx
mov qword [rsp + 0x88], rax
jmp 0x140041797
mov qword [rsp + 0x48], r10
xor eax, eax
mov qword [rsp + 0x40], rcx
mov r10, r8
jmp 0x140041ab3
call fcn.140036e60
jmp 0x1400414d1
lea rbx, [rsp + 0x80]
lea r9, [rsp + 0xe0]
mov rcx, rbx
mov rdx, rdi
mov r8, r14
call fcn.140036ec0
mov rcx, qword [rbx]
mov r15, qword [rsp + 0x88]
test rcx, rcx
je 0x1400417ae
mov r13, qword [rsp + 0x38]
jmp 0x140040f10
lea rdx, [rsp + 0x88]
mov rax, qword [rdx + 8]
movzx ecx, word [rdx + 0x10]
mov r8d, dword [rdx + 0x12]
mov dword [rsp + 0xd8], r8d
movzx r9d, word [rdx + 0x16]
mov word [rsp + 0xdc], r9w
mov word [rsp + 0x36], cx
mov qword [rdx], r15
mov qword [rdx + 8], rax
mov word [rdx + 0x10], cx
mov dword [rdx + 0x12], r8d
mov word [rdx + 0x16], r9w
mov qword [rdx - 8], r13
lea rcx, [rsp + 0x100]
call fcn.140036ce0
movzx esi, word [rsp + 0x100]
cmp si, 2
jne 0x14004182f
mov rcx, qword [rsp + 0x88]
call sub.ws2_32.dll_freeaddrinfo
mov edi, 4
xor r15d, r15d
mov ebp, 4
jmp 0x140040f8e
mov ebx, dword [rsp + 0x102]
movzx ebp, word [rsp + 0x106]
mov eax, dword [rsp + 0x118]
mov dword [rsp + 0x50], eax
movdqu xmm0, xmmword [rsp + 0x108]
movdqa xmmword [rsp + 0x40], xmm0
movzx r15d, word [rsp + 0x11c]
movzx r14d, word [rsp + 0x11e]
mov rax, qword [rsp + 0x80]
movzx r12d, word [rax]
mov al, byte [0x14005a148]
mov edx, pe_nt_image_headers64
xor ecx, ecx
call fcn.1400378c0
test rax, rax
je 0x140041b21
mov rdi, rax
test si, si
cmovne r15d, r12d
cmove ebp, r12d
lea rcx, [rsp + 0x48]
mov eax, dword [rcx + 8]
mov dword [rdi + 0x18], eax
movaps xmm0, xmmword [rcx - 8]
movups xmmword [rdi + 8], xmm0
mov word [rdi], si
mov dword [rdi + 2], ebx
mov word [rdi + 6], bp
mov word [rdi + 0x1c], r15w
mov word [rdi + 0x1e], r14w
movdqu xmm0, xmmword [rsp + 0x80]
movdqu xmm1, xmmword [rsp + 0x90]
movdqa xmmword [rcx + 8], xmm1
movdqa xmmword [rcx - 8], xmm0
mov ebp, 1
mov r14d, 0x20
xor eax, eax
mov qword [rsp + 0xd0], rax
mov r15d, 4
mov r13, qword [rsp + 0x38]
lea rcx, [rsp + 0x100]
lea rdx, [rsp + 0x48]
call fcn.140036ce0
movzx esi, word [rsp + 0x100]
cmp si, 2
je 0x140041a7d
mov r9d, dword [rsp + 0x102]
lea rax, [rsp + 0x108]
movups xmm0, xmmword [rax]
movaps xmmword [rsp + 0xe0], xmm0
mov eax, dword [rax + 0x10]
mov dword [rsp + 0xf0], eax
movzx r8d, word [rsp + 0x11e]
mov rax, qword [rsp + 0x40]
movzx r12d, word [rax]
test si, si
movzx ebx, word [rsp + 0x106]
cmove bx, r12w
cmove r12w, word [rsp + 0x11c]
cmp rbp, r15
jne 0x140041a39
mov r13, r15
inc r13
je 0x140041af8
lea rax, [r15 + r15]
cmp rax, r13
cmova r13, rax
xor edx, edx
mov rax, r13
shr rax, 0x3a
sete al
cmp r13, 5
mov ecx, 4
cmovb r13, rcx
test r15, r15
mov word [rsp + 0x78], r8w
mov dword [rsp + 0xac], r9d
je 0x1400419e1
mov rcx, r15
shl rcx, 5
mov qword [rsp + 0x100], rdi
mov qword [rsp + 0x110], rcx
mov ecx, 4
jmp 0x1400419e3
xor ecx, ecx
mov r8, r13
shl r8, 5
mov dl, al
shl edx, 2
mov qword [rsp + 0x108], rcx
lea rcx, [rsp + 0xb0]
lea r9, [rsp + 0x100]
call fcn.14000f7f0
cmp qword [rsp + 0xb0], 0
jne 0x140041afa
mov rdi, qword [rsp + 0xb8]
mov r15, r13
mov r13, qword [rsp + 0x38]
movzx r8d, word [rsp + 0x78]
mov r9d, dword [rsp + 0xac]
mov word [rdi + r14], si
mov dword [rdi + r14 + 2], r9d
mov word [rdi + r14 + 6], bx
movdqa xmm0, xmmword [rsp + 0xe0]
movdqu xmmword [rdi + r14 + 8], xmm0
mov eax, dword [rsp + 0xf0]
mov dword [rdi + r14 + 0x18], eax
mov word [rdi + r14 + 0x1c], r12w
mov word [rdi + r14 + 0x1e], r8w
inc rbp
add r14, 0x20
jmp 0x140041902
mov rcx, qword [rsp + 0x48]
call sub.ws2_32.dll_freeaddrinfo
test rdi, rdi
je 0x140041a98
shl rbp, 5
add rbp, rdi
jmp 0x140040f8e
mov eax, 1
xor r15d, r15d
jmp 0x140041313
xor eax, eax
test r11d, r11d
setne al
je 0x14004175f
cmp ax, 1
jne 0x1400416ab
xor eax, eax
test al, al
jne 0x140040ea6
test r10, r10
jne 0x140040ea6
movd r15d, xmm0
pshufd xmm6, xmm0, 0xf9
shl r15, 8
mov bx, 1
xor esi, esi
jmp 0x140040f26
mov ecx, 4
mov edx, 0x20
call fcn.140005a90
jmp 0x140041b12
mov rax, qword [rsp + 0xb8]
mov qword [rsp + 0xd0], rax
mov rdx, qword [rsp + 0xc0]
mov rcx, qword [rsp + 0xd0]
call fcn.140005a30
jmp 0x140041b30
mov ecx, 4
mov edx, pe_nt_image_headers64
call fcn.140005a30
ud2
lea rax, str.librarycore_src_netparser.rs
mov edx, 7
mov rcx, r8
mov r8, rax
call fcn.140007550
lea r8, str.librarycore_src_netparser.rs
mov edx, 8
call fcn.140008060
lea r8, str.librarycore_src_netparser.rs
mov ecx, 8
mov edx, 7
call fcn.140007550
jmp 0x140041b72
mov rsi, rax
mov rcx, qword [rsp + 0x88]
call sub.ws2_32.dll_freeaddrinfo
jmp 0x140041ba5
mov rcx, rsi
call fcn.140043590
int3