summaryrefslogtreecommitdiff
path: root/ftp
diff options
context:
space:
mode:
authorAndrey A. Chernov <ache@FreeBSD.org>2010-06-29 12:28:54 +0000
committerAndrey A. Chernov <ache@FreeBSD.org>2010-06-29 12:28:54 +0000
commit46895a72533703a6541ce697994bb311147b73ce (patch)
tree5ce7a0d4e8144b13c35c80bc941966cfd39c4170 /ftp
parentUncomment dologout(-1) on SIGHUP and the like signals, stale wtmp entries (diff)
Add SIGTERM to the list, needs wtmp cleanup too
Feature safe: yes
Notes
Notes: svn path=/head/; revision=257158
Diffstat (limited to 'ftp')
-rw-r--r--ftp/wu-ftpd/files/patch-aa37
1 files changed, 25 insertions, 12 deletions
diff --git a/ftp/wu-ftpd/files/patch-aa b/ftp/wu-ftpd/files/patch-aa
index 523ec5127f8c..7db805ae3528 100644
--- a/ftp/wu-ftpd/files/patch-aa
+++ b/ftp/wu-ftpd/files/patch-aa
@@ -1,5 +1,5 @@
---- ftpd.c.orig 2010-06-29 15:52:01.000000000 +0400
-+++ ftpd.c 2010-06-29 16:11:19.000000000 +0400
+--- src/ftpd.c.orig 2010-06-29 16:24:04.000000000 +0400
++++ src/ftpd.c 2010-06-29 16:26:15.000000000 +0400
@@ -447,7 +447,6 @@
#ifdef OPIE
#include <opie.h>
@@ -8,7 +8,20 @@
struct opie opiestate;
#endif
-@@ -1219,10 +1218,6 @@
+@@ -785,6 +784,12 @@
+ sigemptyset(&block_sigmask);
+ #endif
+ #ifndef SIG_DEBUG
++#ifdef SIGTERM
++ (void) signal(SIGTERM, randomsig);
++#ifdef NEED_SIGFIX
++ sigaddset(&block_sigmask, SIGTERM);
++#endif
++#endif
+ #ifdef SIGHUP
+ (void) signal(SIGHUP, randomsig);
+ #ifdef NEED_SIGFIX
+@@ -1219,10 +1224,6 @@
exit(0);
}
@@ -19,7 +32,7 @@
#ifdef HAVE_LIBRESOLV
/* check permitted access based on remote host DNS information */
if (!check_reverse_dns()) {
-@@ -1387,8 +1382,7 @@
+@@ -1387,8 +1388,7 @@
chdir("/");
signal(SIGIOT, SIG_DFL);
signal(SIGILL, SIG_DFL);
@@ -29,7 +42,7 @@
}
SIGNAL_TYPE lostconn(int sig)
-@@ -1662,9 +1656,9 @@
+@@ -1662,9 +1662,9 @@
/* Display s/key challenge where appropriate. */
if (pwd == NULL || skeychallenge(&skey, pwd->pw_name, sbuf))
@@ -41,7 +54,7 @@
pwok ? "allowed" : "required", name);
return (buf);
}
-@@ -2105,16 +2099,17 @@
+@@ -2105,16 +2105,17 @@
#ifdef OPIE
{
char prompt[OPIE_CHALLENGE_MAX + 1];
@@ -67,7 +80,7 @@
}
#else
reply(331, "Password required for %s.", name);
-@@ -2593,8 +2588,8 @@
+@@ -2593,8 +2594,8 @@
if (pw == NULL)
salt = "xx";
else
@@ -77,7 +90,7 @@
#ifdef SECUREOSF
if ((pr = getprpwnam(pw->pw_name)) != NULL) {
if (pr->uflg.fg_newcrypt)
-@@ -2627,9 +2622,15 @@
+@@ -2627,9 +2628,15 @@
xpasswd = crypt(passwd, salt);
#endif /* SKEY */
#else /* OPIE */
@@ -96,7 +109,7 @@
#endif /* OPIE */
#ifdef ULTRIX_AUTH
if ((numfails = ultrix_check_pass(passwd, xpasswd)) >= 0) {
-@@ -3189,7 +3190,7 @@
+@@ -3189,7 +3196,7 @@
pw->pw_name, pw->pw_dir);
goto bad;
#else
@@ -105,7 +118,7 @@
#ifdef VERBOSE_ERROR_LOGING
syslog(LOG_NOTICE, "FTP LOGIN FAILED (cannot chdir) for %s, %s",
remoteident, pw->pw_name);
-@@ -3508,7 +3509,7 @@
+@@ -3508,7 +3515,7 @@
{
char *a;
a = (char *) malloc(len + 1);
@@ -114,7 +127,7 @@
a[len] = 0;
if (strlen(s) <= len)
memcpy(a, s, strlen(s));
-@@ -7469,6 +7470,8 @@
+@@ -7469,6 +7476,8 @@
in++;
if (*in == '/')
in++;
@@ -123,7 +136,7 @@
}
else if ((in[0] == '.') && (in[1] == '.') && ((in[2] == '/') || (in[2] == '\0'))) {
if (out == path) {
-@@ -7497,6 +7500,9 @@
+@@ -7497,6 +7506,9 @@
}
else {
do