From 32d52faf9fbb817592105fca2159eb91896e968b Mon Sep 17 00:00:00 2001 From: Bob Mottram Date: Thu, 25 Jan 2018 12:17:37 +0000 Subject: [PATCH] Install tor daemon from backports --- src/freedombone-app-xmpp | 2 +- src/freedombone-image-customise | 2 +- src/freedombone-upgrade | 6 ++++++ src/freedombone-utils-onion | 2 +- 4 files changed, 9 insertions(+), 3 deletions(-) diff --git a/src/freedombone-app-xmpp b/src/freedombone-app-xmpp index 7cc33b4f..0a853c4d 100755 --- a/src/freedombone-app-xmpp +++ b/src/freedombone-app-xmpp @@ -17,7 +17,7 @@ # License # ======= # -# Copyright (C) 2014-2017 Bob Mottram +# Copyright (C) 2014-2018 Bob Mottram # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU Affero General Public License as published by diff --git a/src/freedombone-image-customise b/src/freedombone-image-customise index fa399cd8..7e9410b3 100755 --- a/src/freedombone-image-customise +++ b/src/freedombone-image-customise @@ -909,7 +909,7 @@ initialise_mesh() { chroot "$rootdir" apt-get -yq install apt-transport-https # install tor as a possible way of routing traffic between internet gateways - chroot "$rootdir" apt-get -yq install tor + chroot "$rootdir" apt-get -yq -t stretch-backports install tor # dhcp daemon for hotspot on secondary wifi adapter chroot "$rootdir" apt-get -yq install dnsmasq diff --git a/src/freedombone-upgrade b/src/freedombone-upgrade index 50a73033..35ad41e4 100755 --- a/src/freedombone-upgrade +++ b/src/freedombone-upgrade @@ -97,6 +97,12 @@ if [ -d $PROJECT_DIR ]; then email_install_tls email_disable_chunking #defrag_filesystem + + # reinstall tor from backports + tor_version=$(tor --version) + if [[ "$tor_version" == *' 0.2'* ]]; then + apt-get -yq -t stretch-backports install tor + fi fi fi diff --git a/src/freedombone-utils-onion b/src/freedombone-utils-onion index e90a3ab5..83d5338d 100755 --- a/src/freedombone-utils-onion +++ b/src/freedombone-utils-onion @@ -270,7 +270,7 @@ function install_tor { return fi - apt-get -yq install tor + apt-get -yq -t stretch-backports install tor if [ ! -f /etc/tor/torrc ]; then echo 'Tor failed to install' exit 38259