File: sha256.h

package info (click to toggle)
bglibs 2.04%2Bdfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 3,368 kB
  • sloc: ansic: 15,820; perl: 674; sh: 64; makefile: 26
file content (18 lines) | stat: -rw-r--r-- 335 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#ifndef BGLIBS__SHA256__H__
#define BGLIBS__SHA256__H__

#include "sysdeps.h"

#define SHA256_DIGEST_LENGTH (256/8)

typedef struct {
  uint32 H[8];
  uint64 bytes;
  uint8 M[64];
} SHA256_ctx;

void SHA256_init(SHA256_ctx*);
void SHA256_update(SHA256_ctx*, const void*, unsigned long);
void SHA256_final(SHA256_ctx*, uint8*);

#endif