aboutsummaryrefslogtreecommitdiffstats
path: root/games/xsoldier
diff options
context:
space:
mode:
authorasami <asami@FreeBSD.org>1999-12-16 11:29:47 +0800
committerasami <asami@FreeBSD.org>1999-12-16 11:29:47 +0800
commit506ec5d93a78be1c9ce0795cdefb2d8b60fa30e3 (patch)
treeb47a6a65087741617a5a3c61a6ec57bbcbb4a3bc /games/xsoldier
parent8710fca6aff416552c26386326784e5013b7bc3b (diff)
downloadfreebsd-ports-gnome-506ec5d93a78be1c9ce0795cdefb2d8b60fa30e3.tar.gz
freebsd-ports-gnome-506ec5d93a78be1c9ce0795cdefb2d8b60fa30e3.tar.zst
freebsd-ports-gnome-506ec5d93a78be1c9ce0795cdefb2d8b60fa30e3.zip
Plug root exploit.
Submitted by: imp
Diffstat (limited to 'games/xsoldier')
-rw-r--r--games/xsoldier/files/patch-ac19
1 files changed, 19 insertions, 0 deletions
diff --git a/games/xsoldier/files/patch-ac b/games/xsoldier/files/patch-ac
new file mode 100644
index 000000000000..292382939991
--- /dev/null
+++ b/games/xsoldier/files/patch-ac
@@ -0,0 +1,19 @@
+--- main.c Fri Feb 28 08:50:07 1997
++++ main.c.new Wed Dec 15 19:35:37 1999
+@@ -129,14 +129,14 @@
+ argv0++;
+ else
+ argv0 = argv[0];
+- strcpy(command,argv0); /*** コマンド名取得とコピー ***/
++ strlcpy(command,argv0,sizeof(command)); /*** コマンド名取得とコピー ***/
+
+ for (i=1; i<argc; i++)
+ {
+ if ((strcmp(argv[i],"-display")==0) || (strcmp(argv[i],"-d")==0))
+ {
+ if (i < argc-1)
+- strcpy(display,argv[i+1]);
++ strlcpy(display,argv[i+1],sizeof(display));
+ }
+ else if ((strcmp(argv[i],"-wait")==0) || (strcmp(argv[i],"-w")==0))
+ {