diff --git a/client/fwknop.c b/client/fwknop.c index bb5b95e6..b1e96ca5 100644 --- a/client/fwknop.c +++ b/client/fwknop.c @@ -447,7 +447,7 @@ main(int argc, char **argv) */ if(options.digest_type) { - fko_set_spa_digest_type(ctx, options.digest_type); + res = fko_set_spa_digest_type(ctx, options.digest_type); if(res != FKO_SUCCESS) { errmsg("fko_set_spa_digest_type", res); diff --git a/lib/cipher_funcs.c b/lib/cipher_funcs.c index abfb5737..2d3c1f51 100644 --- a/lib/cipher_funcs.c +++ b/lib/cipher_funcs.c @@ -213,14 +213,12 @@ rijndael_init(RIJNDAEL_context *ctx, const char *key, if(encryption_mode == FKO_ENC_MODE_CBC || encryption_mode == FKO_ENC_MODE_CBC_LEGACY_IV) ctx->mode = MODE_CBC; - else if(encryption_mode == FKO_ENC_MODE_CFB) - ctx->mode = MODE_CFB; + else if(encryption_mode == FKO_ENC_MODE_CTR) + ctx->mode = MODE_CTR; else if(encryption_mode == FKO_ENC_MODE_PCBC) ctx->mode = MODE_PCBC; else if(encryption_mode == FKO_ENC_MODE_OFB) ctx->mode = MODE_OFB; - else if(encryption_mode == FKO_ENC_MODE_CTR) - ctx->mode = MODE_CTR; else if(encryption_mode == FKO_ENC_MODE_CFB) ctx->mode = MODE_CFB; else if(encryption_mode == FKO_ENC_MODE_ECB) diff --git a/server/extcmd.c b/server/extcmd.c index fd9e4f66..0cb49b4f 100644 --- a/server/extcmd.c +++ b/server/extcmd.c @@ -149,9 +149,6 @@ _run_extcmd(uid_t user_uid, const char *cmd, char *so_buf, const size_t so_buf_s while((fgets(so_read_buf, IO_READ_BUF_LEN, ipt)) != NULL) { - if(so_buf == NULL) - continue; - strlcat(so_buf, so_read_buf, so_buf_sz); if(strlen(so_buf) >= so_buf_sz-1)