Function at 0x407e40
Capabilities:
Get socket status
Send data
Send data on socket

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x358
mov r14, qword [sym.imp.WS2_32.dll_select]
mov r15, qword [sym.imp.WS2_32.dll_send]
lea rsi, [rcx + 0x130]
mov rax, rcx
lea r13, [rsp + 0x80]
add rax, 0x240
mov qword [rsp + 0x40], rcx
mov byte [rsp + 0x7b], 0
mov qword [rsp + 0x50], rsi
lea rsi, [rsp + 0x140]
mov qword [rsp + 0x48], 0
mov qword [rsp + 0x58], 0
mov qword [rsp + 0x68], rax
mov qword [rsp + 0x38], rsi
lea rsi, [rsp + 0x90]
mov qword [rsp + 0x60], rsi
nop dword [rax]
mov rax, qword [rsp + 0x40]
mov rbx, qword [rax + 0x140]
test rbx, rbx
je 0x40859c
mov rcx, rbx
call sub.msvcrt.dll_strlen
lea rcx, [rax + 0x80]
call sub.msvcrt.dll_malloc
cmp byte [rsp + 0x7b], 0
mov rbp, rax
jne 0x408210
lea rdx, str._id_:_1___method_:__mining.subscribe____params_:___cpuminer_2.4_xcn_____s__
mov r8, rbx
mov rcx, rax
call sub.msvcrt.dll_sprintf
cmp byte [0x007ef090], 0
je 0x407f26
lea rdx, [0x0065cb28]
mov r8, rbp
mov ecx, 4
call fcn.004060f0
mov rcx, qword [rsp + 0x50]
call fcn.00600c90
mov rax, qword [rsp + 0x40]
mov rdx, rbp
mov rdi, qword [rax + 0x118]
mov ecx, dword [rdx]
add rdx, 4
lea eax, [rcx - 0x1010101]
not ecx
and eax, ecx
and eax, 0x80808080
je 0x407f3f
mov ecx, eax
shr ecx, 0x10
test eax, 0x8080
cmove eax, ecx
lea rcx, [rdx + 2]
cmove rdx, rcx
add al, al
sbb rdx, 3
sub rdx, rbp
lea rbx, [rdx + 1]
mov byte [rbp + rdx], 0xa
test rbx, rbx
jle 0x408020
lea r12d, [rdi + 1]
xor esi, esi
jmp 0x407f9f
sub rbx, rax
add rsi, rax
test rbx, rbx
jle 0x408020
xor r9d, r9d
xor edx, edx
mov dword [rsp + 0x80], 0
mov dword [rsp + 0x84], 0
mov qword [rsp + 0x148], rdi
mov ecx, r12d
mov dword [rsp + 0x140], 1
mov qword [rsp + 0x20], r13
mov r8, qword [rsp + 0x38]
call r14
test eax, eax
jle 0x408153
xor r9d, r9d
lea rdx, [rbp + rsi]
mov r8d, ebx
mov rcx, rdi
call r15
cdqe
test rax, rax
jns 0x407f90
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
cmp eax, 0x2733
jne 0x408153
xor eax, eax
sub rbx, rax
add rsi, rax
test rbx, rbx
jg 0x407f9f
nop dword [rax + rax]
mov rcx, qword [rsp + 0x50]
call fcn.006008b0
mov rax, qword [rsp + 0x40]
xor r9d, r9d
xor r8d, r8d
mov dword [rsp + 0x140], 1
mov dword [rsp + 0x80], 0x1e
mov dword [rsp + 0x84], 0
mov rdx, qword [rsp + 0x38]
mov rcx, qword [rax + 0x118]
mov qword [rsp + 0x20], r13
mov qword [rsp + 0x148], rcx
add ecx, 1
call r14
test eax, eax
jle 0x408280
mov rcx, qword [rsp + 0x40]
call fcn.00407840
test rax, rax
mov qword [rsp + 0x58], rax
je 0x40816b
mov rdx, qword [rsp + 0x60]
mov rdi, rax
mov rcx, rax
call fcn.005f9b10
mov rcx, rdi
mov rsi, rax
mov qword [rsp + 0x48], rax
call sub.msvcrt.dll_free
test rsi, rsi
je 0x4081b9
mov rdi, qword [rsp + 0x48]
lea rdx, str.result
mov rcx, rdi
call fcn.005fa400
lea rdx, str.error
mov rsi, rax
mov rcx, rdi
call fcn.005fa400
test rsi, rsi
mov rdi, rax
je 0x408103
cmp dword [rsi], 7
je 0x408103
test rax, rax
je 0x408293
cmp dword [rax], 7
je 0x408293
cmp byte [0x007ef0a0], 0
jne 0x408115
xor ebx, ebx
cmp byte [rsp + 0x7b], 0
je 0x408149
mov rcx, rbp
call sub.msvcrt.dll_free
test rdi, rdi
je 0x4084ff
mov edx, 3
mov rcx, rdi
call fcn.005fce30
mov rbp, rax
lea rdx, str.JSON_RPC_call_failed:__s
mov r8, rbp
xor ecx, ecx
xor ebx, ebx
call fcn.004060f0
mov rcx, rbp
call sub.msvcrt.dll_free
jmp 0x40817d
mov rcx, qword [rsp + 0x50]
call fcn.006008b0
lea rdx, str.stratum_subscribe_send_failed
xor ecx, ecx
call fcn.004060f0
mov rcx, rbp
call sub.msvcrt.dll_free
cmp qword [rsp + 0x48], 0
je 0x4081e0
xor ebx, ebx
mov rsi, qword [rsp + 0x48]
mov eax, dword [rsi + 4]
cmp eax, 0xffffffff
je 0x40819c
sub eax, 1
test eax, eax
mov dword [rsi + 4], eax
jne 0x40819c
mov rcx, rsi
call fcn.005faa90
test bl, bl
jne 0x4081f3
cmp qword [rsp + 0x58], 0
je 0x4081f1
cmp byte [rsp + 0x7b], 0
jne 0x4081f1
mov byte [rsp + 0x7b], 1
jmp 0x407ec0
mov r9, qword [rsp + 0x60]
mov r8d, dword [rsp + 0x130]
lea rdx, str.JSON_decode_failed__d_:__s
xor ecx, ecx
call fcn.004060f0
mov rcx, rbp
call sub.msvcrt.dll_free
nop dword [rax]
cmp qword [rsp + 0x58], 0
mov qword [rsp + 0x48], 0
jne 0x4081a8
xor ebx, ebx
mov eax, ebx
add rsp, 0x358
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
movabs rax, 0x31203a226469227b
mov ebx, 0x7d
mov dword [rbp + 0x30], 0x5d5b203a
mov qword [rbp], rax
movabs rax, 0x6f6874656d22202c
mov word [rbp + 0x34], bx
mov qword [rbp + 8], rax
movabs rax, 0x6e696d22203a2264
mov qword [rbp + 0x10], rax
movabs rax, 0x736275732e676e69
mov qword [rbp + 0x18], rax
movabs rax, 0x202c226562697263
mov qword [rbp + 0x20], rax
movabs rax, 0x22736d6172617022
mov qword [rbp + 0x28], rax
jmp 0x407f09
lea rdx, str.stratum_subscribe_timed_out
xor ecx, ecx
call fcn.004060f0
jmp 0x40816b
xor edx, edx
mov rcx, rsi
call fcn.005fa650
test rax, rax
mov rdi, rax
je 0x408319
cmp dword [rax], 1
jne 0x408319
mov rcx, rax
call fcn.005fa630
test eax, eax
jle 0x408319
mov qword [rsp + 0x70], rsi
xor ebx, ebx
mov r12, rbp
mov esi, eax
jmp 0x4082ff
cmp dword [rax], 1
jne 0x408311
xor edx, edx
mov rcx, rax
call fcn.005fa650
mov rcx, rax
call fcn.005fa870
test rax, rax
je 0x4082f8
lea rdx, str.mining.notify
mov rcx, rax
call qword [sym.imp.msvcrt.dll__stricmp]
test eax, eax
je 0x40854a
add ebx, 1
cmp esi, ebx
je 0x408311
mov edx, ebx
mov rcx, rdi
call fcn.005fa650
test rax, rax
mov rbp, rax
jne 0x4082c4
mov rsi, qword [rsp + 0x70]
mov rbp, r12
cmp byte [0x007ef0a0], 0
jne 0x408586
xor edi, edi
mov edx, 1
mov rcx, rsi
call fcn.005fa650
mov rcx, rax
call fcn.005fa870
test rax, rax
mov r12, rax
je 0x40851d
mov edx, 2
mov rcx, rsi
call fcn.005fa650
mov rcx, rax
call fcn.005fa960
test eax, eax
mov dword [rsp + 0x7c], eax
jne 0x40837b
lea rdx, str.Failed_to_get_extranonce2_size
xor ecx, ecx
xor ebx, ebx
call fcn.004060f0
jmp 0x408149
mov rcx, qword [rsp + 0x68]
call fcn.00600c90
mov rsi, qword [rsp + 0x40]
mov rcx, qword [rsi + 0x140]
call sub.msvcrt.dll_free
mov rcx, qword [rsi + 0x150]
call sub.msvcrt.dll_free
xor eax, eax
test rdi, rdi
je 0x4083b1
mov rcx, rdi
call sub.msvcrt.dll__strdup_1
mov rsi, qword [rsp + 0x40]
mov rcx, r12
mov qword [rsi + 0x140], rax
call sub.msvcrt.dll_strlen
mov rbx, rax
shr rbx, 1
mov qword [rsi + 0x148], rbx
mov rcx, rbx
call sub.msvcrt.dll_malloc
mov byte [rsp + 0x82], 0
mov qword [rsi + 0x150], rax
movzx edx, byte [r12]
test dl, dl
je 0x408497
test rbx, rbx
je 0x408497
movzx r8d, byte [r12 + 1]
add rbx, rax
lea rsi, [rax + 1]
test r8b, r8b
je 0x408537
mov qword [rsp + 0x70], rdi
mov rdi, rsi
mov rsi, qword [rsp + 0x38]
jmp 0x408451
add r12, 2
movzx edx, byte [r12]
test dl, dl
je 0x408513
cmp rdi, rbx
je 0x408513
movzx r8d, byte [r12 + 1]
add rdi, 1
test r8b, r8b
je 0x408532
mov byte [rsp + 0x80], dl
mov byte [rsp + 0x81], r8b
mov rdx, rsi
mov r8d, 0x10
mov rcx, r13
call sub.msvcrt.dll_strtol
mov byte [rdi - 1], al
mov rax, qword [rsp + 0x140]
cmp byte [rax], 0
je 0x408424
lea rdx, str.hex2bin_failed_on__s
mov r8, r13
xor ecx, ecx
mov rdi, qword [rsp + 0x70]
call fcn.004060f0
mov rax, qword [rsp + 0x40]
movsxd rsi, dword [rsp + 0x7c]
mov ebx, 1
movsd xmm0, qword [0x0065cf40]
mov rcx, qword [rsp + 0x68]
movsd qword [rax + 0x138], xmm0
mov qword [rax + 0x158], rsi
call fcn.006008b0
cmp byte [0x007ef0a0], 0
je 0x408149
test rdi, rdi
je 0x408149
mov rax, qword [rsp + 0x40]
lea rdx, str.Stratum_session_id:__s
mov ecx, 4
mov r8, qword [rax + 0x140]
call fcn.004060f0
jmp 0x408149
lea rcx, str._unknown_reason_
call sub.msvcrt.dll__strdup_1
mov rbp, rax
jmp 0x408136
mov rdi, qword [rsp + 0x70]
jmp 0x408497
lea rdx, str.Failed_to_get_extranonce1
xor ecx, ecx
xor ebx, ebx
call fcn.004060f0
jmp 0x408149
mov rdi, qword [rsp + 0x70]
lea rdx, str.hex2bin_str_truncated
xor ecx, ecx
call fcn.004060f0
jmp 0x408497
mov rax, r12
mov r12, rbp
mov edx, 1
mov rcx, r12
mov rsi, qword [rsp + 0x70]
mov rbp, rax
call fcn.005fa650
mov rcx, rax
call fcn.005fa870
cmp byte [0x007ef0a0], 0
mov rdi, rax
je 0x408328
test rax, rax
jne 0x408328
lea rdx, str.Failed_to_get_Stratum_session_id
mov ecx, 4
call fcn.004060f0
jmp 0x408326
mov ecx, pe_nt_image_headers64
call sub.msvcrt.dll_malloc
cmp byte [rsp + 0x7b], 0
mov rbp, rax
jne 0x408210
movabs rax, 0x31203a226469227b
mov qword [rbp], rax
movabs rax, 0x6f6874656d22202c
mov qword [rbp + 8], rax
movabs rax, 0x6e696d22203a2264
mov qword [rbp + 0x10], rax
movabs rax, 0x736275732e676e69
mov qword [rbp + 0x18], rax
movabs rax, 0x202c226562697263
mov qword [rbp + 0x20], rax
movabs rax, 0x22736d6172617022
mov qword [rbp + 0x28], rax
movabs rax, 0x6d757063225b203a
mov qword [rbp + 0x30], rax
movabs rax, 0x342e322f72656e69
mov qword [rbp + 0x38], rax
movabs rax, 0x7d5d226e63782d
mov qword [rbp + 0x40], rax
jmp 0x407f09