diff options
Diffstat (limited to 'src/libstrongswan/plugins')
-rw-r--r-- | src/libstrongswan/plugins/pubkey/pubkey_public_key.c | 2 | ||||
-rw-r--r-- | src/libstrongswan/plugins/twofish/twofish.c | 6 | ||||
-rw-r--r-- | src/libstrongswan/plugins/twofish/twofish.h | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/src/libstrongswan/plugins/pubkey/pubkey_public_key.c b/src/libstrongswan/plugins/pubkey/pubkey_public_key.c index 2210f08ce..6d3ae66ab 100644 --- a/src/libstrongswan/plugins/pubkey/pubkey_public_key.c +++ b/src/libstrongswan/plugins/pubkey/pubkey_public_key.c @@ -145,7 +145,7 @@ static void add(private_builder_t *this, builder_part_t part, ...) va_start(args, part); pem = va_arg(args, char *); blob = chunk_clone(chunk_create(pem, strlen(pem))); - if (pem_to_bin(&blob, &chunk_empty, &pgp)) + if (pem_to_bin(&blob, chunk_empty, &pgp) == SUCCESS) { this->key = pubkey_public_key_load(chunk_clone(blob)); } diff --git a/src/libstrongswan/plugins/twofish/twofish.c b/src/libstrongswan/plugins/twofish/twofish.c index 0e01a92d2..44ffca69c 100644 --- a/src/libstrongswan/plugins/twofish/twofish.c +++ b/src/libstrongswan/plugins/twofish/twofish.c @@ -575,7 +575,7 @@ static const u8 calc_sb_tbl[512] = { /* Perform the key setup. */ -int twofish_set_key (TWOFISH_context *ctx, +int twofish_set_key (twofish_context *ctx, const unsigned char *key, int key_len) { @@ -788,7 +788,7 @@ int twofish_set_key (TWOFISH_context *ctx, /* Encrypt one block. in and out may be the same. */ -int twofish_encrypt (TWOFISH_context *ctx, +int twofish_encrypt (twofish_context *ctx, const u8 *in, u8 *out) { /* The four 32-bit chunks of the text. */ @@ -824,7 +824,7 @@ int twofish_encrypt (TWOFISH_context *ctx, /* Decrypt one block. in and out may be the same. */ -int twofish_decrypt (TWOFISH_context *ctx, +int twofish_decrypt (twofish_context *ctx, const u8 *in, u8 *out) { /* The four 32-bit chunks of the text. */ diff --git a/src/libstrongswan/plugins/twofish/twofish.h b/src/libstrongswan/plugins/twofish/twofish.h index 4a1f7625c..6d399766b 100644 --- a/src/libstrongswan/plugins/twofish/twofish.h +++ b/src/libstrongswan/plugins/twofish/twofish.h @@ -11,7 +11,7 @@ * subkeys, K[0] through K[7]. k holds the remaining, "round" subkeys. Note * that k[i] corresponds to what the Twofish paper calls K[i+8]. */ -typedef struct twofish_context { +struct twofish_context { u_int32_t s[4][256], w[8], k[32]; }; |