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

Disassembly:
push rbp
push rsi
push rdi
push r12
push r13
push r15
sub rsp, 0xa8
mov rax, qword [0x1800bddb0]
xor rax, rsp
mov qword [rsp + 0x90], rax
mov rbp, rcx
movsxd r12, edx
mov rax, r8
xor r8d, r8d
lea rdx, str.sqlite_master
lea rcx, str.sqlite_temp_master
mov r15d, r8d
mov qword [rsp + 0x70], r8
mov dword [rsp + 0x54], r8d
cmp r12d, 1
lea r8, [rsp + 0x58]
mov qword [rsp + 0x38], rax
cmovne rcx, rdx
xor r9d, r9d
mov qword [rsp + 0x40], rbp
mov qword [rsp + 0x58], rcx
lea rcx, [0x1800a4a60]
lea edx, [r9 + 3]
mov qword [rsp + 0x60], rcx
lea rcx, str.CREATE_TABLE_x_type_text_name_text_tbl_name_text_rootpage_integer_sql_text_
mov dword [rsp + 0x50], r12d
mov qword [rsp + 0x68], rcx
lea rcx, [rsp + 0x40]
mov qword [rsp + 0x48], rax
call fcn.1800539a0
mov edi, dword [rsp + 0x54]
mov eax, 1
test edi, edi
jne 0x1800540a0
mov rax, qword [rbp + 0x20]
mov rsi, r12
shl rsi, 5
mov qword [rsp + 0x30], rsi
mov rcx, qword [rax + rsi + 8]
lea r13, [rax + rsi]
test rcx, rcx
jne 0x180053c7e
cmp r12d, 1
jne 0x180053c77
mov rax, qword [rax + 0x38]
or word [rax + 0x72], r12w
xor eax, eax
jmp 0x1800540d4
mov qword [rsp + 0xa0], r14
cmp byte [rcx + 0x11], r15b
je 0x180053c9a
inc dword [rcx + 0x14]
cmp byte [rcx + 0x12], r15b
jne 0x180053c9a
call fcn.1800176c0
mov r14, qword [r13 + 8]
mov qword [rsp + 0xf8], rbx
cmp byte [r14 + 0x10], r15b
jne 0x180053e47
mov rbx, qword [r14 + 8]
xor edi, edi
cmp byte [r14 + 0x11], dil
je 0x180053cce
inc dword [r14 + 0x14]
cmp byte [r14 + 0x12], dil
jne 0x180053cce
mov rcx, r14
call fcn.1800176c0
movzx eax, byte [r14 + 0x10]
dec al
cmp al, 1
jbe 0x180053e0d
movzx ecx, word [rbx + 0x26]
test cl, 0x40
je 0x180053cf9
mov rax, qword [rbx + 0x78]
cmp qword [rax], rdi
je 0x180053cf9
mov edi, 0x106
jmp 0x180053e0d
mov rax, qword [r14 + 8]
cmp byte [r14 + 0x11], dil
je 0x180053d3c
cmp qword [rax + 0x78], r14
je 0x180053d19
test byte [rax + 0x26], 0x20
je 0x180053d19
mov edi, 0x106
jmp 0x180053e0d
mov rax, qword [rax + 0x70]
test rax, rax
je 0x180053d3c
cmp qword [rax], r14
je 0x180053d33
cmp dword [rax + 8], 1
jne 0x180053d33
cmp byte [rax + 0xc], 1
jne 0x180053cef
mov rax, qword [rax + 0x10]
test rax, rax
jne 0x180053d22
mov eax, 0xfff7
and cx, ax
mov word [rbx + 0x26], cx
cmp dword [rbx + 0x3c], r15d
jne 0x180053d56
or cx, 8
mov word [rbx + 0x26], cx
cmp qword [rbx + 0x18], r15
jne 0x180053d6c
mov rcx, rbx
call fcn.18002b3c0
mov edi, eax
test eax, eax
je 0x180053d56
jmp 0x180053d70
test edi, edi
je 0x180053d8c
cmp byte [rbx + 0x24], r15b
jne 0x180053d8c
mov rcx, qword [rbx + 0x18]
test rcx, rcx
je 0x180053d8c
mov qword [rbx + 0x18], r15
mov rcx, qword [rcx + 0x70]
call fcn.18005a290
cmp dil, 5
jne 0x180053dca
cmp byte [rbx + 0x24], r15b
jne 0x180053dca
mov rsi, qword [rbx + 8]
add rsi, 0x218
je 0x180053dca
mov rax, qword [rsi]
test rax, rax
je 0x180053dca
mov edx, dword [rsi + 0x10]
test edx, edx
js 0x180053dca
mov rcx, qword [rsi + 8]
call rax
test eax, eax
je 0x180053dc3
inc dword [rsi + 0x10]
jmp 0x180053d56
mov dword [rsi + 0x10], 0xffffffff
test edi, edi
jne 0x180053e08
cmp byte [r14 + 0x10], r15b
jne 0x180053df2
inc dword [rbx + 0x38]
cmp byte [r14 + 0x11], r15b
je 0x180053df2
mov byte [r14 + 0x3c], 1
mov rax, qword [rbx + 0x70]
mov qword [r14 + 0x40], rax
lea rax, [r14 + 0x30]
mov qword [rbx + 0x70], rax
mov rsi, qword [rsp + 0x30]
mov byte [r14 + 0x10], 1
cmp byte [rbx + 0x24], 1
jae 0x180053e0d
mov byte [rbx + 0x24], 1
jmp 0x180053e0d
mov rsi, qword [rsp + 0x30]
cmp byte [r14 + 0x11], r15b
je 0x180053e21
dec dword [r14 + 0x14]
jne 0x180053e21
mov rcx, r14
call fcn.180080340
test edi, edi
je 0x180053e41
mov ecx, edi
call sym.sqlite3.dll_sqlite3_errstr
mov rcx, qword [rsp + 0x38]
mov rdx, rbp
mov r8, rax
call fcn.180065550
jmp 0x180054077
mov r15d, 1
xor r14d, r14d
lea rdi, [rsp + 0x78]
mov ebx, r14d
nop dword [rax]
nop word [rax + rax]
mov rcx, qword [r13 + 8]
inc ebx
mov r8, rdi
mov edx, ebx
call fcn.18003fa30
add rdi, 4
cmp ebx, 5
jl 0x180053e60
mov rcx, qword [r13 + 0x18]
mov eax, dword [rsp + 0x78]
mov dword [rcx], eax
mov ecx, dword [rsp + 0x88]
test ecx, ecx
je 0x180053ecc
test r12d, r12d
jne 0x180053ea6
and cl, 3
mov ebx, 1
movzx eax, cl
cmove eax, ebx
mov byte [rbp + 0x52], al
jmp 0x180053edf
movzx eax, byte [rbp + 0x52]
cmp ecx, eax
je 0x180053eda
mov rcx, qword [rsp + 0x38]
lea r8, str.attached_databases_must_use_the_same_text_encoding_as_main_database
mov rdx, rbp
call fcn.180065550
mov edi, 1
jmp 0x180054069
mov rax, qword [rbp + 0x20]
mov rcx, qword [rsi + rax + 0x18]
or word [rcx + 0x72], 4
mov ebx, 1
mov rcx, qword [r13 + 0x18]
movzx eax, byte [rbp + 0x52]
mov byte [rcx + 0x71], al
mov rcx, qword [r13 + 0x18]
cmp dword [rcx + 0x74], r14d
jne 0x180053f2c
mov eax, dword [rsp + 0x80]
test eax, eax
jns 0x180053f0f
cmp eax, 0x80000000
jne 0x180053f0d
mov eax, 0x7fffffff
jmp 0x180053f19
neg eax
mov edx, 0xfffff830
test eax, eax
cmove eax, edx
mov dword [rcx + 0x74], eax
mov rax, qword [r13 + 0x18]
mov rcx, qword [r13 + 8]
mov edx, dword [rax + 0x74]
call fcn.180041910
mov rax, qword [r13 + 0x18]
mov ecx, dword [rsp + 0x7c]
mov byte [rax + 0x70], cl
mov rax, qword [r13 + 0x18]
cmp byte [rax + 0x70], r14b
jne 0x180053f45
mov byte [rax + 0x70], 1
mov rax, qword [r13 + 0x18]
cmp byte [rax + 0x70], 4
jbe 0x180053f6a
mov rcx, qword [rsp + 0x38]
lea r8, str.unsupported_file_format
mov rdx, rbp
call fcn.180065550
mov edi, ebx
jmp 0x180054069
test r12d, r12d
jne 0x180053f7b
cmp ecx, 4
jl 0x180053f7b
and dword [rbp + 0x2c], 0xffff7fff
mov r8, qword [rbp + 0x20]
mov r9, qword [rsp + 0x58]
lea rdx, str.SELECT_name__rootpage__sql_FROM___w_._s_ORDER_BY_rowid
mov r8, qword [rsi + r8]
mov rcx, rbp
call fcn.180057320
mov rbx, qword [rbp + 0x190]
lea r9, [rsp + 0x40]
lea r8, [fcn.1800539a0]
mov rdx, rax
mov rcx, rbp
mov rsi, rax
mov qword [rbp + 0x190], r14
mov qword [rsp + 0x20], r14
call sym.sqlite3.dll_sqlite3_exec
mov qword [rbp + 0x190], rbx
test eax, eax
mov edi, eax
cmove edi, dword [rsp + 0x54]
test rsi, rsi
je 0x180054022
cmp qword [rbp + 0x298], r14
je 0x180053fef
mov rdx, rsi
mov rcx, rbp
call fcn.18002c290
jmp 0x180054022
cmp rsi, qword [rbp + 0x180]
jb 0x18005401a
cmp rsi, qword [rbp + 0x188]
jae 0x18005401a
mov rax, qword [rbp + 0x178]
mov qword [rsi], rax
dec dword [rbp + 0x160]
mov qword [rbp + 0x178], rsi
jmp 0x180054022
mov rcx, rsi
call sym.sqlite3.dll_sqlite3_free
test edi, edi
jne 0x180054031
mov edx, r12d
mov rcx, rbp
call fcn.18003c3d0
cmp byte [rbp + 0x55], r14b
je 0x180054046
mov rcx, rbp
mov edi, 7
call fcn.18005fbe0
jmp 0x18005404a
test edi, edi
je 0x180054053
test dword [rbp + 0x2c], 0x10000
je 0x180054069
mov rax, qword [rbp + 0x20]
mov rcx, qword [rsp + 0x30]
mov edi, r14d
mov rcx, qword [rcx + rax + 0x18]
or word [rcx + 0x72], 1
test r15d, r15d
je 0x180054077
mov rcx, qword [r13 + 8]
call fcn.18003ef00
mov rcx, qword [r13 + 8]
mov r14, qword [rsp + 0xa0]
mov rbx, qword [rsp + 0xf8]
cmp byte [rcx + 0x11], 0
je 0x18005409b
dec dword [rcx + 0x14]
jne 0x18005409b
call fcn.180080340
mov eax, 1
cmp edi, 7
je 0x1800540ad
cmp edi, 0xc0a
jne 0x1800540d2
cmp byte [rbp + 0x55], 0
jne 0x1800540d2
cmp byte [rbp + 0x56], 0
jne 0x1800540d2
cmp dword [rbp + 0xb8], 0
mov byte [rbp + 0x55], 1
jle 0x1800540cc
mov dword [rbp + 0x150], eax
inc dword [rbp + 0x158]
mov eax, edi
mov rcx, qword [rsp + 0x90]
xor rcx, rsp
call fcn.180092ad0
add rsp, 0xa8
pop r15
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret