wolfcrypt api testwolfcrypt update

This commit is contained in:
Jacob Barthelmeh
2014-12-29 14:35:46 -07:00
parent 67858df5e0
commit cbbdfc7b96
5 changed files with 22 additions and 25 deletions

View File

@ -75,25 +75,9 @@ include swig/include.am
include src/include.am
include support/include.am
#-------------------------------------#
if BUILD_FIPS
include ctaocrypt/benchmark/include.am
else
include wolfcrypt/benchmark/include.am
endif
#-------------------------------------#
if BUILD_FIPS
include ctaocrypt/src/include.am
else
include wolfcrypt/src/include.am
endif
#-------------------------------------#
if BUILD_FIPS
include ctaocrypt/test/include.am
else
include wolfcrypt/test/include.am
endif
#-------------------------------------#
include examples/client/include.am
include examples/server/include.am
include examples/echoclient/include.am

View File

@ -1521,7 +1521,7 @@ void bench_eccKeyAgree(void)
}
#elif defined MICROCHIP_PIC32
#if defined(CYASSL_MICROCHIP_PIC32MZ)
#if defined(WOLFSSL_MICROCHIP_PIC32MZ)
#define CLOCK 80000000.0
#else
#include <peripheral/timer.h>
@ -1543,7 +1543,7 @@ void bench_eccKeyAgree(void)
return ( ns / CLOCK * 2.0);
}
#elif defined(CYASSL_IAR_ARM) || defined (CYASSL_MDK_ARM)
#elif defined(WOLFSSL_IAR_ARM) || defined (WOLFSSL_MDK_ARM)
#warning "Write your current_time()"
double current_time(int reset) { return 0.0 ; }
@ -1560,7 +1560,7 @@ void bench_eccKeyAgree(void)
return (double)tickCount / 1000;
}
#elif defined (CYASSL_TIRTOS)
#elif defined (WOLFSSL_TIRTOS)
extern double current_time(int reset);

View File

@ -28,8 +28,14 @@
#include <wolfssl/wolfcrypt/types.h>
/* included for fips*/
/* included for fips @wc_fips */
#include <cyassl/ctaocrypt/aes.h>
#if defined(CYASSL_AES_COUNTER) && !defined(WOLFSSL_AES_COUNTER)
#define WOLFSSL_AES_COUNTER
#endif
#if !defined(WOLFSSL_AES_DIRECT) && defined(CYASSL_AES_DIRECT)
#define WOLFSSL_AES_DIRECT
#endif
#ifdef __cplusplus
extern "C" {
@ -44,11 +50,11 @@
const byte* key, word32 keySz, const byte* iv);
/* AES-CTR */
#ifdef CYASSL_AES_COUNTER
#ifdef WOLFSSL_AES_COUNTER
WOLFSSL_API void wc_AesCtrEncrypt(Aes* aes, byte* out, const byte* in, word32 sz);
#endif
/* AES-DIRECT */
#if defined(CYASSL_AES_DIRECT)
#if defined(WOLFSSL_AES_DIRECT)
WOLFSSL_API void wc_AesEncryptDirect(Aes* aes, byte* out, const byte* in);
WOLFSSL_API void wc_AesDecryptDirect(Aes* aes, byte* out, const byte* in);
WOLFSSL_API int wc_AesSetKeyDirect(Aes* aes, const byte* key, word32 len,

View File

@ -24,8 +24,14 @@
#ifndef WOLF_CRYPT_RSA_H
#define WOLF_CRYPT_RSA_H
/* for fips */
#include <wolfssl/wolfcrypt/types.h>
/* for fips @wc_fips */
#include <cyassl/ctaocrypt/rsa.h>
#if defined(CYASSL_KEY_GEN) && !defined(WOLFSSL_KEY_GEN)
#define WOLFSSL_KEY_GEN
#endif
#ifdef __cplusplus
extern "C" {
@ -101,3 +107,4 @@ WOLFSSL_API int wc_RsaFlattenPublicKey(RsaKey*, byte*, word32*, byte*,
#endif /* WOLF_CRYPT_RSA_H */
#endif /* NO_RSA */

View File

@ -678,7 +678,7 @@
#if !defined(XMALLOC_USER) && !defined(MICRIUM_MALLOC) && \
!defined(WOLFSSL_LEANPSK) && !defined(NO_CYASSL_MEMORY)
!defined(WOLFSSL_LEANPSK) && !defined(NO_WOLFSSL_MEMORY)
#define USE_WOLFSSL_MEMORY
#endif
@ -713,7 +713,7 @@
#elif defined(XSTREAM_ALIGNMENT)
#define WOLFSSL_GENERAL_ALIGNMENT 4
#elif defined(FREESCALE_MMCAU)
#define WOLFSSL_GENERAL_ALIGNMENT CYASSL_MMCAU_ALIGNMENT
#define WOLFSSL_GENERAL_ALIGNMENT WOLFSSL_MMCAU_ALIGNMENT
#else
#define WOLFSSL_GENERAL_ALIGNMENT 0
#endif