-
Type: Improvement
-
Resolution: Fixed
-
Priority: Minor - P4
-
Affects Version/s: 4.1.9
-
Component/s: None
-
Labels:None
-
Fully Compatible
-
Execution Team 2020-06-01, Execution Team 2020-06-15
There are two issues with how we parse and validate index specs:
1. Each type of index (b-tree, text, etc.) is responsible for parsing its own options here, but we create the SortedDataInterface immediately beforehand. This stores the user-provided index spec in the catalog, and at some points does string parsing on that metadata. If the strings passed to the SDI are invalid, this can lead to undefined behavior or even crashes.
2. It's possible to pass unrecognized options to an index type (ex: pass 'bucketSize' to a text index), and that may still get persisted in the storage engine. This may also introduce a crash or undefined behavior.