aboutsummaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/libstrongswan/crypto/ietf_attr_list.c1
-rw-r--r--src/libstrongswan/utils/optionsfrom.c1
-rwxr-xr-xsrc/openac/openac.c10
3 files changed, 5 insertions, 7 deletions
diff --git a/src/libstrongswan/crypto/ietf_attr_list.c b/src/libstrongswan/crypto/ietf_attr_list.c
index b894edc4f..1ecadf679 100644
--- a/src/libstrongswan/crypto/ietf_attr_list.c
+++ b/src/libstrongswan/crypto/ietf_attr_list.c
@@ -354,7 +354,6 @@ chunk_t ietfAttr_list_encode(linked_list_t *list)
u_char *pos;
iterator_t *iterator = list->create_iterator(list, TRUE);
ietfAttr_t *attr;
- bool first = TRUE;
/* precalculate the total size of all values */
while (iterator->iterate(iterator, (void **)&attr))
diff --git a/src/libstrongswan/utils/optionsfrom.c b/src/libstrongswan/utils/optionsfrom.c
index 093451f88..fcbbcfeb6 100644
--- a/src/libstrongswan/utils/optionsfrom.c
+++ b/src/libstrongswan/utils/optionsfrom.c
@@ -23,6 +23,7 @@
#include <stdio.h>
#include <library.h>
+#include <utils/lexparser.h>
#include "optionsfrom.h"
diff --git a/src/openac/openac.c b/src/openac/openac.c
index 3dbbd2a65..3c6fb5ae1 100755
--- a/src/openac/openac.c
+++ b/src/openac/openac.c
@@ -29,6 +29,7 @@
#include <asn1/asn1.h>
#include <asn1/ttodata.h>
#include <crypto/ac.h>
+#include <crypto/ietf_attr_list.h>
#include <utils/optionsfrom.h>
#include "build.h"
@@ -128,8 +129,7 @@ static chunk_t read_serial(void)
}
else
{
- DBG1(" file '%s' does not exist yet - serial number set to 01",
- OPENAC_SERIAL);
+ DBG1(" file '%s' does not exist yet - serial number set to 01", OPENAC_SERIAL);
}
/**
@@ -137,10 +137,12 @@ static chunk_t read_serial(void)
* and incrementing it by one
* and representing it as a two's complement octet string
*/
+ printf("last_serial: '%#B'\n", &last_serial);
mpz_init(number);
chunk_to_mpz(last_serial, number);
mpz_add_ui(number, number, 0x01);
serial = mpz_to_chunk(number);
+ printf("serial: '%#B'\n", &serial);
mpz_clear(number);
return serial;
@@ -151,8 +153,6 @@ static chunk_t read_serial(void)
*/
static void write_serial(chunk_t serial)
{
- char buf[BUF_LEN];
-
FILE *fd = fopen(OPENAC_SERIAL, "w");
if (fd)
@@ -384,8 +384,6 @@ int main(int argc, char **argv)
/* load the signer's RSA private key */
if (keyfile != NULL)
{
- err_t ugh = NULL;
-
signerkey = rsa_private_key_create_from_file(keyfile, &passphrase);
if (signerkey == NULL)