diff options
Diffstat (limited to 'src/stroke/stroke_keywords.c')
-rw-r--r-- | src/stroke/stroke_keywords.c | 101 |
1 files changed, 51 insertions, 50 deletions
diff --git a/src/stroke/stroke_keywords.c b/src/stroke/stroke_keywords.c index b5ca2e143..3f53b7fa8 100644 --- a/src/stroke/stroke_keywords.c +++ b/src/stroke/stroke_keywords.c @@ -54,12 +54,12 @@ struct stroke_token { stroke_keyword_t kw; }; -#define TOTAL_KEYWORDS 41 +#define TOTAL_KEYWORDS 42 #define MIN_WORD_LENGTH 2 #define MAX_WORD_LENGTH 15 -#define MIN_HASH_VALUE 2 -#define MAX_HASH_VALUE 44 -/* maximum key range = 43, duplicates = 0 */ +#define MIN_HASH_VALUE 4 +#define MAX_HASH_VALUE 49 +/* maximum key range = 46, duplicates = 0 */ #ifdef __GNUC__ __inline @@ -75,32 +75,32 @@ hash (str, len) { static const unsigned char asso_values[] = { - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 15, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 0, 30, 1, - 1, 15, 45, 15, 45, 30, 45, 13, 0, 0, - 45, 9, 3, 45, 6, 18, 1, 0, 45, 45, - 5, 0, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45, 45, 45, 45, 45, - 45, 45, 45, 45, 45, 45 + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 19, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 1, 12, 2, + 2, 16, 50, 14, 50, 11, 50, 16, 1, 8, + 50, 18, 7, 50, 6, 12, 1, 11, 50, 50, + 4, 3, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50, 50, 50, 50, 50, + 50, 50, 50, 50, 50, 50 }; register int hval = len; @@ -125,17 +125,16 @@ hash (str, len) static const struct stroke_token wordlist[] = { - {"up", STROKE_UP}, {"add", STROKE_ADD}, {"del", STROKE_DEL}, {"down", STROKE_DOWN}, - {"listall", STROKE_LIST_ALL}, {"delete", STROKE_DELETE}, + {"listall", STROKE_LIST_ALL}, {"listcrls", STROKE_LIST_CRLS}, + {"up", STROKE_UP}, {"rekey", STROKE_REKEY}, {"listaacerts", STROKE_LIST_AACERTS}, {"listcacerts", STROKE_LIST_CACERTS}, - {"listplugins", STROKE_LIST_PLUGINS}, {"rereadall", STROKE_REREAD_ALL}, {"listcerts", STROKE_LIST_CERTS}, {"rereadcrls", STROKE_REREAD_CRLS}, @@ -143,37 +142,39 @@ static const struct stroke_token wordlist[] = {"rereadaacerts", STROKE_REREAD_AACERTS}, {"rereadcacerts", STROKE_REREAD_CACERTS}, {"leases", STROKE_LEASES}, - {"unroute", STROKE_UNROUTE}, {"listalgs", STROKE_LIST_ALGS}, - {"status", STROKE_STATUS}, - {"listacerts", STROKE_LIST_ACERTS}, + {"listcainfos", STROKE_LIST_CAINFOS}, + {"listcounters", STROKE_LIST_COUNTERS}, {"route", STROKE_ROUTE}, + {"listacerts", STROKE_LIST_ACERTS}, + {"status", STROKE_STATUS}, + {"listplugins", STROKE_LIST_PLUGINS}, + {"listpubkeys", STROKE_LIST_PUBKEYS}, + {"rereadsecrets", STROKE_REREAD_SECRETS}, {"statusall", STROKE_STATUSALL}, {"purgeocsp", STROKE_PURGE_OCSP}, {"statusallnb", STROKE_STATUSALL_NOBLK}, - {"rereadocspcerts", STROKE_REREAD_OCSPCERTS}, - {"user-creds", STROKE_USER_CREDS}, + {"exportx509", STROKE_EXPORT_X509}, {"down-srcip", STROKE_DOWN_SRCIP}, {"purgecrls", STROKE_PURGE_CRLS}, - {"listgroups", STROKE_LIST_GROUPS}, {"listocsp", STROKE_LIST_OCSP}, - {"exportx509", STROKE_EXPORT_X509}, - {"rereadsecrets", STROKE_REREAD_SECRETS}, + {"rereadocspcerts", STROKE_REREAD_OCSPCERTS}, {"loglevel", STROKE_LOGLEVEL}, - {"purgeike", STROKE_PURGE_IKE}, - {"listocspcerts", STROKE_LIST_OCSPCERTS}, {"memusage", STROKE_MEMUSAGE}, - {"listcainfos", STROKE_LIST_CAINFOS}, - {"purgecerts", STROKE_PURGE_CERTS}, - {"listpubkeys", STROKE_LIST_PUBKEYS} + {"listgroups", STROKE_LIST_GROUPS}, + {"listocspcerts", STROKE_LIST_OCSPCERTS}, + {"unroute", STROKE_UNROUTE}, + {"user-creds", STROKE_USER_CREDS}, + {"purgeike", STROKE_PURGE_IKE}, + {"purgecerts", STROKE_PURGE_CERTS} }; static const short lookup[] = { - -1, -1, 0, 1, 2, 3, -1, 4, 5, 6, -1, 7, 8, 9, - 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, - 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, - 38, 39, 40 + -1, -1, -1, -1, 0, 1, 2, -1, -1, 3, 4, -1, 5, 6, + 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, + 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, + 35, 36, 37, 38, 39, 40, -1, 41 }; #ifdef __GNUC__ |