X-Git-Url: https://git.distorted.org.uk/u/mdw/catacomb/blobdiff_plain/b3f050848e5d285c2a1d7f8a4bea98984c201805..908ebb29ff621f582b34d48fd4278b60b78379b6:/rc5.h diff --git a/rc5.h b/rc5.h index 877b849..c029832 100644 --- a/rc5.h +++ b/rc5.h @@ -1,13 +1,13 @@ /* -*-c-*- * - * $Id: rc5.h,v 1.2 1999/12/10 23:29:48 mdw Exp $ + * $Id: rc5.h,v 1.4 2004/04/08 01:36:15 mdw Exp $ * * The RC5-32/12 block cipher * * (c) 1999 Straylight/Edgeware */ -/*----- Licensing notice --------------------------------------------------* +/*----- Licensing notice --------------------------------------------------* * * This file is part of Catacomb. * @@ -15,27 +15,26 @@ * 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: rc5.h,v $ - * Revision 1.2 1999/12/10 23:29:48 mdw - * Change header file guard names. - * - * Revision 1.1 1999/09/03 08:41:12 mdw - * Initial import. +/*----- Notes on the RC5 block cipher -------------------------------------* * + * RC5 was designed by Ron Rivest as a test vehicle for the use of data- + * dependent rotations in cryptographic transformations. The algorithm is + * covered by a patent held by RSA Security Inc. (US Patent# 5,724,428). + * It's vulnerable to some clever differential attacks, which can break it in + * about %$2^{44}$% chosen plaintexts. I don't recommend the use of this + * cipher. */ #ifndef CATACOMB_RC5_H @@ -52,10 +51,12 @@ /*----- Magic numbers -----------------------------------------------------*/ #define RC5_ROUNDS 12 -#define RC5_KEYSZ 0 +#define RC5_KEYSZ 10 #define RC5_BLKSZ 8 #define RC5_CLASS (N, L, 64) +extern const octet rc5_keysz[]; + /*----- Data structures ---------------------------------------------------*/ typedef struct rc5_ctx {