CURLOPT_SSH_COMPRESSION(3)
β¨ CURLOPT_SSH_COMPRESSION β¨
okay bestie, so this is a page from the libcurl Library Functions Manual and honestly? it's a short one but it's lowkey iconic. sit down, hydrate, let's go π
πΈ NAME πΈ
CURLOPT_SSH_COMPRESSION β enable SSH compression π
π¦ SYNOPSIS π¦
#include <curl/curl.h>
CURLcode curl_easy_setopt(CURL *handle, CURLOPT_SSH_COMPRESSION, long enable);
π DESCRIPTION π
so you pass in a long as your parameter, and the vibe is: set it to 1L to enable, or 0L to disable. that's it. that's the whole thing π«Ά
it turns on built-in SSH compression. but bestie, listen to me β this is a request, not an order. the server may or may not actually do it. you're basically sliding into the server's DMs like "hey could u compress π₯Ί" and the server gets to decide. no cap, that's the dynamic. β¨
π DEFAULT π
0, disabled
like, off. not on. the compression is not giving until you ask. π
π PROTOCOLS π
this functionality affects scp and sftp β that's the whole guest list, iykyk π₯
π§ EXAMPLE π§
int main(void)
{
CURL *curl = curl_easy_init();
if(curl) {
curl_easy_setopt(curl, CURLOPT_URL, "sftp://example.com");
/* enable built-in compression */
curl_easy_setopt(curl, CURLOPT_SSH_COMPRESSION, 1L);
/* Perform the request */
curl_easy_perform(curl);
}
}
look at her go. main character energy fr fr π
β AVAILABILITY β
Added in curl 7.56.0 β so if you're on something older, this option is gonna ghost you π
π RETURN VALUE π
curl_easy_setopt(3) returns a CURLcode indicating success or error.
CURLE_OK (0) means everything was OK π₯³ β non-zero means an error occurred, so go see libcurl-errors(3) and figure out what's wrong. π
πΈ SEE ALSO πΈ
and that's the tea, bestie π this page is from libcurl, dated 2026-10-12, and it's literally called CURLOPT_SSH_COMPRESSION(3) β go compress something, ily, bye πβ¨π
π¦ where this page comes from
- fedora 44: libcurl-devel 8.18.0-14.fc44 Β· curl
- fedora 44: libcurl-devel 8.18.0-14.fc44 Β· curl
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms