Function at 0x180024250
Capabilities:
Encode data using xor
Encrypt data using tea

Disassembly:
push rbx
push rdi
push r13
sub rsp, 0x80
mov rax, qword [0x18005d0e0]
xor rax, rsp
mov qword [rsp + 0x58], rax
mov rdi, qword [rsp + 0xc0]
mov eax, edx
mov qword [rsp + 0x38], r9
and eax, 0x80000007
mov r9, r8
mov qword [rsp + 0x20], r8
mov ebx, edx
mov r13, rcx
jge 0x180024295
dec eax
or eax, 0xfffffff8
inc eax
test eax, eax
jne 0x18002469b
cmp edx, 0x10
jl 0x18002469b
lea r8, [rsp + 0x48]
mov rdx, r9
mov qword [rsp + 0x68], r14
call fcn.180023e20
movzx r11d, byte [rsp + 0x48]
mov r14d, ebx
and r11d, 7
sub r14d, r11d
sub r14d, 0xa
cmp dword [rdi], r14d
jl 0x180024697
test r14d, r14d
js 0x180024697
xor eax, eax
mov qword [rsp + 0xa8], rbp
mov qword [rsp + 0x78], rsi
mov qword [rsp + 0x70], r12
mov dword [rdi], r14d
lea rbp, [r13 + 8]
lea r12d, [rax + 8]
lea esi, [rax + 1]
mov qword [rsp + 0x60], r15
mov qword [rsp + 0x50], rax
lea r15, [rsp + 0x50]
lea rax, [rsp + 0x48]
mov rdi, rbp
inc r11d
mov qword [rsp + 0x28], r15
sub rdi, rax
cmp r11d, 8
jge 0x180024331
inc r11d
inc esi
cmp r11d, 8
jne 0x180024383
mov r15, r13
mov qword [rsp + 0x28], r13
xor edx, edx
mov r8d, r12d
cmp r8d, ebx
jge 0x180024693
lea rcx, [rsp + rdx + 0x48]
inc rdx
inc r8d
movzx eax, byte [rdi + rcx]
xor byte [rcx], al
cmp rdx, 8
jl 0x180024340
mov rdx, qword [rsp + 0x20]
lea r8, [rsp + 0x48]
lea rcx, [rsp + 0x48]
call fcn.180023e20
add r12d, 8
add rbp, 8
add rdi, 8
xor r11d, r11d
cmp esi, 2
jle 0x180024322
movsxd rcx, r11d
test r14d, r14d
je 0x18002450f
lea rax, [rsp + 0x48]
mov rdi, rbp
sub rdi, rax
lea rax, [rsp + 0x48]
sub rax, 8
mov qword [rsp + 0x40], rax
nop dword [rax]
cmp rcx, 8
jge 0x1800243e1
movzx eax, byte [rcx + r15]
mov rdx, qword [rsp + 0x38]
inc rcx
xor al, byte [rsp + rcx + 0x47]
inc rdx
dec r14d
mov byte [rdx - 1], al
mov rax, qword [rsp + 0x40]
inc r11d
mov qword [rsp + 0x38], rdx
cmp rcx, 8
jne 0x1800244fb
add rax, rdi
mov r8d, r12d
xor edx, edx
mov qword [rsp + 0x28], rax
cmp r8d, ebx
jge 0x180024693
lea rcx, [rsp + rdx + 0x48]
inc rdx
inc r8d
movzx eax, byte [rdi + rcx]
xor byte [rcx], al
cmp rdx, 8
jl 0x1800243f4
mov ecx, dword [rsp + 0x48]
call qword [sym.imp.WS2_32.dll_ntohl]
mov ecx, dword [rsp + 0x4c]
mov esi, eax
call qword [sym.imp.WS2_32.dll_ntohl]
mov r13d, eax
mov rax, qword [rsp + 0x20]
mov ecx, dword [rax]
call qword [sym.imp.WS2_32.dll_ntohl]
mov r15d, eax
mov rax, qword [rsp + 0x20]
mov ecx, dword [rax + 4]
call qword [sym.imp.WS2_32.dll_ntohl]
mov dword [rsp + 0x34], eax
mov rax, qword [rsp + 0x20]
mov ecx, dword [rax + 8]
call qword [sym.imp.WS2_32.dll_ntohl]
mov dword [rsp + 0x30], eax
mov rax, qword [rsp + 0x20]
mov ecx, dword [rax + 0xc]
call qword [sym.imp.WS2_32.dll_ntohl]
mov r9d, dword [rsp + 0x34]
mov r10d, dword [rsp + 0x30]
mov r11d, eax
mov edx, 0xe3779b90
mov r8d, reloc.WS2_32.dll_recv
nop word [rax + rax]
mov ecx, esi
mov eax, esi
shr ecx, 5
shl eax, 4
add ecx, r11d
add eax, r10d
xor ecx, eax
lea eax, [rdx + rsi]
xor ecx, eax
sub r13d, ecx
mov ecx, r13d
mov eax, r13d
shr ecx, 5
shl eax, 4
add ecx, r9d
add eax, r15d
xor ecx, eax
lea eax, [rdx + r13]
add edx, 0x61c88647
xor ecx, eax
sub esi, ecx
dec r8d
jne 0x180024490
mov ecx, esi
call qword [sym.imp.WS2_32.dll_htonl]
mov ecx, r13d
mov dword [rsp + 0x48], eax
call qword [sym.imp.WS2_32.dll_htonl]
add r12d, 8
add rbp, 8
add rdi, 8
xor r11d, r11d
mov dword [rsp + 0x4c], eax
xor ecx, ecx
test r14d, r14d
je 0x18002450f
mov rax, qword [rsp + 0x40]
mov r15, qword [rsp + 0x28]
jmp 0x1800243b0
mov rdx, qword [rsp + 0x28]
mov r13d, 1
movsxd rcx, r11d
nop dword [rax]
cmp rcx, 8
jge 0x18002453e
movzx eax, byte [rcx + rdx]
xor al, byte [rsp + rcx + 0x48]
jne 0x180024693
inc rcx
inc r11d
cmp rcx, 8
jne 0x18002464c
xor r11d, r11d
mov qword [rsp + 0x28], rbp
mov edx, r12d
xor ecx, ecx
cmp edx, ebx
jge 0x180024649
movzx eax, byte [rcx + rbp]
inc rcx
inc r11d
xor byte [rsp + rcx + 0x47], al
inc edx
cmp rcx, 8
jl 0x180024551
mov ecx, dword [rsp + 0x48]
call qword [sym.imp.WS2_32.dll_ntohl]
mov ecx, dword [rsp + 0x4c]
mov edi, eax
call qword [sym.imp.WS2_32.dll_ntohl]
mov r15, qword [rsp + 0x20]
mov ecx, dword [r15]
mov esi, eax
call qword [sym.imp.WS2_32.dll_ntohl]
mov ecx, dword [r15 + 4]
mov r14d, eax
call qword [sym.imp.WS2_32.dll_ntohl]
mov r15d, eax
mov rax, qword [rsp + 0x20]
mov ecx, dword [rax + 8]
call qword [sym.imp.WS2_32.dll_ntohl]
mov dword [rsp + 0x30], eax
mov rax, qword [rsp + 0x20]
mov ecx, dword [rax + 0xc]
call qword [sym.imp.WS2_32.dll_ntohl]
mov r9d, dword [rsp + 0x30]
mov edx, 0xe3779b90
mov r11d, eax
mov r8d, reloc.WS2_32.dll_recv
nop dword [rax + rax]
mov ecx, edi
mov eax, edi
shr ecx, 5
shl eax, 4
add ecx, r11d
add eax, r9d
xor ecx, eax
lea eax, [rdx + rdi]
xor ecx, eax
sub esi, ecx
mov ecx, esi
mov eax, esi
shr ecx, 5
shl eax, 4
add ecx, r15d
add eax, r14d
xor ecx, eax
lea eax, [rdx + rsi]
add edx, 0x61c88647
xor ecx, eax
sub edi, ecx
dec r8d
jne 0x1800245e0
mov ecx, edi
call qword [sym.imp.WS2_32.dll_htonl]
mov ecx, esi
mov dword [rsp + 0x48], eax
call qword [sym.imp.WS2_32.dll_htonl]
mov rdx, qword [rsp + 0x28]
add r12d, 8
add rbp, 8
xor r11d, r11d
mov dword [rsp + 0x4c], eax
xor ecx, ecx
jmp 0x18002464c
mov rdx, rbp
inc r13d
cmp r13d, 8
jl 0x180024520
mov eax, 1
mov rbp, qword [rsp + 0xa8]
mov r12, qword [rsp + 0x70]
mov rsi, qword [rsp + 0x78]
mov r15, qword [rsp + 0x60]
mov r14, qword [rsp + 0x68]
mov rcx, qword [rsp + 0x58]
xor rcx, rsp
call fcn.18002f950
add rsp, 0x80
pop r13
pop rdi
pop rbx
ret
xor eax, eax
jmp 0x18002465e
xor eax, eax
jmp 0x180024675
xor eax, eax
jmp 0x18002467a