Function at 0x18007ac40
Capabilities:
Encrypt data using rc4 ksa

Disassembly:
mov qword [rsp + 8], rbx
mov qword [rsp + 0x20], r9
mov qword [rsp + 0x18], r8
mov qword [rsp + 0x10], rdx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x4d0
lea rdx, [rsp + 0xa0]
mov dword [rsp + 0xbc], 0xff
mov rbx, rcx
xor r15d, r15d
call fcn.18007bbb0
test rax, rax
je 0x18007bb8d
mov ecx, dword [rbx + 4]
mov eax, ecx
neg eax
mov dword [rsp + 0x98], ecx
cmovs eax, ecx
mov dword [rbx + 4], eax
cmp eax, 0x1000000
jbe 0x18007acc7
mov edx, dword [0x1802b4f40]
mov rax, qword gs:[0x58]
mov rax, qword [rax + rdx*8]
lea rdx, str.too_large
jmp 0x18007bb84
cmp dword [rbx], 0x1000000
ja 0x18007aca8
mov eax, dword [rsp + 0xac]
mov ebp, dword [rsp + 0xa8]
mov esi, dword [rsp + 0xb8]
mov edi, dword [rsp + 0xc0]
mov r13d, dword [rsp + 0xa4]
mov r14d, dword [rsp + 0xa0]
mov dword [rsp + 0x34], eax
mov eax, dword [rsp + 0xb0]
mov dword [rsp + 0x40], eax
mov eax, dword [rsp + 0xb4]
mov dword [rsp + 0x64], eax
mov eax, dword [rsp + 0xbc]
mov dword [rsp + 0x3c], eax
mov dword [rsp + 0x68], esi
mov dword [rsp + 0x48], edi
mov dword [rsp + 0x4c], r13d
mov dword [rsp + 0x30], ebp
mov dword [rsp + 0x60], r14d
cmp ebp, 0xc
jne 0x18007ad5c
cmp r14d, 0x18
jge 0x18007ad74
mov ecx, r13d
mov eax, 0x55555556
sub ecx, edi
sub ecx, 0x18
imul ecx
mov r15d, edx
shr r15d, 0x1f
add r15d, edx
jmp 0x18007ad6f
cmp r14d, 0x10
jge 0x18007ad74
mov r15d, r13d
sub r15d, edi
sub r15d, ebp
sar r15d, 2
test r15d, r15d
jne 0x18007adb6
mov ecx, dword [rbx + 0xc0]
sub ecx, dword [rbx + 0xd0]
add ecx, dword [rbx + 0xb8]
lea eax, [rcx - 1]
cmp eax, 0x3ff
ja 0x18007bb6a
cmp r13d, ecx
jl 0x18007bb4e
mov edx, r13d
sub edx, ecx
cmp edx, 0x400
jg 0x18007bb4e
mov rcx, rbx
call fcn.180089680
cmp r14d, 0x18
jne 0x18007adcc
cmp esi, 0xff000000
jne 0x18007adcc
mov r12d, 3
jmp 0x18007add9
xor r12d, r12d
test esi, esi
setne r12b
add r12d, 3
mov eax, dword [rsp + 0x530]
mov dword [rbx + 8], r12d
mov r9d, dword [rbx + 4]
mov r10d, r9d
mov ecx, dword [rbx]
mov r8d, ecx
cmp eax, 3
jl 0x18007adf8
mov r12d, eax
test r8d, r8d
js 0x18007aca8
je 0x18007ae15
mov eax, 0x7fffffff
cdq
idiv r8d
cmp r12d, eax
jg 0x18007aca8
imul r8d, r12d
test r8d, r8d
js 0x18007aca8
test r10d, r10d
js 0x18007aca8
je 0x18007ae3f
mov eax, 0x7fffffff
cdq
idiv r10d
cmp r8d, eax
jg 0x18007aca8
test r12d, r12d
js 0x18007bb32
test ecx, ecx
jne 0x18007ae55
mov r8d, ecx
imul r8d, r12d
jmp 0x18007ae6d
mov eax, 0x7fffffff
cdq
idiv ecx
cmp r12d, eax
jg 0x18007bb32
mov r8d, r12d
imul r8d, ecx
test r9d, r9d
je 0x18007ae84
mov eax, 0x7fffffff
cdq
idiv r9d
cmp r8d, eax
jg 0x18007bb32
imul ecx, r9d
mov eax, r12d
imul eax, ecx
movsxd rcx, eax
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_malloc]
mov qword [rsp + 0x78], rax
mov rsi, rax
mov qword [rsp + 0x90], rax
test rax, rax
je 0x18007bb32
cmp r14d, 0x10
jge 0x18007b425
xor edi, edi
mov dword [rsp + 0x50], edi
test r15d, r15d
je 0x18007b3fd
cmp r15d, 0x100
jg 0x18007b3fd
test r15d, r15d
jle 0x18007b031
mov r13d, dword [rsp + 0x30]
lea rbp, [rbx + 0x30]
xor r14d, r14d
movsxd rdi, r15d
nop
mov rax, qword [rbx + 0xc0]
cmp rax, qword [rbx + 0xc8]
jae 0x18007af0f
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007af39
cmp dword [rbx + 0x30], 0
lea rbp, [rbx + 0x30]
je 0x18007af37
mov rcx, rbx
call fcn.180088f30
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007af39
xor cl, cl
mov qword [rsp + 0x70], rbp
mov byte [rsp + r14*4 + 0xd2], cl
cmp rax, qword [rbx + 0xc8]
jae 0x18007af5e
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007af84
cmp dword [rbp], 0
je 0x18007af82
mov rcx, rbx
call fcn.180088f30
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007af84
xor cl, cl
mov byte [rsp + r14*4 + 0xd1], cl
cmp rax, qword [rbx + 0xc8]
jae 0x18007afa8
movzx ecx, byte [rax]
lea rbp, [rbx + 0x30]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007afce
cmp dword [rbp], 0
je 0x18007afcc
mov rcx, rbx
call fcn.180088f30
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007afce
xor cl, cl
mov byte [rsp + r14*4 + 0xd0], cl
cmp r13d, 0xc
je 0x18007b00a
cmp rax, qword [rbx + 0xc8]
jae 0x18007aff1
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b00a
mov rax, qword [rsp + 0x70]
cmp dword [rax], 0
je 0x18007b00a
mov rcx, rbx
call fcn.180088f30
inc qword [rbx + 0xc0]
mov byte [rsp + r14*4 + 0xd3], 0xff
inc r14
cmp r14, rdi
jl 0x18007aef0
mov edi, dword [rsp + 0x50]
mov r13d, dword [rsp + 0x4c]
mov r14d, dword [rsp + 0x60]
mov ebp, dword [rsp + 0x30]
xor eax, eax
mov rcx, rbx
cmp ebp, 0xc
setne al
add eax, 3
imul eax, r15d
sub r13d, eax
sub r13d, dword [rsp + 0x48]
sub r13d, ebp
mov edx, r13d
call fcn.180089680
cmp r14d, 1
jne 0x18007b069
mov r15d, dword [rbx]
add r15d, 7
shr r15d, 3
jmp 0x18007b087
cmp r14d, 4
jne 0x18007b07a
mov r15d, dword [rbx]
inc r15d
shr r15d, 1
jmp 0x18007b087
cmp r14d, 8
jne 0x18007b3d5
mov r15d, dword [rbx]
mov eax, dword [rbx + 4]
neg r15d
and r15d, 3
xor r13d, r13d
cmp r14d, 1
jne 0x18007b216
test eax, eax
jle 0x18007b9fb
xor edi, edi
nop dword [rax + rax]
mov rax, qword [rbx + 0xc0]
mov ebp, 7
cmp rax, qword [rbx + 0xc8]
jae 0x18007b0d4
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b0fa
cmp dword [rbx + 0x30], 0
je 0x18007b0f8
mov rcx, rbx
call fcn.180088f30
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b0fa
xor cl, cl
xor r14d, r14d
movzx edx, cl
cmp dword [rbx], r14d
jle 0x18007b1bf
nop dword [rax]
mov eax, edx
mov ecx, ebp
sar eax, cl
and eax, 1
lea rcx, [rax*4]
movzx eax, byte [rsp + rcx + 0xd0]
mov byte [rdi + rsi], al
movzx eax, byte [rsp + rcx + 0xd1]
mov byte [rdi + rsi + 1], al
movzx eax, byte [rsp + rcx + 0xd2]
mov byte [rdi + rsi + 2], al
add rdi, 3
cmp r12d, 4
jne 0x18007b155
mov byte [rdi + rsi], 0xff
inc rdi
mov ecx, dword [rbx]
lea eax, [r14 + 1]
mov r14d, eax
cmp eax, ecx
je 0x18007b1bf
sub ebp, 1
jns 0x18007b1b6
mov rax, qword [rbx + 0xc0]
mov ebp, 7
cmp rax, qword [rbx + 0xc8]
jae 0x18007b18b
movzx edx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b1b3
cmp dword [rbx + 0x30], 0
je 0x18007b1b1
mov rcx, rbx
call fcn.180088f30
mov rax, qword [rbx + 0xc0]
movzx edx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
mov ecx, dword [rbx]
jmp 0x18007b1b3
xor dl, dl
movzx edx, dl
cmp r14d, ecx
jl 0x18007b110
test r15d, r15d
je 0x18007b202
cmp qword [rbx + 0x10], 0
je 0x18007b1f8
mov ecx, dword [rbx + 0xc8]
sub ecx, dword [rbx + 0xc0]
cmp ecx, r15d
jge 0x18007b1f8
mov rax, qword [rbx + 0xc8]
mov edx, r15d
sub edx, ecx
mov qword [rbx + 0xc0], rax
mov rcx, qword [rbx + 0x28]
call qword [rbx + Ordinal_26]
jmp 0x18007b202
mov eax, r15d
add qword [rbx + 0xc0], rax
mov eax, dword [rbx + 4]
inc r13d
cmp r13d, eax
jl 0x18007b0b0
jmp 0x18007b9fb
test eax, eax
jle 0x18007b9fb
nop
xor ebp, ebp
cmp dword [rbx], ebp
jle 0x18007b37e
nop word [rax + rax]
mov rax, qword [rbx + 0xc0]
cmp rax, qword [rbx + 0xc8]
jae 0x18007b24f
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b275
cmp dword [rbx + 0x30], 0
je 0x18007b273
mov rcx, rbx
call fcn.180088f30
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b275
xor cl, cl
xor r8d, r8d
movzx eax, cl
cmp r14d, 4
jne 0x18007b28b
mov r8d, eax
and r8d, 0xf
shr eax, 4
movsxd rcx, edi
lea rdx, [rax*4]
movzx eax, byte [rsp + rdx + 0xd0]
inc edi
mov byte [rcx + rsi], al
movzx eax, byte [rsp + rdx + 0xd1]
movsxd rcx, edi
inc edi
mov byte [rcx + rsi], al
movzx eax, byte [rsp + rdx + 0xd2]
movsxd rcx, edi
inc edi
mov byte [rcx + rsi], al
cmp r12d, 4
jne 0x18007b2d2
movsxd rax, edi
inc edi
mov byte [rax + rsi], 0xff
lea eax, [rbp + 1]
cmp eax, dword [rbx]
je 0x18007b37e
cmp r14d, 8
jne 0x18007b32c
mov rax, qword [rbx + 0xc0]
cmp rax, qword [rbx + 0xc8]
jae 0x18007b302
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b328
cmp dword [rbx + 0x30], 0
je 0x18007b326
mov rcx, rbx
call fcn.180088f30
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b328
xor cl, cl
movzx r8d, cl
movsxd rcx, edi
lea rdx, [r8*4]
movzx eax, byte [rsp + rdx + 0xd0]
inc edi
mov byte [rcx + rsi], al
movzx eax, byte [rsp + rdx + 0xd1]
movsxd rcx, edi
inc edi
mov byte [rcx + rsi], al
movzx eax, byte [rsp + rdx + 0xd2]
movsxd rcx, edi
inc edi
mov byte [rcx + rsi], al
cmp r12d, 4
jne 0x18007b373
movsxd rax, edi
inc edi
mov byte [rax + rsi], 0xff
add ebp, 2
cmp ebp, dword [rbx]
jl 0x18007b230
test r15d, r15d
je 0x18007b3c1
cmp qword [rbx + 0x10], 0
je 0x18007b3b7
mov ecx, dword [rbx + 0xc8]
sub ecx, dword [rbx + 0xc0]
cmp ecx, r15d
jge 0x18007b3b7
mov rax, qword [rbx + 0xc8]
mov edx, r15d
sub edx, ecx
mov qword [rbx + 0xc0], rax
mov rcx, qword [rbx + 0x28]
call qword [rbx + Ordinal_26]
jmp 0x18007b3c1
mov eax, r15d
add qword [rbx + 0xc0], rax
mov eax, dword [rbx + 4]
inc r13d
cmp r13d, eax
jl 0x18007b220
jmp 0x18007b9fb
mov rcx, rsi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov edx, dword [0x1802b4f40]
mov rax, qword gs:[0x58]
mov rax, qword [rax + rdx*8]
lea rdx, str.bad_bpp
jmp 0x18007bb84
mov rcx, rsi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov edx, dword [0x1802b4f40]
mov rax, qword gs:[0x58]
mov rax, qword [rax + rdx*8]
lea rdx, str.invalid
jmp 0x18007bb84
xor eax, eax
sub r13d, edi
sub r13d, ebp
mov dword [rsp + 0x80], eax
mov edx, r13d
mov dword [rsp + 0x88], eax
mov rcx, rbx
mov dword [rsp + 0x48], eax
mov dword [rsp + 0x50], eax
mov r15d, eax
mov dword [rsp + 0x38], eax
mov dword [rsp + 0x84], eax
mov dword [rsp + 0x8c], eax
mov dword [rsp + 0x4c], eax
call fcn.180089680
cmp r14d, 0x18
jne 0x18007b474
mov eax, dword [rbx]
lea edx, [rax + rax*2]
jmp 0x18007b482
cmp r14d, 0x10
jne 0x18007b480
mov edx, dword [rbx]
add edx, edx
jmp 0x18007b482
xor edx, edx
neg edx
and edx, 3
mov dword [rsp + 0x44], edx
cmp r14d, 0x18
jne 0x18007b4a9
mov r13d, 1
mov qword [rsp + 0x70], rsi
mov qword [rsp + 0x58], r13
mov edi, r15d
jmp 0x18007b705
mov r10d, dword [rsp + 0x64]
xor r13d, r13d
mov r11d, dword [rsp + 0x40]
mov eax, r12d
mov qword [rsp + 0x58], r13
mov r8, rsi
cmp r14d, 0x20
jne 0x18007b524
mov qword [rsp + 0x58], r13
cmp r10d, 0xff
jne 0x18007b524
mov ecx, dword [rsp + 0x34]
mov qword [rsp + 0x58], r13
cmp r11d, 0xff00
jne 0x18007b528
mov qword [rsp + 0x58], r13
cmp ecx, 0xff0000
jne 0x18007b528
mov r9d, dword [rsp + 0x68]
mov qword [rsp + 0x58], r13
mov qword [rsp + 0x70], rsi
cmp r9d, 0xff000000
jne 0x18007b564
mov r13d, 2
mov qword [rsp + 0x70], rsi
mov qword [rsp + 0x58], r13
mov edi, r15d
jmp 0x18007b705
mov ecx, dword [rsp + 0x34]
mov r12d, eax
mov rax, qword [rsp + 0x90]
mov qword [rsp + 0x90], rax
test ecx, ecx
je 0x18007bb0d
test r11d, r11d
je 0x18007bb0d
mov qword [rsp + 0x70], rsi
mov qword [rsp + 0x78], r8
test r10d, r10d
je 0x18007bb0d
mov r9d, dword [rsp + 0x68]
call fcn.180080b10
mov edx, dword [rsp + 0x34]
sub eax, 7
mov ecx, dword [rsp + 0x34]
shr edx, 1
and ecx, 0x55555555
and edx, 0x55555555
mov dword [rsp + 0x80], eax
add edx, ecx
mov ecx, edx
and edx, 0x33333333
shr ecx, 2
and ecx, 0x33333333
add ecx, edx
mov edx, ecx
shr edx, 4
add edx, ecx
mov ecx, r11d
and edx, 0xf0f0f0f
mov eax, edx
shr eax, 8
add edx, eax
mov eax, edx
shr eax, 0x10
add eax, edx
movzx edi, al
mov dword [rsp + 0x38], edi
call fcn.180080b10
sub eax, 7
mov edx, r11d
shr edx, 1
mov ecx, r11d
and edx, 0x55555555
mov dword [rsp + 0x88], eax
and ecx, 0x55555555
add edx, ecx
mov ecx, edx
and edx, 0x33333333
shr ecx, 2
and ecx, 0x33333333
add ecx, edx
mov edx, ecx
shr edx, 4
add edx, ecx
mov ecx, r10d
and edx, 0xf0f0f0f
mov eax, edx
shr eax, 8
add edx, eax
mov eax, edx
shr eax, 0x10
add eax, edx
movzx r11d, al
mov dword [rsp + 0x84], r11d
call fcn.180080b10
sub eax, 7
mov edx, r10d
shr edx, 1
mov ecx, r10d
and edx, 0x55555555
mov dword [rsp + 0x48], eax
and ecx, 0x55555555
add edx, ecx
mov ecx, edx
and edx, 0x33333333
shr ecx, 2
and ecx, 0x33333333
add ecx, edx
mov edx, ecx
shr edx, 4
add edx, ecx
mov ecx, r9d
and edx, 0xf0f0f0f
mov eax, edx
shr eax, 8
add edx, eax
mov eax, edx
shr eax, 0x10
add eax, edx
movzx r10d, al
mov dword [rsp + 0x8c], r10d
call fcn.180080b10
sub eax, 7
mov edx, r9d
shr edx, 1
mov ecx, r9d
and edx, 0x55555555
mov dword [rsp + 0x50], eax
and ecx, 0x55555555
add edx, ecx
mov ecx, edx
and edx, 0x33333333
shr ecx, 2
and ecx, 0x33333333
add ecx, edx
mov edx, ecx
shr edx, 4
add edx, ecx
and edx, 0xf0f0f0f
mov eax, edx
shr eax, 8
add edx, eax
mov eax, edx
shr eax, 0x10
add eax, edx
movzx eax, al
mov dword [rsp + 0x4c], eax
cmp edi, 8
ja 0x18007bb0d
cmp r11d, 8
ja 0x18007bb0d
cmp r10d, 8
ja 0x18007bb0d
cmp eax, 8
ja 0x18007bb0d
mov edx, dword [rsp + 0x44]
mov eax, dword [rbx + 4]
xor ebp, ebp
mov dword [rsp + 0x30], ebp
test eax, eax
jle 0x18007b9fb
nop word [rax + rax]
mov eax, dword [rbx]
movsxd rcx, r15d
test r13, r13
je 0x18007b8f2
xor ebp, ebp
test eax, eax
jle 0x18007b8a7
lea r14, [rcx + rsi]
lea rdi, [rbx + 0x30]
mov rax, qword [rbx + 0xc0]
cmp rax, qword [rbx + 0xc8]
jae 0x18007b75f
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b789
cmp dword [rbx + 0x30], 0
lea rdi, [rbx + 0x30]
je 0x18007b787
mov rcx, rbx
call fcn.180088f30
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b789
xor cl, cl
mov byte [r14 + 2], cl
mov rax, qword [rbx + 0xc0]
cmp rax, qword [rbx + 0xc8]
jae 0x18007b7ac
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b7d1
cmp dword [rdi], 0
je 0x18007b7cf
mov rcx, rbx
call fcn.180088f30
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b7d1
xor cl, cl
mov byte [r14 + 1], cl
mov rax, qword [rbx + 0xc0]
cmp rax, qword [rbx + 0xc8]
jae 0x18007b7f4
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b819
cmp dword [rdi], 0
je 0x18007b817
mov rcx, rbx
call fcn.180088f30
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b819
xor cl, cl
mov byte [r14], cl
add r15d, 3
add r14, 3
cmp r13, 2
jne 0x18007b87d
mov rax, qword [rbx + 0xc0]
cmp rax, qword [rbx + 0xc8]
jae 0x18007b849
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b86f
cmp dword [rbx + 0x30], 0
je 0x18007b86d
mov rcx, rbx
call fcn.180088f30
mov rax, qword [rbx + 0xc0]
movzx ecx, byte [rax]
inc rax
mov qword [rbx + 0xc0], rax
jmp 0x18007b86f
xor cl, cl
mov edx, Ordinal_50
mov rax, rbx
lea rdi, [rbx + rdx]
jmp 0x18007b883
mov cl, 0xff
lea rdi, [rbx + 0x30]
movzx eax, cl
or dword [rsp + 0x3c], eax
cmp r12d, 4
jne 0x18007b899
inc r15d
mov byte [r14], cl
inc r14
inc ebp
cmp ebp, dword [rbx]
jl 0x18007b740
mov edx, dword [rsp + 0x44]
mov ebp, dword [rsp + 0x30]
test edx, edx
je 0x18007b9e6
cmp qword [rbx + 0x10], 0
je 0x18007b9dd
mov ecx, dword [rbx + 0xc8]
sub ecx, dword [rbx + 0xc0]
cmp ecx, edx
jge 0x18007b9dd
mov rax, qword [rbx + 0xc8]
sub edx, ecx
mov rcx, qword [rbx + 0x28]
mov qword [rbx + 0xc0], rax
call qword [rbx + Ordinal_26]
mov edx, dword [rsp + 0x44]
jmp 0x18007b9e6
test eax, eax
jle 0x18007b9d3
lea r14, [rcx + rsi]
mov esi, dword [rsp + 0x60]
mov rcx, rbx
call fcn.18007e9c0
cmp esi, 0x10
jne 0x18007b913
mov ebp, eax
jmp 0x18007b928
mov rcx, rbx
mov edi, eax
call fcn.18007e9c0
mov ebp, eax
shl ebp, 0x10
add ebp, edi
mov edi, dword [rsp + 0x38]
mov edx, dword [rsp + 0x80]
mov ecx, ebp
and ecx, dword [rsp + 0x34]
mov r8d, edi
call fcn.1800895f0
mov r8d, dword [rsp + 0x84]
mov ecx, ebp
and ecx, dword [rsp + 0x40]
mov edx, dword [rsp + 0x88]
mov byte [r14], al
call fcn.1800895f0
mov r8d, dword [rsp + 0x8c]
mov ecx, ebp
and ecx, dword [rsp + 0x64]
mov edx, dword [rsp + 0x48]
mov byte [r14 + 1], al
call fcn.1800895f0
mov r9d, dword [rsp + 0x68]
add r15d, 3
mov byte [r14 + 2], al
add r14, 3
test r9d, r9d
je 0x18007b9a0
mov r8d, dword [rsp + 0x4c]
and ebp, r9d
mov edx, dword [rsp + 0x50]
mov ecx, ebp
call fcn.1800895f0
jmp 0x18007b9a5
mov eax, 0xff
or dword [rsp + 0x3c], eax
cmp r12d, 4
jne 0x18007b9b8
inc r15d
mov byte [r14], al
inc r14
inc r13d
cmp r13d, dword [rbx]
jl 0x18007b902
mov rsi, qword [rsp + 0x70]
mov r13, qword [rsp + 0x58]
jmp 0x18007b8a3
mov r13, qword [rsp + 0x58]
jmp 0x18007b8ab
mov eax, edx
add qword [rbx + 0xc0], rax
mov eax, dword [rbx + 4]
inc ebp
mov edi, dword [rsp + 0x38]
mov dword [rsp + 0x30], ebp
cmp ebp, eax
jl 0x18007b720
cmp r12d, 4
jne 0x18007ba2a
cmp dword [rsp + 0x3c], 0
jne 0x18007ba2a
imul eax, dword [rbx]
lea eax, [rax*4 - 1]
movsxd rcx, eax
test eax, eax
js 0x18007ba2a
mov rax, qword [rsp + 0x78]
nop
mov byte [rcx + rax], 0xff
sub rcx, 4
jns 0x18007ba20
cmp dword [rsp + 0x98], 0
jle 0x18007ba9f
mov edx, dword [rbx + 4]
xor r10d, r10d
test edx, 0xfffffffe
jle 0x18007ba9f
mov ecx, dword [rbx]
sub edx, r10d
dec edx
mov r9d, ecx
imul edx, ecx
xor r8d, r8d
imul r9d, r10d
imul ecx, r12d
imul edx, r12d
imul r9d, r12d
add rdx, rsi
add r9, rsi
test ecx, ecx
jle 0x18007ba90
sub r9, rdx
nop
movzx eax, byte [rdx]
inc r8d
movzx ecx, byte [rdx + r9]
mov byte [rdx + r9], al
mov eax, r12d
mov byte [rdx], cl
lea rdx, [rdx + 1]
imul eax, dword [rbx]
cmp r8d, eax
jl 0x18007ba70
mov edx, dword [rbx + 4]
inc r10d
mov eax, edx
sar eax, 1
cmp r10d, eax
jl 0x18007ba42
mov r8d, dword [rsp + 0x530]
test r8d, r8d
je 0x18007bad1
cmp r8d, r12d
je 0x18007bad1
mov eax, dword [rbx + 4]
mov edx, r12d
mov r9d, dword [rbx]
mov rcx, rsi
mov dword [rsp + 0x20], eax
call fcn.18007cd90
test rax, rax
je 0x18007bb8d
jmp 0x18007bad9
mov rax, qword [rsp + 0x90]
mov ecx, dword [rbx]
mov rdx, qword [rsp + 0x518]
mov dword [rdx], ecx
mov rdx, qword [rsp + 0x520]
mov ecx, dword [rbx + 4]
mov dword [rdx], ecx
mov rdx, qword [rsp + 0x528]
test rdx, rdx
je 0x18007bb8f
mov ecx, dword [rbx + 8]
mov dword [rdx], ecx
jmp 0x18007bb8f
mov rcx, rsi
call qword [sym.imp.api_ms_win_crt_heap_l1_1_0.dll_free]
mov edx, dword [0x1802b4f40]
mov rax, qword gs:[0x58]
mov rax, qword [rax + rdx*8]
lea rdx, str.bad_masks
jmp 0x18007bb84
mov edx, dword [0x1802b4f40]
mov rax, qword gs:[0x58]
mov rax, qword [rax + rdx*8]
lea rdx, str.outofmem
jmp 0x18007bb84
mov edx, dword [0x1802b4f40]
mov rax, qword gs:[0x58]
mov rax, qword [rax + rdx*8]
lea rdx, str.bad_offset
jmp 0x18007bb84
mov edx, dword [0x1802b4f40]
mov rax, qword gs:[0x58]
mov rax, qword [rax + rdx*8]
lea rdx, str.bad_header
mov ecx, reloc.WLDAP32.dll_Ordinal_32
mov qword [rcx + rax], rdx
xor eax, eax
mov rbx, qword [rsp + 0x510]
add rsp, 0x4d0
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret