- priority: 5 --> 6
- assigned_to: nobody --> vab
CKS lacks of the feature to perform "word seach", for
example "searching for "John Smith" and return all the
keys with those words.
CSKS and other keyserver uses a auxiliary database
(words.db in cksd) that stores the word--> keyid
information.
The idea is that when a key is updated/inserted in the
database the keyid information is splited in word ,
the most common words are skipped (for example "at" , "I",
etc,. and the rest of words added in a table that maps
words to keyid
Later when searching the search is first done for the
keys results of the SQL intersec of the search more or
less:
with the following example table:
word | keyid
John key1
Smith key1
John key2
Lopez key2
Pepe key3
Lopez key3
if we want to retrieve the key for "John Lopez", the
sql statment could be:
select keyid from words where word='Lopez' intersect
select keyid from words where word='John' ;
that return key2.
To split the keyid in different "tokens" o words we can
use the C strtok function with "\n <>@.()" as
delimiters (or others)