Function at 0x180066fd0
Capabilities:
Resolve function by parsing pe exports

Disassembly:
mov qword [rsp + 8], rbx
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, 0x60
mov r15, qword [rsp + 0xc0]
xor r14d, r14d
mov ebx, r9d
mov rdi, r8
mov rsi, rdx
mov r12, rcx
mov r13d, 1
test rdx, rdx
jne 0x180067081
cmp byte [rcx], r14b
jne 0x180067077
movzx r10d, byte [rcx + 1]
test r10b, 2
je 0x180067077
mov rax, qword [rcx + 0x30]
cmp rax, r8
jne 0x180067036
mov rax, r15
mov dword [rax], r14d
xor eax, eax
jmp 0x1800674b6
jge 0x180067077
test r10b, 8
jne 0x180067101
inc rax
cmp rax, rdi
jne 0x180067077
xor edx, edx
mov dword [r15], r14d
call fcn.1800676f0
test eax, eax
jne 0x18006706e
mov rcx, r12
call fcn.180066360
cmp qword [r12 + 0x30], rdi
jne 0x180067077
xor eax, eax
jmp 0x1800674b6
cmp eax, 0x65
jne 0x1800674b6
mov rbp, r14
mov qword [rsp + 0x48], r14
jmp 0x1800670ec
mov rcx, qword [rdx]
cmp word [rcx + 8], 0xd
ja 0x1800670dc
mov rax, qword [rdx + 8]
mov r9d, 0xffffffff
mov edx, r9d
movzx r8d, word [rax + 8]
mov rax, qword [rcx + 0x18]
movzx ecx, byte [rax]
mov eax, r13d
test cl, cl
cmove eax, r9d
cmove edx, r13d
mov byte [rsi + 0x14], al
mov byte [rsi + 0x15], dl
test r8b, 4
je 0x1800670c6
lea rbp, [0x180076d60]
jmp 0x1800670e3
test r8b, 0x19
jne 0x1800670dc
mov rax, qword [rsi]
lea rbp, [0x180076f30]
cmp qword [rax + 0x20], r14
je 0x1800670e3
lea rbp, [0x180076d50]
mov qword [rsp + 0x48], rbp
mov byte [rsi + 0x13], r14b
mov rcx, r12
call fcn.180066bf0
test eax, eax
je 0x18006710f
cmp eax, 0x10
jne 0x1800674b6
mov dword [r15], 0xffffffff
xor eax, eax
jmp 0x1800674b6
mov eax, r13d
sub eax, ebx
mov dword [rsp + 0x30], eax
nop dword [rax + rax]
mov r13, qword [r12 + 0x88]
mov r15d, r14d
mov ecx, eax
movzx r14d, word [r13 + 0x18]
lea rdx, [r13 + 0x60]
dec r14d
mov qword [rsp + 0x38], rdx
mov edi, r14d
lea r8, [r13 + 0x1a]
sar edi, cl
mov word [r12 + 0x56], di
mov qword [rsp + 0x40], r8
test rbp, rbp
jne 0x180067250
mov rbx, qword [rdx]
movzx esi, word [r8]
mov rbp, qword [r13 + 0x68]
nop word [rax + rax]
lea eax, [rdi + rdi]
movsxd rcx, eax
movzx eax, word [rcx + rbx]
ror ax, 8
movzx ecx, ax
movzx eax, si
and rcx, rax
add rcx, rbp
cmp byte [r13 + 3], 0
je 0x1800671b4
cmp byte [rcx], 0x80
jb 0x1800671b1
mov rax, qword [r13 + 0x58]
nop word [rax + rax]
inc rcx
cmp rcx, rax
jae 0x1800673e9
cmp byte [rcx], 0x80
jae 0x1800671a0
inc rcx
lea rdx, [rsp + 0x50]
call fcn.180051250
mov rax, qword [rsp + 0x50]
cmp rax, qword [rsp + 0xb0]
jge 0x180067210
lea r15d, [rdi + 1]
cmp r15d, r14d
jle 0x18006721b
mov ebx, 0xffffffff
cmp byte [r13 + 8], 0
mov rdx, qword [rsp + 0x38]
mov r8, qword [rsp + 0x40]
jne 0x180067439
movzx eax, word [r13 + 0x18]
cmp r15d, eax
jl 0x180067393
movzx ecx, byte [r13 + 9]
mov rax, qword [r13 + 0x50]
mov edx, dword [rcx + rax + 8]
jmp 0x1800673b6
jle 0x18006722d
lea r14d, [rdi - 1]
cmp r15d, r14d
jg 0x180067226
lea edi, [r14 + r15]
sar edi, 1
jmp 0x180067170
mov ebx, 1
jmp 0x1800671db
mov word [r12 + 0x56], di
cmp byte [r13 + 8], 0
jne 0x18006741a
mov rdx, qword [rsp + 0x38]
mov r15d, edi
mov r8, qword [rsp + 0x40]
jmp 0x1800671f0
lea eax, [rdi + rdi]
movsxd rcx, eax
mov rax, qword [rdx]
movzx edx, word [rcx + rax]
movzx eax, word [r8]
ror dx, 8
movzx edx, dx
and rdx, rax
movzx eax, byte [r13 + 0xb]
add rdx, qword [r13 + 0x68]
movzx ecx, byte [rdx]
cmp ecx, eax
ja 0x18006728a
mov r8, rsi
inc rdx
call rbp
mov ebx, eax
jmp 0x180067361
movzx eax, byte [rdx + 1]
test al, al
js 0x1800672b6
and ecx, 0x7f
movzx eax, al
shl ecx, 7
add ecx, eax
movzx eax, word [r13 + 0xe]
cmp ecx, eax
ja 0x1800672b6
add rdx, 2
mov r8, rsi
call rbp
mov ebx, eax
jmp 0x180067361
movzx eax, byte [r13 + 0xa]
lea r8, [r12 + 0x30]
sub rdx, rax
mov rcx, r13
call qword [r13 + 0x80]
mov ebx, dword [r12 + 0x30]
cmp ebx, 2
jl 0x180067480
mov rcx, qword [r12 + 0x20]
xor edx, edx
mov eax, ebx
div dword [rcx + 0x34]
cmp eax, dword [rcx + 0x3c]
ja 0x180067480
lea eax, [rbx + 0x12]
movsxd rcx, eax
call fcn.18004cc10
mov rsi, rax
test rax, rax
je 0x180067479
mov r9, rax
mov word [r12 + 0x56], di
mov r8d, ebx
mov dword [rsp + 0x20], 0
xor edx, edx
mov rcx, r12
call fcn.180066680
and byte [r12 + 1], 0xfb
mov ebp, eax
test eax, eax
jne 0x18006746f
mov r8, qword [rsp + 0xa8]
xor r9d, r9d
mov rdx, rsi
mov ecx, ebx
call fcn.1800764b0
mov rcx, rsi
mov ebx, eax
call sym.SafeBase64.dll_sqlite3_free
mov rsi, qword [rsp + 0xa8]
mov rbp, qword [rsp + 0x48]
test ebx, ebx
jns 0x18006736b
lea r15d, [rdi + 1]
jmp 0x180067375
jle 0x18006744f
lea r14d, [rdi - 1]
cmp r15d, r14d
jg 0x1800671db
mov rdx, qword [rsp + 0x38]
lea edi, [r14 + r15]
mov r8, qword [rsp + 0x40]
sar edi, 1
jmp 0x180067250
lea eax, [r15 + r15]
movsxd rcx, eax
mov rax, qword [rdx]
movzx edx, word [rcx + rax]
movzx eax, word [r8]
ror dx, 8
movzx ecx, dx
and rcx, rax
mov rax, qword [r13 + 0x50]
mov edx, dword [rcx + rax]
bswap edx
mov rcx, r12
mov word [r12 + 0x56], r15w
call fcn.180066ac0
mov ebp, eax
test eax, eax
jne 0x1800674ac
mov rsi, qword [rsp + 0xa8]
xor r14d, r14d
mov rbp, qword [rsp + 0x48]
mov eax, dword [rsp + 0x30]
jmp 0x180067120
lea rax, [0x180160304]
mov ebp, 0xb
mov ecx, ebp
mov qword [rsp + 0x20], rax
mov r9d, 0x10c20
lea r8, str.database_corruption
lea rdx, str._s_at_line__d_of___.10s_
call fcn.18004f880
jmp 0x1800674b4
mov rcx, qword [rsp + 0xc0]
or byte [r12 + 1], 2
mov qword [r12 + 0x30], rax
xor eax, eax
mov word [r12 + 0x46], ax
mov dword [rcx], eax
jmp 0x1800674b6
mov rcx, qword [rsp + 0xc0]
xor eax, eax
mov word [r12 + 0x56], di
mov ebp, eax
mov dword [rcx], ebx
jmp 0x1800674ae
mov rcx, qword [rsp + 0xc0]
xor ebp, ebp
mov word [r12 + 0x56], di
mov dword [rcx], ebp
cmp byte [rsi + 0x13], bpl
je 0x1800674ac
mov r9d, 0x10c89
jmp 0x180067486
mov rcx, rsi
call sym.SafeBase64.dll_sqlite3_free
jmp 0x1800674ac
mov ebp, 7
jmp 0x1800674ac
mov r9d, 0x10c6a
lea rax, [0x180160304]
mov ebp, 0xb
mov ecx, ebp
mov qword [rsp + 0x20], rax
lea r8, str.database_corruption
lea rdx, str._s_at_line__d_of___.10s_
call fcn.18004f880
xor eax, eax
mov word [r12 + 0x46], ax
mov eax, ebp
mov rbx, qword [rsp + 0xa0]
add rsp, 0x60
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret