# rpmio/digest.c File Reference

`#include "system.h"`
`#include "rpmio_internal.h"`
`#include "beecrypt.h"`
`#include "md5.h"`
`#include "endianness.h"`
`#include "fips180.h"`
`#include "debug.h"`

Go to the source code of this file.

## Data Structures

struct | DIGEST_CTX_s
| MD5/SHA1 digest private data. More...
union | _dendian

## Defines

#define | DPRINTF(_a)
#define | IS_BIG_ENDIAN() (_endian->b[0] == '\x44')
#define | IS_LITTLE_ENDIAN() (_endian->b[0] == '\x11')

## Functions

DIGEST_CTX | rpmDigestDup (DIGEST_CTX octx)
| Duplicate a digest context.
DIGEST_CTX | rpmDigestInit (pgpHashAlgo hashalgo, rpmDigestFlags flags)
| Initialize digest.
int | rpmDigestUpdate (DIGEST_CTX ctx, const void *data, size_t len)
| Update context with next plain text buffer.
int | rpmDigestFinal (DIGEST_CTX ctx, void **datap, size_t *lenp, int asAscii)
| Return digest and destroy context.

## Variables

static int | _ie = 0x44332211
static union _dendian * | _endian

## Detailed Description

Definition in file digest.c.

## Define Documentation

#define DPRINTF | ( | _a |  | ) |

Definition at line 16 of file digest.c.

Referenced by rpmDigestFinal(), rpmDigestInit(), and rpmDigestUpdate().

#define IS_BIG_ENDIAN | ( |  | ) | (_endian->b[0] == '\x44')

Definition at line 115 of file digest.c.

#define IS_LITTLE_ENDIAN | ( |  | ) | (_endian->b[0] == '\x11')

Definition at line 116 of file digest.c.

Referenced by rpmDigestFinal().

## Variable Documentation

union _dendian * _endian `[static]`

int _ie = 0x44332211`[static]`

Definition at line 107 of file digest.c.