]>
git.saurik.com Git - apple/xnu.git/blob - EXTERNAL_HEADERS/corecrypto/ccrc4.h
5 * Created on 12/22/2010
7 * Copyright (c) 2010,2011,2012,2013,2014,2015 Apple Inc. All rights reserved.
11 #ifndef _CORECRYPTO_CCRC4_H_
12 #define _CORECRYPTO_CCRC4_H_
14 #include <corecrypto/ccmode.h>
16 cc_aligned_struct(16) ccrc4_ctx
;
18 /* Declare a rc4 key named _name_. Pass the size field of a struct ccmode_ecb
20 #define ccrc4_ctx_decl(_size_, _name_) cc_ctx_decl(ccrc4_ctx, _size_, _name_)
21 #define ccrc4_ctx_clear(_size_, _name_) cc_clear(_size_, _name_)
24 size_t size
; /* first argument to ccrc4_ctx_decl(). */
25 void (*init
)(ccrc4_ctx
*ctx
, size_t key_len
, const void *key
);
26 void (*crypt
)(ccrc4_ctx
*ctx
, unsigned long nbytes
, const void *in
, void *out
);
30 const struct ccrc4_info
*ccrc4(void);
32 extern const struct ccrc4_info ccrc4_eay
;
37 unsigned long datalen
;
42 int ccrc4_test(const struct ccrc4_info
*rc4
, const struct ccrc4_vector
*v
);
44 #endif /* _CORECRYPTO_CCRC4_H_ */