FILE *afp = NULL, *rfp = NULL;
char ibuf[2048];
char tbuf[2048];
- int ilen, len, ret = 0;
+ int len;
char algo[8] = "";
char amode[8] = "";
char atest[8] = "";
while (!err && (fgets(ibuf, sizeof(ibuf), afp)) != NULL)
{
tidy_line(tbuf, ibuf);
- ilen = strlen(ibuf);
/* printf("step=%d ibuf=%s",step,ibuf); */
switch (step)
{
}
else
{
- ret = AESTest(&ctx, amode, akeysz, aKey, iVec,
+ AESTest(&ctx, amode, akeysz, aKey, iVec,
dir, /* 0 = decrypt, 1 = encrypt */
plaintext, ciphertext, len);
OutputValue("CIPHERTEXT",ciphertext,len,rfp,
}
else
{
- ret = AESTest(&ctx, amode, akeysz, aKey, iVec,
+ AESTest(&ctx, amode, akeysz, aKey, iVec,
dir, /* 0 = decrypt, 1 = encrypt */
plaintext, ciphertext, len);
OutputValue("PLAINTEXT",(unsigned char *)plaintext,len,rfp,
char *rqlist = "req.txt", *rspfile = NULL;
FILE *fp = NULL;
char fn[250] = "", rfn[256] = "";
- int f_opt = 0, d_opt = 1;
+ int d_opt = 1;
fips_algtest_init();
if (argc > 1)
}
else if (strcasecmp(argv[1], "-f") == 0)
{
- f_opt = 1;
d_opt = 0;
}
else
char *keyword, *value;
int inlen = 0;
int encrypt = 0;
- int rv;
long l;
unsigned char *key = NULL, *iv = NULL;
unsigned char *inbuf = NULL, *outbuf = NULL;
{
FIPS_cipherinit(&ctx, xts, key, iv, encrypt);
outbuf = OPENSSL_malloc(inlen);
- rv = FIPS_cipher(&ctx, outbuf, inbuf, inlen);
+ FIPS_cipher(&ctx, outbuf, inbuf, inlen);
OutputValue(encrypt ? "CT":"PT", outbuf, inlen, out, 0);
OPENSSL_free(inbuf);
OPENSSL_free(outbuf);
char afn[256], rfn[256];
FILE *afp = NULL, *rfp = NULL;
char ibuf[2048], tbuf[2048];
- int ilen, len, ret = 0;
+ int len;
char amode[8] = "";
char atest[100] = "";
int akeysz=0;
while (!err && (fgets(ibuf, sizeof(ibuf), afp)) != NULL)
{
tidy_line(tbuf, ibuf);
- ilen = strlen(ibuf);
/* printf("step=%d ibuf=%s",step,ibuf);*/
if(step == 3 && !strcmp(amode,"ECB"))
{
else
{
assert(dir == 1);
- ret = DESTest(&ctx, amode, akeysz, aKey, iVec,
+ DESTest(&ctx, amode, akeysz, aKey, iVec,
dir, /* 0 = decrypt, 1 = encrypt */
ciphertext, plaintext, len);
OutputValue("CIPHERTEXT",ciphertext,len,rfp,
else
{
assert(dir == 0);
- ret = DESTest(&ctx, amode, akeysz, aKey, iVec,
+ DESTest(&ctx, amode, akeysz, aKey, iVec,
dir, /* 0 = decrypt, 1 = encrypt */
plaintext, ciphertext, len);
OutputValue("PLAINTEXT",(unsigned char *)plaintext,len,rfp,
char *rqlist = "req.txt", *rspfile = NULL;
FILE *fp = NULL;
char fn[250] = "", rfn[256] = "";
- int f_opt = 0, d_opt = 1;
+ int d_opt = 1;
fips_algtest_init();
if (argc > 1)
}
else if (fips_strcasecmp(argv[1], "-f") == 0)
{
- f_opt = 1;
d_opt = 0;
}
else