From owner-svn-ports-head@freebsd.org Wed Jan 16 11:02:38 2019 Return-Path: Delivered-To: svn-ports-head@mailman.ysv.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.ysv.freebsd.org (Postfix) with ESMTP id DD3D41483C9E; Wed, 16 Jan 2019 11:02:37 +0000 (UTC) (envelope-from rene@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) server-signature RSA-PSS (4096 bits) client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 7975D96FC0; Wed, 16 Jan 2019 11:02:37 +0000 (UTC) (envelope-from rene@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 3F4CE149C; Wed, 16 Jan 2019 11:02:37 +0000 (UTC) (envelope-from rene@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id x0GB2bSX064416; Wed, 16 Jan 2019 11:02:37 GMT (envelope-from rene@FreeBSD.org) Received: (from rene@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id x0GB2aNs064412; Wed, 16 Jan 2019 11:02:36 GMT (envelope-from rene@FreeBSD.org) Message-Id: <201901161102.x0GB2aNs064412@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: rene set sender to rene@FreeBSD.org using -f From: Rene Ladan Date: Wed, 16 Jan 2019 11:02:36 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r490469 - in head/mail/imap-uw: . files X-SVN-Group: ports-head X-SVN-Commit-Author: rene X-SVN-Commit-Paths: in head/mail/imap-uw: . files X-SVN-Commit-Revision: 490469 X-SVN-Commit-Repository: ports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 7975D96FC0 X-Spamd-Bar: -- Authentication-Results: mx1.freebsd.org X-Spamd-Result: default: False [-2.98 / 15.00]; local_wl_from(0.00)[FreeBSD.org]; NEURAL_HAM_MEDIUM(-1.00)[-0.999,0]; NEURAL_HAM_LONG(-1.00)[-0.999,0]; NEURAL_HAM_SHORT(-0.98)[-0.977,0]; ASN(0.00)[asn:11403, ipnet:2610:1c1:1::/48, country:US] X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 16 Jan 2019 11:02:38 -0000 Author: rene Date: Wed Jan 16 11:02:35 2019 New Revision: 490469 URL: https://svnweb.freebsd.org/changeset/ports/490469 Log: mail/imap-uw: remove support for expired mail/drac Deleted: head/mail/imap-uw/files/patch-src_imapd_imapd.c Modified: head/mail/imap-uw/Makefile head/mail/imap-uw/files/patch-src_imapd_Makefile head/mail/imap-uw/files/patch-src_ipopd_Makefile head/mail/imap-uw/files/patch-src_ipopd_ipop3d.c head/mail/imap-uw/files/pkg-message.in Modified: head/mail/imap-uw/Makefile ============================================================================== --- head/mail/imap-uw/Makefile Wed Jan 16 10:55:55 2019 (r490468) +++ head/mail/imap-uw/Makefile Wed Jan 16 11:02:35 2019 (r490469) @@ -33,20 +33,14 @@ ALL_TARGET= bsf # This port must have the same SSL settings as mail/cclient, which it depends on # To make MBX format the default mailbox format, change the settings of cclient -OPTIONS_DEFINE= SSL SSL_AND_PLAINTEXT DRAC NETSCAPE_BRAIN_DAMAGE DOCS +OPTIONS_DEFINE= SSL SSL_AND_PLAINTEXT NETSCAPE_BRAIN_DAMAGE DOCS OPTIONS_DEFAULT= SSL OPTIONS_SUB= yes SSL_AND_PLAINTEXT_DESC= Allow plain text passwords and SSL -DRAC_DESC= Dynamically open MTA for relaying NETSCAPE_BRAIN_DAMAGE_DESC= See Makefile for documentation .include - -.if ${PORT_OPTIONS:MDRAC} -BUILD_DEPENDS= ${LOCALBASE}/lib/libdrac.a:mail/drac -MAKE_ARGS+= WITH_DRAC=yes -.endif .if ! ${PORT_OPTIONS:MSSL} MAKE_ARGS+= SSLTYPE=none SSLDIR=${OPENSSLBASE} Modified: head/mail/imap-uw/files/patch-src_imapd_Makefile ============================================================================== --- head/mail/imap-uw/files/patch-src_imapd_Makefile Wed Jan 16 10:55:55 2019 (r490468) +++ head/mail/imap-uw/files/patch-src_imapd_Makefile Wed Jan 16 11:02:35 2019 (r490469) @@ -55,7 +55,7 @@ clean: rm -f *.o imapd || true ---- 37,63 ---- +--- 37,59 ---- # causes the "Manage Mail" menu item to open the given URL, e.g. to point to # an alternative IMAP client (e.g. Pine) or perhaps to a homebrew mail # account management page. @@ -71,10 +71,6 @@ -DALERTFILE=\"$(ALERT)\" -DNNTPFILE=\"$(NNTP)\" \ -DUSERALERTFILE=\"$(USERALERT)\" -DSHUTDOWNFILE=\"$(SHUTDOWN)\" ! LDFLAGS+= $(EXTRALDFLAGS) -L$(LOCALBASE)/lib -lc-client4 -! .if defined(WITH_DRAC) -! CFLAGS+= -DETC_DIR=\"$(PREFIX)/etc\" -DDRAC_AUTH -! LDFLAGS+= -ldrac -! .endif all: imapd Modified: head/mail/imap-uw/files/patch-src_ipopd_Makefile ============================================================================== --- head/mail/imap-uw/files/patch-src_ipopd_Makefile Wed Jan 16 10:55:55 2019 (r490468) +++ head/mail/imap-uw/files/patch-src_ipopd_Makefile Wed Jan 16 11:02:35 2019 (r490469) @@ -1,6 +1,6 @@ --- src/ipopd/Makefile.orig Wed Oct 25 01:55:07 2000 +++ src/ipopd/Makefile Mon Oct 1 03:44:26 2001 -@@ -19,29 +19,25 @@ +@@ -19,29 +19,21 @@ C = ../c-client @@ -15,10 +15,6 @@ -LDFLAGS = $(CCLIENTLIB) `cat $C/LDFLAGS` +CFLAGS+= -DNFSKLUDGE -I$(LOCALBASE)/include/c-client +LDFLAGS+= -L$(LOCALBASE)/lib -lc-client4 -+.if defined(WITH_DRAC) -+CFLAGS+= -DDRAC_AUTH -DETC_DIR=\"$(PREFIX)/etc\" -+LDFLAGS+= -ldrac -+.endif ipopd: ipop2d ipop3d Modified: head/mail/imap-uw/files/patch-src_ipopd_ipop3d.c ============================================================================== --- head/mail/imap-uw/files/patch-src_ipopd_ipop3d.c Wed Jan 16 10:55:55 2019 (r490468) +++ head/mail/imap-uw/files/patch-src_ipopd_ipop3d.c Wed Jan 16 11:02:35 2019 (r490469) @@ -1,86 +1,6 @@ --- src/ipopd/ipop3d.c.orig 2008-06-04 20:18:34.000000000 +0200 +++ src/ipopd/ipop3d.c 2009-01-16 10:19:50.000000000 +0100 -@@ -34,6 +34,11 @@ - #include - #include "c-client.h" - -+#ifdef DRAC_AUTH -+#include -+#include -+#include -+#endif /* DRAC_AUTH */ - - #define CRLF PSOUT ("\015\012") /* primary output terpri */ - -@@ -59,6 +64,12 @@ - - /* Global storage */ - -+#ifdef DRAC_AUTH -+#define DRACTIMEOUT 10*60 /* check every 10 minutes */ -+time_t lastdrac = 0; /* time of last drac check */ -+extern char *getenv (); -+#endif /* DRAC_AUTH */ -+ - char *version = "104"; /* edit number of this server */ - short state = AUTHORIZATION; /* server state */ - short critical = NIL; /* non-zero if in critical code */ -@@ -100,7 +111,53 @@ - int mbxopen (char *mailbox); - long blat (char *text,long lines,unsigned long size,STRING *st); - void rset (); -- -+#ifdef DRAC_AUTH -+void drac_auth(); -+#endif /* DRAC_AUTH */ -+ -+#ifdef DRAC_AUTH -+/* DRAC Authorization -+ */ -+void drac_auth () -+{ -+ if (time (0) > lastdrac + DRACTIMEOUT) -+ { -+ FILE *dracconf; -+ char host[100]; -+ char *drachost; -+ char *err; -+ char *p; -+ -+ if ( (dracconf = fopen(ETC_DIR "/dracd.host", "r")) == NULL) -+ { -+ syslog (LOG_INFO, "dracd: error opening %s/dracd.host config file",ETC_DIR); -+ exit(1); -+ } -+ -+ fgets(host, 100, dracconf); -+ p = strchr(host, '\n'); -+ if(p != NULL) -+ *p = '\0'; -+ fclose(dracconf); -+ -+ if( drachost = (host) ) -+ { -+ struct sockaddr_in sin; -+ int sinlen = sizeof (struct sockaddr_in); -+ char *client = getpeername (0,(struct sockaddr *) &sin,(void *) &sinlen) ? -+ "UNKNOWN" : inet_ntoa (sin.sin_addr); -+ -+ lastdrac = time(0); -+ -+ if (dracauth(drachost, inet_addr(client), &err) != 0) -+ syslog (LOG_INFO, err); -+ else -+ syslog (LOG_INFO, "dracd: authorized ip %s", client); -+ } -+ } -+} -+#endif /* DRAC_AUTH */ -+ - /* Main program */ - - int main (int argc,char *argv[]) -@@ -113,7 +170,7 @@ +@@ -113,7 +113,7 @@ (((s = strrchr (argv[0],'/')) || (s = strrchr (argv[0],'\\'))) ? s+1 : argv[0]) : "ipop3d"; /* set service name before linkage */ @@ -89,43 +9,3 @@ #include "linkage.c" /* initialize server */ server_init (pgmname,"pop3","pop3s",clkint,kodint,hupint,trmint,NIL); -@@ -228,9 +285,13 @@ - syslog (LOG_INFO,"AUTHENTICATE %s failure host=%.80s",s, - tcp_clienthost ()); - } -- else if ((state = mbxopen ("INBOX")) == TRANSACTION) -+ else if ((state = mbxopen ("INBOX")) == TRANSACTION) { -+ #ifdef DRAC_AUTH -+ drac_auth(); -+ #endif /* DRAC_AUTH */ - syslog (LOG_INFO,"Auth user=%.80s host=%.80s nmsgs=%lu/%lu", - user,tcp_clienthost (),nmsgs,stream->nmsgs); -+ } - else syslog (LOG_INFO,"Auth user=%.80s host=%.80s no mailbox", - user,tcp_clienthost ()); - } -@@ -260,9 +321,13 @@ - PSOUT ("-ERR Missing APOP argument\015\012"); - else if (!(user = apop_login (challenge,s,t,argc,argv))) - PSOUT ("-ERR Bad APOP\015\012"); -- else if ((state = mbxopen ("INBOX")) == TRANSACTION) -+ else if ((state = mbxopen ("INBOX")) == TRANSACTION) { -+ #ifdef DRAC_AUTH -+ drac_auth(); -+ #endif /* DRAC_AUTH */ - syslog (LOG_INFO,"APOP user=%.80s host=%.80s nmsgs=%lu/%lu", - user,tcp_clienthost (),nmsgs,stream->nmsgs); -+ } - else syslog (LOG_INFO,"APOP user=%.80s host=%.80s no mailbox", - user,tcp_clienthost ()); - } -@@ -665,6 +730,9 @@ - /* attempt the login */ - if (server_login (user,pass,t,argc,argv)) { - int ret = mbxopen ("INBOX"); -+ #ifdef DRAC_AUTH -+ drac_auth(); -+ #endif /* DRAC_AUTH */ - if (ret == TRANSACTION) /* mailbox opened OK? */ - syslog (LOG_INFO,"%sLogin user=%.80s host=%.80s nmsgs=%lu/%lu", - t ? "Admin " : "",user,tcp_clienthost (),nmsgs,stream->nmsgs); Modified: head/mail/imap-uw/files/pkg-message.in ============================================================================== --- head/mail/imap-uw/files/pkg-message.in Wed Jan 16 10:55:55 2019 (r490468) +++ head/mail/imap-uw/files/pkg-message.in Wed Jan 16 11:02:35 2019 (r490469) @@ -31,12 +31,7 @@ dir accessed. WITHOUT_SSL - build without SSL/encryption support. WITH_SSL_AND_PLAINTEXT - build with SSL/encryption support, but allow non-encrypted logins. -%%DRAC%%================================================================================ -%%DRAC%%To have DRAC working, you must create ${PREFIX}/etc/dracd.host, containing -%%DRAC%%the hostname of the DRAC server: -%%DRAC%% -%%DRAC%%localhost -%%DRAC%%================================================================================ +%%SSL%%================================================================================ %%SSL%% %%SSL%%To create and install a new SSL certificate for imapd and ipop3d, type \"make %%SSL%%cert\". Or install manually in ${PREFIX}/certs.