MSWSP: parse_CColumnGroupArray() etc.
[wireshark-wip.git] / wsutil / rc4.h
blobe59f34d6c1e1ae511c0699ae973597a60288756b
1 /*
2 Unix SMB/CIFS implementation.
4 a partial implementation of RC4 designed for use in the
5 SMB authentication protocol
7 Copyright (C) Andrew Tridgell 1998
9 $Id$
11 This program is free software; you can redistribute it and/or modify
12 it under the terms of the GNU General Public License as published by
13 the Free Software Foundation; either version 2 of the License, or
14 (at your option) any later version.
16 This program is distributed in the hope that it will be useful,
17 but WITHOUT ANY WARRANTY; without even the implied warranty of
18 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 GNU General Public License for more details.
21 You should have received a copy of the GNU General Public License
22 along with this program; if not, write to the Free Software
23 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA.
26 #ifndef __RC4_H__
27 #define __RC4_H__
29 #include "ws_symbol_export.h"
31 typedef struct _rc4_state_struct {
32 unsigned char s_box[256];
33 unsigned char index_i;
34 unsigned char index_j;
35 } rc4_state_struct;
37 WS_DLL_PUBLIC
38 void crypt_rc4_init(rc4_state_struct *rc4_state,
39 const unsigned char *key, int key_len);
41 WS_DLL_PUBLIC
42 void crypt_rc4(rc4_state_struct *rc4_state, unsigned char *data, int data_len);
44 #endif