ifdef抜けの修正 その5

git-svn-id: file:///Volumes/Transfer/gigaleak_20231201/2020-09-30%20-%20paladin.7z/paladin/ctr_eFuse@29 ff987cc8-cf2f-4642-8568-d52cce064691
This commit is contained in:
kubodera_yuichi 2009-12-22 07:00:14 +00:00
parent de0d9f3712
commit 8bd6f50acc

View File

@ -128,9 +128,7 @@
#include "rqcard-fips.h"
// nShield optional
#include "simplebignum.h"
#endif // USE_HSM
#ifdef USE_HSM
// TORIAEZU : nFast variables
NFast_AppHandle hsmHandle;
NFastApp_Connection hsmConnection;
@ -145,18 +143,16 @@ M_ByteBlock *hsmBlobptr = NULL;
M_KeyID hsmAeskeyid;
const NFKM_KeyIdent hsmAeskeyident = { (char*)"simple", (char*)"aes-test-key" };
NFKM_Key *hsmAeskeyinfo = NULL; // allocate
static int hsm_aes_load_key( void );
#else // !ENCRYPT_AES
M_KeyID hsmRsaPrivkeyid, hsmRsaPubkeyid;
const NFKM_KeyIdent hsmRsakeyident = { (char*)"simple", (char*)"rsa-priv-key-2048" };
NFKM_Key *hsmRsakeyinfo = NULL; // allocate
#endif // ENCRYPT_AES
#endif // USE_HSM
static int hsm_rsa_load_keypair( void );
static int hsm_aes_load_key( void );
#endif // ENCRYPT_AES
#ifdef USE_HSM
// init HSM
int hsm_initialize( void )
{
@ -326,7 +322,7 @@ int hsm_get_rtc( time_t *time )
return CR_GENID_SUCCESS;
} // hsm_get_rtc
#ifdef ENCYRPT_AES
#ifdef ENCRYPT_AES
int hsm_aes_load_key( void )
{
@ -492,7 +488,7 @@ int hsm_aes_decrypt( unsigned char *dst_buf, unsigned char *org_buf, int size )
return CR_GENID_SUCCESS;
} // hsm_aes_decrypt
#else // !ENCRYPT_AES
#else !ENCRYPT_AES
int hsm_rsa_load_keypair( void )
{
@ -749,6 +745,6 @@ int hsm_rsa_decrypt( unsigned char *dst_buf, unsigned char *org_buf, int size )
return CR_GENID_SUCCESS;
} // hsm_rsa_decrypt
#endif // ENCRYPT_AES
#endif // !ENCRYPT_AES
#endif // USE_HSM