Function at 0x1005c2a0
Capabilities:
Send data
Send data on socket

Disassembly:
mov r11, rsp
sub rsp, 0xc8
mov rax, qword [0x100b4478]
xor rax, rsp
mov qword [rsp + 0x90], rax
mov qword [r11 + 0x18], rbx
mov qword [r11 + 0x20], rbp
mov qword [r11 - 8], rsi
mov qword [r11 - 0x10], rdi
mov rbx, rcx
mov qword [r11 - 0x18], r12
mov rax, qword [rbx + 0x10]
mov qword [r11 - 0x20], r13
mov qword [r11 - 0x28], r14
mov rsi, qword [rax]
xor r14d, r14d
lea rcx, str.octet
cmp dword [rsi + 0x78c], r14d
lea r13, str.netascii
mov ebp, r14d
cmove r13, rcx
cmp edx, 7
ja case.0x1005bede.1
movsxd rax, edx
lea rdx, [0x10000000]
mov ecx, dword [rdx + rax*4 + 0x5c280]
add rcx, rdx
jmp rcx
add dword [rbx + 0x20], 1
mov eax, dword [rbx + 0x20]
cmp eax, dword [rbx + 0x28]
jle 0x1005bf00
mov dword [rbx + 8], 0xffffff9e
mov dword [rbx], 3
xor eax, eax
jmp 0x1005c22d
cmp dword [rsi + 0x7c4], ebp
je 0x1005bf48
lea r12, [rbx + 0x170]
mov dx, 2
mov rcx, r12
call fcn.1005ae00
mov rax, qword [rbx + 0x10]
mov rdx, qword [r12]
mov rcx, qword [rax]
add rdx, 4
mov qword [rcx + 0x1f0], rdx
mov rdx, qword [rsi + 0x10e0]
cmp rdx, 0xffffffffffffffff
je 0x1005bf5b
mov rcx, rsi
call fcn.100700f0
jmp 0x1005bf5b
lea r12, [rbx + 0x170]
mov dx, 1
mov rcx, r12
call fcn.1005ae00
mov rax, qword [rbx + 0x10]
lea r9, [rsp + 0x40]
xor r8d, r8d
mov rcx, qword [rax]
mov dword [rsp + 0x28], r14d
mov qword [rsp + 0x20], r14
mov rdx, qword [rcx + 0x10a8]
mov rcx, rsi
add rdx, 1
call fcn.1006f450
test eax, eax
mov ebp, eax
jne 0x1005c22d
movsxd r10, dword [rbx + 0x15c]
mov r9, qword [rsp + 0x40]
xor eax, eax
mov rcx, 0xffffffffffffffff
mov rdi, r13
mov rdx, r10
repne scasb al, byte [rdi]
mov rdi, r9
not rcx
sub rcx, 1
sub rdx, rcx
mov rcx, 0xffffffffffffffff
repne scasb al, byte [rdi]
sub rdx, 4
not rcx
sub rcx, 1
cmp rcx, rdx
jbe 0x1005bff6
lea rdx, str.TFTP_file_name_too_long_n
mov rcx, rsi
call fcn.1004b840
mov rcx, qword [rsp + 0x40]
call qword [fcn.10021fb0]
lea eax, [rbp + 0x47]
jmp 0x1005c22d
mov rcx, qword [r12]
mov qword [rsp + 0x30], r14
lea r8, str._s_c_s_c
mov rdx, r10
add rcx, 2
mov qword [rsp + 0x28], r13
mov qword [rsp + 0x20], r14
call fcn.1006e680
mov rdi, qword [rsp + 0x40]
xor eax, eax
mov rcx, 0xffffffffffffffff
repne scasb al, byte [rdi]
mov rdi, r13
not rcx
lea rdx, [rcx - 1]
mov rcx, 0xffffffffffffffff
repne scasb al, byte [rdi]
cmp dword [rsi + 0x350], eax
not rcx
lea rdi, [rdx + rcx + 3]
jne 0x1005c164
cmp dword [rsi + 0x7c4], eax
je 0x1005c07e
mov r9, qword [rsi + 0x10e0]
cmp r9, 0xffffffffffffffff
je 0x1005c07e
lea r8, str._I64d
lea edx, [rax + 0x40]
lea rcx, [rsp + 0x50]
call fcn.1006e680
jmp 0x1005c085
mov word [rsp + 0x50], gethostbyname
mov rax, qword [r12]
lea r9, str.tsize
mov rdx, rdi
lea r8, [rdi + rax]
mov rcx, rbx
call fcn.1005b210
lea r9, [rsp + 0x50]
mov rcx, rbx
add rdi, rax
mov rax, qword [r12]
lea r8, [rdi + rax]
mov rdx, rdi
call fcn.1005b210
mov r9d, dword [rbx + 0x160]
lea r8, [0x1008bea0]
lea rcx, [rsp + 0x50]
mov edx, 0x40
add rdi, rax
call fcn.1006e680
mov rdx, qword [r12]
lea r9, str.blksize
lea r8, [rdi + rdx]
mov rdx, rdi
mov rcx, rbx
call fcn.1005b210
lea r9, [rsp + 0x50]
mov rcx, rbx
add rdi, rax
mov rax, qword [r12]
lea r8, [rdi + rax]
mov rdx, rdi
call fcn.1005b210
mov r9d, dword [rbx + 0x24]
lea r8, [0x1008bea0]
lea rcx, [rsp + 0x50]
mov edx, 0x40
add rdi, rax
call fcn.1006e680
mov rdx, qword [r12]
lea r9, str.timeout
lea r8, [rdi + rdx]
mov rdx, rdi
mov rcx, rbx
call fcn.1005b210
lea r9, [rsp + 0x50]
mov rcx, rbx
add rdi, rax
mov rax, qword [r12]
lea r8, [rdi + rax]
mov rdx, rdi
call fcn.1005b210
add rdi, rax
mov rax, qword [rbx + 0x10]
mov rdx, qword [r12]
xor r9d, r9d
mov rcx, qword [rax + 0x70]
mov r8d, edi
mov eax, dword [rcx + 0x10]
mov dword [rsp + 0x28], eax
mov rax, qword [rcx + 0x20]
mov rcx, qword [rbx + 0x18]
mov qword [rsp + 0x20], rax
call qword [sym.imp.WS2_32.dll_sendto]
movsxd rcx, eax
cmp rcx, rdi
je 0x1005c1bb
call qword [sym.imp.WS2_32.dll_WSAGetLastError]
mov rcx, qword [rbx + 0x10]
mov edx, eax
call fcn.10076e10
lea rdx, [0x1008d828]
mov rcx, rsi
mov r8, rax
call fcn.1004b840
mov rcx, qword [rsp + 0x40]
call qword [fcn.10021fb0]
jmp 0x1005c22b
cmp dword [rsi + 0x7c4], ebp
je 0x1005c1e1
mov edx, 6
mov rcx, rbx
call fcn.1005bda0
mov ebp, eax
jmp 0x1005c22b
mov edx, 6
mov rcx, rbx
call fcn.1005be00
mov ebp, eax
jmp 0x1005c22b
mov edx, 4
mov rcx, rbx
call fcn.1005bda0
mov ebp, eax
jmp 0x1005c22b
mov edx, 3
mov rcx, rbx
call fcn.1005be00
mov ebp, eax
jmp 0x1005c22b
mov dword [rbx], 3
jmp 0x1005c22b
lea rdx, str.tftp_send_first:_internal_error
mov rcx, rsi
call fcn.1004b840
mov eax, ebp
mov r14, qword [rsp + 0xa0]
mov r13, qword [rsp + 0xa8]
mov r12, qword [rsp + 0xb0]
mov rdi, qword [rsp + 0xb8]
mov rsi, qword [rsp + 0xc0]
mov rbp, qword [rsp + 0xe8]
mov rbx, qword [rsp + 0xe0]
mov rcx, qword [rsp + 0x90]
xor rcx, rsp
call fcn.10021bf0
add rsp, 0xc8
ret
sub rsp, 0x28
mov rax, qword [rcx + 0x10]
mov r8d, dword [rcx]
test r8d, r8d
mov r9, qword [rax]
je 0x1005c311
sub r8d, 1
je 0x1005c308
sub r8d, 1
je 0x1005c2ff
cmp r8d, 1
mov rcx, r9
je 0x1005c2e5
lea r8, str.Internal_state_machine_error
lea rdx, [0x1008d828]
call fcn.1004b840
mov eax, 0x47
add rsp, 0x28
ret
lea r8, str.TFTP_finished
lea rdx, [0x1008c5b8]
call fcn.1004b790
xor eax, eax
add rsp, 0x28
ret
add rsp, 0x28
jmp fcn.1005b560
add rsp, 0x28
jmp fcn.1005b270
add rsp, 0x28
jmp 0x1005be60