projects
/
u
/
mdw
/
catacomb
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Slight reorganization. Add elliptic curves from X9.62.
[u/mdw/catacomb]
/
cc-kem.c
diff --git
a/cc-kem.c
b/cc-kem.c
index
4f71d0d
..
8ba29fd
100644
(file)
--- a/
cc-kem.c
+++ b/
cc-kem.c
@@
-1,6
+1,6
@@
/* -*-c-*-
*
/* -*-c-*-
*
- * $Id
: cc-kem.c,v 1.1 2004/04/17 09:58:37 mdw Exp
$
+ * $Id$
*
* Catcrypt key-encapsulation
*
*
* Catcrypt key-encapsulation
*
@@
-324,11
+324,7
@@
static const kemops ec_decops = {
/* --- The switch table --- */
/* --- The switch table --- */
-static const struct kemtab {
- const char *name;
- const kemops *encops;
- const kemops *decops;
-} kemtab[] = {
+const struct kemtab kemtab[] = {
{ "rsa", &rsa_encops, &rsa_decops },
{ "dh", &dh_encops, &dh_decops },
{ "ec", &ec_encops, &ec_decops },
{ "rsa", &rsa_encops, &rsa_decops },
{ "dh", &dh_encops, &dh_decops },
{ "ec", &ec_encops, &ec_decops },
@@
-483,7
+479,7
@@
int setupkem(kem *k, dstr *d, gcipher **cx, gcipher **c, gmac **m)
octet *kd;
size_t n, cn, mn;
ghash *h;
octet *kd;
size_t n, cn, mn;
ghash *h;
- int rc =
0
;
+ int rc =
-1
;
h = GH_INIT(k->h);
if (k->ops->doit(k, d, h))
h = GH_INIT(k->h);
if (k->ops->doit(k, d, h))