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

Disassembly:
sub esp, 0x64
push ebx
push ebp
mov ebp, dword [esp + 0x70]
mov eax, dword [ebp]
push esi
mov esi, dword [eax]
mov dword [esp + 0x50], eax
movzx eax, byte [ebp + 0x29]
push edi
xor edi, edi
cmp eax, 1
mov dword [esp + 0x40], edi
mov dword [esp + 0x48], edi
mov dword [esp + 0x44], edi
mov dword [esp + 0x2c], edi
mov dword [esp + 0x58], esi
mov dword [esp + 0x28], eax
jg 0x1005f26c
lea ebx, [edi + 1]
jmp 0x1005f27b
mov ebx, eax
sub ebx, 2
neg ebx
sbb ebx, ebx
and ebx, 5
add ebx, 5
mov ecx, dword [ebp + 8]
mov dword [esp + 0x30], ebx
cmp ecx, edi
je 0x1005f291
cmp word [esp + 0x7c], di
je 0x1005f291
mov ecx, dword [ecx]
jmp 0x1005f293
xor ecx, ecx
add eax, 8
imul eax, ebx
lea eax, [ecx + eax*4]
add eax, eax
cdq
push edx
push eax
mov dword [esp + 0x44], ecx
call fcn.10028800
add esp, 8
mov dword [esp + 0x1c], eax
cmp eax, edi
jne 0x1005f2c2
mov eax, 7
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x64
ret
mov edx, dword [esp + 0x1c]
xor eax, eax
mov ecx, ebx
shl ecx, 5
lea edi, [ecx + edx]
mov dword [edi], eax
mov dword [edi + 4], eax
mov dword [edi + 8], eax
mov dword [edi + 0xc], eax
mov dword [edi + 0x10], eax
mov dword [edi + 0x14], eax
mov dword [edi + 0x18], eax
mov dword [edi + 0x1c], eax
lea eax, [ebx + ebx]
mov ebx, dword [esp + 0x28]
add ecx, edi
mov dword [esp + 0x24], edx
mov dword [esp + 0x38], edi
test eax, eax
jle 0x1005f312
lea esi, [ebx*4]
add edx, 0x18
mov dword [edx], ecx
dec eax
add edx, 0x20
add ecx, esi
test eax, eax
jg 0x1005f306
mov esi, dword [esp + 0x3c]
test esi, esi
je 0x1005f32d
lea eax, [esi + esi]
push eax
push 0
push ecx
mov dword [esp + 0x38], ecx
call fcn.10004b00
add esp, 0xc
mov ecx, dword [esp + 0x54]
mov eax, dword [ecx + 0x1a8]
cmp eax, 0x2e
jb 0x1005f341
mov eax, 0x2e
mov word [edi + 0x10], ax
mov eax, 1
test esi, esi
je 0x1005f35c
test ebx, ebx
jle 0x1005f357
or ecx, 0xffffffff
jmp 0x1005f359
mov ecx, esi
mov byte [edi + 0x16], cl
mov dword [esp + 0x34], 0
test ebx, ebx
jle 0x1005f890
lea esp, [esp]
mov dword [esp + 0x20], 0
test eax, eax
jle 0x1005f7da
mov edx, dword [esp + 0x38]
add edx, 0x10
mov dword [esp + 0x18], edx
mov dword [esp + 0x50], eax
nop
mov eax, dword [esp + 0x78]
mov ebx, dword [eax + 0x10]
mov dword [esp + 0x4c], ebx
test ebx, ebx
je 0x1005f7ca
mov eax, dword [esp + 0x18]
mov cl, byte [eax + 6]
mov edx, dword [eax - 0xc]
mov edi, dword [eax - 0x10]
add eax, 0xfffffff0
mov byte [esp + 0x13], cl
xor ecx, ecx
mov dword [esp + 0x5c], ecx
mov dword [esp + 0x60], ecx
mov eax, edi
mov ecx, edx
not eax
and eax, dword [ebx]
not ecx
and ecx, dword [ebx + 4]
mov dword [esp + 0x70], edx
or eax, ecx
jne 0x1005f7bb
mov esi, dword [ebx + 8]
mov ebp, dword [ebx + 0xc]
mov eax, esi
mov ecx, ebp
and eax, edi
and ecx, edx
or eax, ecx
jne 0x1005f7bb
mov edx, dword [esp + 0x18]
movzx eax, word [edx]
mov cx, word [ebx + 0x14]
add cx, ax
movzx eax, cx
movzx ecx, word [ebx + 0x12]
cmp cx, ax
jl 0x1005f43e
movsx edx, ax
movsx eax, cx
lea ebx, [edx + 0x31]
cmp eax, ebx
jg 0x1005f46e
lea ebx, [edx + 0x1f]
cmp eax, ebx
jle 0x1005f428
inc ecx
movzx eax, cx
mov dword [esp + 0x14], eax
jmp 0x1005f475
sub eax, edx
movzx dx, byte [eax + str._n_n_t_t_b_b_a_a_a]
add dx, cx
movzx eax, dx
mov dword [esp + 0x14], eax
jmp 0x1005f475
movsx edx, cx
movsx ecx, ax
lea ebx, [edx + 0x31]
cmp ecx, ebx
jle 0x1005f454
movzx ecx, ax
mov dword [esp + 0x14], ecx
jmp 0x1005f475
lea ebx, [edx + 0x1f]
cmp ecx, ebx
jle 0x1005f461
inc eax
movzx edx, ax
jmp 0x1005f471
sub ecx, edx
movzx cx, byte [ecx + str._n_n_t_t_b_b_a_a_a]
add cx, ax
movzx edx, cx
mov dword [esp + 0x14], edx
mov eax, dword [esp + 0x18]
movzx ecx, word [eax + 4]
mov dx, word [esp + 0x14]
cmp dx, cx
jl 0x1005f4b5
movsx ecx, cx
movsx eax, dx
lea ebx, [ecx + 0x31]
cmp eax, ebx
jg 0x1005f4ec
lea ebx, [ecx + 0x1f]
cmp eax, ebx
jle 0x1005f4a1
inc dword [esp + 0x14]
jmp 0x1005f4ec
sub eax, ecx
movzx cx, byte [eax + str._n_n_t_t_b_b_a_a_a]
add dx, cx
mov word [esp + 0x14], dx
jmp 0x1005f4ec
movsx edx, dx
movsx eax, cx
lea ebx, [edx + 0x31]
cmp eax, ebx
jle 0x1005f4cb
movzx edx, cx
mov dword [esp + 0x14], edx
jmp 0x1005f4ec
lea ebx, [edx + 0x1f]
cmp eax, ebx
jle 0x1005f4d8
inc ecx
movzx eax, cx
jmp 0x1005f4e8
sub eax, edx
movzx dx, byte [eax + str._n_n_t_t_b_b_a_a_a]
add dx, cx
movzx eax, dx
mov dword [esp + 0x14], eax
mov ecx, dword [esp + 0x18]
mov ebx, dword [esp + 0x4c]
movzx eax, word [ecx]
mov dx, word [ebx + 0x16]
or ebp, dword [esp + 0x70]
add dx, ax
movzx eax, dx
mov dword [esp + 0x4c], eax
mov al, byte [esp + 0x13]
or esi, edi
mov edi, dword [esp + 0x78]
mov dword [esp + 0x64], esi
mov dword [esp + 0x68], ebp
test al, al
jge 0x1005f54a
movzx eax, word [edi + 0x22]
mov edx, dword [esp + 0x34]
lea ecx, [esp + 0x5c]
push ecx
mov ecx, dword [edi + 8]
push ebx
push edx
push eax
mov eax, dword [esp + 0x28]
add eax, 0xfffffff0
push eax
push ecx
push edi
call fcn.1005e280
add esp, 0x1c
mov byte [esp + 0x13], al
jmp 0x1005f558
mov edx, dword [ecx - 8]
mov ecx, dword [ecx - 4]
mov dword [esp + 0x5c], edx
mov dword [esp + 0x60], ecx
test al, al
jl 0x1005f64e
mov ecx, dword [esp + 0x3c]
movsx esi, al
cmp esi, ecx
jge 0x1005f64e
mov edx, dword [esp + 0x2c]
cmp word [edx + esi*2], 0
jne 0x1005f5d9
mov eax, ecx
sub eax, esi
imul eax, eax, 0x64
cdq
idiv ecx
cdq
push edx
push eax
call fcn.100161e0
sub ax, 0x42
add esp, 8
cmp word [esp + 0x7c], 0xa
movzx ebp, ax
jg 0x1005f5a2
xor eax, eax
jmp 0x1005f5b6
movsx eax, word [esp + 0x7c]
cdq
push edx
push eax
call fcn.100161e0
cwde
add esp, 8
sub eax, 0x21
mov ecx, dword [esp + 0x7c]
add eax, ebp
lea edx, [eax + ecx + 0x10]
mov ecx, 0x400
movzx eax, dx
test word [edi + 0x22], cx
je 0x1005f5d1
add eax, 0x10
mov edx, dword [esp + 0x2c]
mov word [edx + esi*2], ax
mov eax, dword [esp + 0x2c]
movzx eax, word [eax + esi*2]
mov dx, word [esp + 0x14]
cmp dx, ax
movsx ecx, ax
jl 0x1005f620
movsx eax, dx
lea esi, [ecx + 0x31]
cmp eax, esi
jle 0x1005f5fd
movzx esi, dx
jmp 0x1005f653
lea esi, [ecx + 0x1f]
cmp eax, esi
jle 0x1005f60e
mov ecx, dword [esp + 0x14]
inc ecx
movzx esi, cx
jmp 0x1005f653
sub eax, ecx
movzx ax, byte [eax + str._n_n_t_t_b_b_a_a_a]
add ax, dx
movzx esi, ax
jmp 0x1005f653
movsx edx, dx
lea esi, [edx + 0x31]
cmp ecx, esi
jle 0x1005f62f
movzx esi, ax
jmp 0x1005f653
lea esi, [edx + 0x1f]
cmp ecx, esi
jle 0x1005f63c
inc eax
movzx esi, ax
jmp 0x1005f653
sub ecx, edx
movzx cx, byte [ecx + str._n_n_t_t_b_b_a_a_a]
add cx, ax
movzx esi, cx
jmp 0x1005f653
movzx esi, word [esp + 0x14]
mov edi, dword [esp + 0x20]
mov ebp, dword [esp + 0x24]
xor eax, eax
test edi, edi
jle 0x1005f690
mov edx, dword [ebp]
cmp edx, dword [esp + 0x64]
jne 0x1005f682
mov ecx, dword [ebp + 4]
cmp ecx, dword [esp + 0x68]
jne 0x1005f682
mov dl, byte [ebp + 0x16]
xor dl, byte [esp + 0x13]
mov edi, dword [esp + 0x20]
test dl, dl
jns 0x1005f68c
inc eax
add ebp, 0x20
cmp eax, edi
jl 0x1005f661
jmp 0x1005f690
cmp eax, edi
jl 0x1005f6d2
cmp edi, dword [esp + 0x30]
jl 0x1005f6c2
mov eax, dword [esp + 0x48]
cmp si, ax
jg 0x1005f7bb
jne 0x1005f6b5
mov ax, word [esp + 0x14]
cmp ax, word [esp + 0x44]
jge 0x1005f7bb
mov ebp, dword [esp + 0x40]
shl ebp, 5
add ebp, dword [esp + 0x24]
jmp 0x1005f6f0
mov ebp, edi
inc edi
shl ebp, 5
add ebp, dword [esp + 0x24]
mov dword [esp + 0x20], edi
jmp 0x1005f6f0
movzx eax, word [ebp + 0x12]
cmp ax, si
jl 0x1005f7bb
jne 0x1005f6f0
mov cx, word [ebp + 0x10]
cmp cx, word [esp + 0x4c]
jle 0x1005f7bb
mov edx, dword [ebx + 8]
mov ecx, dword [ebx + 0xc]
mov eax, dword [esp + 0x18]
or edx, dword [eax - 0x10]
or ecx, dword [eax - 0xc]
add eax, 0xfffffff0
mov eax, dword [esp + 0x60]
mov word [ebp + 0x12], si
mov esi, dword [esp + 0x34]
mov dword [ebp], edx
mov edx, dword [esp + 0x5c]
mov dword [ebp + 4], ecx
mov cx, word [esp + 0x4c]
mov dword [ebp + 0xc], eax
mov al, byte [esp + 0x13]
mov dword [ebp + 8], edx
mov dx, word [esp + 0x14]
mov word [ebp + 0x10], cx
mov ecx, dword [esp + 0x18]
add esi, esi
mov byte [ebp + 0x16], al
mov eax, dword [ebp + 0x18]
mov word [ebp + 0x14], dx
mov edx, dword [ecx + 8]
add esi, esi
push esi
push edx
push eax
call fcn.100091c0
mov ecx, dword [ebp + 0x18]
add esp, 0xc
cmp edi, dword [esp + 0x30]
mov dword [esi + ecx], ebx
jl 0x1005f7bb
mov ecx, dword [esp + 0x24]
movzx esi, word [ecx + 0x12]
movzx edi, word [ecx + 0x10]
mov ebp, dword [esp + 0x30]
mov eax, 1
cmp ebp, eax
mov dword [esp + 0x40], 0
mov dword [esp + 0x48], esi
mov dword [esp + 0x44], edi
jle 0x1005f7bb
add ecx, 0x32
lea esp, [esp]
movzx edx, word [ecx]
cmp dx, si
jg 0x1005f7a0
jne 0x1005f7ab
cmp word [ecx + 2], di
jle 0x1005f7ab
movzx edi, word [ecx + 2]
movzx esi, dx
mov dword [esp + 0x40], eax
inc eax
add ecx, 0x20
cmp eax, ebp
jl 0x1005f790
mov dword [esp + 0x44], edi
mov dword [esp + 0x48], esi
mov ebx, dword [ebx + 0x34]
mov dword [esp + 0x4c], ebx
test ebx, ebx
jne 0x1005f3a3
add dword [esp + 0x18], 0x20
sub dword [esp + 0x50], 1
jne 0x1005f390
mov ecx, dword [esp + 0x34]
mov eax, dword [esp + 0x24]
mov edx, dword [esp + 0x38]
inc ecx
cmp ecx, dword [esp + 0x28]
mov dword [esp + 0x38], eax
mov eax, dword [esp + 0x20]
mov dword [esp + 0x24], edx
mov dword [esp + 0x34], ecx
jl 0x1005f370
test eax, eax
jne 0x1005f888
mov edi, dword [esp + 0x54]
push str.no_query_solution
call fcn.100320c0
mov ecx, dword [esp + 0x5c]
mov eax, dword [esp + 0x20]
add esp, 4
test ecx, ecx
je 0x1005f872
cmp dword [ecx + 0x208], 0
je 0x1005f841
call fcn.10022ca0
mov eax, 1
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x64
ret
cmp eax, dword [ecx + 0x114]
jb 0x1005f872
cmp eax, dword [ecx + 0x118]
jae 0x1005f872
mov edx, dword [ecx + 0x110]
mov dword [eax], edx
dec dword [ecx + 0xfc]
mov dword [ecx + 0x110], eax
mov eax, 1
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x64
ret
push eax
call sym.SQLite.Interop.dll_sqlite3_free
add esp, 4
mov eax, 1
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x64
ret
mov ebp, dword [esp + 0x78]
mov edi, dword [esp + 0x38]
cmp eax, 1
mov ebx, dword [esp + 0x28]
jle 0x1005f8b4
lea ecx, [edi + 0x20]
dec eax
lea ecx, [ecx]
mov dx, word [edi + 0x12]
cmp dx, word [ecx + 0x12]
jle 0x1005f8ac
mov edi, ecx
add ecx, 0x20
sub eax, 1
jne 0x1005f8a0
xor ecx, ecx
test ebx, ebx
jle 0x1005f8e9
lea eax, [ebp + 0x304]
mov edx, dword [edi + 0x18]
mov esi, dword [edx + ecx*4]
mov dword [eax + 0x14], esi
mov dl, byte [esi + 0x10]
mov byte [eax], dl
mov esi, dword [ebp + 4]
movzx edx, dl
lea edx, [edx + edx*4]
shl edx, 4
mov edx, dword [edx + esi + 0x38]
mov dword [eax - 0x20], edx
inc ecx
add eax, 0x48
cmp ecx, ebx
jl 0x1005f8c0
movzx eax, word [ebp + 0x22]
test eax, 0x400
je 0x1005f93b
test eax, 0x200
jne 0x1005f93b
cmp byte [ebp + 0x28], 0
jne 0x1005f93b
cmp word [esp + 0x7c], 0
je 0x1005f93b
mov ecx, dword [edi + 0x18]
mov edx, dword [ecx + ebx*4 - 4]
mov ecx, dword [ebp + 0xc]
lea eax, [esp + 0x6c]
push eax
push edx
lea eax, [ebx - 1]
push eax
push 0x200
push edi
push ecx
push ebp
call fcn.1005e280
mov edx, dword [ebp + 0xc]
movsx eax, al
add esp, 0x1c
cmp eax, dword [edx]
jne 0x1005f93b
mov byte [ebp + 0x28], 2
mov ecx, dword [ebp + 8]
xor esi, esi
cmp ecx, esi
je 0x1005f9cb
movzx edx, word [ebp + 0x22]
test edx, 0x200
je 0x1005f962
movsx eax, byte [edi + 0x16]
cmp eax, dword [ecx]
jne 0x1005f97c
mov byte [ebp + 0x28], 2
jmp 0x1005f97c
mov al, byte [edi + 0x16]
mov byte [ebp + 0x24], al
test al, al
jge 0x1005f970
mov byte [ebp + 0x24], 0
mov eax, dword [edi + 8]
mov dword [ebp + 0x18], eax
mov eax, dword [edi + 0xc]
mov dword [ebp + 0x1c], eax
test edx, 0x800
je 0x1005f9cb
movsx edx, byte [ebp + 0x24]
cmp edx, dword [ecx]
jne 0x1005f9cb
mov edx, dword [edi + 0x18]
lea eax, [esp + 0x5c]
push eax
mov eax, dword [edx + ebx*4 - 4]
push eax
dec ebx
push ebx
push esi
push edi
push ecx
push ebp
mov dword [esp + 0x78], esi
mov dword [esp + 0x7c], esi
call fcn.1005e280
mov ecx, dword [ebp + 8]
movsx eax, al
add esp, 0x1c
cmp eax, dword [ecx]
jne 0x1005f9cb
mov edx, dword [esp + 0x5c]
mov eax, dword [esp + 0x60]
mov byte [ebp + 0x25], 1
mov dword [ebp + 0x18], edx
mov dword [ebp + 0x1c], eax
mov cx, word [edi + 0x10]
mov eax, dword [esp + 0x1c]
mov word [ebp + 0x20], cx
mov ecx, dword [esp + 0x58]
cmp ecx, esi
je 0x1005fa24
cmp dword [ecx + 0x208], esi
je 0x1005f9f6
call fcn.10022ca0
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x64
ret
cmp eax, dword [ecx + 0x114]
jb 0x1005fa24
cmp eax, dword [ecx + 0x118]
jae 0x1005fa24
mov edx, dword [ecx + 0x110]
mov dword [eax], edx
dec dword [ecx + 0xfc]
mov dword [ecx + 0x110], eax
xor eax, eax
pop edi
pop esi
pop ebp
pop ebx
add esp, 0x64
ret
push eax
call sym.SQLite.Interop.dll_sqlite3_free
add esp, 4
pop edi
pop esi
pop ebp
xor eax, eax
pop ebx
add esp, 0x64
ret