source: protocols/sha.h @ 13c4cd3

Last change on this file since 13c4cd3 was b7d3cc34, checked in by Wilmer van der Gaast <wilmer@…>, at 2005-11-06T18:23:18Z

Initial repository (0.99 release tree)

  • Property mode set to 100644
File size: 554 bytes
Line 
1#ifndef __SHA_H__
2#define __SHA_H__
3
4#include <gmodule.h>
5
6G_MODULE_EXPORT int strprintsha(char *dest, int *hashval);
7 
8typedef struct {
9  guint32 H[5];
10  guint32 W[80];
11  int lenW;
12  guint32 sizeHi,sizeLo;
13} SHA_CTX;
14 
15G_MODULE_EXPORT void shaInit(SHA_CTX *ctx);
16G_MODULE_EXPORT void shaUpdate(SHA_CTX *ctx, unsigned char *dataIn, int len);
17G_MODULE_EXPORT void shaFinal(SHA_CTX *ctx, unsigned char hashout[20]);
18G_MODULE_EXPORT void shaBlock(unsigned char *dataIn, int len, unsigned char hashout[20]);
19G_MODULE_EXPORT char *shahash(char *str);
20
21#endif
Note: See TracBrowser for help on using the repository browser.