Function at 0x140178260
Capabilities:
Encode data using xor

Disassembly:
push rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
mov eax, 0xb8
call fcn.140186310
sub rsp, rax
mov rax, qword [0x140361e80]
xor rax, rsp
mov qword [rsp + 0xa0], rax
mov qword [rsp + 0x80], rcx
mov rdi, r9
mov rcx, r9
mov qword [rsp + 0x78], r9
mov rsi, r8
mov qword [rsp + 0x68], r8
mov rbx, rdx
xor r14d, r14d
call fcn.1400a2890
mov rcx, rdi
call fcn.1400a25d0
mov rcx, rdi
mov qword [rsp + 0x48], rax
call fcn.1400a25d0
mov rcx, rdi
mov qword [rsp + 0x38], rax
call fcn.1400a25d0
mov rcx, qword [rsp + 0x78]
mov rdi, rax
mov qword [rsp + 0x70], rax
call fcn.1400a25d0
mov qword [rsp + 0x40], rax
mov r15, rax
test rax, rax
je 0x140178765
mov r8d, 6
lea rdx, [rsp + 0x88]
mov rcx, rsi
call fcn.140179690
test eax, eax
je 0x140178741
cmp eax, 6
jg 0x140178741
lea r8, [rsp + 0x88]
mov rdx, rbx
mov rcx, rdi
call fcn.140177d10
test eax, eax
je 0x140178765
mov rcx, rdi
call fcn.1400a1a90
test eax, eax
jne 0x140178765
mov rdx, rsi
mov rcx, r15
call fcn.1400a17d0
test rax, rax
je 0x140178765
mov rcx, rdi
call fcn.1400a1b80
mov rcx, r15
mov ebp, eax
call fcn.1400a1b80
movsxd r13, dword [rsi + 8]
mov rcx, rdi
mov edx, r13d
mov dword [rsp + 0x30], eax
mov dword [rsp + 0x50], r13d
call fcn.1400a2460
test rax, rax
je 0x140178765
movsxd rax, dword [rdi + 8]
mov r12, r13
mov rbx, qword [rdi]
cmp rax, r13
jge 0x1401783b4
mov r8, r13
lea rcx, [rbx + rax*8]
sub r8, rax
xor edx, edx
shl r8, 3
call fcn.1401bace0
mov dword [rdi + 8], r13d
mov edx, r13d
mov rdi, qword [rsp + 0x48]
mov rcx, rdi
call fcn.1400a2460
test rax, rax
je 0x140178765
mov r15, qword [rdi]
mov qword [r15], 1
cmp r13d, 1
jle 0x1401783f7
lea eax, [r13 - 1]
xor edx, edx
movsxd r8, eax
lea rcx, [r15 + 8]
shl r8, 3
call fcn.1401bace0
mov rcx, qword [rsp + 0x38]
mov edx, r13d
mov dword [rdi + 8], r13d
call fcn.1400a2460
test rax, rax
je 0x140178765
mov r9, qword [rsp + 0x38]
mov rdi, qword [r9]
mov qword [rsp + 0x58], rdi
test r13d, r13d
jle 0x140178439
mov r8, r13
xor edx, edx
shl r8, 3
mov rcx, rdi
call fcn.1401bace0
mov r9, qword [rsp + 0x38]
mov r8, qword [rsp + 0x40]
mov dword [r9 + 8], r13d
mov r11, qword [r8]
mov qword [rsp + 0x60], r11
nop word [rax + rax]
test ebp, ebp
je 0x140178535
nop dword [rax + rax]
mov r9, qword [rbx]
test r9b, 1
jne 0x14017851e
mov rax, qword [r15]
mov r12, r14
mov rcx, qword [rsi]
mov r10, rax
and r10d, 1
neg r10
mov rdx, qword [rcx]
lea ecx, [r13 - 1]
and rdx, r10
movsxd rdi, ecx
xor rax, rdx
test ecx, ecx
jle 0x140178507
mov r13, qword [rsp + 0x68]
lea r11, [r15 + 8]
mov rsi, rbx
mov r14, 0xfffffffffffffff8
sub rsi, r15
mov r12, rdi
sub r14, r15
mov rcx, qword [r11 + rsi]
lea rdx, [r14 + r11]
shl rcx, 0x3f
lea r11, [r11 + 8]
shr r9, 1
or rcx, r9
shr rax, 1
mov r9, qword [r11 + rsi - 8]
mov qword [r11 + rsi - 0x10], rcx
mov rcx, qword [r13]
mov r8, qword [rdx + rcx + 8]
and r8, r10
xor r8, qword [r11 - 8]
mov rcx, r8
shl rcx, 0x3f
or rcx, rax
mov rax, r8
mov qword [r11 - 0x10], rcx
sub rdi, 1
jne 0x1401784b0
mov r13d, dword [rsp + 0x50]
xor r14d, r14d
mov rsi, qword [rsp + 0x68]
shr r9, 1
shr rax, 1
mov qword [rbx + r12*8], r9
mov qword [r15 + r12*8], rax
sub ebp, 1
jne 0x140178460
mov rdi, qword [rsp + 0x58]
mov r11, qword [rsp + 0x60]
mov r8, qword [rsp + 0x40]
mov r9, qword [rsp + 0x38]
movsxd r12, r13d
cmp ebp, 0x40
jg 0x140178550
mov rax, qword [rbx]
test rax, rax
je 0x140178765
cmp rax, 1
je 0x140178718
mov ecx, dword [rsp + 0x30]
cmp ebp, ecx
jge 0x140178592
mov rax, qword [rsp + 0x48]
mov rbx, r11
mov dword [rsp + 0x30], ebp
mov r15, rdi
mov ebp, ecx
mov qword [rsp + 0x48], r9
mov rcx, qword [rsp + 0x70]
mov rdi, qword [rax]
mov qword [rsp + 0x70], r8
mov qword [rsp + 0x40], rcx
mov r11, qword [rcx]
mov qword [rsp + 0x60], r11
mov qword [rsp + 0x38], rax
mov qword [rsp + 0x58], rdi
mov rdx, r14
test r13d, r13d
jle 0x140178676
cmp r13d, 2
jb 0x140178676
lea eax, [r13 - 1]
movsxd rcx, eax
lea r10, [rdi + rcx*8]
lea rax, [r15 + rcx*8]
cmp r15, r10
ja 0x1401785c5
cmp rax, rdi
jae 0x140178676
lea r8, [rbx + rcx*8]
cmp r15, r8
ja 0x1401785d7
cmp rax, rbx
jae 0x140178676
lea r9, [r11 + rcx*8]
cmp r15, r9
ja 0x1401785e9
cmp rax, r11
jae 0x140178676
cmp rbx, r10
ja 0x1401785f7
cmp r8, rdi
jae 0x140178676
lea eax, [r13 - 1]
movsxd rcx, eax
lea rax, [rbx + rcx*8]
cmp rbx, r9
ja 0x14017860c
cmp rax, r11
jae 0x140178676
mov ecx, r13d
and ecx, 0x80000001
jge 0x14017861e
dec ecx
or ecx, 0xfffffffe
inc ecx
mov eax, r13d
mov r8, rdi
sub eax, ecx
sub r8, rbx
mov rcx, r11
movsxd r10, eax
sub rcx, rbx
mov r9, r15
sub r9, rbx
mov rax, rbx
nop dword [rax + rax]
movdqu xmm0, xmmword [rax]
add rdx, 2
movdqu xmm1, xmmword [rax + rcx]
lea rax, [rax + 0x10]
xorps xmm1, xmm0
movdqu xmm0, xmmword [r9 + rax - 0x10]
movdqu xmmword [rax - 0x10], xmm1
movdqu xmm1, xmmword [r8 + rax - 0x10]
xorps xmm1, xmm0
movdqu xmmword [r9 + rax - 0x10], xmm1
cmp rdx, r10
jl 0x140178640
cmp rdx, r12
jge 0x1401786ac
mov r8, r11
lea rcx, [rbx + rdx*8]
mov r9, rdi
sub r8, rbx
sub r9, rbx
mov r10, r15
sub r10, rbx
mov rax, qword [rcx + r8]
inc rdx
xor qword [rcx], rax
mov rax, qword [r9 + rcx]
xor qword [r10 + rcx], rax
lea rcx, [rcx + 8]
cmp rdx, r12
jl 0x140178691
mov r8, qword [rsp + 0x40]
mov r9, qword [rsp + 0x38]
cmp ebp, dword [rsp + 0x30]
jne 0x140178450
lea eax, [rbp - 1]
cdq
and edx, 0x3f
add eax, edx
sar eax, 6
movsxd rdi, eax
mov rax, rdi
mov rcx, qword [rbx + rdi*8]
test rcx, rcx
jne 0x1401786f4
nop dword [rax + rax]
test rax, rax
je 0x1401786f4
mov rcx, qword [rbx + rax*8 - 8]
dec rax
dec edi
test rcx, rcx
je 0x1401786e0
call fcn.1400a1c70
mov r11, qword [rsp + 0x60]
mov r8, qword [rsp + 0x40]
mov r9, qword [rsp + 0x38]
shl edi, 6
lea ebp, [rdi + rax]
mov rdi, qword [rsp + 0x58]
jmp 0x140178450
mov rcx, qword [rsp + 0x48]
call fcn.1400a22f0
mov rdx, qword [rsp + 0x48]
mov rcx, qword [rsp + 0x80]
call fcn.1400a17d0
test rax, rax
je 0x140178765
mov r14d, 1
jmp 0x140178765
lea r9, str.crypto_bn_bn_gf2m.c
mov dword [rsp + 0x20], 0x18e
mov edx, 0x83
mov ecx, 3
mov r8d, WSAGetLastError
call fcn.1400a41b0
mov rcx, qword [rsp + 0x78]
call fcn.1400a2490
mov eax, r14d
mov rcx, qword [rsp + 0xa0]
xor rcx, rsp
call fcn.140185590
add rsp, 0xb8
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
pop rbx
ret