summaryrefslogtreecommitdiff
path: root/sbin/isakmpd/regress
diff options
context:
space:
mode:
authorTodd T. Fries <todd@cvs.openbsd.org>2002-06-09 08:13:10 +0000
committerTodd T. Fries <todd@cvs.openbsd.org>2002-06-09 08:13:10 +0000
commit3ed8b10a8df515c0cb5a2a6a0962c67f1c697164 (patch)
tree16644eb4e4232e2d2cd65fc342c5dbaafdc4e136 /sbin/isakmpd/regress
parentc021608bd50b74de1b8074e336f7adad03b1c7d8 (diff)
rm trailing whitespace
Diffstat (limited to 'sbin/isakmpd/regress')
-rw-r--r--sbin/isakmpd/regress/b2n/b2ntest.c10
-rw-r--r--sbin/isakmpd/regress/crypto/cryptotest.c8
-rw-r--r--sbin/isakmpd/regress/dh/dhtest.c4
-rw-r--r--sbin/isakmpd/regress/hmac/hmactest.c12
-rw-r--r--sbin/isakmpd/regress/prf/prftest.c16
-rw-r--r--sbin/isakmpd/regress/rsakeygen/Makefile6
-rw-r--r--sbin/isakmpd/regress/rsakeygen/rsakeygen.c4
-rw-r--r--sbin/isakmpd/regress/x509/x509test.c20
8 files changed, 40 insertions, 40 deletions
diff --git a/sbin/isakmpd/regress/b2n/b2ntest.c b/sbin/isakmpd/regress/b2n/b2ntest.c
index f8e985c81a8..92ed91297c3 100644
--- a/sbin/isakmpd/regress/b2n/b2ntest.c
+++ b/sbin/isakmpd/regress/b2n/b2ntest.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: b2ntest.c,v 1.6 2002/01/23 17:43:24 ho Exp $ */
+/* $OpenBSD: b2ntest.c,v 1.7 2002/06/09 08:13:07 todd Exp $ */
/* $EOM: b2ntest.c,v 1.4 1998/07/16 19:31:55 provos Exp $ */
/*
@@ -85,7 +85,7 @@ main (void)
b2n_set_ui (m, 0);
b2n_add (n, n, m);
CMP_FAIL (n, "0x9090900000000000000000");
-
+
printf ("\nTesting: b2n_lshift: ");
b2n_set_str (m, "0x808b8080c0");
b2n_lshift (n, m, 3);
@@ -158,13 +158,13 @@ main (void)
CMP_FAIL (n, "0x40005001040511");
b2n_set_str (m, "0x12329");
- printf ("\nTesting: sigbit: 0x12329: %d, %s",
+ printf ("\nTesting: sigbit: 0x12329: %d, %s",
b2n_sigbit(m), b2n_sigbit(m) == 17 ? "OKAY" : "FAILED");
b2n_set_ui (m, 0);
- printf ("\nTesting: sigbit: 0x0: %d, %s",
+ printf ("\nTesting: sigbit: 0x0: %d, %s",
b2n_sigbit(m), b2n_sigbit(m) == 0 ? "OKAY" : "FAILED");
b2n_set_str (m, "0x7f3290000");
- printf ("\nTesting: sigbit: 0x7f3290000: %d, %s",
+ printf ("\nTesting: sigbit: 0x7f3290000: %d, %s",
b2n_sigbit(m), b2n_sigbit(m) == 35 ? "OKAY" : "FAILED");
printf ("\nTesting: b2n_cmp: ");
diff --git a/sbin/isakmpd/regress/crypto/cryptotest.c b/sbin/isakmpd/regress/crypto/cryptotest.c
index 4b8045bed12..c5a26a89d91 100644
--- a/sbin/isakmpd/regress/crypto/cryptotest.c
+++ b/sbin/isakmpd/regress/crypto/cryptotest.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: cryptotest.c,v 1.6 2001/06/12 21:46:47 niklas Exp $ */
+/* $OpenBSD: cryptotest.c,v 1.7 2002/06/09 08:13:07 todd Exp $ */
/* $EOM: cryptotest.c,v 1.5 1998/10/07 16:40:49 niklas Exp $ */
/*
@@ -90,7 +90,7 @@ special_test_blf (void)
asc2bin (key, akey, strlen (akey));
asc2bin (iv, aiv, strlen (aiv));
asc2bin (cipher, acipher, 64);
-
+
xf = crypto_get (BLOWFISH_CBC);
printf ("Special Test-Case %s: ", xf->name);
@@ -129,7 +129,7 @@ main (void)
test_crypto (BLOWFISH_CBC);
test_crypto (CAST_CBC);
-
+
special_test_blf ();
return 1;
@@ -152,7 +152,7 @@ test_crypto (enum transform which)
struct crypto_xf *xf;
struct keystate *ks;
enum cryptoerr err;
-
+
xf = crypto_get (which);
printf ("Testing %s: ", xf->name);
diff --git a/sbin/isakmpd/regress/dh/dhtest.c b/sbin/isakmpd/regress/dh/dhtest.c
index 3add8c4ce9e..7e6099a618c 100644
--- a/sbin/isakmpd/regress/dh/dhtest.c
+++ b/sbin/isakmpd/regress/dh/dhtest.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: dhtest.c,v 1.3 1998/12/21 01:02:29 niklas Exp $ */
+/* $OpenBSD: dhtest.c,v 1.4 2002/06/09 08:13:07 todd Exp $ */
/* $EOM: dhtest.c,v 1.1 1998/07/18 21:14:20 provos Exp $ */
/*
@@ -100,7 +100,7 @@ main (void)
printf ("FAILED ");
else
printf ("OKAY ");
-
+
printf ("\n");
return 1;
diff --git a/sbin/isakmpd/regress/hmac/hmactest.c b/sbin/isakmpd/regress/hmac/hmactest.c
index 0d8ec23ab95..bc2fc0fa27d 100644
--- a/sbin/isakmpd/regress/hmac/hmactest.c
+++ b/sbin/isakmpd/regress/hmac/hmactest.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: hmactest.c,v 1.3 1998/12/21 01:02:34 niklas Exp $ */
+/* $OpenBSD: hmactest.c,v 1.4 2002/06/09 08:13:07 todd Exp $ */
/* $EOM: hmactest.c,v 1.3 1998/08/09 19:16:24 niklas Exp $ */
/*
@@ -49,7 +49,7 @@ int
main (void)
{
char key[100];
-
+
memset(key, 11, 20);
test_hmac ("HMAC-MD5 Test Case 1", hash_get (HASH_MD5),
key, 16, "Hi There", 8, "9294727a3638bb1c13f48ef8158bfc9d");
@@ -58,12 +58,12 @@ main (void)
"what do ya want for nothing?", 28,
"750c783e6ab0b503eaa86e310a5db738");
test_hmac ("HMAC-SHA1 Test Case 1", hash_get (HASH_SHA1),
- key, 20, "Hi There", 8,
+ key, 20, "Hi There", 8,
"b617318655057264e28bc0b6fb378c8ef146be00");
test_hmac ("HMAC-SHA1 Test Case 2", hash_get (HASH_SHA1),
- "Jefe", 4, "what do ya want for nothing?", 28,
+ "Jefe", 4, "what do ya want for nothing?", 28,
"effcdf6ae5eb2fa2d27416d5f184df9c259a7c79");
-
+
return 1;
}
@@ -87,7 +87,7 @@ test_hmac(char *test, struct hash *hash, char *key, int klen,
}
output[2*i] = 0;
- if (!strcmp(output, cmp))
+ if (!strcmp(output, cmp))
{
printf("OKAY\n");
return 1;
diff --git a/sbin/isakmpd/regress/prf/prftest.c b/sbin/isakmpd/regress/prf/prftest.c
index 0935e720018..0d95b790f50 100644
--- a/sbin/isakmpd/regress/prf/prftest.c
+++ b/sbin/isakmpd/regress/prf/prftest.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: prftest.c,v 1.5 2001/08/17 14:11:05 niklas Exp $ */
+/* $OpenBSD: prftest.c,v 1.6 2002/06/09 08:13:07 todd Exp $ */
/* $EOM: prftest.c,v 1.2 1998/10/07 16:40:50 niklas Exp $ */
/*
@@ -56,7 +56,7 @@ int
main (void)
{
char key[100];
-
+
memset (key, 11, 20);
test_prf ("PRF MD5 Test Case 1", HASH_MD5,
key, 16, "Hi There", 8, "9294727a3638bb1c13f48ef8158bfc9d");
@@ -65,17 +65,17 @@ main (void)
"what do ya want for nothing?", 28,
"750c783e6ab0b503eaa86e310a5db738");
test_prf ("PRF SHA1 Test Case 1", HASH_SHA1,
- key, 20, "Hi There", 8,
+ key, 20, "Hi There", 8,
"b617318655057264e28bc0b6fb378c8ef146be00");
test_prf ("PRF SHA1 Test Case 2", HASH_SHA1,
- "Jefe", 4, "what do ya want for nothing?", 28,
+ "Jefe", 4, "what do ya want for nothing?", 28,
"effcdf6ae5eb2fa2d27416d5f184df9c259a7c79");
test_prf ("PRF SHA1 Test Case 3", HASH_SHA1,
"Bloody long key, this one, eben longer than the blocksize "
"of ordinary keyed HMAC functions", 90,
- "what do ya want for nothing?", 28,
+ "what do ya want for nothing?", 28,
"52ca5fbcd7d4821bc6bf8b6e95e131109dff901b");
-
+
return 0;
}
@@ -91,7 +91,7 @@ test_prf (char *test, enum hashes hash, char *key, int klen,
printf ("Testing %s: ", test);
prf = prf_alloc (PRF_HMAC, hash, key, klen);
- if (!prf)
+ if (!prf)
{
printf("prf_alloc () failed\n");
return 0;
@@ -110,7 +110,7 @@ test_prf (char *test, enum hashes hash, char *key, int klen,
}
output[2 * i] = 0;
- if (strcmp (output, cmp) == 0)
+ if (strcmp (output, cmp) == 0)
{
printf ("OKAY\n");
return 1;
diff --git a/sbin/isakmpd/regress/rsakeygen/Makefile b/sbin/isakmpd/regress/rsakeygen/Makefile
index 552997f9db6..e05c6f2f62d 100644
--- a/sbin/isakmpd/regress/rsakeygen/Makefile
+++ b/sbin/isakmpd/regress/rsakeygen/Makefile
@@ -1,4 +1,4 @@
-# $OpenBSD: Makefile,v 1.12 2001/01/27 12:03:38 niklas Exp $
+# $OpenBSD: Makefile,v 1.13 2002/06/09 08:13:07 todd Exp $
# $EOM: Makefile,v 1.10 2000/03/28 21:23:24 ho Exp $
#
@@ -76,8 +76,8 @@ DPADD+= ${LIBCRYPTO}
PROG=
.else
-# USE_X509 is required for libcrypto.h to include the correct headers,
-# but it is not set by ${OS}/Makefile.sysdep - setting it manually here
+# USE_X509 is required for libcrypto.h to include the correct headers,
+# but it is not set by ${OS}/Makefile.sysdep - setting it manually here
# should be safe enough.
CFLAGS+= -DUSE_X509
.endif
diff --git a/sbin/isakmpd/regress/rsakeygen/rsakeygen.c b/sbin/isakmpd/regress/rsakeygen/rsakeygen.c
index ac3d96bf1a3..f9631e7eeff 100644
--- a/sbin/isakmpd/regress/rsakeygen/rsakeygen.c
+++ b/sbin/isakmpd/regress/rsakeygen/rsakeygen.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: rsakeygen.c,v 1.14 2002/01/03 16:27:41 ho Exp $ */
+/* $OpenBSD: rsakeygen.c,v 1.15 2002/06/09 08:13:07 todd Exp $ */
/* $EOM: rsakeygen.c,v 1.10 2000/12/21 15:18:53 ho Exp $ */
/*
@@ -84,7 +84,7 @@ main (void)
strlcpy (dec, TEST_STRING, 256);
key = LC (RSA_generate_key, (1024, RSA_F4, NULL, NULL));
- if (key == NULL)
+ if (key == NULL)
{
printf("Failed to generate key\n");
return 0;
diff --git a/sbin/isakmpd/regress/x509/x509test.c b/sbin/isakmpd/regress/x509/x509test.c
index 7948547a341..8f7d25f0014 100644
--- a/sbin/isakmpd/regress/x509/x509test.c
+++ b/sbin/isakmpd/regress/x509/x509test.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: x509test.c,v 1.18 2002/01/03 16:27:41 ho Exp $ */
+/* $OpenBSD: x509test.c,v 1.19 2002/06/09 08:13:07 todd Exp $ */
/* $EOM: x509test.c,v 1.9 2000/12/21 15:24:25 ho Exp $ */
/*
@@ -115,7 +115,7 @@ x509_check_subjectaltname (u_char *id, u_int id_len, X509 *scert)
return 0;
}
- /*
+ /*
* Now that we have the X509 certicate in native form, get the
* subjectAltName extension and verify that it matches our ID.
*/
@@ -129,15 +129,15 @@ x509_check_subjectaltname (u_char *id, u_int id_len, X509 *scert)
switch (idtype)
{
case IPSEC_ID_IPV4_ADDR:
- if (type == X509v3_IP_ADDR)
+ if (type == X509v3_IP_ADDR)
ret = 1;
break;
case IPSEC_ID_FQDN:
- if (type == X509v3_DNS_NAME)
+ if (type == X509v3_DNS_NAME)
ret = 1;
break;
case IPSEC_ID_USER_FQDN:
- if (type == X509v3_RFC_NAME)
+ if (type == X509v3_RFC_NAME)
ret = 1;
break;
default:
@@ -201,7 +201,7 @@ main (int argc, char *argv[])
printf ("Reading private key %s\n", argv[1]);
keyfile = LC (BIO_new, (LC (BIO_s_file, ())));
- if (LC (BIO_read_filename, (keyfile, argv[1])) == -1)
+ if (LC (BIO_read_filename, (keyfile, argv[1])) == -1)
{
perror ("read");
exit (1);
@@ -221,7 +221,7 @@ main (int argc, char *argv[])
/* Use a certificate created by ssleay. */
printf ("Reading ssleay created certificate %s\n", argv[2]);
certfile = LC (BIO_new, (LC (BIO_s_file, ())));
- if (LC (BIO_read_filename, (certfile, argv[2])) == -1)
+ if (LC (BIO_read_filename, (certfile, argv[2])) == -1)
{
perror ("read");
exit (1);
@@ -232,7 +232,7 @@ main (int argc, char *argv[])
cert = LC (PEM_read_bio_X509, (certfile, NULL, NULL));
#endif
LC (BIO_free, (certfile));
- if (cert == NULL)
+ if (cert == NULL)
{
printf("PEM_read_bio_X509 () failed\n");
exit (1);
@@ -252,7 +252,7 @@ main (int argc, char *argv[])
strlcpy (dec, "Eine kleine Testmeldung", 256);
if ((len = LC (RSA_private_encrypt, (strlen (dec), dec, enc, priv_key,
RSA_PKCS1_PADDING))) == -1)
-
+
printf ("SIGN FAILED ");
else
err = LC (RSA_public_decrypt, (len, enc, dec, pub_key, RSA_PKCS1_PADDING));
@@ -262,7 +262,7 @@ main (int argc, char *argv[])
else
printf ("OKAY");
printf ("\n");
-
+
printf ("Validate SIGNED: ");
err = LC (X509_verify, (cert, pkey_pub));