1/*
2 * rc4.h
3 * RC4 stream cipher
4 *
5 * Copyright 2003, Broadcom Corporation
6 * All Rights Reserved.
7 *
8 * This is UNPUBLISHED PROPRIETARY SOURCE CODE of Broadcom Corporation; the
9 * contents of this file may not be disclosed to third parties, copied or
10 * duplicated in any form, in whole or in part, without the prior written
11 * permission of Broadcom Corporation.
12 *
13 * $Id: rc4.h,v 1.1.1.1 2008/10/15 03:31:22 james26_jang Exp $
14 */
15
16#ifndef _RC4_H_
17#define _RC4_H_
18
19#include <typedefs.h>
20
21#define RC4_STATE_NBYTES 256
22
23typedef struct rc4_ks
24{
25   uchar state[RC4_STATE_NBYTES];
26   uchar x;
27   uchar y;
28} rc4_ks_t;
29
30void prepare_key(uchar *key_data_ptr, int key_data_len, rc4_ks_t *key);
31
32void rc4(uchar *buffer_ptr, int buffer_len, rc4_ks_t *key);
33
34#endif /* _RC4_H_ */
35
36