Function at 0x180005790
Capabilities:
Reference sql statements

Disassembly:
mov qword [rsp + 0x18], rbx
push rbp
push rsi
push rdi
push r12
push r13
push r14
push r15
sub rsp, 0x40
inc qword [rcx + 0x40]
xor r13d, r13d
or edi, 0xffffffff
cmp dword [rcx + 0x48], 0xb
mov rbx, rcx
mov esi, r13d
je 0x180005b2e
lea r14, [0x180000000]
lea r15, [0x180149830]
nop dword [rax]
mov ecx, dword [rbx + 0x48]
dec ecx
je 0x180005a4a
sub ecx, 6
je 0x1800059d1
dec ecx
je 0x1800058e8
dec ecx
jne 0x1800058db
cmp qword [rbx + 0x38], r13
lea rbp, [rbx + 0x38]
jne 0x1800058ce
mov rcx, qword [rbx + 8]
lea rax, [rsp + 0x80]
mov qword [rsp + 0x30], r13
mov qword [rsp + 0x28], rax
lea rdx, str.PRAGMA_database_list
mov r9d, 0x80
or r8d, 0xffffffff
mov qword [rsp + 0x20], r13
mov r12, r13
lea rsi, [0x180143844]
call fcn.180087650
mov rdi, qword [rsp + 0x80]
mov rcx, rdi
call sym.sqlite.dll_sqlite3_step
cmp eax, 0x64
jne 0x180005899
mov edx, 1
mov rcx, rdi
call sym.sqlite.dll_sqlite3_column_text
lea rcx, str._z_sSELECT_pti.name_FROM___w_.sqlite_schema_AS_sm_JOIN_pragma_table_info_sm.name__Q__AS_pti_WHERE_sm.typetable
mov r8, rsi
mov r9, rax
mov rdx, r12
mov qword [rsp + 0x20], rax
call sym.sqlite.dll_sqlite3_mprintf
mov r12, rax
test rax, rax
je 0x180005b48
mov rcx, rdi
lea rsi, str._UNION
call sym.sqlite.dll_sqlite3_step
cmp eax, 0x64
je 0x180005852
mov rcx, rdi
call sym.sqlite.dll_sqlite3_finalize
mov rcx, qword [rbx + 8]
mov qword [rsp + 0x30], r13
mov r9d, 0x80
or r8d, 0xffffffff
mov rdx, r12
mov qword [rsp + 0x28], rbp
mov qword [rsp + 0x20], r13
call fcn.180087650
mov rcx, r12
call sym.sqlite.dll_sqlite3_free
mov edi, r13d
mov esi, 0xb
jmp 0x180005a0c
test edi, edi
jns 0x180005a0c
jmp 0x180005a90
cmp qword [rbx + 0x38], r13
lea rbp, [rbx + 0x38]
jne 0x1800059c7
mov rcx, qword [rbx + 8]
lea rax, [rsp + 0x88]
mov qword [rsp + 0x30], r13
mov qword [rsp + 0x28], rax
lea rdx, str.PRAGMA_database_list
mov r9d, 0x80
or r8d, 0xffffffff
mov qword [rsp + 0x20], r13
mov r12, r13
lea rsi, [0x180143844]
call fcn.180087650
mov rdi, qword [rsp + 0x88]
mov rcx, rdi
call sym.sqlite.dll_sqlite3_step
cmp eax, 0x64
jne 0x180005992
nop word [rax + rax]
mov edx, 1
mov rcx, rdi
call sym.sqlite.dll_sqlite3_column_text
lea rcx, str._z_sSELECT_name_FROM___w_.sqlite_schema
mov r8, rsi
mov r9, rax
mov rdx, r12
call sym.sqlite.dll_sqlite3_mprintf
mov r12, rax
test rax, rax
je 0x180005b48
mov rcx, rdi
lea rsi, str._UNION
call sym.sqlite.dll_sqlite3_step
cmp eax, 0x64
je 0x180005950
mov rcx, rdi
call sym.sqlite.dll_sqlite3_finalize
mov rcx, qword [rbx + 8]
mov qword [rsp + 0x30], r13
mov r9d, 0x80
or r8d, 0xffffffff
mov rdx, r12
mov qword [rsp + 0x28], rbp
mov qword [rsp + 0x20], r13
call fcn.180087650
mov rcx, r12
call sym.sqlite.dll_sqlite3_free
mov edi, r13d
mov esi, 9
jmp 0x180005a0c
cmp qword [rbx + 0x38], r13
lea rax, [rbx + 0x38]
jne 0x180005a04
mov rcx, qword [rbx + 8]
mov qword [rsp + 0x30], r13
mov qword [rsp + 0x28], rax
lea rdx, str.PRAGMA_database_list
mov r9d, 0x80
or r8d, 0xffffffff
mov qword [rsp + 0x20], r13
call fcn.180087650
mov edi, 1
lea esi, [rdi + 7]
mov rcx, qword [rbx + 0x38]
call sym.sqlite.dll_sqlite3_step
mov rcx, qword [rbx + 0x38]
cmp eax, 0x64
jne 0x180005a39
mov edx, edi
call sym.sqlite.dll_sqlite3_column_text
mov rcx, qword [rbx + 0x38]
mov edx, edi
mov qword [rbx + 0x28], rax
call sym.sqlite.dll_sqlite3_column_bytes
mov dword [rbx + 0x30], eax
jmp 0x180005a9a
call sym.sqlite.dll_sqlite3_finalize
mov qword [rbx + 0x38], r13
mov dword [rbx + 0x48], esi
jmp 0x180005b24
mov eax, dword [rbx + 0x4c]
cmp eax, 0x93
jl 0x180005a61
mov qword [rbx + 0x28], r13
mov dword [rbx + 0x48], 7
jmp 0x180005a8d
lea ecx, [rax + 1]
mov dword [rbx + 0x4c], ecx
cmp eax, 0x92
ja 0x180005a8d
movsxd rcx, ecx
movzx eax, word [r14 + rcx*2 + 0x149cf0]
add rax, r15
mov qword [rbx + 0x28], rax
movzx eax, byte [rcx + r14 + 0x149c20]
mov dword [rbx + 0x30], eax
or edi, 0xffffffff
cmp qword [rbx + 0x28], r13
je 0x180005b24
mov edx, dword [rbx + 0x10]
test edx, edx
je 0x180005b2e
cmp edx, dword [rbx + 0x30]
jg 0x180005b24
mov r9, qword [rbx + 0x18]
mov r8, qword [rbx + 0x28]
test r9, r9
jne 0x180005abe
neg r8
sbb eax, eax
jmp 0x180005b20
test r8, r8
je 0x180005b24
test edx, edx
jle 0x180005afe
nop word [rax + rax]
movzx ecx, byte [r9]
dec edx
test cl, cl
je 0x180005b00
movzx eax, byte [r8]
movzx ecx, cl
movzx eax, byte [rax + r14 + 0x1439c0]
cmp byte [rcx + r14 + 0x1439c0], al
jne 0x180005b00
inc r9
inc r8
test edx, edx
jg 0x180005ad0
dec edx
test edx, edx
js 0x180005b2e
movzx eax, byte [r8]
movzx ecx, byte [rax + r14 + 0x1439c0]
movzx eax, byte [r9]
movzx eax, byte [rax + r14 + 0x1439c0]
sub eax, ecx
test eax, eax
je 0x180005b2e
cmp dword [rbx + 0x48], 0xb
jne 0x1800057d0
xor eax, eax
mov rbx, qword [rsp + 0x90]
add rsp, 0x40
pop r15
pop r14
pop r13
pop r12
pop rdi
pop rsi
pop rbp
ret
mov eax, 7
jmp 0x180005b30