X-Git-Url: http://erislabs.net/gitweb/?a=blobdiff_plain;f=lib%2Farcfour.h;h=ee8ef8a9c73a0daad8ee09874974109de691faaa;hb=618fd97d05ba9f1411536c887dbeebe3807c055a;hp=28ef679d05531b51219cfa0eb6061ef7cc2db3a1;hpb=13083d5caa5989dab4238adce19a2fa55efc4201;p=gnulib.git diff --git a/lib/arcfour.h b/lib/arcfour.h index 28ef679d0..ee8ef8a9c 100644 --- a/lib/arcfour.h +++ b/lib/arcfour.h @@ -1,6 +1,5 @@ /* arcfour.h --- The arcfour stream cipher - * Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005 - * Free Software Foundation, Inc. + * Copyright (C) 2000-2005, 2009-2012 Free Software Foundation, Inc. * * This file is free software; you can redistribute it and/or modify * it under the terms of the GNU General Public License as published @@ -13,9 +12,7 @@ * General Public License for more details. * * You should have received a copy of the GNU General Public License - * along with this file; if not, write to the Free Software - * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA - * 02110-1301, USA. + * along with this file; if not, see . * */ @@ -25,13 +22,14 @@ # define ARCFOUR_H # include +# include #define ARCFOUR_SBOX_SIZE 256 typedef struct { - size_t idx_i, idx_j; char sbox[ARCFOUR_SBOX_SIZE]; + uint8_t idx_i, idx_j; } arcfour_context; /* Apply ARCFOUR stream to INBUF placing the result in OUTBUF, both of @@ -39,7 +37,7 @@ typedef struct before this function is called. */ extern void arcfour_stream (arcfour_context * context, - const char *inbuf, char *outbuf, size_t length); + const char *inbuf, char *outbuf, size_t length); /* Initialize CONTEXT using encryption KEY of KEYLEN bytes. KEY should be 40 bits (5 bytes) or longer. The KEY cannot be zero