summaryrefslogtreecommitdiff
path: root/src/starter/keywords.c
diff options
context:
space:
mode:
authorRené Mayrhofer <rene@mayrhofer.eu.org>2011-03-05 09:20:09 +0100
committerRené Mayrhofer <rene@mayrhofer.eu.org>2011-03-05 09:20:09 +0100
commit568905f488e63e28778f87ac0e38d845f45bae79 (patch)
treed9969a147e36413583ff4bc75542d34c955f8823 /src/starter/keywords.c
parentf73fba54dc8b30c6482e1e8abf15bbf455592fcd (diff)
downloadvyos-strongswan-568905f488e63e28778f87ac0e38d845f45bae79.tar.gz
vyos-strongswan-568905f488e63e28778f87ac0e38d845f45bae79.zip
Imported Upstream version 4.5.1
Diffstat (limited to 'src/starter/keywords.c')
-rw-r--r--src/starter/keywords.c288
1 files changed, 146 insertions, 142 deletions
diff --git a/src/starter/keywords.c b/src/starter/keywords.c
index 0c24c7dcf..340b7131d 100644
--- a/src/starter/keywords.c
+++ b/src/starter/keywords.c
@@ -54,12 +54,12 @@ struct kw_entry {
kw_token_t token;
};
-#define TOTAL_KEYWORDS 127
+#define TOTAL_KEYWORDS 130
#define MIN_WORD_LENGTH 3
#define MAX_WORD_LENGTH 17
-#define MIN_HASH_VALUE 12
-#define MAX_HASH_VALUE 238
-/* maximum key range = 227, duplicates = 0 */
+#define MIN_HASH_VALUE 18
+#define MAX_HASH_VALUE 249
+/* maximum key range = 232, duplicates = 0 */
#ifdef __GNUC__
__inline
@@ -75,32 +75,32 @@ hash (str, len)
{
static const unsigned char asso_values[] =
{
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 2,
- 104, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 15, 239, 20, 14, 58,
- 51, 1, 7, 1, 81, 1, 239, 132, 47, 4,
- 1, 49, 10, 9, 23, 1, 20, 48, 4, 239,
- 239, 35, 1, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239, 239, 239, 239, 239,
- 239, 239, 239, 239, 239, 239
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 11,
+ 125, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 20, 250, 18, 6, 55,
+ 59, 3, 9, 3, 92, 3, 250, 147, 71, 12,
+ 29, 83, 38, 4, 13, 3, 8, 80, 3, 250,
+ 250, 12, 9, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250, 250, 250, 250, 250,
+ 250, 250, 250, 250, 250, 250
};
register int hval = len;
@@ -124,160 +124,164 @@ hash (str, len)
static const struct kw_entry wordlist[] =
{
{"pfs", KW_PFS},
- {"uniqueids", KW_UNIQUEIDS},
- {"rightgroups", KW_RIGHTGROUPS},
- {"lifetime", KW_KEYLIFE},
- {"rightsubnetwithin", KW_RIGHTSUBNETWITHIN},
- {"rightnatip", KW_RIGHTNATIP},
- {"esp", KW_ESP},
- {"rightnexthop", KW_RIGHTNEXTHOP},
- {"rightsourceip", KW_RIGHTSOURCEIP},
{"right", KW_RIGHT},
- {"leftupdown", KW_LEFTUPDOWN},
- {"leftnexthop", KW_LEFTNEXTHOP},
+ {"rightgroups", KW_RIGHTGROUPS},
{"left", KW_LEFT},
- {"keep_alive", KW_KEEP_ALIVE},
+ {"lifetime", KW_KEYLIFE},
{"rightsubnet", KW_RIGHTSUBNET},
{"rightikeport", KW_RIGHTIKEPORT},
{"rightsendcert", KW_RIGHTSENDCERT},
- {"leftcert", KW_LEFTCERT,},
- {"interfaces", KW_INTERFACES},
- {"lifepackets", KW_LIFEPACKETS},
- {"leftsendcert", KW_LEFTSENDCERT},
- {"leftgroups", KW_LEFTGROUPS},
- {"eap", KW_EAP},
- {"rightprotoport", KW_RIGHTPROTOPORT},
- {"leftnatip", KW_LEFTNATIP},
+ {"leftcert", KW_LEFTCERT},
{"keyingtries", KW_KEYINGTRIES},
- {"type", KW_TYPE},
{"keylife", KW_KEYLIFE},
- {"mark_in", KW_MARK_IN},
+ {"leftsendcert", KW_LEFTSENDCERT},
{"lifebytes", KW_LIFEBYTES},
- {"leftca", KW_LEFTCA},
- {"margintime", KW_REKEYMARGIN},
- {"marginbytes", KW_MARGINBYTES},
+ {"keep_alive", KW_KEEP_ALIVE},
+ {"leftgroups", KW_LEFTGROUPS},
{"leftrsasigkey", KW_LEFTRSASIGKEY},
- {"marginpackets", KW_MARGINPACKETS},
+ {"leftcertpolicy", KW_LEFTCERTPOLICY},
{"certuribase", KW_CERTURIBASE},
- {"virtual_private", KW_VIRTUAL_PRIVATE},
- {"rightid", KW_RIGHTID},
- {"rightupdown", KW_RIGHTUPDOWN},
- {"compress", KW_COMPRESS},
+ {"lifepackets", KW_LIFEPACKETS},
+ {"rightrsasigkey", KW_RIGHTRSASIGKEY},
{"leftprotoport", KW_LEFTPROTOPORT},
- {"overridemtu", KW_OVERRIDEMTU},
+ {"uniqueids", KW_UNIQUEIDS},
+ {"rightallowany", KW_RIGHTALLOWANY},
+ {"virtual_private", KW_VIRTUAL_PRIVATE},
+ {"leftca", KW_LEFTCA},
+ {"rightsubnetwithin", KW_RIGHTSUBNETWITHIN},
+ {"strictcrlpolicy", KW_STRICTCRLPOLICY},
+ {"type", KW_TYPE},
+ {"interfaces", KW_INTERFACES},
+ {"rightsourceip", KW_RIGHTSOURCEIP},
+ {"leftnexthop", KW_LEFTNEXTHOP},
+ {"rightprotoport", KW_RIGHTPROTOPORT},
+ {"mark_in", KW_MARK_IN},
{"reqid", KW_REQID},
{"inactivity", KW_INACTIVITY},
+ {"margintime", KW_REKEYMARGIN},
+ {"marginbytes", KW_MARGINBYTES},
+ {"rightid", KW_RIGHTID},
+ {"marginpackets", KW_MARGINPACKETS},
+ {"leftnatip", KW_LEFTNATIP},
+ {"rightcert", KW_RIGHTCERT},
+ {"ocspuri", KW_OCSPURI},
+ {"esp", KW_ESP},
+ {"rightnatip", KW_RIGHTNATIP},
+ {"keyexchange", KW_KEYEXCHANGE},
+ {"rightnexthop", KW_RIGHTNEXTHOP},
+ {"rightca", KW_RIGHTCA},
+ {"rightcertpolicy", KW_RIGHTCERTPOLICY},
+ {"leftupdown", KW_LEFTUPDOWN},
+ {"ocspuri1", KW_OCSPURI},
+ {"mediated_by", KW_MEDIATED_BY},
+ {"me_peerid", KW_ME_PEERID},
+ {"cacert", KW_CACERT},
+ {"crluri", KW_CRLURI},
+ {"eap", KW_EAP},
{"leftfirewall", KW_LEFTFIREWALL},
{"rightfirewall", KW_RIGHTFIREWALL},
- {"rightallowany", KW_RIGHTALLOWANY},
+ {"overridemtu", KW_OVERRIDEMTU},
{"mobike", KW_MOBIKE},
- {"lefthostaccess", KW_LEFTHOSTACCESS},
- {"leftsubnetwithin", KW_LEFTSUBNETWITHIN},
- {"rightrsasigkey", KW_RIGHTRSASIGKEY},
- {"pfsgroup", KW_PFSGROUP},
- {"me_peerid", KW_ME_PEERID},
- {"crluri", KW_CRLURI},
- {"leftsourceip", KW_LEFTSOURCEIP},
+ {"packetdefault", KW_PACKETDEFAULT},
{"crluri1", KW_CRLURI},
+ {"ldapbase", KW_LDAPBASE},
+ {"leftallowany", KW_LEFTALLOWANY},
{"mediation", KW_MEDIATION},
- {"dumpdir", KW_DUMPDIR},
- {"forceencaps", KW_FORCEENCAPS},
+ {"compress", KW_COMPRESS},
{"leftsubnet", KW_LEFTSUBNET},
- {"rightca", KW_RIGHTCA},
- {"rightcert", KW_RIGHTCERT},
- {"ocspuri", KW_OCSPURI},
- {"dpdaction", KW_DPDACTION},
- {"ocspuri1", KW_OCSPURI},
+ {"lefthostaccess", KW_LEFTHOSTACCESS},
+ {"forceencaps", KW_FORCEENCAPS},
+ {"dumpdir", KW_DUMPDIR},
+ {"righthostaccess", KW_RIGHTHOSTACCESS},
+ {"authby", KW_AUTHBY},
+ {"aaa_identity", KW_AAA_IDENTITY},
+ {"tfc", KW_TFC},
+ {"nat_traversal", KW_NAT_TRAVERSAL},
+ {"rightauth", KW_RIGHTAUTH},
+ {"rightupdown", KW_RIGHTUPDOWN},
{"dpdtimeout", KW_DPDTIMEOUT},
{"installpolicy", KW_INSTALLPOLICY},
- {"righthostaccess", KW_RIGHTHOSTACCESS},
- {"ldapbase", KW_LDAPBASE},
- {"also", KW_ALSO},
- {"leftallowany", KW_LEFTALLOWANY},
+ {"mark_out", KW_MARK_OUT},
+ {"fragicmp", KW_FRAGICMP},
{"force_keepalive", KW_FORCE_KEEPALIVE},
- {"keyexchange", KW_KEYEXCHANGE},
- {"hidetos", KW_HIDETOS},
- {"klipsdebug", KW_KLIPSDEBUG},
- {"plutostderrlog", KW_PLUTOSTDERRLOG},
- {"rightauth", KW_RIGHTAUTH},
- {"strictcrlpolicy", KW_STRICTCRLPOLICY},
- {"charondebug", KW_CHARONDEBUG},
- {"rightid2", KW_RIGHTID2},
{"leftid", KW_LEFTID},
- {"mediated_by", KW_MEDIATED_BY},
- {"fragicmp", KW_FRAGICMP},
- {"mark_out", KW_MARK_OUT},
- {"auto", KW_AUTO},
- {"leftcert2", KW_LEFTCERT2,},
- {"nat_traversal", KW_NAT_TRAVERSAL},
- {"cacert", KW_CACERT},
- {"plutostart", KW_PLUTOSTART},
+ {"leftsubnetwithin", KW_LEFTSUBNETWITHIN},
{"eap_identity", KW_EAP_IDENTITY},
- {"prepluto", KW_PREPLUTO},
- {"packetdefault", KW_PACKETDEFAULT},
+ {"cachecrls", KW_CACHECRLS},
+ {"pfsgroup", KW_PFSGROUP},
+ {"rightid2", KW_RIGHTID2},
+ {"dpdaction", KW_DPDACTION},
{"xauth_identity", KW_XAUTH_IDENTITY},
+ {"leftsourceip", KW_LEFTSOURCEIP},
+ {"klipsdebug", KW_KLIPSDEBUG},
+ {"leftcert2", KW_LEFTCERT2},
+ {"charondebug", KW_CHARONDEBUG},
+ {"hidetos", KW_HIDETOS},
+ {"ike", KW_IKE},
{"charonstart", KW_CHARONSTART},
- {"crlcheckinterval", KW_CRLCHECKINTERVAL},
{"rightauth2", KW_RIGHTAUTH2},
- {"ike", KW_IKE},
- {"aaa_identity", KW_AAA_IDENTITY},
+ {"also", KW_ALSO},
{"leftca2", KW_LEFTCA2},
- {"authby", KW_AUTHBY},
- {"leftauth", KW_LEFTAUTH},
- {"cachecrls", KW_CACHECRLS},
+ {"rekey", KW_REKEY},
+ {"plutostderrlog", KW_PLUTOSTDERRLOG},
+ {"plutostart", KW_PLUTOSTART},
+ {"ikelifetime", KW_IKELIFETIME},
+ {"crlcheckinterval", KW_CRLCHECKINTERVAL},
+ {"auto", KW_AUTO},
{"ldaphost", KW_LDAPHOST},
- {"rekeymargin", KW_REKEYMARGIN},
{"rekeyfuzz", KW_REKEYFUZZ},
- {"dpddelay", KW_DPDDELAY},
- {"ikelifetime", KW_IKELIFETIME},
- {"auth", KW_AUTH},
- {"xauth", KW_XAUTH},
- {"postpluto", KW_POSTPLUTO},
- {"plutodebug", KW_PLUTODEBUG},
- {"modeconfig", KW_MODECONFIG},
- {"nocrsend", KW_NOCRSEND},
- {"leftauth2", KW_LEFTAUTH2},
- {"leftid2", KW_LEFTID2},
{"leftikeport", KW_LEFTIKEPORT},
+ {"mark", KW_MARK},
+ {"auth", KW_AUTH},
+ {"prepluto", KW_PREPLUTO},
+ {"dpddelay", KW_DPDDELAY},
+ {"leftauth", KW_LEFTAUTH},
{"rightca2", KW_RIGHTCA2},
- {"rekey", KW_REKEY},
+ {"xauth", KW_XAUTH},
{"rightcert2", KW_RIGHTCERT2},
- {"mark", KW_MARK},
- {"crluri2", KW_CRLURI2},
- {"reauth", KW_REAUTH},
+ {"rekeymargin", KW_REKEYMARGIN},
+ {"leftid2", KW_LEFTID2},
{"ocspuri2", KW_OCSPURI2},
+ {"nocrsend", KW_NOCRSEND},
+ {"reauth", KW_REAUTH},
+ {"crluri2", KW_CRLURI2},
+ {"plutodebug", KW_PLUTODEBUG},
+ {"leftauth2", KW_LEFTAUTH2},
{"pkcs11module", KW_PKCS11MODULE},
{"pkcs11initargs", KW_PKCS11INITARGS},
{"pkcs11keepstate", KW_PKCS11KEEPSTATE},
- {"pkcs11proxy", KW_PKCS11PROXY}
+ {"pkcs11proxy", KW_PKCS11PROXY},
+ {"modeconfig", KW_MODECONFIG},
+ {"postpluto", KW_POSTPLUTO}
};
static const short lookup[] =
{
-1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, 0, 1, -1, 2, -1, -1, 3, -1,
- -1, 4, -1, 5, 6, 7, 8, 9, -1, 10,
- 11, -1, 12, 13, 14, 15, 16, 17, -1, 18,
- 19, 20, 21, 22, -1, -1, 23, 24, -1, 25,
- 26, 27, 28, 29, 30, 31, 32, 33, 34, 35,
- 36, 37, 38, 39, 40, 41, 42, 43, 44, 45,
- 46, 47, 48, 49, 50, 51, -1, 52, 53, 54,
- 55, -1, 56, 57, -1, 58, 59, 60, -1, 61,
- 62, 63, 64, -1, -1, 65, -1, 66, -1, 67,
- 68, 69, 70, 71, -1, -1, 72, -1, -1, 73,
- 74, 75, 76, 77, 78, 79, 80, -1, 81, 82,
- 83, 84, 85, 86, 87, -1, 88, -1, 89, 90,
- -1, 91, 92, 93, 94, -1, 95, 96, 97, 98,
- -1, -1, -1, -1, 99, 100, 101, -1, 102, 103,
- 104, 105, 106, 107, 108, 109, -1, 110, -1, -1,
- 111, -1, -1, -1, -1, -1, -1, 112, -1, 113,
- 114, 115, 116, 117, 118, -1, -1, -1, -1, 119,
- -1, -1, 120, -1, -1, -1, -1, -1, -1, 121,
- -1, -1, -1, -1, 122, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, 123, -1, 124, 125, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, -1, -1,
- -1, -1, -1, -1, -1, -1, -1, -1, 126
+ -1, -1, -1, -1, -1, -1, -1, -1, 0, 1,
+ -1, -1, -1, 2, 3, -1, 4, -1, 5, 6,
+ 7, 8, 9, -1, 10, 11, 12, 13, 14, -1,
+ 15, 16, -1, 17, 18, 19, 20, 21, -1, 22,
+ -1, -1, 23, -1, 24, 25, 26, 27, -1, 28,
+ 29, -1, -1, -1, 30, -1, 31, -1, -1, -1,
+ 32, 33, 34, 35, 36, 37, 38, 39, 40, -1,
+ -1, 41, 42, 43, 44, 45, 46, -1, 47, 48,
+ 49, -1, -1, 50, 51, 52, 53, 54, 55, 56,
+ 57, 58, 59, -1, -1, 60, 61, 62, 63, 64,
+ 65, -1, 66, 67, -1, 68, 69, -1, 70, 71,
+ -1, -1, 72, 73, -1, 74, 75, 76, 77, -1,
+ 78, -1, 79, -1, 80, -1, 81, 82, -1, 83,
+ 84, 85, 86, 87, 88, 89, 90, -1, -1, 91,
+ -1, -1, -1, 92, -1, 93, 94, -1, 95, 96,
+ -1, 97, 98, -1, -1, -1, -1, 99, -1, -1,
+ -1, 100, 101, 102, 103, 104, 105, 106, 107, -1,
+ -1, -1, 108, -1, 109, -1, -1, 110, 111, -1,
+ -1, -1, 112, -1, 113, 114, 115, -1, -1, -1,
+ -1, -1, 116, 117, 118, -1, -1, -1, 119, -1,
+ -1, 120, -1, -1, -1, -1, -1, -1, -1, 121,
+ -1, -1, -1, 122, -1, -1, 123, -1, 124, -1,
+ 125, 126, -1, -1, -1, -1, 127, -1, 128, -1,
+ -1, -1, -1, -1, -1, -1, -1, -1, -1, 129
};
#ifdef __GNUC__