Function at 0x1401521a0
Capabilities:
Encrypt data using rc4 ksa
Resolve function by parsing pe exports

Disassembly:
mov word [rsp + 0x10], dx
mov qword [rsp + 8], rcx
push rbx
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0xb0
mov rax, qword [rcx]
movzx edi, dx
xor edx, edx
mov qword [rsp + 0x88], rax
mov r14, rcx
mov dword [rsp + 0x58], edx
movzx ecx, byte [rcx + 0x3a]
mov r13d, 1
mov r8, qword [rax]
movzx esi, dx
mov qword [rsp + 0x90], r8
movzx r12d, dx
mov qword [rsp + 0x80], rdx
mov dword [rsp + 0x100], ecx
cmp ecx, r13d
jg 0x140152208
mov ebx, r13d
jmp 0x140152218
cmp ecx, 2
mov ebx, 0xa
mov eax, 5
cmove ebx, eax
mov rax, qword [r14 + 0x10]
mov dword [rsp + 0x54], ebx
test rax, rax
je 0x140152234
test di, di
je 0x140152234
mov r15d, dword [rax]
mov dword [rsp + 0x50], r15d
jmp 0x14015223b
mov r15d, edx
mov dword [rsp + 0x50], edx
lea eax, [rcx + 4]
imul eax, ebx
lea ecx, [r15 + rax*8]
add ecx, ecx
movsxd rdx, ecx
mov rcx, r8
call fcn.14010b530
mov qword [rsp + 0x60], rax
mov rdx, rax
test rax, rax
jne 0x140152267
lea eax, [rdx + 7]
jmp 0x140152ca8
movsxd r8, dword [rsp + 0x100]
xor ecx, ecx
mov eax, ebx
shl rax, 5
lea r9, [rax + rdx]
mov qword [rsp + 0xa8], rbp
mov qword [r9], rcx
mov rbp, rdx
mov qword [r9 + 8], rcx
mov qword [r9 + 0x10], rcx
mov qword [r9 + 0x18], rcx
lea rcx, [rax + r9]
shl r8, 3
lea eax, [rbx + rbx]
mov qword [rsp + 0x40], rdx
add rdx, 0x18
mov qword [rsp + 0x70], r9
nop
mov qword [rdx], rcx
lea rdx, [rdx + 0x20]
add rcx, r8
dec eax
test eax, eax
jg 0x1401522b0
test r15d, r15d
je 0x1401522df
movsxd r8, r15d
xor edx, edx
add r8, r8
mov qword [rsp + 0x80], rcx
call fcn.1401803b0
mov r9, qword [rsp + 0x70]
mov rax, qword [rsp + 0x88]
mov ecx, 0x30
mov edx, r13d
mov dword [rsp + 0x6c], edx
mov eax, dword [rax + 0xb4]
cmp eax, ecx
cmovb ecx, eax
mov word [r9 + 0x10], cx
test r15d, r15d
je 0x140152323
movzx eax, r15b
or ecx, 0xffffffff
mov r15d, dword [rsp + 0x100]
test r15d, r15d
cmovg eax, ecx
mov byte [r9 + 0x16], al
jmp 0x14015232b
mov r15d, dword [rsp + 0x100]
xor r8d, r8d
mov ecx, r8d
mov dword [rsp + 0x108], ecx
test r15d, r15d
jle 0x1401529a7
mov r10d, 0x4000
nop word [rax + rax]
mov qword [rsp + 0x48], r9
mov eax, r8d
mov dword [rsp + 0x68], eax
mov r13d, r8d
mov rdi, r9
test edx, edx
jle 0x14015287c
nop word [rax + rax]
mov r15, qword [r14 + 0x48]
test r15, r15
je 0x140152851
nop dword [rax]
mov r9, qword [rdi]
movzx r11d, byte [rdi + 0x16]
mov rax, r9
not rax
mov qword [rsp + 0x78], r8
test qword [r15], rax
jne 0x140152834
mov rbp, qword [r15 + 8]
test r9, rbp
jne 0x14015282f
test dword [r15 + 0x28], r10d
je 0x1401523ba
cmp word [rdi + 0x10], 0xa
jl 0x14015282f
movzx r10d, word [rdi + 0x10]
lea r14, [0x140000000]
movzx ecx, word [r15 + 0x14]
movzx ebx, word [r15 + 0x12]
add cx, r10w
movsx edx, cx
cmp bx, cx
jl 0x140152405
movsx ecx, bx
lea eax, [rdx + 0x31]
cmp ecx, eax
jg 0x140152435
lea eax, [rdx + 0x1f]
cmp ecx, eax
jle 0x1401523f2
inc bx
jmp 0x140152435
sub ecx, edx
movsxd rax, ecx
movzx eax, byte [rax + r14 + 0x203b50]
add bx, ax
jmp 0x140152435
movsx r8d, bx
lea eax, [r8 + 0x31]
cmp edx, eax
jle 0x140152416
movzx ebx, cx
jmp 0x140152435
lea eax, [r8 + 0x1f]
cmp edx, eax
jle 0x140152423
lea ebx, [rcx + 1]
jmp 0x140152435
sub edx, r8d
movsxd rax, edx
movzx ebx, byte [rax + r14 + 0x203b50]
add bx, cx
movzx ecx, word [rdi + 0x14]
movsx edx, cx
cmp bx, cx
jl 0x14015246a
movsx ecx, bx
lea eax, [rdx + 0x31]
cmp ecx, eax
jg 0x14015249a
lea eax, [rdx + 0x1f]
cmp ecx, eax
jle 0x140152457
inc bx
jmp 0x14015249a
sub ecx, edx
movsxd rax, ecx
movzx eax, byte [rax + r14 + 0x203b50]
add bx, ax
jmp 0x14015249a
movsx r8d, bx
lea eax, [r8 + 0x31]
cmp edx, eax
jle 0x14015247b
movzx ebx, cx
jmp 0x14015249a
lea eax, [r8 + 0x1f]
cmp edx, eax
jle 0x140152488
lea ebx, [rcx + 1]
jmp 0x14015249a
sub edx, r8d
movsxd rax, edx
movzx ebx, byte [rax + r14 + 0x203b50]
add bx, cx
movzx r14d, word [r15 + 0x16]
or rbp, r9
add r14w, r10w
test r11b, r11b
jns 0x1401524f0
lea rax, [rsp + 0x78]
mov r8, rdi
mov qword [rsp + 0x30], rax
mov eax, dword [rsp + 0x108]
mov qword [rsp + 0x28], r15
mov word [rsp + 0x20], ax
mov rax, qword [rsp + 0xf0]
mov rcx, rax
mov rdi, rax
movzx r9d, word [rax + 0x38]
mov rdx, qword [rax + 0x10]
call fcn.1401518d0
mov r10, qword [rsp + 0x78]
movzx r11d, al
jmp 0x1401524fc
mov r10, qword [rdi + 8]
mov rdi, qword [rsp + 0xf0]
test r11b, r11b
js 0x1401526f1
movsx edx, r11b
cmp edx, dword [rsp + 0x50]
jge 0x1401526f1
mov rcx, qword [rsp + 0x80]
movsx rax, r11b
lea r9, [rcx + rax*2]
movzx ecx, word [rcx + rax*2]
test cx, cx
jne 0x140152684
mov eax, dword [rsp + 0x50]
movzx r8d, word [rsp + 0xf8]
sub eax, edx
imul eax, eax, 0x64
cdq
idiv dword [rsp + 0x50]
movsxd rcx, eax
mov eax, 0x28
cmp rcx, 8
jae 0x140152571
cmp rcx, 2
jae 0x140152562
xor eax, eax
movzx edx, ax
jmp 0x1401525c6
add ax, 0xfff6
add rcx, rcx
cmp rcx, 8
jb 0x140152562
jmp 0x1401525ad
cmp rcx, 0xff
jbe 0x140152591
nop word [rax + rax]
add ax, 0x28
shr rcx, 4
cmp rcx, 0xff
ja 0x140152580
cmp rcx, 0xf
jbe 0x1401525ad
nop word [rax + rax]
add ax, 0xa
shr rcx, 1
cmp rcx, 0xf
ja 0x1401525a0
and ecx, 7
lea rdx, [0x140000000]
movzx edx, word [rdx + rcx*2 + 0x27ee98]
sub dx, 0xa
add dx, ax
movzx ecx, word [rsp + 0xf8]
sub dx, 0x32
add dx, cx
mov eax, 0x4000
test word [rdi + 0x38], ax
je 0x1401525ea
cmp word [rdi + 0x20], cx
cmovl r8w, word [rdi + 0x20]
cmp r8w, 0xa
jg 0x1401525fa
xor eax, eax
mov ecx, eax
jmp 0x14015267d
movsx rax, r8w
mov ecx, 0x28
cmp rax, 8
jae 0x140152622
cmp rax, 2
jae 0x140152613
xor eax, eax
jmp 0x140152677
add cx, 0xfff6
add rax, rax
cmp rax, 8
jb 0x140152613
jmp 0x14015265d
cmp rax, 0xff
jbe 0x140152640
nop word [rax + rax]
add cx, 0x28
shr rax, 4
cmp rax, 0xff
ja 0x140152630
cmp rax, 0xf
jbe 0x14015265d
nop word [rax + rax]
add cx, 0xa
shr rax, 1
cmp rax, 0xf
ja 0x140152650
and eax, 7
lea r8, [0x140000000]
movzx eax, word [r8 + rax*2 + 0x27ee98]
sub ax, 0xa
add ax, cx
movsx ecx, ax
sub ecx, 0x21
add cx, dx
mov word [r9], cx
movsx edx, cx
cmp bx, cx
jl 0x1401526bb
movsx ecx, bx
lea eax, [rdx + 0x31]
cmp ecx, eax
jg 0x1401526f1
lea eax, [rdx + 0x1f]
cmp ecx, eax
jle 0x1401526a2
lea ecx, [rbx + 1]
jmp 0x1401526f4
sub ecx, edx
movsxd rax, ecx
lea rcx, [0x140000000]
movzx ecx, byte [rax + rcx + 0x203b50]
add cx, bx
jmp 0x1401526f4
movsx r8d, bx
lea eax, [r8 + 0x31]
cmp edx, eax
jg 0x1401526f4
lea eax, [r8 + 0x1f]
cmp edx, eax
jle 0x1401526d4
inc cx
jmp 0x1401526f4
sub edx, r8d
movsxd rax, edx
lea rdx, [0x140000000]
movzx eax, byte [rax + rdx + 0x203b50]
add ax, cx
movzx ecx, ax
jmp 0x1401526f4
movzx ecx, bx
mov rdi, qword [rsp + 0x40]
xor r8d, r8d
mov edx, r8d
test r13d, r13d
jle 0x14015271d
cmp qword [rdi], rbp
jne 0x140152712
movzx eax, byte [rdi + 0x16]
xor al, r11b
jge 0x14015273f
inc edx
add rdi, 0x20
cmp edx, r13d
jl 0x140152704
cmp r13d, dword [rsp + 0x54]
jl 0x140152765
cmp cx, si
jg 0x140152824
jne 0x140152739
cmp bx, r12w
jge 0x140152824
mov eax, dword [rsp + 0x58]
jmp 0x14015276b
cmp edx, r13d
jge 0x14015271d
movzx eax, word [rdi + 0x12]
mov rbp, qword [rsp + 0x40]
cmp ax, cx
jl 0x140152817
jne 0x14015277a
cmp word [rdi + 0x10], r14w
jle 0x140152817
jmp 0x14015277a
mov eax, r13d
inc r13d
mov rbp, qword [rsp + 0x40]
movsxd rdi, eax
shl rdi, 5
add rdi, rbp
mov rax, qword [r15 + 8]
mov rdx, qword [rsp + 0x48]
or rax, qword [rdx]
mov qword [rdi], rax
movsxd rax, dword [rsp + 0x108]
mov word [rdi + 0x14], bx
mov word [rdi + 0x12], cx
mov rcx, qword [rdi + 0x18]
lea rbx, [rax*8]
mov qword [rdi + 8], r10
mov word [rdi + 0x10], r14w
mov r8, rbx
mov byte [rdi + 0x16], r11b
mov rdx, qword [rdx + 0x18]
call fcn.140180560
mov rax, qword [rdi + 0x18]
xor r8d, r8d
mov qword [rbx + rax], r15
mov ebx, dword [rsp + 0x54]
cmp r13d, ebx
jl 0x140152817
movzx esi, word [rbp + 0x12]
mov edx, 1
movzx r12d, word [rbp + 0x10]
mov dword [rsp + 0x58], r8d
cmp ebx, edx
jbe 0x140152817
lea rax, [rbp + 0x32]
nop dword [rax]
movzx ecx, word [rax]
cmp cx, si
jg 0x140152801
jne 0x14015280d
cmp word [rax + 2], r12w
jle 0x14015280d
movzx r12d, word [rax + 2]
movzx esi, cx
mov dword [rsp + 0x58], edx
inc edx
add rax, 0x20
cmp edx, ebx
jl 0x1401527f0
mov rdi, qword [rsp + 0x48]
mov r10d, 0x4000
jmp 0x140152834
mov rdi, qword [rsp + 0x48]
mov r10d, 0x4000
mov rbp, qword [rsp + 0x40]
mov r15, qword [r15 + 0x40]
test r15, r15
jne 0x140152380
mov r14, qword [rsp + 0xf0]
mov eax, dword [rsp + 0x68]
mov edx, dword [rsp + 0x6c]
inc eax
add rdi, 0x20
mov dword [rsp + 0x68], eax
mov qword [rsp + 0x48], rdi
cmp eax, edx
jl 0x140152370
mov ecx, dword [rsp + 0x108]
mov r9, qword [rsp + 0x70]
mov r15d, dword [rsp + 0x100]
mov rax, rbp
mov qword [rsp + 0x40], r9
inc ecx
mov qword [rsp + 0x70], rax
mov dword [rsp + 0x108], ecx
mov edx, r13d
mov dword [rsp + 0x6c], edx
mov rbp, r9
mov r9, rax
cmp ecx, r15d
jl 0x140152350
test r13d, r13d
jne 0x140152999
mov rcx, qword [rsp + 0x88]
lea rdx, str.no_query_solution
call fcn.14010da60
mov rcx, qword [rsp + 0x90]
test rcx, rcx
je 0x140152927
cmp qword [rcx + 0x298], 0
je 0x1401528ef
mov rdx, qword [rsp + 0x60]
call fcn.1400f1940
lea eax, [r13 + 1]
jmp 0x140152ca0
mov rbx, qword [rsp + 0x60]
cmp rbx, qword [rcx + 0x180]
jb 0x14015292c
cmp rbx, qword [rcx + 0x188]
jae 0x14015292c
mov rax, qword [rcx + 0x178]
mov qword [rbx], rax
mov eax, 1
dec dword [rcx + 0x160]
mov qword [rcx + 0x178], rbx
jmp 0x140152ca0
mov rbx, qword [rsp + 0x60]
cmp dword [0x14027d280], 0
je 0x140152986
mov rcx, qword [0x140286200]
test rcx, rcx
je 0x140152947
call qword [0x14027d308]
mov rcx, rbx
call qword [0x14027d2c0]
dec qword [0x140286338]
movsxd rcx, eax
sub qword [0x1402862f0], rcx
mov rcx, rbx
call qword [0x14027d2b0]
mov rcx, qword [0x140286200]
test rcx, rcx
je 0x14015298f
call qword [0x14027d318]
mov eax, 1
jmp 0x140152ca0
mov rcx, rbx
call qword [0x14027d2b0]
mov eax, 1
jmp 0x140152ca0
movzx edi, word [rsp + 0xf8]
mov r13d, 1
movsxd rdx, edx
mov rbx, r9
cmp rdx, 1
jle 0x1401529e0
lea rcx, [r9 + 0x32]
dec rdx
nop word [rax + rax]
movzx eax, word [rcx]
cmp word [rbx + 0x12], ax
jle 0x1401529d3
movsxd rbx, r13d
shl rbx, 5
add rbx, r9
inc r13d
add rcx, 0x20
sub rdx, 1
jne 0x1401529c0
test r15d, r15d
jle 0x140152a21
lea rdx, [r14 + 0x3bc]
mov r9d, r15d
nop
mov rax, qword [rbx + 0x18]
lea rdx, [rdx + 0x58]
lea r8, [r8 + 8]
mov rcx, qword [r8 + rax - 8]
mov qword [rdx - 0x3c], rcx
movzx eax, byte [rcx + 0x10]
imul rcx, rax, 0x78
mov byte [rdx - 0x58], al
mov rax, qword [r14 + 8]
mov ecx, dword [rcx + rax + 0x50]
mov dword [rdx - 0x80], ecx
sub r9, 1
jne 0x1401529f0
movzx eax, word [r14 + 0x38]
mov ecx, 0x180
and ax, cx
mov ecx, 0x100
cmp ax, cx
jne 0x140152a93
cmp byte [r14 + 0x3f], 0
jne 0x140152a93
test di, di
je 0x140152a93
lea eax, [r15 - 1]
mov r9d, 0x80
movsxd rcx, eax
lea r8, [rsp + 0xf0]
mov rax, qword [rbx + 0x18]
lea edx, [r15 - 1]
mov qword [rsp + 0x30], r8
mov r8, rbx
mov rax, qword [rax + rcx*8]
mov rcx, r14
mov qword [rsp + 0x28], rax
mov word [rsp + 0x20], dx
mov rdx, qword [r14 + 0x18]
call fcn.1401518d0
movsx ecx, al
mov rax, qword [r14 + 0x18]
cmp ecx, dword [rax]
jne 0x140152a93
mov byte [r14 + 0x3f], 2
mov rdx, qword [r14 + 0x10]
test rdx, rdx
je 0x140152bdf
test byte [r14 + 0x38], 0x80
je 0x140152abf
movsx eax, byte [rbx + 0x16]
xor edi, edi
cmp eax, dword [rdx]
jne 0x140152b68
mov byte [r14 + 0x3f], 2
jmp 0x140152b68
movzx ecx, byte [rbx + 0x16]
mov byte [r14 + 0x3b], cl
mov rax, qword [rbx + 8]
mov qword [r14 + 0x50], rax
test cl, cl
jg 0x140152b66
mov byte [r14 + 0x3b], 0
test r15d, r15d
jle 0x140152b66
lea eax, [r15 - 1]
movsxd rcx, eax
mov rax, qword [rbx + 0x18]
mov r10, qword [rax + rcx*8]
mov eax, dword [r10 + 0x28]
and eax, 0x104
cmp eax, 0x104
setne cl
bt dword [r10 + 0x28], 0xc
setae al
xor edi, edi
test al, cl
je 0x140152b68
lea rcx, [rsp + 0xf0]
mov qword [rsp + 0xf0], rdi
mov qword [rsp + 0x30], rcx
lea eax, [r15 - 1]
mov qword [rsp + 0x28], r10
mov rcx, r14
mov r9d, 0x800
mov word [rsp + 0x20], ax
mov r8, rbx
call fcn.1401518d0
mov rdx, qword [r14 + 0x10]
movsx ecx, al
cmp ecx, dword [rdx]
jne 0x140152b68
mov rax, qword [rsp + 0xf0]
mov qword [r14 + 0x50], rax
mov byte [r14 + 0x40], 1
jmp 0x140152b68
xor edi, edi
mov eax, 0x200
test word [r14 + 0x38], ax
je 0x140152bdf
movsx eax, byte [r14 + 0x3b]
cmp eax, dword [rdx]
jne 0x140152bdf
test r15d, r15d
jle 0x140152bdf
lea eax, [r15 - 1]
mov qword [rsp + 0xf0], rdi
movsxd rcx, eax
lea r8, [rsp + 0xf0]
mov rax, qword [rbx + 0x18]
dec r15w
mov qword [rsp + 0x30], r8
xor r9d, r9d
mov r8, rbx
mov rax, qword [rax + rcx*8]
mov rcx, r14
mov qword [rsp + 0x28], rax
mov word [rsp + 0x20], r15w
call fcn.1401518d0
movsx ecx, al
mov rax, qword [r14 + 0x10]
cmp ecx, dword [rax]
jne 0x140152bdf
mov rax, qword [rsp + 0xf0]
mov qword [r14 + 0x50], rax
mov byte [r14 + 0x3c], 1
mov rcx, qword [rsp + 0x90]
movzx eax, word [rbx + 0x10]
mov word [r14 + 0x58], ax
test rcx, rcx
je 0x140152c3e
cmp qword [rcx + 0x298], 0
je 0x140152c0e
mov rdx, qword [rsp + 0x60]
call fcn.1400f1940
jmp 0x140152c9e
mov rbx, qword [rsp + 0x60]
cmp rbx, qword [rcx + 0x180]
jb 0x140152c43
cmp rbx, qword [rcx + 0x188]
jae 0x140152c43
mov rax, qword [rcx + 0x178]
mov qword [rbx], rax
dec dword [rcx + 0x160]
mov qword [rcx + 0x178], rbx
jmp 0x140152c9e
mov rbx, qword [rsp + 0x60]
cmp dword [0x14027d280], 0
je 0x140152c95
mov rcx, qword [0x140286200]
test rcx, rcx
je 0x140152c5e
call qword [0x14027d308]
mov rcx, rbx
call qword [0x14027d2c0]
dec qword [0x140286338]
movsxd rcx, eax
sub qword [0x1402862f0], rcx
mov rcx, rbx
call qword [0x14027d2b0]
mov rcx, qword [0x140286200]
test rcx, rcx
je 0x140152c9e
call qword [0x14027d318]
jmp 0x140152c9e
mov rcx, rbx
call qword [0x14027d2b0]
xor eax, eax
mov rbp, qword [rsp + 0xa8]
add rsp, 0xb0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbx
ret