/home/dko/projects/mobilec/trunk/src/security/xyssl-0.7/programs/aes/aescrypt2.c File Reference

#include <sys/types.h>
#include <unistd.h>
#include <string.h>
#include <stdlib.h>
#include <stdio.h>
#include <time.h>
#include "xyssl/aes.h"
#include "xyssl/sha2.h"

Go to the source code of this file.

Defines

#define _CRT_SECURE_NO_DEPRECATE   1
#define MODE_ENCRYPT   0
#define MODE_DECRYPT   1
#define USAGE

Functions

void scanf_argv (char *prompt, char **arg)
int main (int argc, char *argv[])


Define Documentation

#define _CRT_SECURE_NO_DEPRECATE   1

Definition at line 22 of file aescrypt2.c.

#define MODE_DECRYPT   1

Definition at line 41 of file aescrypt2.c.

Referenced by main().

#define MODE_ENCRYPT   0

Definition at line 40 of file aescrypt2.c.

Referenced by main().

#define USAGE

Value:

"\n  aescrypt2 <mode> <input filename> <output filename> <key>\n" \
    "\n   <mode>: 0 = encrypt, 1 = decrypt\n" \
    "\n  example: aescrypt2 0 file file.aes hex:E76B2413958B00E193\n" \
    "\n"

Definition at line 43 of file aescrypt2.c.

Referenced by main().


Function Documentation

int main ( int  argc,
char *  argv[] 
)

Definition at line 57 of file aescrypt2.c.

References aes_decrypt(), aes_encrypt(), aes_set_key(), int, MODE_DECRYPT, MODE_ENCRYPT, scanf_argv(), sha2_finish(), sha2_hmac_finish(), sha2_hmac_starts(), sha2_hmac_update(), sha2_starts(), sha2_update(), and USAGE.

void scanf_argv ( char *  prompt,
char **  arg 
)

Definition at line 49 of file aescrypt2.c.

Referenced by main().


Generated on Fri May 16 14:49:56 2008 for Mobile-C by  doxygen 1.5.4