summaryrefslogtreecommitdiff
path: root/src/libstrongswan/crypto/proposal/proposal_keywords.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/libstrongswan/crypto/proposal/proposal_keywords.h')
-rw-r--r--src/libstrongswan/crypto/proposal/proposal_keywords.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/libstrongswan/crypto/proposal/proposal_keywords.h b/src/libstrongswan/crypto/proposal/proposal_keywords.h
index d6107abc0..5cdbafc51 100644
--- a/src/libstrongswan/crypto/proposal/proposal_keywords.h
+++ b/src/libstrongswan/crypto/proposal/proposal_keywords.h
@@ -46,6 +46,8 @@
typedef struct proposal_token_t proposal_token_t;
typedef struct proposal_keywords_t proposal_keywords_t;
+typedef proposal_token_t*(*proposal_algname_parser_t)(const char *algname);
+
#include <library.h>
#include <crypto/transform.h>
@@ -102,6 +104,17 @@ struct proposal_keywords_t {
u_int16_t keysize);
/**
+ * Register an algorithm name parser.
+ *
+ * It is meant to parse an algorithm name into a proposal token in a
+ * generic, user defined way.
+ *
+ * @param parser a pointer to the parser function
+ */
+ void (*register_algname_parser)(proposal_keywords_t *this,
+ proposal_algname_parser_t parser);
+
+ /**
* Destroy a proposal_keywords_t instance.
*/
void (*destroy)(proposal_keywords_t *this);