summaryrefslogtreecommitdiff
path: root/mail/popa3d/files.smtp
diff options
context:
space:
mode:
Diffstat (limited to 'mail/popa3d/files.smtp')
-rw-r--r--mail/popa3d/files.smtp/POPAUTH49
-rw-r--r--mail/popa3d/files.smtp/patch-aa37
-rw-r--r--mail/popa3d/files.smtp/patch-ab23
-rw-r--r--mail/popa3d/files.smtp/patch-pop_auth.c11
-rw-r--r--mail/popa3d/files.smtp/patch-pop_pbs.c11
-rw-r--r--mail/popa3d/files.smtp/patch-pop_root.c18
-rw-r--r--mail/popa3d/files.smtp/popauth.m447
7 files changed, 0 insertions, 196 deletions
diff --git a/mail/popa3d/files.smtp/POPAUTH b/mail/popa3d/files.smtp/POPAUTH
deleted file mode 100644
index abb368505724..000000000000
--- a/mail/popa3d/files.smtp/POPAUTH
+++ /dev/null
@@ -1,49 +0,0 @@
- popa3d patch for POP-before-SMTP and SMTP-after-POP
-
- Garry Glendown / Dec. 12th 2000
-
-On the 'net there are a couple of solutions to allow for POP-before-SMTP
-authentication in order to allow for relaying of mails. Anyway, the
-solutions I found didn't really apeal to me, so I hacked popa3d a bit,
-which we already used on one of our machines to serve mail to dialup
-customers.
-
- Prerequisites
-
-This patch supplies data to sendmail to allow for certain IPs to use it
-as a relaying host. In order to use with your sendmail installation, get
-the popauth-hack (http://www.sendmail.org/~ca/email/rules/popauth.m4)
-and install it by adding "HACK(`popauth')" to you .mc-file.
-
- Installing
-
-The patch - enabled through the POPB4SMTP-define in the Makefile -
-accesses the file "/etc/mail/popauth.db" (create with "makemap hash
-/etc/mail/popauth </dev/null") and adds the IP of the sucessfully
-authenticated POP-user to it. Once the IP appears in the .db-file,
-sendmail will allow the IP to relay mail from it.
-
-Apart from the IP, which is added as LHS in the database, the patch adds
-the timestamp of the authentication as RHS (which the sendmail-hack
-ignores). This timestamp is then used to remove old IPs which are older
-than VALIDTIME seconds (defined in the Makefile).
-
- Disclaimer
-
-This hack has been in production use for a week on our server and though
-there are in average 30-60 POP3 logins per minute (going up to 2-3
-requests per seconds during daytime), we have not had any problems.
-Please note that I'm no expert at the Berkeley db library - I just
-hacked up a version using the old db1 functions and it worked out.
-There may be things to do better, but it seems to work fine for me. If
-you have any suggestions, let me know ... I've tried to play it safe and
-wrapped all db-access into a semaphore-protected block, hopefully
-allowing for safe multiple execution ... also, I tried to make sure that
-the string functions all check for the available array length.
-
-If you have any suggestions, questions or feedback of any other kind
-concerning this hack, don't bug the author of popa3d, but drop me a mail
-at garry@glendown.de
-
-G.Glendown / Dec 15th 2000
-
diff --git a/mail/popa3d/files.smtp/patch-aa b/mail/popa3d/files.smtp/patch-aa
deleted file mode 100644
index b873e9ac3561..000000000000
--- a/mail/popa3d/files.smtp/patch-aa
+++ /dev/null
@@ -1,37 +0,0 @@
---- params.h.orig Tue Feb 1 09:16:24 2000
-+++ params.h Sat Mar 4 16:12:48 2000
-@@ -33,7 +33,7 @@
- * An unprivileged dummy user to run as before authentication. The user
- * and its UID must not be used for any other purpose.
- */
--#define POP_USER "popa3d"
-+#define POP_USER "pop"
-
- /*
- * Sessions will be closed if idle for longer than POP_TIMEOUT seconds.
-@@ -62,7 +62,7 @@
- * Do we have shadow passwords? (Not for *BSD.)
- * Note: password aging is not supported.
- */
--#define AUTH_SHADOW 1
-+#define AUTH_SHADOW 0
-
- /*
- * A salt used to waste some CPU time on dummy crypt(3) calls and make
-@@ -81,14 +81,14 @@
- * Your mail spool directory. Note: only local (non-NFS) mode 775 mail
- * spools are currently supported.
- */
--#define MAIL_SPOOL_PATH "/var/spool/mail"
-+#define MAIL_SPOOL_PATH "/var/mail"
-
- /*
- * How do we talk to syslogd? These should be fine for most systems.
- */
- #define SYSLOG_IDENT "popa3d"
- #define SYSLOG_OPTIONS LOG_PID
--#define SYSLOG_FACILITY LOG_DAEMON
-+#define SYSLOG_FACILITY LOG_MAIL
- #define SYSLOG_PRIORITY LOG_NOTICE
-
- /*
diff --git a/mail/popa3d/files.smtp/patch-ab b/mail/popa3d/files.smtp/patch-ab
deleted file mode 100644
index 2565bb67698a..000000000000
--- a/mail/popa3d/files.smtp/patch-ab
+++ /dev/null
@@ -1,23 +0,0 @@
---- Makefile.orig Mon Jul 16 11:35:16 2001
-+++ Makefile Mon Jul 16 11:43:29 2001
-@@ -1,9 +1,8 @@
--CC = gcc
--LD = gcc
-+CC? = gcc
- RM = rm -f
- CFLAGS = -c -Wall -O2 -fomit-frame-pointer -DPOPB4SMTP -DVALIDTIME=600
- #LDFLAGS = -s
--LDFLAGS = -s -lcrypt -ldb1
-+LDFLAGS = -s -lcrypt
-
-
- PROJ = popa3d
-@@ -14,7 +13,7 @@
- misc.o pop_pbs.o
-
- popa3d: $(OBJS)
-- $(LD) $(LDFLAGS) $(OBJS) -o popa3d
-+ $(CC) $(LDFLAGS) $(OBJS) -o popa3d
-
- md5/md5.o: md5/md5.c md5/md5.h
- $(CC) $(CFLAGS) -D_LIBC md5/md5.c -o md5/md5.o
diff --git a/mail/popa3d/files.smtp/patch-pop_auth.c b/mail/popa3d/files.smtp/patch-pop_auth.c
deleted file mode 100644
index fe0638ac55a7..000000000000
--- a/mail/popa3d/files.smtp/patch-pop_auth.c
+++ /dev/null
@@ -1,11 +0,0 @@
---- pop_auth.c.orig Mon Jul 16 11:51:30 2001
-+++ pop_auth.c Mon Jul 16 11:54:35 2001
-@@ -12,6 +12,8 @@
- #include "protocol.h"
- #include "pop_auth.h"
-
-+char *client_addr(int);
-+
- static char *pop_user, *pop_pass;
-
- static int pop_auth_quit(char *params)
diff --git a/mail/popa3d/files.smtp/patch-pop_pbs.c b/mail/popa3d/files.smtp/patch-pop_pbs.c
deleted file mode 100644
index 397de2d09e9c..000000000000
--- a/mail/popa3d/files.smtp/patch-pop_pbs.c
+++ /dev/null
@@ -1,11 +0,0 @@
---- pop_pbs.c.orig Mon Jul 16 11:38:00 2001
-+++ pop_pbs.c Mon Jul 16 11:41:40 2001
-@@ -1,6 +1,7 @@
-+#include <sys/types.h>
- #include <sys/socket.h>
-+#include <netinet/in.h>
- #include <arpa/inet.h>
--#include <sys/types.h>
- #include <sys/stat.h>
-
- char addr_buf[256];
diff --git a/mail/popa3d/files.smtp/patch-pop_root.c b/mail/popa3d/files.smtp/patch-pop_root.c
deleted file mode 100644
index cdc98a60e1f5..000000000000
--- a/mail/popa3d/files.smtp/patch-pop_root.c
+++ /dev/null
@@ -1,18 +0,0 @@
---- pop_root.c.neu.orig Mon Jul 16 11:55:05 2001
-+++ pop_root.c Tue Jul 17 11:45:22 2001
-@@ -210,6 +210,7 @@
- sem=sem_attach(0x50413453);
- sem_enter(sem);
- db=dbopen("/etc/mail/popauth.db",O_RDWR,0664,DB_HASH,0 );
-+ if ( db != NULL ) {
- key.data=client_addr(1);
- key.size=strlen(key.data);
- sprintf(ts,"%d",(int)time(0));
-@@ -233,6 +234,7 @@
- ret=db->seq(db,&key,&data,R_NEXT);
- }
- db->close(db);
-+ }
- sem_leave(sem);
- #endif
-
diff --git a/mail/popa3d/files.smtp/popauth.m4 b/mail/popa3d/files.smtp/popauth.m4
deleted file mode 100644
index 2520978ad904..000000000000
--- a/mail/popa3d/files.smtp/popauth.m4
+++ /dev/null
@@ -1,47 +0,0 @@
-divert(-1)
-#
-# Copyright (c) 2000 Claus Assmann <ca+popauth@mine.informatik.uni-kiel.de>
-#
-# In short: you can do whatever you want with this, but don't blame me!
-#
-# THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
-# ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
-# IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
-# ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
-# FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
-# DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
-# OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
-# HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
-# LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
-# OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
-# SUCH DAMAGE.
-#
-# <URL: http://www.sendmail.org/~ca/email/chk-89n.html >
-#
-VERSIONID(`$Id: popauth.m4,v 1.5 2000/10/19 17:47:53 ca Exp $')
-
-LOCAL_CONFIG
-ifdef(`DATABASE_MAP_TYPE', `', `define(`DATABASE_MAP_TYPE', `hash')')
-Kpopauth ifelse(defn(`_ARG_'), `',
- `DATABASE_MAP_TYPE -a<OK> /etc/mail/popauth',
- `_ARG_')
-ifdef(`CF_LEVEL', `dnl has been introduced in 8.10
-dnl this can be used to add a tag to entries in the map
-dnl to restrict the access
-ifdef(`POP_B4_SMTP_TAG',, `define(`POP_B4_SMTP_TAG', `POP:')')dnl
-ifdef(`POP_TO', `dnl
-ifdef(`_ARITH_MAP_', `', `dnl
-define(`_ARITH_MAP_', `1')dnl
-Karith arith')
-')', `dnl
-define(`POP_B4_SMTP_TAG', `')dnl
-')dnl
-LOCAL_RULESETS
-SLocal_check_rcpt
-R$* $: $(popauth `'$&{client_addr} $: <?> $)
-R<?> $@ NoPopAuth
-ifdef(`POP_TO', `dnl
-R$+ $: $(arith - $@ $1 $@ $&t $)
-R$+ $: $(arith l $@ $1 $@ POP_TO $)
-RTRUE $# OK', `
-R$*<OK> $# OK')