use '--no-check-certificate' for wget in scripts

arm-sdk7
pedro 4 years ago
parent c940ccfcd8
commit 6e1ef2f0cf

@ -14,7 +14,7 @@ WORK1="$PREFIX/hosts.work1"
WORK2="$PREFIX/hosts.work2"
FINAL="/etc/dnsmasq.adblock"
CHK_FILE="/tmp/adblock.time"
WGET="/usr/bin/wget -T 15"
WGET="/usr/bin/wget --no-check-certificate -T 15"
BLACKLIST=$(nvram get adblock_blacklist)
WHITELIST=$(nvram get adblock_whitelist)

@ -2,6 +2,7 @@
unset LD_LIBRARY_PATH
unset LD_PRELOAD
WGET="/usr/bin/wget --no-check-certificate"
echo "Info: Checking for prerequisites and creating folders..."
@ -26,13 +27,13 @@ done
echo "Info: Opkg package manager deployment..."
DLOADER="ld-linux.so.3"
URL=https://bin.entware.net/armv7sf-k2.6/installer
wget $URL/opkg -O /opt/bin/opkg
$WGET $URL/opkg -O /opt/bin/opkg
chmod 755 /opt/bin/opkg
wget $URL/opkg.conf -O /opt/etc/opkg.conf
wget $URL/ld-2.23.so -O /opt/lib/ld-2.23.so
wget $URL/libc-2.23.so -O /opt/lib/libc-2.23.so
wget $URL/libgcc_s.so.1 -O /opt/lib/libgcc_s.so.1
wget $URL/libpthread-2.23.so -O /opt/lib/libpthread-2.23.so
$WGET $URL/opkg.conf -O /opt/etc/opkg.conf
$WGET $URL/ld-2.23.so -O /opt/lib/ld-2.23.so
$WGET $URL/libc-2.23.so -O /opt/lib/libc-2.23.so
$WGET $URL/libgcc_s.so.1 -O /opt/lib/libgcc_s.so.1
$WGET $URL/libpthread-2.23.so -O /opt/lib/libpthread-2.23.so
cd /opt/lib
chmod 755 ld-2.23.so
ln -s ld-2.23.so $DLOADER

@ -65,7 +65,7 @@ _install_package()
{
PACKAGE=$1
echo "Installing package ${PACKAGE} ..."
wget -O ${TMP}/${PACKAGE} ${REPOSITORY}/${PACKAGE}
wget --no-check-certificate -O ${TMP}/${PACKAGE} ${REPOSITORY}/${PACKAGE}
cd ${TMP}
tar xzf ${TMP}/${PACKAGE}
tar xzf ${TMP}/control.tar.gz

@ -46,7 +46,7 @@ ANON_NOTIFY=$(nvram get tomatoanon_notify)
VER_MAJ=$(echo $VER | awk '{print $1}' | cut -d "." -f1 | sed 's/[^0-9]*//g')
VER_MNR=$(echo $VER | awk '{print $1}' | cut -d "." -f2 | sed 's/[^0-9]*//g')
RESCHK=$(wget -O- "http://freshtomato.org/version.txt")
RESCHK=$(wget --no-check-certificate -O- "http://freshtomato.org/version.txt")
CHKVER_MAJ=$(echo $RESCHK | awk '{print $1}' | cut -d "." -f1 | sed 's/[^0-9]*//g')
ISMNR=$(echo $RESCHK | grep "\." | wc -l)
@ -109,7 +109,7 @@ ANON_NOTIFY=$(nvram get tomatoanon_notify)
# We have all we need well we can send data to Anon database
RESULT="/tmp/anon.result"
wget -O $RESULT $ANONSEND
wget --no-check-certificate -O $RESULT $ANONSEND
# Thanks. Now add cron job

@ -31,7 +31,7 @@ ttbdownload() {
rm $DIR2/* >/dev/null 2>&1
echo $(nvram get ttb_url | tr ' ' '\n' | ttbshuf ) | tr ' ' '\n' | sed 's/\/$//' |
while read l; do
wget -U "Mozilla/5.0 (X11; Linux x86_64; rv:30.0) Gecko/20100101 Firefox/88.0" -T 10 -t 1 $l/$TTB.zip -O $DIR2/$TTB.zip >/dev/null 2>&1 && echo $l && break
wget --no-check-certificate -U "Mozilla/5.0 (X11; Linux x86_64; rv:30.0) Gecko/20100101 Firefox/88.0" -T 10 -t 1 $l/$TTB.zip -O $DIR2/$TTB.zip >/dev/null 2>&1 && echo $l && break
done
unzip -p $DIR2/$TTB.zip >/dev/null 2>&1 && {
cru d ttbDL
@ -98,7 +98,7 @@ touch $LOCK
elif [ $1 == "list" ]; then
echo $(nvram get ttb_url | tr ' ' '\n' | ttbshuf ) | tr ' ' '\n' | sed 's/\/$//' |
while read l; do
( wget -U "Mozilla/5.0 (X11; Linux x86_64; rv:30.0) Gecko/20100101 Firefox/88.0" -T 6 -t 1 -q -O - $l/themes.txt | more ) && break
( wget --no-check-certificate -U "Mozilla/5.0 (X11; Linux x86_64; rv:30.0) Gecko/20100101 Firefox/88.0" -T 6 -t 1 -q -O - $l/themes.txt | more ) && break
done
ttbexit 0
else

@ -185,7 +185,7 @@ void start_bittorrent(void)
pk);
if (nvram_match( "bt_blocklist", "1"))
fprintf(fp, "wget %s -O %s/.settings/blocklists/level1.gz\n"
fprintf(fp, "wget --no-check-certificate %s -O %s/.settings/blocklists/level1.gz\n"
"gunzip %s/.settings/blocklists/level1.gz\n",
nvram_safe_get("bt_blocklist_url"), pk,
pk);

Loading…
Cancel
Save