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

Disassembly:
mov eax, dword fs:[0]
push 0xffffffffffffffff
push 0x62d950
push eax
mov dword fs:[0], esp
sub esp, 0x18
push ebx
push ebp
mov ebp, dword [esp + 0x30]
mov ebx, ecx
push esi
push edi
mov cl, byte [ebp + 6]
mov eax, ecx
and eax, 0xff
lea eax, [eax + eax*4]
lea esi, [ebx + eax*8 + 0x3e98]
mov al, byte [ebp + 4]
test al, al
je 0x5a09f1
mov edi, dword [esi + 0x18]
mov dl, 2
cmp edi, dword [ebp + 0x18]
jne 0x5a09de
cmp al, 1
jne 0x5a09de
mov byte [ebp + 4], dl
mov eax, dword [esi + 0xc]
mov esi, dword [ebp + 0xc]
cmp eax, esi
jne 0x5a09f1
cmp byte [ebp + 4], dl
jne 0x5a09f1
mov byte [ebp + 4], 3
mov al, byte [ebp + 4]
cmp al, 3
jbe 0x5a0a47
mov ecx, dword [0x6cd768]
mov dword [esp + 0x44], ecx
and eax, 0xff
lea edx, [esp + 0x44]
push eax
push str.SendPacket_failed__Header_type:_0x_02x
push edx
mov dword [esp + 0x3c], 0
call fcn.005fc86b
mov eax, dword [esp + 0x50]
add esp, 0xc
mov ecx, ebx
push eax
call fcn.0054d2a0
lea ecx, [esp + 0x44]
mov dword [esp + 0x30], 0xffffffff
call fcn.00603a3c
or eax, 0xffffffff
jmp 0x5a0d8e
mov edx, eax
and edx, 0xff
shl al, 6
mov esi, dword [edx*4 + 0x63f1b4]
xor edx, edx
mov dword [esp + 0x1d], edx
or al, cl
mov dword [esp + 0x21], edx
cmp esi, 1
mov word [esp + 0x25], dx
mov dword [esp + 0x10], esi
mov byte [esp + 0x27], dl
mov byte [esp + 0x1c], al
jle 0x5a0a8c
mov eax, dword [ebp + 8]
lea ecx, [esp + 0x1d]
push eax
push ecx
call fcn.005a0780
add esp, 8
cmp esi, 4
jle 0x5a0aa9
mov edx, dword [ebp + 0x18]
lea eax, [esp + 0x20]
push edx
push eax
call fcn.005a0780
mov cl, byte [ebp + 5]
add esp, 8
mov byte [esp + 0x23], cl
cmp esi, 8
jle 0x5a0abf
mov edx, dword [ebp + 0xc]
lea eax, [esp + 0x24]
push edx
push eax
call fcn.00542430
add esp, 8
mov ecx, dword [ebx + 0xb0]
xor edi, edi
mov dword [esp + 0x14], edi
mov dword [esp + 0x38], edi
cmp dword [ecx + 0x24], 5
jne 0x5a0b61
mov dl, byte [esp + 0x44]
mov eax, dword [ebp + 0x18]
neg dl
sbb edx, edx
mov ecx, esi
and edx, 0x600
add ecx, edx
lea edx, [ecx + eax*2]
push edx
call fcn.005ffe3f
add esp, 4
mov dword [esp + 0x14], eax
test eax, eax
jne 0x5a0b0c
mov eax, 0x753b
jmp 0x5a0d8e
mov cl, byte [esp + 0x44]
test cl, cl
je 0x5a0b39
mov edx, dword [ebx + 0x3200]
test edx, edx
je 0x5a0b39
mov ecx, 0x180
mov esi, edx
mov edi, eax
mov dword [esp + 0x38], 0x600
rep movsd dword es:[edi], dword [esi]
mov esi, dword [esp + 0x10]
mov edi, dword [esp + 0x38]
mov ecx, esi
add edi, eax
mov eax, ecx
lea esi, [esp + 0x1c]
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, eax
mov eax, dword [esp + 0x38]
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x10]
add eax, ecx
mov dword [esp + 0x38], eax
mov edi, eax
jmp 0x5a0b89
mov eax, dword [ebx + 0x31d8]
push str.send_rtmp_header
push edi
lea edx, [esp + 0x24]
push esi
push edx
push eax
call sub.WS2_32.dll_send
push eax
mov ecx, ebx
call fcn.0054d360
test eax, eax
jne 0x5a0d8e
mov ecx, dword [ebp + 0x18]
mov esi, dword [ebp + 0x20]
test ecx, ecx
mov dword [esp + 0x10], ecx
mov dword [esp + 0x18], esi
je 0x5a0c9e
jmp 0x5a0ba5
mov esi, dword [esp + 0x18]
cmp byte [ebp + 5], 0x14
jne 0x5a0bb6
mov eax, 0x80
mov dword [esp + 0x44], eax
jmp 0x5a0bbf
mov edx, dword [ebp + 0x18]
mov dword [esp + 0x44], edx
mov eax, edx
cmp ecx, 0x80
jge 0x5a0bcd
mov dword [esp + 0x44], ecx
mov eax, ecx
mov ecx, dword [ebx + 0xb0]
cmp dword [ecx + 0x24], 5
jne 0x5a0c01
mov edx, dword [esp + 0x14]
mov ecx, eax
add edi, edx
mov edx, ecx
shr ecx, 2
rep movsd dword es:[edi], dword [esi]
mov ecx, edx
and ecx, 3
rep movsb byte es:[edi], byte [esi]
mov ecx, dword [esp + 0x38]
add ecx, eax
mov dword [esp + 0x38], ecx
mov edi, ecx
mov ecx, dword [esp + 0x10]
jmp 0x5a0c2e
push str.send_rtmp_packet
push 0
push eax
mov eax, dword [ebx + 0x31d8]
push esi
push eax
call sub.WS2_32.dll_send
push eax
mov ecx, ebx
call fcn.0054d360
test eax, eax
jne 0x5a0d8e
mov ecx, dword [esp + 0x10]
mov eax, dword [esp + 0x44]
mov edx, dword [esp + 0x18]
sub ecx, eax
add edx, eax
mov dword [esp + 0x10], ecx
test ecx, ecx
mov dword [esp + 0x18], edx
jle 0x5a0c98
mov al, byte [ebp + 6]
mov edx, dword [ebx + 0xb0]
or al, 0xc0
mov byte [esp + 0x44], al
mov esi, dword [edx + 0x24]
cmp esi, 5
jne 0x5a0c68
mov edx, dword [esp + 0x14]
inc edi
mov dword [esp + 0x38], edi
mov byte [edi + edx - 1], al
jmp 0x5a0c96
mov ecx, dword [ebx + 0x31d8]
push str.send_rtmp_packet
push 0
lea eax, [esp + 0x4c]
push 1
push eax
push ecx
call sub.WS2_32.dll_send
push eax
mov ecx, ebx
call fcn.0054d360
test eax, eax
jne 0x5a0d8e
mov ecx, dword [esp + 0x10]
test ecx, ecx
jne 0x5a0ba1
mov edx, dword [ebx + 0xb0]
cmp dword [edx + 0x24], 5
jne 0x5a0cc2
mov eax, dword [esp + 0x3c]
test eax, eax
je 0x5a0da3
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x40]
mov dword [eax], ecx
mov dword [edx], edi
cmp byte [ebp + 5], 0x14
jne 0x5a0d01
mov eax, dword [ebp + 0x20]
lea ecx, [esp + 0x38]
inc eax
push eax
push ecx
call fcn.005a0620
add esp, 8
mov eax, dword [eax]
lea ecx, [ebx + 0x4998]
push eax
mov dword [esp + 0x34], 1
call fcn.005825d0
lea ecx, [esp + 0x38]
mov dword [esp + 0x30], 0xffffffff
call fcn.00603a3c
xor eax, eax
mov cl, byte [ebp + 4]
mov al, byte [ebp + 6]
push str.Send_packet:_OK_n
lea edx, [eax + eax*4]
lea eax, [ebx + edx*8 + 0x3e98]
mov byte [eax + 4], cl
mov dl, byte [ebp + 5]
mov byte [eax + 5], dl
mov cl, byte [ebp + 6]
mov byte [eax + 6], cl
mov edx, dword [ebp + 8]
mov dword [eax + 8], edx
mov ecx, dword [ebp + 0xc]
mov dword [eax + 0xc], ecx
mov dl, byte [ebp + 0x10]
mov byte [eax + 0x10], dl
mov ecx, dword [ebp + 0x14]
mov dword [eax + 0x14], ecx
mov edx, dword [ebp + 0x18]
mov dword [eax + 0x18], edx
mov ecx, dword [ebp + 0x1c]
mov dword [eax + 0x1c], ecx
mov edx, dword [ebp + 0x20]
mov dword [eax + 0x20], edx
mov cl, byte [ebp + 0x24]
mov byte [eax + 0x24], cl
xor eax, eax
mov al, byte [ebp + 6]
mov ecx, ebx
lea edx, [eax + eax*4]
mov dword [ebx + edx*8 + 0x3eb8], 0
call fcn.0054d2a0
mov eax, dword [ebx + 0xb0]
cmp dword [eax + 0x24], 5
jne 0x5a0d8c
mov eax, dword [esp + 0x3c]
test eax, eax
jne 0x5a0d8c
mov ecx, ebx
call fcn.0059e000
xor eax, eax
mov ecx, dword [esp + 0x28]
pop edi
pop esi
pop ebp
pop ebx
mov dword fs:[0], ecx
add esp, 0x24
ret 0x10
push edi
mov edi, dword [esp + 0x18]
push edi
push str.send
mov ecx, ebx
call fcn.005a0050
push edi
mov esi, eax
call fcn.005ffe68
add esp, 4
test esi, esi
je 0x5a0cc2
mov eax, esi
jmp 0x5a0d8e