--- embedaddon/strongswan/src/libstrongswan/plugins/wolfssl/wolfssl_common.h 2020/06/03 09:46:44 1.1.1.1 +++ embedaddon/strongswan/src/libstrongswan/plugins/wolfssl/wolfssl_common.h 2021/03/17 00:20:08 1.1.1.2 @@ -1,4 +1,7 @@ /* + * Copyright (C) 2020 Tobias Brunner + * HSR Hochschule fuer Technik Rapperswil + * * Copyright (C) 2019 Sean Parkinson, wolfSSL Inc. * * Permission is hereby granted, free of charge, to any person obtaining a copy @@ -59,6 +62,24 @@ #include #endif #include + +/* Special type used to handle EdDSA keys depending on config options */ +#if defined(HAVE_ED25519) || defined(HAVE_ED448) +#ifdef HAVE_ED25519 +#include +#endif +#ifdef HAVE_ED448 +#include +#endif +typedef union { +#ifdef HAVE_ED25519 + ed25519_key ed25519; +#endif +#ifdef HAVE_ED448 + ed448_key ed448; +#endif +} wolfssl_ed_key; +#endif /* HAVE_ED25519 || HAVE_ED448 */ #undef PARSE_ERROR