DSi SHA1 functions.
More...
#include <stddef.h>
#include <nds/ndstypes.h>
|
typedef struct swiSHA1context | swiSHA1context_t |
| Context that holds information about an active SHA1 calculation.
|
|
◆ swiSHA1Calc()
void swiSHA1Calc |
( |
void * |
digest, |
|
|
const void * |
data, |
|
|
size_t |
len |
|
) |
| |
SHA-1 checksum.
- Parameters
-
digest | Buffer to hold SHA-1 checksum result. |
data | Buffer to process. |
len | Length of data. |
◆ swiSHA1Final()
SHA-1 final digest.
- Parameters
-
digest | Buffer to hold SHA-1 checksum result |
ctx | SHA-1 context |
◆ swiSHA1Init()
SHA-1 context setup.
- Parameters
-
ctx | Context to be initialized |
◆ swiSHA1Update()
SHA-1 process buffer.
- Parameters
-
ctx | SHA-1 context. |
data | Buffer to process. |
len | Length of data. |
◆ swiSHA1Verify()
int swiSHA1Verify |
( |
const void * |
digest1, |
|
|
const void * |
digest2 |
|
) |
| |
SHA-1 verify.
- Parameters
-
digest1 | Buffer containing hash to verify. |
digest2 | Buffer containing hash to verify. |
- Returns
- 1 if they match, else 0. If either pointer is NULL it returns 0.