summaryrefslogtreecommitdiffhomepage
path: root/debian
diff options
context:
space:
mode:
authorMatt Johnston <matt@ucc.asn.au>2004-06-01 02:46:09 +0000
committerMatt Johnston <matt@ucc.asn.au>2004-06-01 02:46:09 +0000
commit674a60748884dc55ee7091b7c23a41240e75f73c (patch)
tree3b5a173c356f867b94df3873b57ff36d33129ea7 /debian
Makefile.in contains updated files required
--HG-- extra : convert_revision : cc8a8c49dc70e632c352853a39801089b08149be
Diffstat (limited to 'debian')
-rw-r--r--debian/README.Debian41
-rw-r--r--debian/changelog79
-rw-r--r--debian/compat1
-rw-r--r--debian/conffiles0
-rw-r--r--debian/control14
-rw-r--r--debian/copyright.in9
-rw-r--r--debian/dirs2
-rw-r--r--debian/docs2
-rw-r--r--debian/dropbear.default0
-rw-r--r--debian/dropbear.init78
-rw-r--r--debian/postinst90
-rw-r--r--debian/postrm45
-rw-r--r--debian/rules134
13 files changed, 495 insertions, 0 deletions
diff --git a/debian/README.Debian b/debian/README.Debian
new file mode 100644
index 0000000..8cdac38
--- /dev/null
+++ b/debian/README.Debian
@@ -0,0 +1,41 @@
+Dropbear for Debian
+-------------------
+
+This package will attempt to listen on port 22. If the OpenSSH
+package ("ssh") is installed, the file /etc/default/dropbear
+will be set up so that the server does not start by default.
+
+You can run Dropbear concurrently with OpenSSH 'sshd' by
+modifying /etc/default/dropbear so that "NO_START" is set to
+"0" and changing the port number that Dropbear runs on. Follow
+the instructions in the file.
+
+This package suggests you install the "ssh" package. This package
+provides the "ssh" client program, as well as the "/usr/bin/scp"
+binary you will need to be able to retrieve files from a server
+running Dropbear via SCP.
+
+Replacing OpenSSH "sshd" with Dropbear
+--------------------------------------
+
+You will still want to have the "ssh" package installed, as it
+provides the "ssh" and "scp" binaries. When you install this
+package, it checks for existing OpenSSH host keys and if found,
+converts them to the Dropbear format.
+
+If this appears to have worked, you should be able to change over
+by following these steps:
+
+1. Stop the OpenSSH server
+ % /etc/init.d/ssh stop
+2. Prevent the OpenSSH server from starting in the future
+ % touch /etc/ssh/sshd_not_to_be_run
+3. Modify the Dropbear defaults file, set NO_START to 0 and
+ ensure DROPBEAR_PORT is set to 22.
+ % editor /etc/default/dropbear
+4. Restart the Dropbear server.
+ % /etc/init.d/dropbear restart
+
+See the Dropbear homepage for more information:
+ http://matt.ucc.asn.au/dropbear/dropbear.html
+
diff --git a/debian/changelog b/debian/changelog
new file mode 100644
index 0000000..cb7253f
--- /dev/null
+++ b/debian/changelog
@@ -0,0 +1,79 @@
+dropbear (0.41-1) unstable; urgency=low
+
+ * Updated to 0.41 release.
+ * Various minor fixes
+
+ -- Matt Johnston <matt@ucc.asn.au> Mon, 19 Jan 2004 23:20:54 +0800
+
+dropbear (0.39-1) unstable; urgency=low
+
+ * updated to 0.39 release. Some new features, some bugfixes.
+
+ -- Matt Johnston <matt@ucc.asn.au> Tue, 16 Dec 2003 16:20:54 +0800
+
+dropbear (0.38-1) unstable; urgency=medium
+
+ * updated to 0.38 release - various important bugfixes
+
+ -- Matt Johnston <matt@ucc.asn.au> Sat, 11 Oct 2003 16:28:54 +0800
+
+dropbear (0.37-1) unstable; urgency=medium
+
+ * updated to 0.37 release - various important bugfixes
+
+ -- Matt Johnston <matt@ucc.asn.au> Wed, 24 Sept 2003 19:43:54 +0800
+
+dropbear (0.36-1) unstable; urgency=high
+
+ * updated to 0.36 release - various important bugfixes
+
+ -- Matt Johnston <matt@ucc.asn.au> Tues, 19 Aug 2003 12:20:54 +0800
+
+dropbear (0.35-1) unstable; urgency=high
+
+ * updated to 0.35 release - contains fix for remotely exploitable
+ vulnerability.
+
+ -- Matt Johnston <matt@ucc.asn.au> Sun, 17 Aug 2003 05:37:47 +0800
+
+dropbear (0.34-1) unstable; urgency=medium
+
+ * updated to 0.34 release
+
+ -- Matt Johnston <matt@ucc.asn.au> Fri, 15 Aug 2003 15:10:00 +0800
+
+dropbear (0.33-1) unstable; urgency=medium
+
+ * updated to 0.33 release
+
+ -- Matt Johnston <matt@ucc.asn.au> Sun, 22 Jun 2003 22:22:00 +0800
+
+dropbear (0.32cvs-1) unstable; urgency=medium
+
+ * now maintained in UCC CVS
+ * debian/copyright.in file added, generated from LICENSE
+
+ -- Grahame Bowland <grahame@angrygoats.net> Tue, 21 Jun 2003 17:57:02 +0800
+
+dropbear (0.32cvs-1) unstable; urgency=medium
+
+ * sync with CVS
+ * fixes X crash bug
+
+ -- Grahame Bowland <grahame@angrygoats.net> Tue, 20 Jun 2003 15:04:47 +0800
+
+dropbear (0.32-2) unstable; urgency=low
+
+ * fix creation of host keys to use correct names in /etc/dropbear
+ * init script "restart" function fixed
+ * purging this package now deletes the host keys and /etc/dropbear
+ * change priority in debian/control to 'standard'
+
+ -- Grahame Bowland <grahame@angrygoats.net> Tue, 17 Jun 2003 15:04:47 +0800
+
+dropbear (0.32-1) unstable; urgency=low
+
+ * Initial Release.
+
+ -- Grahame Bowland <grahame@angrygoats.net> Tue, 17 Jun 2003 15:04:47 +0800
+
diff --git a/debian/compat b/debian/compat
new file mode 100644
index 0000000..b8626c4
--- /dev/null
+++ b/debian/compat
@@ -0,0 +1 @@
+4
diff --git a/debian/conffiles b/debian/conffiles
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/debian/conffiles
diff --git a/debian/control b/debian/control
new file mode 100644
index 0000000..e528454
--- /dev/null
+++ b/debian/control
@@ -0,0 +1,14 @@
+Source: dropbear
+Section: net
+Priority: standard
+Maintainer: Grahame Bowland <grahame@angrygoats.net>
+Build-Depends: debhelper (>> 4.0.0), zlib1g-dev
+Standards-Version: 3.5.8
+
+Package: dropbear
+Architecture: any
+Depends: ${shlibs:Depends} ${misc:Depends}
+Suggests: ssh
+Description: a minimal SSH2 server
+ A small secure shell version 2 server.
+
diff --git a/debian/copyright.in b/debian/copyright.in
new file mode 100644
index 0000000..015d9ab
--- /dev/null
+++ b/debian/copyright.in
@@ -0,0 +1,9 @@
+This package was debianized by Grahame Bowland <grahame.angrygoats.net> on
+Tue, 17 Jun 2003 15:04:47 +0800.
+
+It was downloaded from http://matt.ucc.asn.au/dropbear/
+
+Upstream Author(s): Matt Johnston <matt@ucc.asn.au>
+
+Copyright:
+
diff --git a/debian/dirs b/debian/dirs
new file mode 100644
index 0000000..ca882bb
--- /dev/null
+++ b/debian/dirs
@@ -0,0 +1,2 @@
+usr/bin
+usr/sbin
diff --git a/debian/docs b/debian/docs
new file mode 100644
index 0000000..724e084
--- /dev/null
+++ b/debian/docs
@@ -0,0 +1,2 @@
+README
+TODO
diff --git a/debian/dropbear.default b/debian/dropbear.default
new file mode 100644
index 0000000..e69de29
--- /dev/null
+++ b/debian/dropbear.default
diff --git a/debian/dropbear.init b/debian/dropbear.init
new file mode 100644
index 0000000..25eda9f
--- /dev/null
+++ b/debian/dropbear.init
@@ -0,0 +1,78 @@
+#! /bin/sh
+#
+# skeleton example file to build /etc/init.d/ scripts.
+# This file should be used to construct scripts for /etc/init.d.
+#
+# Written by Miquel van Smoorenburg <miquels@cistron.nl>.
+# Modified for Debian
+# by Ian Murdock <imurdock@gnu.ai.mit.edu>.
+#
+# Version: @(#)skeleton 1.9 26-Feb-2001 miquels@cistron.nl
+#
+
+#
+# Do not configure this file. Edit /etc/default/dropbear instead!
+#
+
+PATH=/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin
+DAEMON=/usr/sbin/dropbear
+NAME=dropbear
+DESC="Dropbear SSH server"
+
+DROPBEAR_PORT=22
+DROPBEAR_EXTRA_ARGS=
+NO_START=0
+set -e
+test -f /etc/default/dropbear && . /etc/default/dropbear
+
+if [ -n "$DROPBEAR_BANNER" ]; then
+ DROPBEAR_EXTRA_ARGS="$DROPBEAR_EXTRA_ARGS -b $DROPBEAR_BANNER"
+fi
+
+if [ -z "$DROPBEAR_RSAKEY" ]; then
+ DROPBEAR_RSAKEY="/etc/dropbear/dropbear_rsa_host_key"
+fi
+
+if [ -z "$DROPBEAR_DSSKEY" ]; then
+ DROPBEAR_DSSKEY="/etc/dropbear/dropbear_dss_host_key"
+fi
+
+test "$NO_START" != "0" && exit 0
+
+test -x $DAEMON || exit 0
+
+case "$1" in
+ start)
+ echo -n "Starting $DESC: "
+ start-stop-daemon --start --quiet --pidfile /var/run/$NAME.pid \
+ --exec $DAEMON -- -d $DROPBEAR_DSSKEY -r $DROPBEAR_RSAKEY -p $DROPBEAR_PORT $DROPBEAR_EXTRA_ARGS
+ echo "$NAME."
+ ;;
+ stop)
+ echo -n "Stopping $DESC: "
+ start-stop-daemon --stop --quiet --oknodo --pidfile /var/run/$NAME.pid
+ echo "$NAME."
+ ;;
+ restart|force-reload)
+ #
+ # If the "reload" option is implemented, move the "force-reload"
+ # option to the "reload" entry above. If not, "force-reload" is
+ # just the same as "restart".
+ #
+ echo -n "Restarting $DESC: "
+ start-stop-daemon --stop --quiet --oknodo --pidfile \
+ /var/run/$NAME.pid
+ sleep 1
+ start-stop-daemon --start --quiet --pidfile /var/run/$NAME.pid \
+ --exec $DAEMON -- -d $DROPBEAR_DSSKEY -r $DROPBEAR_RSAKEY -p $DROPBEAR_PORT $DROPBEAR_EXTRA_ARGS
+ echo "$NAME."
+ ;;
+ *)
+ N=/etc/init.d/$NAME
+ # echo "Usage: $N {start|stop|restart|reload|force-reload}" >&2
+ echo "Usage: $N {start|stop|restart|force-reload}" >&2
+ exit 1
+ ;;
+esac
+
+exit 0
diff --git a/debian/postinst b/debian/postinst
new file mode 100644
index 0000000..010618d
--- /dev/null
+++ b/debian/postinst
@@ -0,0 +1,90 @@
+#! /bin/sh
+# postinst script for #PACKAGE#
+#
+# see: dh_installdeb(1)
+
+set -e
+
+# summary of how this script can be called:
+# * <postinst> `configure' <most-recently-configured-version>
+# * <old-postinst> `abort-upgrade' <new version>
+# * <conflictor's-postinst> `abort-remove' `in-favour' <package>
+# <new-version>
+# * <deconfigured's-postinst> `abort-deconfigure' `in-favour'
+# <failed-install-package> <version> `removing'
+# <conflicting-package> <version>
+# for details, see http://www.debian.org/doc/debian-policy/ or
+# the debian-policy package
+#
+# quoting from the policy:
+# Any necessary prompting should almost always be confined to the
+# post-installation script, and should be protected with a conditional
+# so that unnecessary prompting doesn't happen if a package's
+# installation fails and the `postinst' is called with `abort-upgrade',
+# `abort-remove' or `abort-deconfigure'.
+
+case "$1" in
+ configure)
+ if [ ! -e /etc/dropbear/dropbear_rsa_host_key ]; then
+ if [ -f /etc/ssh/ssh_host_rsa_key ]; then
+ echo "Converting existing OpenSSH RSA host key to Dropbear format."
+ /usr/bin/dropbearconvert openssh dropbear /etc/ssh/ssh_host_rsa_key /etc/dropbear/dropbear_rsa_host_key
+ else
+ echo "Generating Dropbear RSA key. Please wait."
+ /usr/bin/dropbearkey -t rsa -f /etc/dropbear/dropbear_rsa_host_key
+ fi
+ fi
+ if [ ! -e /etc/dropbear/dropbear_dss_host_key ]; then
+ if [ -f /etc/ssh/ssh_host_dsa_key ]; then
+ echo "Converting existing OpenSSH RSA host key to Dropbear format."
+ /usr/bin/dropbearconvert openssh dropbear /etc/ssh/ssh_host_dsa_key /etc/dropbear/dropbear_dss_host_key
+ else
+ echo "Generating Dropbear DSS key. Please wait."
+ /usr/bin/dropbearkey -t dss -f /etc/dropbear/dropbear_dss_host_key
+ fi
+ fi
+ if [ ! -s /etc/default/dropbear ]; then
+ # check whether OpenSSH seems to be installed.
+ if dpkg -l ssh >/dev/null 2>&1; then
+ echo "OpenSSH appears to be installed. Setting /etc/default/dropbear"
+ echo "so that Dropbear will not start by default. Edit this file to change"
+ echo "this behaviour."
+ echo "# disabled because OpenSSH is installed, change to NO_START=0 to enable Dropbear" > /etc/default/dropbear
+ echo "NO_START=1" >> /etc/default/dropbear
+ fi
+ echo "# the TCP port that Dropbear listens on" >> /etc/default/dropbear
+ echo "DROPBEAR_PORT=22" >> /etc/default/dropbear
+ echo "# any additional arguments for Dropbear" >> /etc/default/dropbear
+ echo "DROPBEAR_EXTRA_ARGS=" >> /etc/default/dropbear
+ echo "# specify an optional banner file containing a message to be" >> /etc/default/dropbear
+ echo "# sent to clients before they connect, such as \"/etc/issue.net\"" >> /etc/default/dropbear
+ echo "DROPBEAR_BANNER=\"\"" >> /etc/default/dropbear
+ echo "# RSA hostkey file (default: /etc/dropbear/dropbear_rsa_host_key" >> /etc/default/dropbear
+ echo "#DROPBEAR_RSAKEY=\"/etc/dropbear/dropbear_rsa_host_key\"" >> /etc/default/dropbear
+ echo "# DSS hostkey file (default: /etc/dropbear/dropbear_dss_host_key" >> /etc/default/dropbear
+ echo "#DROPBEAR_DSSKEY=\"/etc/dropbear/dropbear_dss_host_key\"" >> /etc/default/dropbear
+ fi
+ if [ -e /etc/init.d/dropbear ]; then
+ update-rc.d dropbear defaults >/dev/null
+ /etc/init.d/dropbear restart
+ fi
+ ;;
+
+ abort-upgrade|abort-remove|abort-deconfigure)
+
+ ;;
+
+ *)
+ echo "postinst called with unknown argument \`$1'" >&2
+ exit 1
+ ;;
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+
+
+exit 0
+
+
diff --git a/debian/postrm b/debian/postrm
new file mode 100644
index 0000000..da11dc4
--- /dev/null
+++ b/debian/postrm
@@ -0,0 +1,45 @@
+#! /bin/sh
+# postrm script for #PACKAGE#
+#
+# see: dh_installdeb(1)
+
+set -e
+
+# summary of how this script can be called:
+# * <postrm> `remove'
+# * <postrm> `purge'
+# * <old-postrm> `upgrade' <new-version>
+# * <new-postrm> `failed-upgrade' <old-version>
+# * <new-postrm> `abort-install'
+# * <new-postrm> `abort-install' <old-version>
+# * <new-postrm> `abort-upgrade' <old-version>
+# * <disappearer's-postrm> `disappear' <r>overwrit>r> <new-version>
+# for details, see http://www.debian.org/doc/debian-policy/ or
+# the debian-policy package
+
+
+case "$1" in
+ purge|remove|upgrade|failed-upgrade|abort-install|abort-upgrade|disappear)
+ if [ "$1" = "purge" ]
+ then
+ if [ -e /etc/dropbear ]; then
+ rm -f /etc/dropbear/dropbear_rsa_host_key
+ rm -f /etc/dropbear/dropbear_dss_host_key
+ rmdir --ignore-fail-on-non-empty /etc/dropbear
+ fi
+ update-rc.d dropbear remove >/dev/null
+ fi
+ ;;
+
+ *)
+ echo "postrm called with unknown argument \`$1'" >&2
+ exit 1
+
+esac
+
+# dh_installdeb will replace this with shell code automatically
+# generated by other debhelper scripts.
+
+#DEBHELPER#
+
+exit 0
diff --git a/debian/rules b/debian/rules
new file mode 100644
index 0000000..4d73093
--- /dev/null
+++ b/debian/rules
@@ -0,0 +1,134 @@
+#!/usr/bin/make -f
+# Sample debian/rules that uses debhelper.
+# GNU copyright 1997 to 1999 by Joey Hess.
+#
+# Modified to make a template file for a multi-binary package with separated
+# build-arch and build-indep targets by Bill Allombert 2001
+
+# Uncomment this to turn on verbose mode.
+#export DH_VERBOSE=1
+
+# This has to be exported to make some magic below work.
+export DH_OPTIONS
+
+# These are used for cross-compiling and for saving the configure script
+# from having to guess our platform (since we know it already)
+DEB_HOST_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_HOST_GNU_TYPE)
+DEB_BUILD_GNU_TYPE ?= $(shell dpkg-architecture -qDEB_BUILD_GNU_TYPE)
+
+
+CFLAGS = -Wall -g
+
+ifneq (,$(findstring noopt,$(DEB_BUILD_OPTIONS)))
+ CFLAGS += -O0
+else
+ CFLAGS += -O2
+endif
+ifeq (,$(findstring nostrip,$(DEB_BUILD_OPTIONS)))
+ INSTALL_PROGRAM += -s
+endif
+
+config.status: configure
+ dh_testdir
+ # Add here commands to configure the package.
+ CFLAGS='-DSFTPSERVER_PATH="\"/usr/lib/sftp-server\""' ./configure --host=$(DEB_HOST_GNU_TYPE) --build=$(DEB_BUILD_GNU_TYPE) --prefix=/usr --mandir=\$${prefix}/share/man --infodir=\$${prefix}/share/info
+
+
+#Architecture
+build: build-arch #build-indep
+
+build-arch: build-arch-stamp
+build-arch-stamp: config.status
+
+ # Add here commands to compile the arch part of the package.
+ $(MAKE) CC=gcc LD=gcc
+
+build-indep: build-indep-stamp
+build-indep-stamp: config.status
+
+ # Add here commands to compile the indep part of the package.
+ #$(MAKE) doc
+
+clean:
+ dh_testdir
+ dh_testroot
+ rm -f build-arch-stamp build-indep-stamp config-stamp
+
+ # Add here commands to clean up after the build process.
+ -$(MAKE) clean
+ifneq "$(wildcard /usr/share/misc/config.sub)" ""
+ cp -f /usr/share/misc/config.sub config.sub
+endif
+ifneq "$(wildcard /usr/share/misc/config.guess)" ""
+ cp -f /usr/share/misc/config.guess config.guess
+endif
+
+
+ dh_clean
+
+install: install-indep install-arch
+install-indep:
+ dh_testdir
+ dh_testroot
+ dh_clean -k -i
+ dh_installdirs -i
+
+ # Add here commands to install the indep part of the package into
+ # debian/<package>-doc.
+ #INSTALLDOC#
+
+ dh_install -i
+
+install-arch:
+ dh_testdir
+ dh_testroot
+ dh_clean -k -a
+ dh_installdirs -a
+ dh_installdirs /etc/dropbear
+
+ # Add here commands to install the arch part of the package into
+ # debian/tmp.
+ $(MAKE) install prefix=$(CURDIR)/debian/dropbear/usr
+
+ dh_install -a
+# Must not depend on anything. This is to be called by
+# binary-arch/binary-multi
+# in another 'make' thread.
+binary-common:
+ cat $(CURDIR)/debian/copyright.in $(CURDIR)/LICENSE > $(CURDIR)/debian/copyright
+ dh_testdir
+ dh_testroot
+ dh_installchangelogs CHANGES
+ dh_installdocs
+ dh_installexamples
+# dh_installmenu
+# dh_installdebconf
+# dh_installlogrotate
+# dh_installemacsen
+# dh_installpam
+# dh_installmime
+ dh_installinit
+# dh_installcron
+# dh_installinfo
+ dh_installman
+ dh_link
+ dh_strip
+ dh_compress
+ dh_fixperms
+# dh_perl
+# dh_python
+ dh_makeshlibs
+ dh_installdeb
+ dh_gencontrol
+ dh_md5sums
+ dh_builddeb
+# Build architecture independant packages using the common target.
+binary-indep: build-indep install-indep
+ $(MAKE) -f debian/rules DH_OPTIONS=-i binary-common
+
+# Build architecture dependant packages using the common target.
+binary-arch: build-arch install-arch
+ $(MAKE) -f debian/rules DH_OPTIONS=-a binary-common
+
+binary: binary-arch #binary-indep
+.PHONY: build clean binary-indep binary-arch binary install install-indep install-arch