27 #ifndef WOLF_CRYPT_ENCRYPT_H 28 #define WOLF_CRYPT_ENCRYPT_H 42 #define WC_MAX_SYM_KEY_SIZE (AES_MAX_KEY_SIZE/8) 43 #elif defined(HAVE_CHACHA) 44 #define WC_MAX_SYM_KEY_SIZE CHACHA_MAX_KEY_SZ 45 #elif !defined(NO_DES3) 46 #define WC_MAX_SYM_KEY_SIZE DES3_KEY_SIZE 47 #elif !defined(NO_RC4) 48 #define WC_MAX_SYM_KEY_SIZE RC4_KEY_SIZE 50 #define WC_MAX_SYM_KEY_SIZE 32 54 #if !defined(NO_AES) && defined(HAVE_AES_CBC) 55 WOLFSSL_API
int wc_AesCbcEncryptWithKey(byte* out,
const byte* in, word32 inSz,
66 const byte* in, word32 sz,
67 const byte*
key,
const byte* iv);
69 const byte* in, word32 sz,
70 const byte*
key,
const byte* iv);
72 const byte* in, word32 sz,
73 const byte*
key,
const byte* iv);
75 const byte* in, word32 sz,
76 const byte*
key,
const byte* iv);
82 #ifdef WOLFSSL_ENCRYPTED_KEYS 84 WOLFSSL_API
int wc_BufferKeyDecrypt(
struct EncryptedInfo* info, byte* der, word32 derSz,
85 const byte* password,
int passwordSz,
int hashType);
86 WOLFSSL_API
int wc_BufferKeyEncrypt(
struct EncryptedInfo* info, byte* der, word32 derSz,
87 const byte* password,
int passwordSz,
int hashType);
91 WOLFSSL_LOCAL
int wc_CryptKey(
const char* password,
int passwordSz,
92 byte* salt,
int saltSz,
int iterations,
int id, byte* input,
int length,
93 int version, byte* cbcIv,
int enc,
int shaOid);
byte * key
Definition: srp.h:118
word32 keySz
Definition: srp.h:119
Definition: asn_public.h:195
WOLFSSL_API int wc_Des3_CbcEncryptWithKey(byte *out, const byte *in, word32 sz, const byte *key, const byte *iv)
This function encrypts the input plaintext, in, and stores the resulting ciphertext in the output buf...
Definition: wc_encrypt.c:175
WOLFSSL_API int wc_AesCbcDecryptWithKey(byte *out, const byte *in, word32 inSz, const byte *key, word32 keySz, const byte *iv)
Decrypts a cipher from the input buffer in, and places the resulting plain text in the output buffer ...
Definition: wc_encrypt.c:48
WOLFSSL_API int wc_Des3_CbcDecryptWithKey(byte *out, const byte *in, word32 sz, const byte *key, const byte *iv)
This function decrypts the input ciphertext, in, and stores the resulting plaintext in the output buf...
Definition: ti-des3.c:178
WOLFSSL_API int wc_Des_CbcEncryptWithKey(byte *out, const byte *in, word32 sz, const byte *key, const byte *iv)
This function encrypts the input plaintext, in, and stores the resulting ciphertext in the output buf...
Definition: wc_encrypt.c:120
WOLFSSL_API int wc_Des_CbcDecryptWithKey(byte *out, const byte *in, word32 sz, const byte *key, const byte *iv)
This function decrypts the input ciphertext, in, and stores the resulting plaintext in the output buf...
Definition: ti-des3.c:161