[Pkg-privacy-commits] [vidalia] 06/160: Updated a bunch of files to add new debconf question to existing debconf prompt. This allows users to disable and re-enable Tor's ability to start at boot.

Ximin Luo infinity0 at moszumanska.debian.org
Sat Aug 22 13:13:53 UTC 2015


This is an automated email from the git hooks/post-receive script.

infinity0 pushed a commit to branch master
in repository vidalia.

commit 0d4c8ddbed543b8b8cdb3e0859a980b78ac35335
Author: Erinn Clark <erinn at torproject.org>
Date:   Sun Apr 4 20:39:09 2010 -0700

    Updated a bunch of files to add new debconf question to existing debconf prompt. This allows users to disable and re-enable Tor's ability to start at boot.
---
 debian/0.2.x/README.Debian   | 28 +++++++++-------------------
 debian/0.2.x/changelog       |  7 +++++++
 debian/0.2.x/config          | 20 +++++++++++++++++---
 debian/0.2.x/control         |  6 +++---
 debian/0.2.x/default.tor-off |  3 +++
 debian/0.2.x/default.tor-on  |  1 +
 debian/0.2.x/postrm          | 14 ++++++++++++++
 debian/0.2.x/templates       | 12 +++---------
 debian/0.2.x/vidalia.install |  2 ++
 9 files changed, 59 insertions(+), 34 deletions(-)

diff --git a/debian/0.2.x/README.Debian b/debian/0.2.x/README.Debian
index 8fd686e..1754d24 100644
--- a/debian/0.2.x/README.Debian
+++ b/debian/0.2.x/README.Debian
@@ -4,28 +4,15 @@ Vidalia for Debian
 There are currently two ways of communication supported between 
 Tor daemon (carried with 'tor' package), and Vidalia interface:
 
-1. Letting Vidalia start Tor process by its own.
+1. Letting Vidalia start Tor process on its own.
    ---------------------------------------------
 
  This is default option on debconf while configuring vidalia package
  (easy reconfigurable by running 'dpkg-reconfigure vidalia').
 
- This option implies that you have to manually disable Tor 
-  starting automatically on every reboot, as shown below:
-
- # update-rc.d -f tor remove
-  Removing any system startup links for /etc/init.d/tor ...
-    /etc/rc0.d/K20tor
-    /etc/rc1.d/K20tor
-    /etc/rc2.d/S20tor
-    /etc/rc3.d/S20tor
-    /etc/rc4.d/S20tor
-    /etc/rc5.d/S20tor
-    /etc/rc6.d/K20tor
-
- You can create all the symlinks back by using:
- # update-rc.d tor defaults
-
+ This is now handled in the debconf front-end to Vidalia. If you decide you no
+ longer wish to have Vidalia control Tor, and want to re-enable Tor's ability to
+ start when your machine boots, dpkg-reconfigure vidalia and choose 'no'.
 
 2. Enable Tor to use a control port to communicate with Vidalia.
    -------------------------------------------------------------
@@ -35,8 +22,10 @@ Tor daemon (carried with 'tor' package), and Vidalia interface:
  and adding the proper value to 'HashedControlPassword', as shown below:
  
  # tor --hash-password SOME_PASSWORD_HERE
- Sep 17 18:48:49.421 [notice] Tor v0.2.0.30 (r15956). This is experimental software. Do not rely on it for strong anonymity. (Running on Linux x86_64)
- 16:167F667A98F859D2600BD708B48B95343FEF7800B479E2AA4284ACF029
+ Sep 17 18:48:49.421 [notice] Tor v0.2.0.30 (r15956). This is experimental
+ software. Do not rely on it for strong anonymity. (Running on Linux x86_64)
+ 
+16:167F667A98F859D2600BD708B48B95343FEF7800B479E2AA4284ACF029
 
  You will have to have something like this:
  
@@ -51,3 +40,4 @@ Tor daemon (carried with 'tor' package), and Vidalia interface:
 
 
  -- Ulises Vitulli <uvitulli at fi.uba.ar>  Wed, 17 Sep 2008 17:24:06 -0300
