]> www.average.org Git - pam_pcsc_cr.git/blob - crypto.h
ad4cf63d2e00cb577bea3171c6072346742edf31
[pam_pcsc_cr.git] / crypto.h
1 #ifndef _CRYPTO_H
2 #define _CRYPTO_H
3
4 int select_crypto_if(int ifno);
5 const char *crypto_init(int ifno);
6 unsigned long encrypt(void *key, int keylen, void *pt, void *ct, int tlen);
7 unsigned long decrypt(void *key, int keylen, void *ct, void *pt, int tlen);
8 unsigned long hash(void *pt, int tlen, void *tag, int *taglen);
9 unsigned long hmac(void *key, int keylen, void *pt, int tlen,
10                         void *tag, int *taglen);
11 const char *crypto_errstr(unsigned long err);
12
13 #define HASHSIZE 20
14 #define CBLKSIZE 16
15
16 #endif