Rizin
unix-like reverse engineering framework and cli tools
check.h
Go to the documentation of this file.
1 
6 /*
7  * Author: Lasse Collin
8  *
9  * This file has been put into the public domain.
10  * You can do whatever you want with this file.
11  *
12  * See ../lzma.h for information about liblzma as a whole.
13  */
14 
15 #ifndef LZMA_H_INTERNAL
16 # error Never include this file directly. Use <lzma.h> instead.
17 #endif
18 
19 
27 typedef enum {
28  LZMA_CHECK_NONE = 0,
35  LZMA_CHECK_CRC32 = 1,
42  LZMA_CHECK_CRC64 = 4,
56 
57 
68 #define LZMA_CHECK_ID_MAX 15
69 
70 
81 extern LZMA_API(lzma_bool) lzma_check_is_supported(lzma_check check)
83 
84 
95 extern LZMA_API(uint32_t) lzma_check_size(lzma_check check)
97 
98 
102 #define LZMA_CHECK_SIZE_MAX 64
103 
104 
119 extern LZMA_API(uint32_t) lzma_crc32(
120  const uint8_t *buf, size_t size, uint32_t crc)
122 
123 
131 extern LZMA_API(uint64_t) lzma_crc64(
132  const uint8_t *buf, size_t size, uint64_t crc)
134 
135 
136 /*
137  * SHA-256 functions are currently not exported to public API.
138  * Contact Lasse Collin if you think it should be.
139  */
140 
141 
149 extern LZMA_API(lzma_check) lzma_get_check(const lzma_stream *strm)
150  lzma_nothrow;
lzma_check
Type of the integrity check (Check ID)
Definition: check.h:27
@ LZMA_CHECK_CRC32
Definition: check.h:35
@ LZMA_CHECK_NONE
Definition: check.h:28
@ LZMA_CHECK_CRC64
Definition: check.h:42
@ LZMA_CHECK_SHA256
Definition: check.h:49
size_t uint32_t crc lzma_nothrow lzma_attr_pure
Definition: check.h:121
LZMA_API(lzma_bool) lzma_check_is_supported(lzma_check check) lzma_nothrow lzma_attr_const
Test if the given Check ID is supported.
Definition: index.c:1209
lzma_check check
Definition: container.h:292
static lzma_stream strm
Definition: full_flush.c:20
voidpf void uLong size
Definition: ioapi.h:138
voidpf void * buf
Definition: ioapi.h:138
#define const
Definition: ansidecl.h:240
#define lzma_attr_const
Definition: lzma.h:269
#define lzma_nothrow
Definition: lzma.h:231
unsigned int uint32_t
Definition: sftypes.h:29
unsigned long uint64_t
Definition: sftypes.h:28
unsigned char uint8_t
Definition: sftypes.h:31
Passing data to and from liblzma.
Definition: base.h:485
unsigned char lzma_bool
Boolean.
Definition: base.h:29