wolfSSL SSL/TLS library, support up to TLS1.3
Dependents: CyaSSL-Twitter-OAuth4Tw Example-client-tls-cert TwitterReader TweetTest ... more
rc4.h
00001 /* rc4.h 00002 * 00003 * Copyright (C) 2006-2020 wolfSSL Inc. 00004 * 00005 * This file is part of wolfSSL. 00006 * 00007 * wolfSSL is free software; you can redistribute it and/or modify 00008 * it under the terms of the GNU General Public License as published by 00009 * the Free Software Foundation; either version 2 of the License, or 00010 * (at your option) any later version. 00011 * 00012 * wolfSSL is distributed in the hope that it will be useful, 00013 * but WITHOUT ANY WARRANTY; without even the implied warranty of 00014 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00015 * GNU General Public License for more details. 00016 * 00017 * You should have received a copy of the GNU General Public License 00018 * along with this program; if not, write to the Free Software 00019 * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1335, USA 00020 */ 00021 00022 00023 00024 /* rc4.h defines mini des openssl compatibility layer 00025 * 00026 */ 00027 00028 #ifndef WOLFSSL_RC4_COMPAT_H_ 00029 #define WOLFSSL_RC4_COMPAT_H_ 00030 00031 #include <wolfssl/wolfcrypt/settings.h> 00032 #include <wolfssl/openssl/ssl.h> /* included for size_t */ 00033 00034 #ifdef __cplusplus 00035 extern "C" { 00036 #endif 00037 00038 /* applications including wolfssl/openssl/rc4.h are expecting to have access to 00039 * the size of RC4_KEY structures. */ 00040 typedef struct WOLFSSL_RC4_KEY { 00041 /* big enough for Arc4 from wolfssl/wolfcrypt/arc4.h */ 00042 void* holder[(272 + WC_ASYNC_DEV_SIZE) / sizeof(void*)]; 00043 } WOLFSSL_RC4_KEY; 00044 typedef WOLFSSL_RC4_KEY RC4_KEY; 00045 00046 WOLFSSL_API void wolfSSL_RC4_set_key(WOLFSSL_RC4_KEY* key, int len, 00047 const unsigned char* data); 00048 WOLFSSL_API void wolfSSL_RC4(WOLFSSL_RC4_KEY* key, size_t len, 00049 const unsigned char* in, unsigned char* out); 00050 00051 #define RC4 wolfSSL_RC4 00052 #define RC4_set_key wolfSSL_RC4_set_key 00053 00054 #ifdef __cplusplus 00055 } /* extern "C" */ 00056 #endif 00057 00058 #endif /* WOLFSSL_RC4_COMPAT_H_ */ 00059 00060
Generated on Tue Jul 12 2022 20:58:41 by 1.7.2