Rizin
unix-like reverse engineering framework and cli tools
|
Go to the source code of this file.
Macros | |
#define | MAXOUT 50000000 |
Functions | |
RZ_API ut8 * | rz_inflate (RZ_NONNULL const ut8 *src, int srcLen, int *srcConsumed, int *dstLen) |
inflate zlib compressed or gzipped, automatically accepts either the zlib or gzip format, and use MAX_WBITS as the window size logarithm. More... | |
RZ_API ut8 * | rz_inflate_ignore_header (RZ_NONNULL const ut8 *src, int srcLen, int *srcConsumed, int *dstLen) |
inflate zlib compressed or gzipped. The input must be a raw stream with no header or trailer. More... | |
RZ_API ut8 * | rz_inflatew (RZ_NONNULL const ut8 *src, int srcLen, int *srcConsumed, int *dstLen, int wbits) |
RZ_API ut8 * | rz_deflatew (RZ_NONNULL const ut8 *src, int srcLen, int *srcConsumed, int *dstLen, int wbits) |
RZ_API bool | rz_deflatew_buf (RZ_NONNULL RzBuffer *src, RZ_NONNULL RzBuffer *dst, ut64 block_size, ut8 *src_consumed, int wbits) |
RZ_API bool | rz_inflatew_buf (RZ_NONNULL RzBuffer *src, RZ_NONNULL RzBuffer *dst, ut64 block_size, ut8 *src_consumed, int wbits) |
RZ_API ut8 * | rz_deflate (RZ_NONNULL const ut8 *src, int srcLen, int *srcConsumed, int *dstLen) |
deflate uncompressed data to zlib or gzipped, use MAX_WBITS as the window size logarithm. More... | |
RZ_API bool | rz_deflate_buf (RZ_NONNULL RzBuffer *src, RZ_NONNULL RzBuffer *dst, ut64 block_size, ut8 *src_consumed) |
deflate uncompressed data in RzBbuffer to zlib or gzipped, use MAX_WBITS as the window size logarithm. More... | |
RZ_API bool | rz_inflate_buf (RZ_NONNULL RzBuffer *src, RZ_NONNULL RzBuffer *dst, ut64 block_size, ut8 *src_consumed) |
inflate compressed data in RzBbuffer, use MAX_WBITS as the window size logarithm. More... | |
static bool | lzma_action_buf (RZ_NONNULL RzBuffer *src, RZ_NONNULL RzBuffer *dst, ut64 block_size, ut8 *src_consumed, bool encode) |
RZ_API bool | rz_lzma_dec_buf (RZ_NONNULL RzBuffer *src, RZ_NONNULL RzBuffer *dst, ut64 block_size, ut8 *src_consumed) |
Decompress the src buffer with LZMA algorithm and put the decompressed data in dst . More... | |
RZ_API bool | rz_lzma_enc_buf (RZ_NONNULL RzBuffer *src, RZ_NONNULL RzBuffer *dst, ut64 block_size, ut8 *src_consumed) |
Compress the src buffer with LZMA algorithm and put the compressed data in dst . More... | |
#define MAXOUT 50000000 |
Definition at line 12 of file compression.c.
|
static |
Definition at line 449 of file compression.c.
Referenced by rz_lzma_dec_buf(), and rz_lzma_enc_buf().
deflate uncompressed data to zlib or gzipped, use MAX_WBITS as the window size logarithm.
Definition at line 340 of file compression.c.
References MAX_WBITS, NULL, rz_deflatew(), rz_return_val_if_fail, and src.
RZ_API bool rz_deflate_buf | ( | RZ_NONNULL RzBuffer * | src, |
RZ_NONNULL RzBuffer * | dst, | ||
ut64 | block_size, | ||
ut8 * | src_consumed | ||
) |
deflate uncompressed data in RzBbuffer to zlib or gzipped, use MAX_WBITS as the window size logarithm.
Definition at line 350 of file compression.c.
References dst, MAX_WBITS, rz_deflatew_buf(), rz_return_val_if_fail, and src.
Referenced by rz_file_deflate().
RZ_API ut8* rz_deflatew | ( | RZ_NONNULL const ut8 * | src, |
int | srcLen, | ||
int * | srcConsumed, | ||
int * | dstLen, | ||
int | wbits | ||
) |
RZ_API bool rz_deflatew_buf | ( | RZ_NONNULL RzBuffer * | src, |
RZ_NONNULL RzBuffer * | dst, | ||
ut64 | block_size, | ||
ut8 * | src_consumed, | ||
int | wbits | ||
) |
Definition at line 327 of file compression.c.
Referenced by rz_deflate_buf(), and rz_sign_flirt_write_compressed_pattern_to_buffer().
inflate zlib compressed or gzipped, automatically accepts either the zlib or gzip format, and use MAX_WBITS as the window size logarithm.
Definition at line 18 of file compression.c.
References MAX_WBITS, NULL, rz_inflatew(), rz_return_val_if_fail, and src.
Referenced by __open(), rz_cmd_print(), rz_file_gzslurp(), and rz_sign_flirt_parse_compressed_pattern_from_buffer().
RZ_API bool rz_inflate_buf | ( | RZ_NONNULL RzBuffer * | src, |
RZ_NONNULL RzBuffer * | dst, | ||
ut64 | block_size, | ||
ut8 * | src_consumed | ||
) |
inflate compressed data in RzBbuffer, use MAX_WBITS as the window size logarithm.
Definition at line 360 of file compression.c.
References dst, MAX_WBITS, rz_inflatew_buf(), rz_return_val_if_fail, and src.
Referenced by rz_file_inflate().
RZ_API ut8* rz_inflate_ignore_header | ( | RZ_NONNULL const ut8 * | src, |
int | srcLen, | ||
int * | srcConsumed, | ||
int * | dstLen | ||
) |
inflate zlib compressed or gzipped. The input must be a raw stream with no header or trailer.
Definition at line 28 of file compression.c.
References MAX_WBITS, NULL, rz_inflatew(), rz_return_val_if_fail, and src.
Referenced by rz_sign_flirt_parse_compressed_pattern_from_buffer().
RZ_API ut8* rz_inflatew | ( | RZ_NONNULL const ut8 * | src, |
int | srcLen, | ||
int * | srcConsumed, | ||
int * | dstLen, | ||
int | wbits | ||
) |
Definition at line 319 of file compression.c.
References NULL.
Referenced by rz_inflate(), and rz_inflate_ignore_header().
RZ_API bool rz_inflatew_buf | ( | RZ_NONNULL RzBuffer * | src, |
RZ_NONNULL RzBuffer * | dst, | ||
ut64 | block_size, | ||
ut8 * | src_consumed, | ||
int | wbits | ||
) |
Definition at line 331 of file compression.c.
Referenced by rz_inflate_buf().
RZ_API bool rz_lzma_dec_buf | ( | RZ_NONNULL RzBuffer * | src, |
RZ_NONNULL RzBuffer * | dst, | ||
ut64 | block_size, | ||
ut8 * | src_consumed | ||
) |
Decompress the src
buffer with LZMA algorithm and put the decompressed data in dst
.
src | Where to read the compressed data from |
dst | Where to write the decompressed data to |
block_size | Decompression can happen block after block. Specify the size of the block here. |
Definition at line 462 of file compression.c.
References dst, lzma_action_buf(), and src.
Referenced by get_gnu_debugdata_elf_symbols().
RZ_API bool rz_lzma_enc_buf | ( | RZ_NONNULL RzBuffer * | src, |
RZ_NONNULL RzBuffer * | dst, | ||
ut64 | block_size, | ||
ut8 * | src_consumed | ||
) |
Compress the src
buffer with LZMA algorithm and put the compressed data in dst
.
src | Where to read the decompressed data from |
dst | Where to write the compressed data to |
block_size | Compression can happen block after block. Specify the size of the block here. |
Definition at line 474 of file compression.c.
References dst, lzma_action_buf(), and src.