1CURLOPT_SSH_COMPRESSION(3) curl_easy_setopt options CURLOPT_SSH_COMPRESSION(3)
2
3
4

NAME

6       CURLOPT_SSH_COMPRESSION  -  enables  compression / decompression of SSH
7       traffic
8

SYNOPSIS

10       #include <curl/curl.h>
11
12       CURLcode curl_easy_setopt(CURL *handle,  CURLOPT_SSH_COMPRESSION,  long
13       enable);
14

DESCRIPTION

16       Pass a long as parameter set to 1L to enable or 0L to disable.
17
18       Enables built-in SSH compression.  This is a request, not an order; the
19       server may or may not do it.
20

DEFAULT

22       0, disabled
23

PROTOCOLS

25       All SSH based protocols: SCP, SFTP
26

EXAMPLE

28       CURL *curl = curl_easy_init();
29       if(curl) {
30         curl_easy_setopt(curl, CURLOPT_URL, "sftp://example.com");
31
32         /* enable built-in compression */
33         curl_easy_setopt(curl, CURLOPT_SSH_COMPRESSION, 1L);
34
35         /* Perform the request */
36         curl_easy_perform(curl);
37       }
38

AVAILABILITY

40       Added in 7.56.0
41

RETURN VALUE

43       Returns CURLE_OK if the option is  supported,  CURLE_UNKNOWN_OPTION  if
44       not, or CURLE_OUT_OF_MEMORY if there was insufficient heap space.
45

SEE ALSO

47       CURLOPT_ACCEPT_ENCODING(3), CURLOPT_TRANSFER_ENCODING(3),
48
49
50
51libcurl 7.61.1                  August 10, 2018     CURLOPT_SSH_COMPRESSION(3)
Impressum