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

Disassembly:
push r15
push r14
push r13
push r12
push rbp
push rdi
push rsi
push rbx
sub rsp, 0xd8
mov r15d, 1
mov dword [rsp + 0x8c], edx
mov eax, dword [rsp + 0x8c]
mov rbx, rcx
mov word [rsp + 0x66], ax
mov rax, qword [rcx]
mov qword [rsp + 0x50], rax
movzx eax, byte [rcx + 0x40]
cmp eax, 1
mov byte [rsp + 0x79], al
mov dword [rsp + 0x60], eax
jle 0x4502e1
xor r15d, r15d
cmp eax, 2
setne r15b
lea r15d, [r15 + r15*4 + 5]
mov rax, qword [rbx + 0x10]
test rax, rax
je 0x4502fd
cmp word [rsp + 0x8c], 0
je 0x4502fd
mov eax, dword [rax]
mov dword [rsp + 0x44], eax
jmp 0x450305
mov dword [rsp + 0x44], 0
movzx r13d, byte [rsp + 0x79]
movsxd rsi, r15d
mov edi, dword [rsp + 0x44]
movsxd r12, dword [rsp + 0x44]
lea rax, [r13 + 4]
imul eax, r15d
shl eax, 4
lea edx, [rax + rdi*2]
mov rax, qword [rsp + 0x50]
movsxd rdx, edx
mov rcx, qword [rax]
call sym.sqlite3DbMallocRawNN
mov dword [rsp + 0x7c], 7
test rax, rax
mov qword [rsp + 0x58], rax
je 0x450ad2
shl rsi, 5
mov ecx, 8
lea rbp, [rax + rsi]
xor eax, eax
mov rdi, rbp
add rsi, rbp
rep stosd dword [rdi], eax
mov rcx, qword [rsp + 0x58]
lea eax, [r15 + r15]
mov rdx, rsi
lea rdi, [r13*8]
mov dword [rsp + 0x7c], eax
mov qword [rsp + 0x68], rdi
mov qword [rcx + 0x18], rdx
add rcx, 0x20
add rdx, qword [rsp + 0x68]
dec dword [rsp + 0x7c]
jne 0x45037f
dec eax
cdqe
inc rax
imul rax, qword [rsp + 0x68]
add rax, rsi
cmp dword [rsp + 0x44], 0
mov qword [rsp + 0x80], rax
je 0x4503c3
mov rdi, qword [rsp + 0x80]
lea rcx, [r12 + r12]
xor eax, eax
rep stosb byte [rdi], al
jmp 0x4503cf
mov qword [rsp + 0x80], 0
mov rax, qword [rsp + 0x50]
mov rsi, qword [rsp + 0x50]
cmp dword [rax + 0xd0], 0x30
mov eax, 0x30
cmovbe eax, dword [rsi + 0xd0]
cmp dword [rsp + 0x44], 0
mov word [rbp + 0x10], ax
je 0x450409
cmp dword [rsp + 0x60], 0
mov eax, 0xffffffff
cmove eax, dword [rsp + 0x44]
mov byte [rbp + 0x16], al
mov rax, qword [rsp + 0x58]
mov r12d, 1
mov dword [rsp + 0x88], 0
mov qword [rsp + 0x70], 0
mov word [rsp + 0xbc], 0
mov word [rsp + 0x7a], 0
mov qword [rsp + 0x48], rax
mov ax, word [rsp + 0x66]
sub eax, 0xa
mov word [rsp + 0xbe], ax
mov eax, dword [rsp + 0x70]
cmp dword [rsp + 0x60], eax
mov dword [rsp + 0x9c], eax
mov dword [rsp + 0xb8], eax
jle 0x450709
mov rax, qword [rsp + 0x70]
movsxd r12, r12d
mov r13, rbp
shl r12, 5
shl rax, 3
mov qword [rsp + 0x90], rax
lea rax, [rbp + r12]
xor r12d, r12d
mov qword [rsp + 0xa8], rax
lea rax, [rsp + 0xc8]
mov qword [rsp + 0xb0], rax
cmp r13, qword [rsp + 0xa8]
je 0x4506f2
mov r14, qword [rbx + 0x58]
test r14, r14
je 0x4506e9
mov r11, qword [r13]
mov rax, r11
not rax
test qword [r14], rax
jne 0x4506e0
mov rdi, qword [r14 + 8]
test r11, rdi
jne 0x4506e0
test byte [r14 + 0x39], 0x40
mov r10d, dword [r13 + 0x10]
je 0x4504f6
cmp r10w, 2
jle 0x4506e0
mov edx, r10d
add edx, dword [r14 + 0x14]
movsx ecx, word [r14 + 0x12]
movsx edx, dx
call sym.sqlite3LogEstAdd
movsx edx, word [r13 + 0x14]
movsx ecx, ax
call sym.sqlite3LogEstAdd
add r10w, word [r14 + 0x16]
or r11, rdi
mov esi, eax
mov qword [rsp + 0xa0], r11
mov r11b, byte [r13 + 0x16]
mov word [rsp + 0x9a], r10w
mov word [rsp + 0x98], r10w
test r11b, r11b
jns 0x45058e
mov rdx, qword [rbx + 0x10]
mov qword [rsp + 0x28], r14
mov r8, r13
mov rcx, rbx
mov rax, qword [rsp + 0xb0]
mov qword [rsp + 0xc8], 0
movzx r9d, word [rbx + 0x3c]
mov qword [rsp + 0x30], rax
mov eax, dword [rsp + 0x9c]
mov dword [rsp + 0x20], eax
call sym.wherePathSatisfiesOrderBy
test al, al
mov r11d, eax
js 0x450674
jmp 0x45059a
mov rax, qword [r13 + 8]
mov qword [rsp + 0xc8], rax
movsx edi, r11b
cmp edi, dword [rsp + 0x44]
jge 0x450674
movsx r8, r11b
add r8, r8
add r8, qword [rsp + 0x80]
cmp word [r8], 0
jne 0x450661
mov rax, qword [rbx + 0x20]
mov r9d, 0x1e
mov rax, qword [rax + 0x20]
mov eax, dword [rax]
add eax, 0x3b
cdq
idiv r9d
movsxd rcx, eax
call sym.sqlite3LogEst
mov cx, word [rsp + 0x66]
test edi, edi
lea r9d, [rax + rcx]
jle 0x450609
mov eax, dword [rsp + 0x44]
sub eax, edi
imul eax, eax, 0x64
cdq
idiv dword [rsp + 0x44]
movsxd rcx, eax
call sym.sqlite3LogEst
lea r9d, [r9 + rax - 0x42]
mov eax, dword [rbx + 0x3c]
mov r10d, r9d
test ah, 0x40
je 0x450635
lea edx, [r9 + 0x10]
test edi, edi
jne 0x450620
lea edx, [r9 + 0xa]
mov ax, word [rsp + 0x66]
mov r10d, edx
cmp word [rbx + 0x3e], ax
mov ecx, eax
cmovle cx, word [rbx + 0x3e]
jmp 0x450651
test ah, 1
je 0x45064c
cmp word [rsp + 0x66], 0xa
jle 0x45064c
mov cx, word [rsp + 0xbe]
jmp 0x450651
mov cx, word [rsp + 0x66]
movsx ecx, cx
call sym.estLog
lea edx, [rax + r10]
mov word [r8], dx
movsx edx, word [r8]
movsx ecx, si
call sym.sqlite3LogEstAdd
mov edx, esi
lea esi, [rax + 3]
jmp 0x450677
lea edx, [rsi - 2]
cmp dword [rsp + 0xb8], 0
jne 0x45069e
test byte [r14 + 0x3b], 2
je 0x45069e
mov ax, word [rsp + 0x9a]
sub esi, 0xa
sub eax, 0x1e
mov word [rsp + 0x98], ax
mov rax, qword [rsp + 0x48]
xor ecx, ecx
cmp ecx, r12d
je 0x4506cc
mov rdi, qword [rsp + 0xa0]
cmp qword [rax], rdi
jne 0x4506c4
mov edi, r11d
xor dil, byte [rax + 0x16]
jns 0x4509aa
inc ecx
add rax, 0x20
jmp 0x4506a5
cmp r12d, r15d
jl 0x450abe
cmp word [rsp + 0x7a], si
jge 0x450aa4
mov r14, qword [r14 + 0x50]
jmp 0x4504b7
add r13, 0x20
jmp 0x4504a5
inc qword [rsp + 0x70]
mov rax, rbp
mov rbp, qword [rsp + 0x48]
mov qword [rsp + 0x48], rax
jmp 0x45044e
test r12d, r12d
je 0x450719
lea rax, [rbp + 0x20]
mov edx, 1
jmp 0x450749
mov rcx, qword [rsp + 0x50]
lea rdx, str.no_query_solution
call sym.sqlite3ErrorMsg
mov rax, qword [rsp + 0x50]
mov rdx, qword [rsp + 0x58]
mov rcx, qword [rax]
call sym.sqlite3DbFreeNN
mov dword [rsp + 0x7c], 1
jmp 0x450ad2
cmp edx, r12d
je 0x450762
mov si, word [rax + 0x12]
cmp word [rbp + 0x12], si
cmovg rbp, rax
inc edx
add rax, 0x20
jmp 0x450749
lea rdx, [rbx + 0x364]
xor ecx, ecx
cmp dword [rsp + 0x60], ecx
jle 0x45079b
mov rax, qword [rbp + 0x18]
add rdx, 0x68
mov rax, qword [rax + rcx*8]
inc rcx
mov qword [rdx - 0x14], rax
movzx eax, byte [rax + 0x10]
mov byte [rdx - 0x34], al
imul rax, rax, 0x68
add rax, qword [rbx + 8]
mov eax, dword [rax + 0x4c]
mov dword [rdx - 0x68], eax
jmp 0x45076b
mov eax, dword [rbx + 0x3c]
and ax, 0x180
cmp ax, 0x100
jne 0x45080b
cmp byte [rbx + 0x43], 0
jne 0x45080b
cmp word [rsp + 0x8c], 0
je 0x45080b
mov rdx, qword [rbx + 0x18]
mov r9d, pe_nt_image_headers64
mov r8, rbp
mov rcx, rbx
lea rax, [rsp + 0xc8]
mov rdi, qword [rsp + 0x68]
mov qword [rsp + 0x30], rax
mov rax, qword [rbp + 0x18]
mov rax, qword [rax + rdi - 8]
mov qword [rsp + 0x28], rax
movzx eax, byte [rsp + 0x79]
dec eax
movzx eax, ax
mov dword [rsp + 0x20], eax
call sym.wherePathSatisfiesOrderBy
mov rdx, qword [rbx + 0x18]
movsx eax, al
cmp dword [rdx], eax
jne 0x45080b
mov byte [rbx + 0x43], 2
mov cl, byte [rbx + 0x44]
mov rdx, qword [rbx + 0x10]
and ecx, 0xfffffffb
test rdx, rdx
mov byte [rbx + 0x44], cl
je 0x45098c
mov r8d, dword [rbx + 0x3c]
movsx eax, byte [rbp + 0x16]
test r8b, 0x80
mov byte [rbx + 0x41], al
je 0x45085d
cmp eax, dword [rdx]
jne 0x45083a
mov byte [rbx + 0x43], 2
mov rdx, qword [rbx + 0x20]
mov rdx, qword [rdx + 0x48]
test rdx, rdx
je 0x450910
mov edx, dword [rdx]
cmp eax, edx
jle 0x450910
mov byte [rbx + 0x41], dl
jmp 0x450910
mov r9, qword [rbp + 8]
test al, al
mov qword [rbx + 0x68], r9
jg 0x4508f9
cmp dword [rsp + 0x60], 0
mov byte [rbx + 0x41], 0
je 0x450910
mov rax, qword [rbp + 0x18]
mov rsi, qword [rsp + 0x68]
mov rcx, qword [rax + rsi - 8]
mov eax, dword [rcx + 0x38]
bt eax, 0xc
jb 0x450910
and eax, 0x104
cmp eax, 0x104
je 0x450910
lea rax, [rsp + 0xc8]
mov qword [rsp + 0x28], rcx
mov r9d, 0x800
mov r8, rbp
mov qword [rsp + 0x30], rax
mov rcx, rbx
movzx eax, byte [rsp + 0x79]
mov qword [rsp + 0xc8], 0
dec eax
movzx eax, ax
mov dword [rsp + 0x20], eax
call sym.wherePathSatisfiesOrderBy
mov rdx, qword [rbx + 0x10]
movsx eax, al
cmp dword [rdx], eax
jne 0x450910
mov rax, qword [rsp + 0xc8]
or byte [rbx + 0x44], 4
mov qword [rbx + 0x68], rax
jmp 0x450910
dec al
jne 0x450910
cmp dword [rsp + 0x60], 0
je 0x450910
and r8b, 3
je 0x450910
or ecx, 4
mov byte [rbx + 0x44], cl
test byte [rbx + 0x3d], 2
je 0x45098c
mov rdx, qword [rbx + 0x10]
movsx eax, byte [rbx + 0x41]
cmp eax, dword [rdx]
jne 0x45098c
cmp dword [rsp + 0x60], 0
je 0x45098c
mov rdi, qword [rsp + 0x68]
xor r9d, r9d
mov r8, rbp
mov rcx, rbx
lea rax, [rsp + 0xc8]
mov qword [rsp + 0xc8], 0
mov qword [rsp + 0x30], rax
mov rax, qword [rbp + 0x18]
mov rax, qword [rax + rdi - 8]
mov qword [rsp + 0x28], rax
movzx eax, byte [rsp + 0x79]
dec eax
movzx eax, ax
mov dword [rsp + 0x20], eax
call sym.wherePathSatisfiesOrderBy
mov rdx, qword [rbx + 0x10]
movsx eax, al
cmp dword [rdx], eax
jne 0x45098c
mov rax, qword [rsp + 0xc8]
or byte [rbx + 0x44], 8
mov qword [rbx + 0x68], rax
mov eax, dword [rbp + 0x10]
mov rdx, qword [rsp + 0x58]
mov word [rbx + 0x48], ax
mov rax, qword [rsp + 0x50]
mov rcx, qword [rax]
call sym.sqlite3DbFreeNN
jmp 0x450ad2
cmp word [rax + 0x12], si
jl 0x4506e0
jne 0x4509d3
mov edi, dword [rsp + 0x98]
cmp word [rax + 0x10], di
jl 0x4506e0
jne 0x4509d3
cmp word [rax + 0x14], dx
jle 0x4506e0
mov rcx, qword [r13]
or rcx, qword [r14 + 8]
cmp r12d, r15d
mov edi, dword [rsp + 0x98]
mov qword [rax], rcx
mov rcx, qword [rsp + 0xc8]
mov word [rax + 0x10], di
mov rdi, qword [rax + 0x18]
mov word [rax + 0x12], si
mov byte [rax + 0x16], r11b
mov rsi, qword [r13 + 0x18]
mov qword [rax + 8], rcx
mov ecx, dword [rsp + 0x90]
mov word [rax + 0x14], dx
rep movsb byte [rdi], byte [rsi]
mov rsi, qword [rsp + 0x90]
mov rax, qword [rax + 0x18]
mov qword [rax + rsi], r14
jl 0x4506e0
mov rax, qword [rsp + 0x48]
mov edx, 1
mov dword [rsp + 0x88], 0
mov ax, word [rax + 0x12]
mov word [rsp + 0x7a], ax
mov rax, qword [rsp + 0x48]
mov eax, dword [rax + 0x10]
mov word [rsp + 0xbc], ax
mov rax, qword [rsp + 0x48]
add rax, 0x20
cmp edx, r15d
je 0x4506e0
mov cx, word [rax + 0x12]
cmp cx, word [rsp + 0x7a]
jg 0x450a85
jne 0x450a9c
mov esi, dword [rsp + 0xbc]
cmp word [rax + 0x14], si
jle 0x450a9c
mov esi, dword [rax + 0x14]
mov word [rsp + 0x7a], cx
mov dword [rsp + 0x88], edx
mov word [rsp + 0xbc], si
inc edx
add rax, 0x20
jmp 0x450a62
jne 0x450ab4
cmp word [rsp + 0xbc], dx
jle 0x4506e0
movsxd rax, dword [rsp + 0x88]
jmp 0x450ac4
movsxd rax, r12d
inc r12d
shl rax, 5
add rax, qword [rsp + 0x48]
jmp 0x4509d3
mov eax, dword [rsp + 0x7c]
add rsp, 0xd8
pop rbx
pop rsi
pop rdi
pop rbp
pop r12
pop r13
pop r14
pop r15
ret