Function at 0x410460
Capabilities:
Reference sql statements
Terminate process
Write file on windows

Disassembly:
push ebp
mov ebp, esp
push ebx
push edi
push esi
and esp, 0xfffffff0
sub esp, 0x60
mov edi, edx
mov ebx, ecx
mov esi, dword [ebp + 8]
mov dword [esp + 0xc], 0
mov dword [esp + 0x24], 0xffffffff
mov eax, dword [ecx]
mov dword [esp + 0x10], eax
test esi, esi
je 0x410493
mov dword [esi], 0
mov eax, dword [ebx + 0x2e0]
test eax, eax
je 0x4104bd
push esi
push edi
push eax
call fcn.00404850
add esp, 0xc
xor edx, edx
test eax, eax
setne dl
mov ecx, ebx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
jmp 0x41a600
cmp byte [edi], 0
je 0x410ae0
mov dword [esp + 0x14], ebx
mov dword [esp + 0x28], esi
nop
lea eax, [esp + 0x24]
push eax
lea eax, [esp + 0x10]
push eax
push 0xffffffffffffffff
push edi
push dword [esp + 0x20]
call fcn.0042be00
add esp, 0x14
test eax, eax
jne 0x410ae4
mov eax, dword [esp + 0xc]
test eax, eax
je 0x4106b0
push eax
call fcn.00432ed0
add esp, 4
mov esi, eax
test eax, eax
mov eax, 0x51cfd7
cmove esi, eax
mov ebx, dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_isspace]
nop dword [eax + eax]
mov dword [0x53ddfc], esi
movzx eax, byte [esi]
push eax
call ebx
add esp, 4
inc esi
test eax, eax
jne 0x410520
mov eax, dword [esp + 0xc]
mov ebx, dword [esp + 0x14]
mov dword [ebx + 0x21c], eax
mov dword [ebx + 0x28], 0
xor esi, esi
cmp byte [ebx + 5], 0
je 0x410831
push eax
call fcn.00432dc0
add esp, 4
test eax, eax
jne 0x410831
mov dword [esp + 8], 0xffffffff
mov dword [esp + 0x2c], 0
mov dword [esp + 0x30], 0
push 0x53de00
push 0
push 0x1f
call fcn.0043da80
add esp, 0xc
lea esi, [esp + 0x30]
push esi
push 1
push 0x1f
call fcn.0043da80
add esp, 0xc
push 0x53de04
push 2
push 0x1f
call fcn.0043da80
add esp, 0xc
push esi
push 3
push 0x1f
call fcn.0043da80
add esp, 0xc
lea eax, [esp + 0x2c]
push eax
push 0xffffffffffffffff
push 0x3f0
push dword [esp + 0x1c]
call fcn.004394c0
add esp, 0x10
cmp byte [ebx + 5], 2
jb 0x4105f1
push 0
push 1
push 0x3f0
push dword [esp + 0x1c]
call fcn.004394c0
add esp, 0x10
push dword [0x53ddfc]
push str.EXPLAIN_QUERY_PLAN__s
call fcn.00428600
add esp, 8
test eax, eax
je 0x410b09
mov ecx, eax
push 0
lea eax, [esp + 0xc]
push eax
push 0xffffffffffffffff
push ecx
push dword [esp + 0x20]
mov dword [esp + 0x30], ecx
call fcn.0042be00
add esp, 0x14
mov esi, eax
test eax, eax
jne 0x4106ee
mov dword [esp + 0x18], esi
jmp 0x410652
mov ecx, dword [esp + 0x14]
mov edx, dword [esp + 0x20]
push ebx
push esi
call fcn.00420550
add esp, 8
push dword [esp + 8]
call fcn.0042be30
add esp, 4
cmp eax, 0x64
jne 0x4106df
push 3
push dword [esp + 0xc]
call fcn.00431d90
add esp, 8
mov ebx, eax
push 0
push dword [esp + 0xc]
call fcn.0042d110
add esp, 8
mov dword [esp + 0x20], eax
push 1
push dword [esp + 0xc]
call fcn.0042d110
add esp, 8
mov esi, eax
test ebx, ebx
mov eax, 0x51cfd7
cmove ebx, eax
cmp byte [ebx], 0x2d
jne 0x410640
mov ecx, dword [esp + 0x14]
call fcn.00420910
jmp 0x410640
mov edi, dword [esp + 0x24]
dec edi
mov esi, dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_isspace]
nop dword [eax + eax]
movzx eax, byte [edi + 1]
inc edi
push eax
call esi
add esp, 4
test eax, eax
jne 0x4106c0
xor ebx, ebx
cmp byte [edi], 0
jne 0x410ad2
jmp 0x410aff
mov ebx, dword [esp + 0x14]
mov ecx, ebx
call fcn.00420910
mov esi, dword [esp + 0x18]
push dword [esp + 8]
call fcn.0042d1d0
add esp, 4
push dword [esp + 0x1c]
call fcn.00424f10
add esp, 4
movzx eax, byte [ebx + 5]
cmp al, 3
jb 0x4107bd
push dword [0x53ddfc]
push str.EXPLAIN__s
call fcn.00428600
add esp, 8
test eax, eax
je 0x410b09
mov ebx, eax
push 0
lea eax, [esp + 0xc]
push eax
push 0xffffffffffffffff
push ebx
push dword [esp + 0x20]
call fcn.0042be00
add esp, 0x14
mov esi, eax
test eax, eax
jne 0x4107a0
mov dword [esp + 0x18], esi
mov esi, dword [esp + 0x14]
mov dword [esi + 0x4c], 9
mov edx, dword [esp + 8]
mov ecx, esi
call fcn.004209e0
mov edx, dword [esp + 8]
mov ecx, esi
call fcn.00420ec0
push dword [esi + 0x264]
call fcn.00424f10
add esp, 4
mov dword [esi + 0x264], 0
mov dword [esi + 0x268], 0
mov dword [esi + 0x26c], 0
mov esi, dword [esp + 0x18]
push dword [esp + 8]
call fcn.0042d1d0
add esp, 4
push ebx
call fcn.00424f10
add esp, 4
mov ebx, dword [esp + 0x14]
movzx eax, byte [ebx + 5]
cmp al, 2
jb 0x41080f
cmp dword [esp + 0x2c], 0
jne 0x41080f
push 0
push 0
push 0x3f0
mov dword [esp + 0x24], esi
mov esi, dword [esp + 0x1c]
push esi
call fcn.004394c0
add esp, 0x10
push dword [esp + 0xc]
call fcn.0042d1d0
add esp, 4
push 0
lea eax, [esp + 0x10]
push eax
push 0xffffffffffffffff
push edi
push esi
mov esi, dword [esp + 0x2c]
call fcn.0042be00
add esp, 0x14
mov eax, dword [esp + 0xc]
mov dword [ebx + 0x21c], eax
push 0x53de00
push 1
push 0x1f
call fcn.0043da80
add esp, 0xc
push 0x53de04
push 3
push 0x1f
call fcn.0043da80
add esp, 0xc
mov eax, dword [ebx + 0x44]
mov dword [ebx + 0x4c], eax
cmp byte [ebx + 4], 0
je 0x410872
push dword [esp + 0xc]
call fcn.00432dc0
add esp, 4
cmp eax, 1
jne 0x410855
mov dword [ebx + 0x4c], 9
push dword [esp + 0xc]
call fcn.00432dc0
add esp, 4
cmp eax, 2
jne 0x41086f
mov dword [ebx + 0x4c], 0xc
jmp 0x410882
mov eax, dword [ebx + 0x4c]
cmp eax, 9
jne 0x410882
mov edx, dword [esp + 0xc]
mov ecx, ebx
call fcn.004209e0
mov eax, dword [esp + 0xc]
mov dword [esp + 8], 0
mov dword [esp + 0x20], eax
push eax
call fcn.00432ba0
add esp, 4
mov dword [esp + 0x1c], eax
test eax, eax
je 0x410a10
mov eax, dword [ebx]
sub esp, 0x24
pxor xmm0, xmm0
movdqu xmmword [esp + 0x10], xmm0
mov dword [esp], eax
mov dword [esp + 0x20], 0
mov dword [esp + 0xc], 0x526357
mov dword [esp + 8], str.sqlite_parameters
mov dword [esp + 4], str.TEMP
call fcn.0043c7a0
add esp, 0x24
test eax, eax
jne 0x410a10
push 0
lea eax, [esp + 0xc]
push eax
push 0xffffffffffffffff
push str.SELECT_value_FROM_temp.sqlite_parameters_WHERE_key_1
push dword [ebx]
call fcn.0042be00
add esp, 0x14
test eax, eax
jne 0x410a10
mov eax, dword [esp + 8]
test eax, eax
je 0x410a10
mov ecx, dword [esp + 0x1c]
test ecx, ecx
jle 0x4109f8
neg ecx
mov ebx, 1
mov dword [esp + 0x18], esi
mov dword [esp + 0x1c], ecx
jmp 0x41096b
push ebx
push dword [esp + 0x24]
call fcn.00432640
add esp, 8
push dword [esp + 8]
call fcn.00430240
add esp, 4
mov ecx, dword [esp + 0x1c]
lea eax, [ecx + ebx]
inc eax
inc ebx
cmp eax, 1
je 0x4109f0
pcmpeqd xmm0, xmm0
movdqu xmmword [esp + 0x3e], xmm0
movdqa xmmword [esp + 0x30], xmm0
push ebx
push dword [esp + 0x24]
call fcn.00432bb0
add esp, 8
test eax, eax
jne 0x4109a7
push ebx
push 0x526391
lea esi, [esp + 0x38]
push esi
push 0x1e
call fcn.00428750
add esp, 0x10
mov eax, esi
mov esi, dword [esp + 0x18]
push 0
push 0xffffffffffffffff
push eax
push 1
push dword [esp + 0x18]
call fcn.00432710
add esp, 0x14
push dword [esp + 8]
call fcn.0042be30
add esp, 4
cmp eax, 0x64
jne 0x410940
push 0
push dword [esp + 0xc]
call fcn.00431e50
add esp, 8
push eax
push ebx
push dword [esp + 0x28]
call fcn.004327b0
add esp, 0xc
jmp 0x41094d
mov eax, dword [esp + 8]
mov ebx, dword [esp + 0x14]
push eax
call fcn.0042d1d0
add esp, 4
nop word cs:[eax + eax]
mov edx, dword [esp + 0xc]
mov ecx, ebx
call fcn.00420ec0
push dword [ebx + 0x264]
call fcn.00424f10
add esp, 4
mov dword [ebx + 0x264], 0
mov dword [ebx + 0x268], 0
mov dword [ebx + 0x26c], 0
mov ecx, ebx
call fcn.00420910
cmp dword [ebx + 0x18], 0
je 0x410a5f
mov ecx, dword [esp + 0x10]
mov edx, ebx
call fcn.0041c7a0
push dword [esp + 0xc]
call fcn.0042d1d0
add esp, 4
mov ebx, eax
cmp esi, 7
cmove ebx, esi
test ebx, ebx
mov esi, dword [esp + 0x28]
je 0x410aa0
test esi, esi
je 0x410abf
mov ecx, dword [esp + 0x10]
mov edx, str.stepping
push 0
push ebx
call fcn.00420870
add esp, 8
mov dword [esi], eax
jmp 0x410abf
mov edi, dword [esp + 0x24]
dec edi
mov esi, dword [sym.imp.api_ms_win_crt_string_l1_1_0.dll_isspace]
nop dword [eax + eax]
movzx eax, byte [edi + 1]
inc edi
push eax
call esi
add esp, 4
test eax, eax
jne 0x410ab0
mov eax, dword [esp + 0x14]
mov dword [eax + 0x21c], 0
cmp byte [edi], 0
je 0x410aff
test ebx, ebx
mov esi, dword [esp + 0x28]
je 0x4104d0
jmp 0x410aff
xor ebx, ebx
jmp 0x410aff
mov ebx, eax
test esi, esi
je 0x410aff
mov ecx, dword [esp + 0x10]
mov edx, str.in_prepare
push edi
push ebx
call fcn.00420870
add esp, 8
mov dword [esi], eax
mov eax, ebx
lea esp, [ebp - 0xc]
pop esi
pop edi
pop ebx
pop ebp
ret
push 2
call dword [sym.imp.api_ms_win_crt_stdio_l1_1_0.dll___acrt_iob_func]
add esp, 4
push eax
push 1
push 0x15
push str.Error:_out_of_memory_n
call sub.api_ms_win_crt_stdio_l1_1_0.dll_fwrite
add esp, 0x10
push 1
call sub.api_ms_win_crt_runtime_l1_1_0.dll_exit
nop dword [eax]
push ebp
push ebx
push edi
push esi
sub esp, 0x18
mov ebx, ecx
mov ecx, dword [ecx + 0x2e0]
xor edi, edi
test edx, edx
jne 0x41a7cd
mov esi, dword [ebx + 0x38]
mov ebp, dword [ebx + 0x2e4]
push dword [esp + 0x2c]
push ecx
mov dword [esp + 0xc], ecx
call fcn.00404a80
mov ecx, dword [esp + 0xc]
add esp, 8
mov edi, eax
test eax, eax
jne 0x41a7cd
mov eax, dword [ecx + 0x1c]
test eax, eax
je 0x41a650
mov eax, dword [eax]
inc eax
mov dword [esp], eax
jmp 0x41a657
mov dword [esp], 0
test ebp, ebp
mov dword [esp + 8], esi
je 0x41a698
cmp dword [ecx + 0x20], 0
je 0x41a66d
mov esi, dword [ecx + 0x102c]
jmp 0x41a66f
xor esi, esi
mov edi, dword [esp + 8]
push edi
push 1
push 0x2c
push str.___Candidates_______________________________n
call sub.api_ms_win_crt_stdio_l1_1_0.dll_fwrite
add esp, 0x10
push esi
push 0x51e066
push edi
call fcn.004062d0
add esp, 0xc
mov ecx, dword [esp + 4]
cmp dword [esp], 0
jle 0x41a7cb
mov dword [esp + 0x10], ebp
mov dword [esp + 0xc], ebx
xor esi, esi
mov edi, dword [esp + 8]
jmp 0x41a6eb
push ebx
push 0x51e066
push edi
call fcn.004062d0
add esp, 0xc
push ebp
push 0x51e066
push edi
call fcn.004062d0
add esp, 0xc
cmp esi, dword [esp]
mov ecx, dword [esp + 4]
je 0x41a7c3
cmp dword [ecx + 0x20], 0
mov ebx, 0
mov edx, 0
mov ebp, 0
je 0x41a780
mov eax, dword [ecx + 0x1c]
mov ebx, 0
mov edx, 0
mov ebp, 0
test eax, eax
je 0x41a780
mov ecx, eax
nop dword [eax]
cmp dword [ecx], esi
je 0x41a72f
mov ecx, dword [ecx + 0x10]
test ecx, ecx
jne 0x41a720
xor edx, edx
jmp 0x41a732
mov edx, dword [ecx + 4]
mov ecx, eax
nop word cs:[eax + eax]
cmp dword [ecx], esi
je 0x41a74f
mov ecx, dword [ecx + 0x10]
test ecx, ecx
jne 0x41a740
xor ebx, ebx
jmp 0x41a760
mov ebx, dword [ecx + 8]
nop word cs:[eax + eax]
cmp dword [eax], esi
je 0x41a76f
mov eax, dword [eax + 0x10]
test eax, eax
jne 0x41a760
xor ebp, ebp
jmp 0x41a780
mov ebp, dword [eax + 0xc]
nop word cs:[eax + eax]
test ebx, ebx
mov eax, str._no_new_indexes__n
cmove ebx, eax
inc esi
cmp dword [esp + 0x10], 0
je 0x41a6c0
push esi
push str.___Query__d__________________________________n
push edi
mov dword [esp + 0x20], ebp
mov ebp, edx
call fcn.004062d0
add esp, 0xc
push ebp
mov ebp, dword [esp + 0x18]
push str._s_n_n
push edi
call fcn.004062d0
add esp, 0xc
jmp 0x41a6c0
xor edi, edi
mov ebx, dword [esp + 0xc]
jmp 0x41a7cd
xor edi, edi
push ecx
call fcn.00404670
add esp, 4
mov dword [ebx + 0x2e0], 0
mov eax, edi
add esp, 0x18
pop esi
pop edi
pop ebx
pop ebp
ret