diff options
author | Niklas Hallqvist <niklas@cvs.openbsd.org> | 1999-03-24 14:58:16 +0000 |
---|---|---|
committer | Niklas Hallqvist <niklas@cvs.openbsd.org> | 1999-03-24 14:58:16 +0000 |
commit | ec17c1d121441124f75ff650b9c96ffedf55f55e (patch) | |
tree | 4a2067a995625a5c3f27814d34d3250634fb602e /sbin | |
parent | ae64c7f997475ad14407c3985eed330400b338d5 (diff) |
Merge with EOM 1.6
RSA fixes and optimiations from Ilya Tsindlekht, via Niels Provos
Diffstat (limited to 'sbin')
-rw-r--r-- | sbin/isakmpd/regress/pkcs/pkcstest.c | 8 | ||||
-rw-r--r-- | sbin/isakmpd/regress/rsakeygen/rsakeygen.c | 8 |
2 files changed, 8 insertions, 8 deletions
diff --git a/sbin/isakmpd/regress/pkcs/pkcstest.c b/sbin/isakmpd/regress/pkcs/pkcstest.c index 2b0dd46a731..260ebcb0844 100644 --- a/sbin/isakmpd/regress/pkcs/pkcstest.c +++ b/sbin/isakmpd/regress/pkcs/pkcstest.c @@ -1,5 +1,5 @@ -/* $OpenBSD: pkcstest.c,v 1.5 1999/03/02 15:27:36 niklas Exp $ */ -/* $EOM: pkcstest.c,v 1.5 1998/08/20 14:09:04 provos Exp $ */ +/* $OpenBSD: pkcstest.c,v 1.6 1999/03/24 14:57:54 niklas Exp $ */ +/* $EOM: pkcstest.c,v 1.6 1999/03/13 17:43:22 niklas Exp $ */ /* * Copyright (c) 1998 Niels Provos. All rights reserved. @@ -104,12 +104,12 @@ main (void) printf ("Testing Signing/Verifying: "); /* Sign with Private Key */ - if (!pkcs_rsa_encrypt (PKCS_PRIVATE, priv.n, priv.d, data, strlen(data)+1, + if (!pkcs_rsa_encrypt (PKCS_PRIVATE, NULL, &priv, data, strlen(data)+1, &enc, &enclen)) printf ("FAILED "); else /* Decrypt/Verify with Public Key */ - erg = pkcs_rsa_decrypt (PKCS_PRIVATE, key.n, key.e, enc, &dec, &len); + erg = pkcs_rsa_decrypt (PKCS_PRIVATE, &key, NULL, enc, &dec, &len); if (!erg || strcmp(data,dec)) printf ("FAILED "); diff --git a/sbin/isakmpd/regress/rsakeygen/rsakeygen.c b/sbin/isakmpd/regress/rsakeygen/rsakeygen.c index 9754128f960..4e4bafd3e08 100644 --- a/sbin/isakmpd/regress/rsakeygen/rsakeygen.c +++ b/sbin/isakmpd/regress/rsakeygen/rsakeygen.c @@ -1,5 +1,5 @@ -/* $OpenBSD: rsakeygen.c,v 1.5 1999/03/02 15:27:36 niklas Exp $ */ -/* $EOM: rsakeygen.c,v 1.5 1998/10/07 16:40:51 niklas Exp $ */ +/* $OpenBSD: rsakeygen.c,v 1.6 1999/03/24 14:58:15 niklas Exp $ */ +/* $EOM: rsakeygen.c,v 1.6 1999/03/13 17:43:24 niklas Exp $ */ /* * Copyright (c) 1998 Niels Provos. All rights reserved. @@ -89,12 +89,12 @@ main (void) printf ("Testing Signing/Verifying: "); /* Sign with Private Key */ - if (!pkcs_rsa_encrypt (PKCS_PRIVATE, priv.n, priv.d, data, strlen(data)+1, + if (!pkcs_rsa_encrypt (PKCS_PRIVATE, NULL, &priv, data, strlen(data)+1, &enc, &enclen)) printf ("FAILED "); else /* Decrypt/Verify with Public Key */ - erg = pkcs_rsa_decrypt (PKCS_PRIVATE, key.n, key.e, enc, &dec, &len); + erg = pkcs_rsa_decrypt (PKCS_PRIVATE, &key, NULL, enc, &dec, &len); if (!erg || strcmp(data,dec)) printf ("FAILED "); |