debian/0000755000000000000000000000000012254625515007175 5ustar debian/source/0000755000000000000000000000000012254100767010472 5ustar debian/source/format0000644000000000000000000000001412254100767011700 0ustar 3.0 (quilt) debian/control0000644000000000000000000000172512254100767010602 0ustar Source: monopd Section: games Priority: optional Maintainer: Debian Games Team Uploaders: Markus Koschany Build-Depends: debhelper (>= 9), dh-autoreconf, libcapsinetwork-dev, libmath++-dev Standards-Version: 3.9.5 Homepage: http://sourceforge.net/projects/monopd/ Vcs-Git: git://anonscm.debian.org/pkg-games/monopd.git Vcs-Browser: http://anonscm.debian.org/gitweb/?p=pkg-games/monopd.git Package: monopd Architecture: any Depends: ${misc:Depends}, ${shlibs:Depends} Suggests: gtkatlantic Description: Monopoly game network server monopd is a dedicated game server daemon for playing Monopoly-like board games. Clients such as gtkAtlantic connect to the server, which manages the game. Note that you do not need to install this server unless you want to use one of the clients offline, or play custom game types. . Currently supported board games are Monopoly(R) and Atlantic, a variation on Monopoly(R). debian/monopd.init0000644000000000000000000000432312254100767011355 0ustar #! /bin/sh ### BEGIN INIT INFO # Provides: monopd # Required-Start: $remote_fs $network # Required-Stop: $remote_fs $network # Default-Start: 2 3 4 5 # Default-Stop: 0 1 6 # Short-Description: Start monopd network game server # Description: game server for board games like # GtkAtlantic ### END INIT INFO PATH="/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin" NAME="monopd" DAEMON="/usr/sbin/$NAME" DESC="monopd network game server" PIDFILE="/var/run/$NAME.pid" BINARY="/usr/sbin/$NAME" USER="nobody" test -x $DAEMON || exit 0 . /lib/lsb/init-functions # Include defaults if available if [ -f /etc/default/$NAME ] ; then . /etc/default/$NAME fi monopd_start() { start-stop-daemon --start --quiet --pidfile $PIDFILE --oknodo \ --background --exec $BINARY --startas $DAEMON \ --make-pidfile --chuid $USER \ -- $DAEMON_OPTS > /dev/null 2>&1 || return 1 return 0 } monopd_stop() { start-stop-daemon --stop --quiet --pidfile $PIDFILE \ --oknodo --exec $BINARY || return 1 rm -f $PIDFILE return 0 } case "$1" in start) log_begin_msg "Starting $DESC: $NAME" monopd_start log_end_msg $? ;; stop) log_begin_msg "Stopping $DESC: $NAME" monopd_stop log_end_msg $? ;; #reload) # # If the daemon can reload its config files on the fly # for example by sending it SIGHUP, do it here. # # If the daemon responds to changes in its config file # directly anyway, make this a do-nothing entry. # # echo "Reloading $DESC configuration files." # start-stop-daemon --stop --signal 1 --quiet --pidfile \ # /var/run/$NAME.pid --exec $DAEMON #;; 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". # log_begin_msg "Restarting $DESC: $NAME" monopd_stop && sleep 1 && monopd_start log_end_msg $? ;; status) status_of_proc -p "$PIDFILE" "$DAEMON" "$NAME" && exit 0 || exit $? ;; *) # echo "Usage: $0 {start|stop|restart|reload|force-reload}" >&2 echo "Usage: $0 {start|stop|restart|force-reload|status}" >&2 exit 1 ;; esac exit 0 debian/compat0000644000000000000000000000000212254100767010370 0ustar 9 debian/monopd.60000644000000000000000000000110312254100767010550 0ustar .\" This man page was written by Markus Koschany in October 2013. It is provided .\" under the GNU General Public License 2. .TH monopd 6 "October 2013" "monopd" "games" .SH NAME monopd \- Monopoly™ like game server .SH SYNOPSIS .PP \fBmonopd\fR .SH DESCRIPTION \fBmonopd\fP is a dedicated game server daemon for playing Monopoly-like board games like GtkAtlantic. Clients connect to the server and communicate using short commands and XML messages. .SH OPTIONS There are no further options. You can start and stop the server with service monopd start and service monopd stop debian/monopd.docs0000644000000000000000000000006512254100767011341 0ustar API README README.monopigator TODO doc/api/gameboard debian/rules0000755000000000000000000000056312254100767010256 0ustar #!/usr/bin/make -f export DEB_BUILD_MAINT_OPTIONS = hardening=+all %: dh $@ --parallel --with autoreconf override_dh_auto_configure: dh_auto_configure -- \ --prefix=/usr \ --bindir=\$${prefix}/sbin \ --datadir=\$${prefix}/share/games override_dh_install: dh_install mv $(CURDIR)/debian/monopd/etc/monopd.conf-dist \ $(CURDIR)/debian/monopd/etc/monopd.conf debian/patches/0000755000000000000000000000000012254100767010621 5ustar debian/patches/01_gcc43_includes.patch0000644000000000000000000000434612254100767014742 0ustar From: Daniel Schepler Date: Sun, 6 Oct 2013 13:55:16 +0200 Subject: 01_gcc43_includes Add missing #include's to fix compilation with gcc-4.3 Bug-Debian: http://bugs.debian.org/417322 Forwarded: no --- src/cardgroup.cpp | 2 +- src/estategroup.cpp | 1 + src/game.cpp | 3 ++- src/main.cpp | 1 + src/player.cpp | 1 + src/server.cpp | 2 ++ 6 files changed, 8 insertions(+), 2 deletions(-) diff --git a/src/cardgroup.cpp b/src/cardgroup.cpp index 610bf91..aa7474f 100644 --- a/src/cardgroup.cpp +++ b/src/cardgroup.cpp @@ -14,7 +14,7 @@ // the Free Software Foundation, Inc., 59 Temple Place - Suite 330, // Boston, MA 02111-1307, USA. -#include +#include #include "card.h" #include "cardgroup.h" diff --git a/src/estategroup.cpp b/src/estategroup.cpp index 71d6859..db7ce6d 100644 --- a/src/estategroup.cpp +++ b/src/estategroup.cpp @@ -14,6 +14,7 @@ // the Free Software Foundation, Inc., 59 Temple Place - Suite 330, // Boston, MA 02111-1307, USA. +#include #include #include diff --git a/src/game.cpp b/src/game.cpp index 544d365..fdd2dae 100644 --- a/src/game.cpp +++ b/src/game.cpp @@ -20,7 +20,8 @@ #include #include #include -#include // libstdc++ from the gcc 2.95 has no #include yet :( +#include +#include // libstdc++ from the gcc 2.95 has no #include yet :( #include #include diff --git a/src/main.cpp b/src/main.cpp index 8fa6428..b3d3ed2 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -18,6 +18,7 @@ #include #include #include +#include #include #include diff --git a/src/player.cpp b/src/player.cpp index 98cf22e..88ba9c5 100644 --- a/src/player.cpp +++ b/src/player.cpp @@ -18,6 +18,7 @@ #include #include #include +#include #include diff --git a/src/server.cpp b/src/server.cpp index d0a3c26..1947156 100644 --- a/src/server.cpp +++ b/src/server.cpp @@ -25,6 +25,8 @@ #include #include #include +#include +#include #include debian/patches/CPPFLAGS.patch0000644000000000000000000000071512254100767013044 0ustar From: Markus Koschany Date: Sun, 6 Oct 2013 13:56:07 +0200 Subject: CPPFLAGS Forwarded: no --- src/Makefile.am | 1 + 1 file changed, 1 insertion(+) diff --git a/src/Makefile.am b/src/Makefile.am index 0854433..0771268 100644 --- a/src/Makefile.am +++ b/src/Makefile.am @@ -1,4 +1,5 @@ CPPFLAGS= -DMONOPD_DATADIR=\"$(pkgdatadir)\" -DMONOPD_CONFIGDIR=\"$(sysconfdir)\" +CPPFLAGS+= `dpkg-buildflags --get CPPFLAGS` bin_PROGRAMS = monopd debian/patches/series0000644000000000000000000000010112254100767012026 0ustar 01_gcc43_includes.patch monopd-0.9.3-dosfix.patch CPPFLAGS.patch debian/patches/monopd-0.9.3-dosfix.patch0000644000000000000000000000311712254100767015077 0ustar From: Daniel Schepler Date: Sun, 6 Oct 2013 13:55:16 +0200 Subject: monopd-0.9.3-dosfix Fixes a remote DOS vulnerability (CVE-2006-1046) which could cause the daemon to eat up CPU time on the server. Bug-Debian: http://bugs.debian.org/355797 Forwarded: no --- src/server.cpp | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/server.cpp b/src/server.cpp index 1947156..ca2878f 100644 --- a/src/server.cpp +++ b/src/server.cpp @@ -793,7 +793,7 @@ void MonopdServer::processInput(Socket *socket, const std::string data) switch(data[1]) { case 'n': - pNew = newPlayer(socket, data.substr(2)); + pNew = newPlayer(socket, data.substr(2, 16)); sendXMLUpdates(); sendXMLUpdate(pNew, true, true); // give new player a full update (excluding self) so it knows who's in the lounge return; @@ -834,13 +834,13 @@ void MonopdServer::processCommands(Player *pInput, const std::string data2) switch(data[0]) { case 'n': - setPlayerName(pInput, std::string(data+1)); + setPlayerName(pInput, data2.substr(1, 16)); return; case 'p': switch(data[1]) { case 'i': - pInput->setProperty("image", data+2, this); + pInput->setProperty("image", data2.substr(2, 32), this); return; } break; @@ -1134,7 +1134,7 @@ void MonopdServer::processCommands(Player *pInput, const std::string data2) switch(data[1]) { case 'd': - setGameDescription(pInput, data2.substr(2)); + setGameDescription(pInput, data2.substr(2, 64)); return; case 'c': game->editConfiguration( pInput, data+2 ); debian/watch0000644000000000000000000000007112254100767010221 0ustar version=3 http://sf.net/monopd/monopd-([\d\.]+)\.tar\.gz debian/copyright0000644000000000000000000000227512254100767011133 0ustar Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: monopd Source: http://sourceforge.net/projects/monopd Files: * Copyright: 2001-2002, Rob Kaper 2001, Erik Bourget License: GPL-2 Files: debian/* Copyright: 2003-2011, Daniel Schepler 2011, Paul Wise 2013, Markus Koschany License: GPL-2 License: GPL-2 This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License version 2 as published by the Free Software Foundation. . 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; see the file COPYING. If not, write to the Free Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301, USA. . The text of the GPL is available at /usr/share/common-licenses/GPL-2. debian/changelog0000644000000000000000000001154212254625053011047 0ustar monopd (0.9.3-7) unstable; urgency=medium * New maintainer Debian Games Team. (Closes: #634499) * Add myself to Uploaders. * Bump compat level to 9 and require debhelper >= 9. * debian/rules: - Drop cdbs and switch to dh-sequencer. - Build with --parallel and --with autoreconf. - Install data files to /usr/share/games/monopd - Enable all hardening build flags. Add CPPFLAGS.patch. * monopd.init: - Improve init script and source /lib/lsb/init-functions. - Implement the status option. * Bump Standards-Version to 3.9.5, no changes. * debian/control: - Add VCS-fields. - Remove versioned dependencies. They are trivially satisfied now. * Install upstream changelog only once. * Add monopd.6 man page. * debian/patches: Rename filename extensions from diff to patch. -- Markus Koschany Tue, 17 Dec 2013 17:55:05 +0100 monopd (0.9.3-6) unstable; urgency=low * QA upload. [ James Westby ] * Use --chuid instead of /bin/su to run the daemon as 'nobody'. Using su mean that a pam session was opened, hence a consolekit session, hence trying to shut down via consolekit would require the root password as it thought there were multiple users logged in. (LP: #443441) [ Bilal Akhtar & Ryan Kavanagh ] * Dropped atlantik and atlantikdesigner from suggests because they are not available in Intrepid. [ Paul Wise ] * Dropped atlantik and atlantikdesigner from the package description because they are not available any more. * The software is dead upstream, drop the generalisation efforts from the package description. * Use the sourceforge project as the upstream project location since the other sites are spam sites. * Clean up the patches and add DEP-3 headers to them * Use the new FSF address in copyright information -- Paul Wise Tue, 18 Oct 2011 17:11:49 +0800 monopd (0.9.3-5) unstable; urgency=low * Orphaning package (see #634499). * Bump Standards-Version to 3.9.2. * Update to 3.0 (quilt) source format. -- Daniel Schepler Mon, 18 Jul 2011 22:07:44 -0700 monopd (0.9.3-4) unstable; urgency=low * Add extra includes needed for compilation with current g++-4.3. * Add LSB dependency information to the init script, thanks Lintian. * Update Standards-Version to 3.7.3 (no changes needed). -- Daniel Schepler Fri, 11 Jan 2008 17:04:28 -0500 monopd (0.9.3-3) unstable; urgency=low * Add missing #include's to fix compilation with gcc-4.3. (Closes: #417322) * Update watch file: listing the download directory is now forbidden, so we have to go through the download page. -- Daniel Schepler Tue, 05 Jun 2007 12:20:32 -0400 monopd (0.9.3-2) unstable; urgency=low * New patch monopd-0.9.3-dosfix.diff for CVE-2006-1046: Fixes a remote DOS vulnerability which could cause the daemon to eat up CPU time on the server. (Closes: #355797) * Bump Standards-Version to 3.7.2 (no changes needed). -- Daniel Schepler Sat, 12 Aug 2006 17:05:23 -0400 monopd (0.9.3-1) unstable; urgency=low * g++-4.0 transition. * New upstream release. * Update debian/watch file to new location. * Update to Standards-Version 3.6.2 (no changes needed). -- Daniel Schepler Fri, 8 Jul 2005 16:45:20 -0700 monopd (0.9.0-1) unstable; urgency=low * New upstream release. * Version libcapsinetwork-dev build dependency to 0.2.5 or later. -- Daniel Schepler Fri, 13 Feb 2004 18:05:30 -0800 monopd (0.8.3-1) unstable; urgency=low * New upstream release. + Fixes a DOS vulnerability. (Closes: #229580) -- Daniel Schepler Tue, 27 Jan 2004 17:25:00 -0800 monopd (0.8.2-1) unstable; urgency=low * New upstream release * Update to Standards-Version 3.6.1 (no changes needed). * Add a debian/watch file. -- Daniel Schepler Tue, 21 Oct 2003 01:54:00 -0700 monopd (0.8.1-2) unstable; urgency=low * Fix debian/rules for new cdbs. -- Daniel Schepler Tue, 8 Jul 2003 05:32:23 -0700 monopd (0.8.1-1) unstable; urgency=low * New upstream release. * Remove hack to use prefix instead of DESTDIR in install, which is no longer necessary. -- Daniel Schepler Mon, 7 Jul 2003 13:56:33 -0700 monopd (0.8.0-1) unstable; urgency=low * New upstream release. * Switch to using cdbs. * Update to Standards-Version 3.5.10 (no changes needed). -- Daniel Schepler Sat, 21 Jun 2003 16:27:21 -0700 monopd (0.7.0-2) unstable; urgency=medium * Start monopd as nobody user. -- Daniel Schepler Tue, 4 Mar 2003 06:04:58 -0800 monopd (0.7.0-1) unstable; urgency=low * Initial Release. (Closes: #180321) -- Daniel Schepler Sun, 23 Feb 2003 02:14:21 -0800 debian/manpages0000644000000000000000000000002012254100767010700 0ustar debian/monopd.6