Gzip vs identity

Hi,

I have nextcloud running on my RPi4 openwrt router. I have to modify “gzip” to “identity” in file nextcloud/lib/private/Http/Client/client.php, i.e.

if (!isset($options[RequestOptions::HEADERS]['Accept-Encoding'])) {
$options[RequestOptions::HEADERS]['Accept-Encoding'] = 'gzip';
}

to

if (!isset($options[RequestOptions::HEADERS]['Accept-Encoding'])) {
$options[RequestOptions::HEADERS]['Accept-Encoding'] = 'identity';
}

Otherwise nextcloud won’t be able to fetch the app list from server.

Is openwrt does not support gzip encoding?

I am using nginx, the nginx configuration has the following code:

   # Enable gzip but do not remove ETag headers
    gzip on;
    gzip_vary on;
    gzip_comp_level 4;
    gzip_min_length 256;
    gzip_proxied expired no-cache no-store private no_last_modified no_etag auth;
    gzip_types application/atom+xml text/javascript application/javascript application/json application/ld+json application/manifest+json application/rss+xml application/vnd.geo+json application/vnd.ms-fontobject application/wasm application/x-font-ttf application/x-web-app-manifest+json application/xhtml+xml application/xml font/opentype image/bmp image/svg+xml image/x-icon text/cache-manifest text/css text/plain text/vcard text/vnd.rim.location.xloc text/vtt text/x-component text/x-cross-domain-policy;


so it seems gzip is support. I am get lost here.

checked the log, it says:

cURL error 61: Unrecognized content encoding type. libcurl understands identity content encodings.

Does that mean openwrt libcurl does not support gzip encoding?

Without really looking deeper into curl's packaging, you might need the openssl based variant of curl for that (build time decision).

the curl package config shows:

so the package included in openwrt default does not support gzip. I guess I need rebuild the package by set default to “y”.

EDIT: Compiled a new curl package with LIBCURL_ZLIB included (set default y), installed with force-reinstall (curl and libcurl4), nextcloud works fine with gzip compression.

This topic was automatically closed 10 days after the last reply. New replies are no longer allowed.