+ (Updated by Erinn Clark <erinn at torproject.org>  Sun, 04 Apr 2010 20:16:07 -0700)
diff --git a/debian/0.2.x/changelog b/debian/0.2.x/changelog
index 6ec00c4..1dbc5fa 100644
--- a/debian/0.2.x/changelog
+++ b/debian/0.2.x/changelog
@@ -1,3 +1,10 @@
+vidalia (0.2.7-2) unstable; urgency=low
+
+  * Add option to debconf question to disable Tor on boot in concert with Tor's
+    recent sourcing of /etc/default/tor.vidalia. (Closes: #542671)
+
+ -- Erinn Clark <erinn at torproject.org>  Sun, 04 Apr 2010 20:16:07 -0700
+
 vidalia (0.2.7-1) unstable; urgency=low
 
   * New upstream release (Closes: #566931).
diff --git a/debian/0.2.x/config b/debian/0.2.x/config
index 90e4c2d..b50e7ff 100644
--- a/debian/0.2.x/config
+++ b/debian/0.2.x/config
@@ -21,9 +21,23 @@ if [ "$1" = "configure" ] || [ "$1" = "reconfigure" ]; then
                 # and already running
                 askuser
                 seen='true'
-                if [ "$RET" = "true" ]; then
-                    invoke-rc.d --force tor stop
-                fi
+		case "$RET" in
+			(no)
+			if [ -x /etc/default/tor.vidalia ]; then
+			ucf --debconf-ok --three-way /usr/share/vidalia/default.tor-on /etc/default/tor.vidalia
+			fi
+		;;
+			(yes-now) 
+                    	invoke-rc.d --force tor stop
+			if [ -x /etc/default/tor.vidalia ]; then
+			ucf --debconf-ok --three-way /usr/share/vidalia/default.tor-on /etc/default/tor.vidalia
+			fi
+		;;
+			(yes-always)
+			invoke-rc.d --force tor stop
+			ucf --debconf-ok --three-way /usr/share/vidalia/default.tor-off /etc/default/tor.vidalia
+		;;
+		esac
             fi
         fi
 
diff --git a/debian/0.2.x/control b/debian/0.2.x/control
index fed6be9..a25d506 100644
--- a/debian/0.2.x/control
+++ b/debian/0.2.x/control
@@ -2,14 +2,14 @@ Source: vidalia
 Section: net
 Priority: extra
 Maintainer: Vern Sun <s5unty at gmail.com>
-Uploaders: Ulises Vitulli <uvitulli at fi.uba.ar>
+Uploaders: Ulises Vitulli <uvitulli at fi.uba.ar>, Erinn Clark <erinn at torproject.org>
 Build-Depends: debhelper (>= 5), autotools-dev, libqt4-dev (>= 4.1.0), po-debconf (>= 1.0), cmake (>= 2.4.8), libssl-dev (>= 0.9.8g), quilt
-Standards-Version: 3.8.3
+Standards-Version: 3.8.4
 Homepage: http://www.vidalia-project.net
 
 Package: vidalia
 Architecture: any
-Depends: ${shlibs:Depends}, ${misc:Depends}, debconf (>=1.5.11) | debconf-2.0
+Depends: ${shlibs:Depends}, ${misc:Depends}, debconf (>=1.5.11) | debconf-2.0, ucf 
 Recommends: tor
 Suggests: iceweasel-torbutton
 Description: controller GUI for the Tor software
diff --git a/debian/0.2.x/default.tor-off b/debian/0.2.x/default.tor-off
new file mode 100644
index 0000000..3e6dae2
--- /dev/null
+++ b/debian/0.2.x/default.tor-off
@@ -0,0 +1,3 @@
+if [ -x /usr/bin/vidalia ]; then
+	RUN_DAEMON=no
+fi
diff --git a/debian/0.2.x/default.tor-on b/debian/0.2.x/default.tor-on
new file mode 100644
index 0000000..1e0ca6a
--- /dev/null
+++ b/debian/0.2.x/default.tor-on
@@ -0,0 +1 @@
+# 
diff --git a/debian/0.2.x/postrm b/debian/0.2.x/postrm
new file mode 100644
index 0000000..b3aa626
--- /dev/null
+++ b/debian/0.2.x/postrm
@@ -0,0 +1,14 @@
+#!/bin/sh
+set -e
+
+#DEBHELPER#
+
+if [ "$1" = "purge" ]; then
+  echo " Removing /etc/default/tor.vidalia"
+  rm -f /etc/default/tor.vidalia
+  if [ -x "/usr/bin/ucf" ]; then
+    ucf --purge /etc/default/tor.vidalia
+  fi
+fi
+
+exit 0
diff --git a/debian/0.2.x/templates b/debian/0.2.x/templates
index bfb5735..c27990c 100644
--- a/debian/0.2.x/templates
+++ b/debian/0.2.x/templates
@@ -1,11 +1,5 @@
 Template: vidalia/info
-Type: boolean
-Default: true
+Type: select
+Choices-C: no, yes-now, yes-always
 _Description: Do you want to stop the existing Tor process and let Vidalia start Tor?
- It looks like there is a Tor process already running. If you want to start Tor
- using Vidalia, you might have to stop the existing Tor process. Otherwise you
- will have to enable 'ControlPort' option into Tor as explained in the documentation 
- carried with this package ('/usr/share/doc/vidalia/README.Debian').
- .
- Note that if you choose to let Vidalia start Tor, you will have to manually disable 
- Tor starting automatically on every reboot (See 'README.Debian').
+__Choices: No, Yes (just for now), Yes (and disable it for every boot)
diff --git a/debian/0.2.x/vidalia.install b/debian/0.2.x/vidalia.install
index 081729d..4919049 100644
--- a/debian/0.2.x/vidalia.install
+++ b/debian/0.2.x/vidalia.install
@@ -1,2 +1,4 @@
 debian/vidalia.xpm usr/share/pixmaps
 debian/vidalia.desktop usr/share/applications
+debian/default.tor-on usr/share/vidalia
+debian/default.tor-off usr/share/vidalia

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-privacy/packages/vidalia.git



More information about the Pkg-privacy-commits mailing list