]>
Commit | Line | Data |
---|---|---|
21dcbebc | 1 | /* |
6738bf14 | 2 | * Copyright 2015-2018 The OpenSSL Project Authors. All Rights Reserved. |
9a555706 | 3 | * |
48f4ad77 | 4 | * Licensed under the Apache License 2.0 (the "License"). You may not use |
21dcbebc RS |
5 | * this file except in compliance with the License. You can obtain a copy |
6 | * in the file LICENSE in the source distribution or at | |
7 | * https://www.openssl.org/source/license.html | |
9a555706 RS |
8 | */ |
9 | ||
ae4186b0 DMSP |
10 | #ifndef OPENSSL_COMP_H |
11 | # define OPENSSL_COMP_H | |
d86167ec DMSP |
12 | # pragma once |
13 | ||
14 | # include <openssl/macros.h> | |
936c2b9e | 15 | # ifndef OPENSSL_NO_DEPRECATED_3_0 |
d86167ec DMSP |
16 | # define HEADER_COMP_H |
17 | # endif | |
dfeab068 | 18 | |
3c27208f | 19 | # include <openssl/opensslconf.h> |
82271cee | 20 | |
3c27208f RS |
21 | # ifndef OPENSSL_NO_COMP |
22 | # include <openssl/crypto.h> | |
52df25cf | 23 | # include <openssl/comperr.h> |
3c27208f RS |
24 | # ifdef __cplusplus |
25 | extern "C" { | |
114de5b5 MC |
26 | # endif |
27 | ||
dfeab068 | 28 | |
dfeab068 RE |
29 | |
30 | COMP_CTX *COMP_CTX_new(COMP_METHOD *meth); | |
9a555706 RS |
31 | const COMP_METHOD *COMP_CTX_get_method(const COMP_CTX *ctx); |
32 | int COMP_CTX_get_type(const COMP_CTX* comp); | |
33 | int COMP_get_type(const COMP_METHOD *meth); | |
34 | const char *COMP_get_name(const COMP_METHOD *meth); | |
dfeab068 | 35 | void COMP_CTX_free(COMP_CTX *ctx); |
9a555706 | 36 | |
dfeab068 | 37 | int COMP_compress_block(COMP_CTX *ctx, unsigned char *out, int olen, |
0f113f3e | 38 | unsigned char *in, int ilen); |
dfeab068 | 39 | int COMP_expand_block(COMP_CTX *ctx, unsigned char *out, int olen, |
0f113f3e | 40 | unsigned char *in, int ilen); |
9a555706 | 41 | |
0f113f3e | 42 | COMP_METHOD *COMP_zlib(void); |
12e96a23 TS |
43 | COMP_METHOD *COMP_brotli(void); |
44 | COMP_METHOD *COMP_brotli_oneshot(void); | |
caf9317d TS |
45 | COMP_METHOD *COMP_zstd(void); |
46 | COMP_METHOD *COMP_zstd_oneshot(void); | |
02a247e0 | 47 | |
00db8c60 RL |
48 | #ifndef OPENSSL_NO_DEPRECATED_1_1_0 |
49 | # define COMP_zlib_cleanup() while(0) continue | |
02a247e0 | 50 | #endif |
8931b30d | 51 | |
ae4186b0 | 52 | # ifdef OPENSSL_BIO_H |
04f6b0fd | 53 | const BIO_METHOD *BIO_f_zlib(void); |
12e96a23 | 54 | const BIO_METHOD *BIO_f_brotli(void); |
caf9317d | 55 | const BIO_METHOD *BIO_f_zstd(void); |
0f113f3e | 56 | # endif |
dfeab068 | 57 | |
6d311938 | 58 | |
0cd0a820 | 59 | # ifdef __cplusplus |
dfeab068 | 60 | } |
0cd0a820 | 61 | # endif |
3c27208f | 62 | # endif |
dfeab068 | 63 | #endif |