--- rsh-redone-85.orig/Makefile +++ rsh-redone-85/Makefile @@ -19,22 +19,22 @@ all: $(BIN) $(SBIN) rlogin: rlogin.c - $(CC) $(CFLAGS) -o $@ $< + $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -o $@ $< in.rlogind: rlogind.c - $(CC) $(CFLAGS) -lutil -lpam -o $@ $< + $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -o $@ $< -lutil -lpam rsh: rsh.c - $(CC) $(CFLAGS) -o $@ $< + $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -o $@ $< in.rshd: rshd.c - $(CC) $(CFLAGS) -lpam -o $@ $< + $(CC) $(CPPFLAGS) $(CFLAGS) $(LDFLAGS) -o $@ $< -lpam install: install-bin install-sbin install-man install-pam install-bin: $(BIN) mkdir -p $(DESTDIR)$(BINDIR) - $(INSTALL) -m 4711 $(BIN) $(DESTDIR)$(BINDIR)/ + $(INSTALL) -m 4755 $(BIN) $(DESTDIR)$(BINDIR)/ install-sbin: $(SBIN) mkdir -p $(DESTDIR)$(SBINDIR) --- rsh-redone-85.orig/debian/changelog +++ rsh-redone-85/debian/changelog @@ -0,0 +1,127 @@ +rsh-redone (85-2build1) bionic; urgency=high + + * No change rebuild to pick up -fPIE compiler default + + -- Balint Reczey Tue, 03 Apr 2018 12:42:15 +0000 + +rsh-redone (85-2) unstable; urgency=low + + * Bump Standards-Version. + * Apply patch from Colin Watson fixing the order in which the libraries are + linked. Closes: #641408 + * Enable hardening flags. + * Depend on ${misc:Depends}. + * Leave read permissions on the setuid binaries. + * Add lintian overrides for the setuid binaries. + + -- Guus Sliepen Thu, 21 Feb 2013 12:38:42 +0100 + +rsh-redone (85-1) unstable; urgency=low + + * New upstream release. + * Bump debhelper compatibility level to 7, and use dh_prep instead of + dh_clean -k. + * Fix rhosts.5 to ensure proper indexing. + + -- Guus Sliepen Tue, 05 May 2009 13:21:24 +0200 + +rsh-redone (83-1) unstable; urgency=low + + * New upstream release. + - Closes extra fd to stderr socket. Closes: #479804 + + -- Guus Sliepen Wed, 07 May 2008 10:53:34 +0200 + +rsh-redone (81-2) unstable; urgency=low + + * Use pam_rhosts.so instead of pam_rhosts_auth.so, the latter is buggy. + * Add missing #include to rlogind.c. + * Don't ignore errors in the clean rule. + * Replace dependency on netbase by openbsd-inetd | inet-superserver. + * Make rlogin and rsh world readable. + + -- Guus Sliepen Wed, 29 Aug 2007 14:49:51 +0200 + +rsh-redone (81-1) unstable; urgency=low + + * New upstream release. Closes: #414146 + + -- Guus Sliepen Sun, 11 Mar 2007 18:48:09 +0100 + +rsh-redone (80-1) unstable; urgency=low + + * New upstream release. Closes: #363488 + + -- Guus Sliepen Fri, 28 Apr 2006 13:05:30 +0200 + +rsh-redone (78-1) unstable; urgency=low + + * New upstream release. Closes: #198840, #211301, #262983 + + -- Guus Sliepen Sat, 26 Nov 2005 14:48:35 +0100 + +rsh-redone (71-1) unstable; urgency=low + + * New upstream release. + * Fix bashism in postinst script. + + -- Guus Sliepen Sat, 8 Oct 2005 17:00:24 +0200 + +rsh-redone (66-1) unstable; urgency=low + + * New upstream release. Closes: #282544 + + -- Guus Sliepen Sat, 5 Feb 2005 11:20:24 +0100 + +rsh-redone (65-1) unstable; urgency=low + + * New upstream release. Closes: #268075 + + -- Guus Sliepen Wed, 6 Oct 2004 17:28:02 +0200 + +rsh-redone (64-1) unstable; urgency=low + + * New upstream release. Closes: #257151 + * Bump standards version. + + -- Guus Sliepen Fri, 20 Aug 2004 12:06:01 +0200 + +rsh-redone (63-2) unstable; urgency=low + + * Forgot to fix Makefile which installed rshd and rlogind under wrong name. + + -- Guus Sliepen Wed, 2 Jul 2003 14:20:53 +0200 + +rsh-redone (63-1) unstable; urgency=low + + * New upstream release. + * Fixes verbosity as mentioned in #198840. + + -- Guus Sliepen Tue, 1 Jul 2003 19:34:41 +0200 + +rsh-redone (51-2) unstable; urgency=low + + * Properly named manpages. + * Recommend rsh-client for now, which provides rcp. + * Initial upload. Closes: #192416 + + -- Guus Sliepen Fri, 9 May 2003 12:33:06 +0200 + +rsh-redone (51-1) unstable; urgency=low + + * New upstream release. + + -- Guus Sliepen Wed, 7 May 2003 16:22:39 +0200 + +rsh-redone (39-1) unstable; urgency=low + + * New upstream release. + + -- Guus Sliepen Thu, 13 Mar 2003 21:50:05 +0100 + +rsh-redone (36-1) unstable; urgency=low + + * Initial Release. + + -- Guus Sliepen Thu, 13 Mar 2003 16:34:43 +0100 + --- rsh-redone-85.orig/debian/compat +++ rsh-redone-85/debian/compat @@ -0,0 +1 @@ +7 --- rsh-redone-85.orig/debian/control +++ rsh-redone-85/debian/control @@ -0,0 +1,31 @@ +Source: rsh-redone +Section: net +Priority: optional +Maintainer: Ubuntu Developers +XSBC-Original-Maintainer: Guus Sliepen +Build-Depends: debhelper (>> 7.0.0), libpam0g-dev, dpkg-dev (>= 1.16.1~) +Standards-Version: 3.9.4 + +Package: rsh-redone-server +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends}, openbsd-inetd | inet-superserver +Replaces: rsh-server +Conflicts: rsh-server +Provides: rsh-server +Description: Reimplementation of rshd and rlogind + Rsh-redone is a reimplementation of the remote shell clients and servers. + It is written from the ground up to avoid the bugs found in the standard + clients and servers. It also fully supports IPv6. + . + This package provides rshd and rlogind. + +Package: rsh-redone-client +Architecture: any +Depends: ${shlibs:Depends}, ${misc:Depends} +Recommends: rsh-client +Description: Reimplementation of rsh and rlogin + Rsh-redone is a reimplementation of the remote shell clients and servers. + It is written from the ground up to avoid the bugs found in the standard + clients and servers. It also fully supports IPv6. + . + This package provides rsh and rlogin. --- rsh-redone-85.orig/debian/copyright +++ rsh-redone-85/debian/copyright @@ -0,0 +1,26 @@ +This package was debianized by Guus Sliepen on +Thu, 13 Mar 2003 16:34:43 +0100. + +It was downloaded from http://svn.sliepen.eu.org/rsh-redone/. + +Upstream Author: Guus Sliepen + +Copyright (c) 2003 Guus Sliepen + + This program is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 2 of the License, or + (at your option) any later version. + + This program is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with this program; if not, write to the Free Software + Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, + USA. + +On Debian systems, the complete text of the GNU General Public +License, version 2, can be found in /usr/share/common-licenses/GPL-2. --- rsh-redone-85.orig/debian/rsh-redone-client.dirs +++ rsh-redone-85/debian/rsh-redone-client.dirs @@ -0,0 +1,2 @@ +usr/bin +usr/share/man/man1 --- rsh-redone-85.orig/debian/rsh-redone-client.files +++ rsh-redone-85/debian/rsh-redone-client.files @@ -0,0 +1,2 @@ +usr/bin/* +usr/share/man/man1/* --- rsh-redone-85.orig/debian/rsh-redone-client.lintian-overrides +++ rsh-redone-85/debian/rsh-redone-client.lintian-overrides @@ -0,0 +1,3 @@ +# The client binaries are intentionally setuid. +rsh-redone-client: setuid-binary usr/bin/rsh-redone-rlogin 4755 root/root +rsh-redone-client: setuid-binary usr/bin/rsh-redone-rsh 4755 root/root --- rsh-redone-85.orig/debian/rsh-redone-client.postinst +++ rsh-redone-85/debian/rsh-redone-client.postinst @@ -0,0 +1,8 @@ +#!/bin/sh -e + +update-alternatives --install /usr/bin/rsh rsh /usr/bin/rsh-redone-rsh 150 \ + --slave /usr/share/man/man1/rsh.1.gz rsh.1.gz /usr/share/man/man1/rsh-redone-rsh.1.gz +update-alternatives --install /usr/bin/rlogin rlogin /usr/bin/rsh-redone-rlogin 150 \ + --slave /usr/share/man/man1/rlogin.1.gz rlogin.1.gz /usr/share/man/man1/rsh-redone-rlogin.1.gz + +#DEBHELPER# --- rsh-redone-85.orig/debian/rsh-redone-client.prerm +++ rsh-redone-85/debian/rsh-redone-client.prerm @@ -0,0 +1,9 @@ +#!/bin/sh -e + +if [ "$1" = remove ] || [ "$1" = deconfigure ]; then + update-alternatives --remove rsh /usr/bin/rsh-redone-rsh + update-alternatives --remove rlogin /usr/bin/rsh-redone-rlogin +fi + + +#DEBHELPER# --- rsh-redone-85.orig/debian/rsh-redone-server.dirs +++ rsh-redone-85/debian/rsh-redone-server.dirs @@ -0,0 +1,4 @@ +usr/sbin +usr/share/man/man5 +usr/share/man/man8 +etc/pam.d --- rsh-redone-85.orig/debian/rsh-redone-server.files +++ rsh-redone-85/debian/rsh-redone-server.files @@ -0,0 +1,4 @@ +usr/sbin/* +usr/share/man/man5/* +usr/share/man/man8/* +etc/pam.d/* --- rsh-redone-85.orig/debian/rsh-redone-server.postinst +++ rsh-redone-85/debian/rsh-redone-server.postinst @@ -0,0 +1,10 @@ +#!/bin/sh -e + +if [ "$1" = configure ] && [ -z "$2" ]; then + update-inetd --group BSD --add "shell stream tcp nowait root /usr/sbin/tcpd /usr/sbin/in.rshd" + update-inetd --group BSD --add "login stream tcp nowait root /usr/sbin/tcpd /usr/sbin/in.rlogind" +else + update-inetd --enable shell,login +fi + +#DEBHELPER# --- rsh-redone-85.orig/debian/rsh-redone-server.prerm +++ rsh-redone-85/debian/rsh-redone-server.prerm @@ -0,0 +1,7 @@ +#!/bin/sh -e + +if command -v update-inetd >/dev/null 2>&1; then + update-inetd --disable shell,login +fi + +#DEBHELPER# --- rsh-redone-85.orig/debian/rules +++ rsh-redone-85/debian/rules @@ -0,0 +1,114 @@ +#!/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 + +DPKG_EXPORT_BUILDFLAGS = 1 +include /usr/share/dpkg/buildflags.mk + +configure: configure-stamp +configure-stamp: + dh_testdir + # Add here commands to configure the package. + + touch configure-stamp + + +#Architecture +build: build-arch build-indep + +build-arch: build-arch-stamp +build-arch-stamp: configure-stamp + + # Add here commands to compile the arch part of the package. + $(MAKE) + +build-indep: build-indep-stamp +build-indep-stamp: configure-stamp + + # 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 + + dh_clean + +install: install-arch +install-indep: + dh_testdir + dh_testroot + dh_prep -i + dh_installdirs -i + + # Add here commands to install the indep part of the package into + # debian/-doc. + #INSTALLDOC# + + dh_install -i + +install-arch: + dh_testdir + dh_testroot + dh_prep -a + dh_installdirs -a + + # Add here commands to install the arch part of the package into + # debian/tmp. + + $(MAKE) install SYSCONFDIR=/etc DESTDIR=$(CURDIR)/debian/tmp + ln -s rlogind.8 debian/tmp/usr/share/man/man8/in.rlogind.8 + ln -s rshd.8 debian/tmp/usr/share/man/man8/in.rshd.8 + mv debian/tmp/usr/bin/rlogin debian/tmp/usr/bin/rsh-redone-rlogin + mv debian/tmp/usr/bin/rsh debian/tmp/usr/bin/rsh-redone-rsh + mv debian/tmp/usr/share/man/man1/rlogin.1 debian/tmp/usr/share/man/man1/rsh-redone-rlogin.1 + mv debian/tmp/usr/share/man/man1/rsh.1 debian/tmp/usr/share/man/man1/rsh-redone-rsh.1 + + dh_movefiles -a + + #dh_install -a +# Must not depend on anything. This is to be called by +# binary-arch/binary-multi +# in another 'make' thread. +binary-common: + dh_testdir + dh_testroot + dh_installchangelogs ChangeLog + dh_installdocs + dh_installexamples + dh_lintian + dh_installman + dh_link + dh_strip + dh_compress + dh_fixperms -Xusr/bin/rsh-redone-rsh -Xusr/bin/rsh-redone-rlogin + dh_makeshlibs + dh_shlibdeps + 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 +.PHONY: build clean binary-indep binary-arch binary install install-indep install-arch configure --- rsh-redone-85.orig/rhosts.5 +++ rsh-redone-85/rhosts.5 @@ -1,13 +1,15 @@ .Dd Sun, 13 Apr 2003 00:24:32 +0200 .Dt RHOSTS 5 .Sh NAME -.Pa $HOME/.rhosts +.Nm rhosts .Nd allow .Nm rlogin , .Nm rsh and .Nm rcp connections to the local machine without a password. +.Sh SYNOPSIS +.Pa $HOME/.rhosts .Sh DESCRIPTION The .Pa .rhosts