/* -*-c-*-
*
- * $Id: ec-keys.h,v 1.1 2004/03/28 01:58:47 mdw Exp $
+ * $Id: ec-keys.h,v 1.3 2004/04/08 01:36:15 mdw Exp $
*
* Elliptic curve key-fetching
*
* (c) 2004 Straylight/Edgeware
*/
-/*----- Licensing notice --------------------------------------------------*
+/*----- Licensing notice --------------------------------------------------*
*
* This file is part of Catacomb.
*
* it under the terms of the GNU Library General Public License as
* published by the Free Software Foundation; either version 2 of the
* License, or (at your option) any later version.
- *
+ *
* Catacomb is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU Library General Public License for more details.
- *
+ *
* You should have received a copy of the GNU Library General Public
* License along with Catacomb; if not, write to the Free
* Software Foundation, Inc., 59 Temple Place - Suite 330, Boston,
* MA 02111-1307, USA.
*/
-/*----- Revision history --------------------------------------------------*
- *
- * $Log: ec-keys.h,v $
- * Revision 1.1 2004/03/28 01:58:47 mdw
- * Generate, store and retreive elliptic curve keys.
- *
- */
-
#ifndef CATACOMB_EC_KEYS_H
#define CATACOMB_EC_KEYS_H
mp *x; /* Secret exponent */
} ec_priv;
-extern const key_fetchdef ec_paramfetch[], ec_pubfetch[], ec_privfetch[];
+extern const key_fetchdef ec_paramfetch[];
+#define EC_PARAMFETCHSZ 3
+
+extern const key_fetchdef ec_pubfetch[];
+#define EC_PUBFETCHSZ 4
+
+extern const key_fetchdef ec_privfetch[];
+#define EC_PRIVFETCHSZ 7
+
+/*----- Functions provided ------------------------------------------------*/
+
+/* --- @ec_paramfree@, @ec_pubfree@, @ec_privfree@ --- *
+ *
+ * Arguments: @ec_param *ep@, @ec_pub *ep@, @ec_priv *ep@ = pointer to
+ * key block to free
+ *
+ * Returns: ---
+ *
+ * Use: Frees an elliptic curve key block
+ */
+
+extern void ec_paramfree(ec_param */*ep*/);
+extern void ec_pubfree(ec_pub */*ep*/);
+extern void ec_privfree(ec_priv */*ep*/);
/*----- That's all, folks -------------------------------------------------*/