Function at 0x140011d50
Capabilities:
Reference sql statements

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0x58
mov rbp, rcx
mov r12, rdx
mov rdx, r8
mov qword [rsp + 0xb0], r8
lea rcx, str.SELECT_name__sql_FROM_sqlite_schema_WHERE__s_ORDER_BY_rowid_ASC
mov rsi, r9
mov qword [rsp + 0x40], 0
mov qword [rsp + 0x48], 0
call sym.sqlite3_mprintf
mov rdi, rax
test rax, rax
je 0x1400120b3
mov rcx, qword [rbp]
lea rax, [rsp + 0x40]
mov r8d, 0xffffffff
mov rdx, rdi
mov qword [rsp + 0x20], 0
mov r9, rax
mov qword [rsp + 0x38], rax
call sym.sqlite3_prepare_v2
mov r14, qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
test eax, eax
jne 0x140012080
nop dword [rax]
mov rcx, qword [rsp + 0x40]
call sym.sqlite3_step
cmp eax, 0x64
jne 0x140011e5e
mov rcx, qword [rsp + 0x40]
xor edx, edx
call sym.sqlite3_column_text
mov rcx, qword [rsp + 0x40]
mov edx, 1
mov rbx, rax
call sym.sqlite3_column_text
mov r15, rax
test rbx, rbx
je 0x140011dd8
test rax, rax
je 0x140011dd8
lea rdx, [0x140152298]
mov rcx, rbx
mov r13, r14
call sym.sqlite3_stricmp
test eax, eax
jne 0x140011e90
test rsi, rsi
je 0x140011e38
mov r8, rbx
mov rdx, r12
mov rcx, rbp
call rsi
mov ecx, 1
call r13
lea rcx, str.done_n
mov rdx, rax
call sym.fPutsUtf8.isra.0
mov rcx, qword [rsp + 0x40]
call sym.sqlite3_step
cmp eax, 0x64
je 0x140011de7
mov rcx, qword [rsp + 0x40]
cmp eax, 0x65
jne 0x140011f10
call sym.sqlite3_finalize
mov rcx, rdi
call sym.sqlite3_free
nop
add rsp, 0x58
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret
mov ecx, 1
call r14
mov r8, rbx
lea rdx, str._s...
mov rcx, rax
call sym.fPrintfUtf8
mov ecx, 1
call r14
mov rcx, rax
call sym.fflush
lea rax, [rsp + 0x48]
mov rdx, r15
xor r9d, r9d
mov qword [rsp + 0x20], rax
xor r8d, r8d
mov rcx, r12
call sym.sqlite3_exec
mov rdx, qword [rsp + 0x48]
test rdx, rdx
je 0x140011e28
mov r8, r15
lea rcx, str.Error:__s_nSQL:___s__n
call sym.ePrintfUtf8
mov rcx, qword [rsp + 0x48]
call sym.sqlite3_free
mov qword [rsp + 0x48], 0
jmp 0x140011e28
call sym.sqlite3_finalize
mov rcx, rdi
call sym.sqlite3_free
mov rdx, qword [rsp + 0xb0]
lea rcx, str.SELECT_name__sql_FROM_sqlite_schema_WHERE__s_ORDER_BY_rowid_DESC
call sym.sqlite3_mprintf
mov rdi, rax
test rax, rax
je 0x1400120b3
mov rcx, qword [rbp]
mov r9, qword [rsp + 0x38]
mov r8d, 0xffffffff
mov rdx, rax
mov qword [rsp + 0x20], 0
lea r15, [0x140152298]
call sym.sqlite3_prepare_v2
mov r14, qword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
test eax, eax
jne 0x140012080
nop dword [rax + rax]
mov rcx, qword [rsp + 0x40]
call sym.sqlite3_step
cmp eax, 0x64
jne 0x140012070
mov rcx, qword [rsp + 0x40]
xor edx, edx
call sym.sqlite3_column_text
mov rcx, qword [rsp + 0x40]
mov edx, 1
mov rbx, rax
call sym.sqlite3_column_text
mov r13, rax
test rbx, rbx
je 0x140011f78
test rax, rax
je 0x140011f78
mov rdx, r15
mov rcx, rbx
call sym.sqlite3_stricmp
test eax, eax
je 0x140011f78
mov ecx, 1
call r14
mov r8, rbx
lea rdx, str._s...
mov rcx, rax
call sym.fPrintfUtf8
mov ecx, 1
call r14
mov rcx, rax
call sym.fflush
lea rax, [rsp + 0x48]
mov rdx, r13
xor r9d, r9d
mov qword [rsp + 0x20], rax
xor r8d, r8d
mov rcx, r12
call sym.sqlite3_exec
mov rdx, qword [rsp + 0x48]
test rdx, rdx
je 0x140012036
mov r8, r13
lea rcx, str.Error:__s_nSQL:___s__n
call sym.ePrintfUtf8
mov rcx, qword [rsp + 0x48]
call sym.sqlite3_free
mov qword [rsp + 0x48], 0
test rsi, rsi
je 0x140012046
mov r8, rbx
mov rdx, r12
mov rcx, rbp
call rsi
mov ecx, 1
call r14
lea rcx, str.done_n
mov rdx, rax
call sym.fPutsUtf8.isra.0
mov rcx, qword [rsp + 0x40]
call sym.sqlite3_step
cmp eax, 0x64
je 0x140011f8b
mov rcx, qword [rsp + 0x40]
jmp 0x140011e6c
mov rcx, qword [rbp]
call sym.sqlite3_errmsg
mov rcx, qword [rbp]
mov rbx, rax
call sym.sqlite3_extended_errcode
lea rcx, str.Error:___d___s_on___s__n
mov r9, rdi
mov r8, rbx
mov edx, eax
call sym.ePrintfUtf8
mov rcx, qword [rsp + 0x40]
jmp 0x140011e6c
call sym.shell_out_of_memory
nop
nop dword [rax]