1*5303c0dcScloder /* $OpenBSD: key.h,v 1.8 2005/11/15 22:10:49 cloder Exp $ */ 246c6678dSangelos /* 346c6678dSangelos * The author of this code is Angelos D. Keromytis (angelos@cis.upenn.edu) 446c6678dSangelos * 52edf96f1Sangelos * Copyright (c) 2000-2001 Angelos D. Keromytis. 646c6678dSangelos * 72edf96f1Sangelos * Permission to use, copy, and modify this software with or without fee 846c6678dSangelos * is hereby granted, provided that this entire notice is included in 946c6678dSangelos * all copies of any software which is or includes a copy or 1046c6678dSangelos * modification of this software. 1146c6678dSangelos * You may use this code under the GNU public license if you so wish. Please 1246c6678dSangelos * contribute changes back to the authors under this freer than GPL license 1346c6678dSangelos * so that we may further the use of strong encryption without limitations to 1446c6678dSangelos * all. 1546c6678dSangelos * 1646c6678dSangelos * THIS SOFTWARE IS BEING PROVIDED "AS IS", WITHOUT ANY EXPRESS OR 1746c6678dSangelos * IMPLIED WARRANTY. IN PARTICULAR, NONE OF THE AUTHORS MAKES ANY 1846c6678dSangelos * REPRESENTATION OR WARRANTY OF ANY KIND CONCERNING THE 1946c6678dSangelos * MERCHANTABILITY OF THIS SOFTWARE OR ITS FITNESS FOR ANY PARTICULAR 2046c6678dSangelos * PURPOSE. 2146c6678dSangelos */ 2246c6678dSangelos 2346c6678dSangelos #ifndef _KEY_H_ 2446c6678dSangelos #define _KEY_H_ 2546c6678dSangelos 2646c6678dSangelos #define ISAKMP_KEY_NONE 0 2746c6678dSangelos #define ISAKMP_KEY_PASSPHRASE 1 2846c6678dSangelos #define ISAKMP_KEY_RSA 2 2946c6678dSangelos #define ISAKMP_KEY_DSA 3 3046c6678dSangelos 3146c6678dSangelos #define ISAKMP_KEYTYPE_PUBLIC 0 3246c6678dSangelos #define ISAKMP_KEYTYPE_PRIVATE 1 3346c6678dSangelos 3446c6678dSangelos void key_free(int, int, void *); 351cda6f75Sderaadt void key_serialize(int, int, void *, u_int8_t **, size_t *); 36*5303c0dcScloder char *key_printable(int, int, u_int8_t *, size_t); 37b26670e8Sho void key_from_printable(int, int, char *, u_int8_t **, u_int32_t *); 38*5303c0dcScloder void *key_internalize(int, int, u_int8_t *, size_t); 3946c6678dSangelos #endif /* _KEY_H_ */ 40