Simplify: Remove dynamic version check, use known working v2.0.1-rc4
Issue: GitHub API curl was hanging even with timeouts on network-restricted server Solution: Use tested v2.0.1-rc4 directly instead of querying API - Eliminates hanging during 'Checking available versions...' - Falls back to main branch if release unavailable - Tested and verified to work (51,545 signatures) When new version available, update one line with new version number.
This commit is contained in:
@@ -285,15 +285,12 @@ install_maldet_only() {
|
||||
rm -f "$temp_file"
|
||||
fi
|
||||
|
||||
# Get latest release dynamically from GitHub API (with timeout)
|
||||
local latest_release
|
||||
latest_release=$(curl -s --connect-timeout 5 --max-time 10 "https://api.github.com/repos/rfxn/linux-malware-detect/releases/latest" 2>/dev/null | grep -o '"tag_name":"[^"]*' | head -1 | cut -d'"' -f4)
|
||||
|
||||
# Download sources in priority order
|
||||
# Format: "name|url|label" (using | as delimiter to avoid splitting https://)
|
||||
# Note: Repository is rfxn/linux-malware-detect (not maldet)
|
||||
# Latest tested version: v2.0.1-rc4 (Apr 20, 2026)
|
||||
local sources=(
|
||||
"github-latest|https://api.github.com/repos/rfxn/linux-malware-detect/tarball/${latest_release:-v2.0.1-rc4}|GitHub Latest Release (${latest_release:-v2.0.1-rc4})"
|
||||
"github-release|https://api.github.com/repos/rfxn/linux-malware-detect/tarball/v2.0.1-rc4|GitHub Release v2.0.1-rc4"
|
||||
"github-main|https://github.com/rfxn/linux-malware-detect/archive/refs/heads/main.tar.gz|GitHub main branch (Development)"
|
||||
)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user