Require https for f-droid.org prebuilt downloads

When fetching prebuilt binaries from f-droid.org, we were using http,
but are now redirected to a https URI - unless a MITM attacker gets
there first...

Change to unconditionally use https to fetch prebuilt binaries.

While here, set -e so that failure to download any file is not ignored.
This commit is contained in:
Steven Chamberlain 2015-07-31 19:44:59 +01:00 committed by Paul Kocialkowski
parent 5e4e0a171c
commit e3cca288ad

View File

@ -1,12 +1,13 @@
#!/bin/sh
set -e
BASEDIR=$( dirname $0 )
mkdir -p $BASEDIR/prebuilt/common/apps/
# F-Droid
curl -L -o $BASEDIR/prebuilt/common/apps/FDroid.apk -O -L http://f-droid.org/FDroid.apk
curl -L -o $BASEDIR/prebuilt/common/apps/FDroid.apk -O -L https://f-droid.org/FDroid.apk
# Terminal Emulator
curl -L -o $BASEDIR/prebuilt/common/apps/TerminalEmulator.apk -O -L http://f-droid.org/repo/jackpal.androidterm_71.apk
curl -L -o $BASEDIR/prebuilt/common/apps/TerminalEmulator.apk -O -L https://f-droid.org/repo/jackpal.androidterm_71.apk
unzip -o -d $BASEDIR/prebuilt/common/apps/ $BASEDIR/prebuilt/common/apps/TerminalEmulator.apk lib/armeabi/libjackpal-termexec2.so lib/armeabi/libjackpal-androidterm5.so