MFH: r556068

mail/mutt: Update to 2.0.2

ChangeLog: https://marc.info/?l=mutt-users&m=160589518808669&w=2

vuxml entry in PR: 251278

PR:	251277
Submitted by:	dereks@lifeofadishwasher.com

Approved by:	ports-secteam (blanket, security fix)
This commit is contained in:
Fernando Apesteguía 2020-11-23 08:19:56 +00:00
parent 08682d4012
commit 8593605964
Notes: svn2git 2021-03-31 03:12:20 +00:00
svn path=/branches/2020Q4/; revision=556093
6 changed files with 15 additions and 129 deletions

View File

@ -2,7 +2,7 @@
# $FreeBSD$
PORTNAME= mutt
DISTVERSION= 1.14.7
DISTVERSION= 2.0.2
CATEGORIES+= mail
MASTER_SITES= ftp://ftp.mutt.org/pub/mutt/ \
https://bitbucket.org/mutt/mutt/downloads/ \
@ -26,33 +26,30 @@ RUN_DEPENDS= ${LOCALBASE}/etc/mime.types:misc/mime-support
USES= cpe perl5 shebangfix ssl
USE_PERL5= build
CONFLICTS= ja-mutt-[0-9]* ja-mutt-devel-[0-9]* mutt-1.4* mutt-devel-lite-[0-9]* mutt-lite-[0-9]* zh-mutt-devel-[0-9]*
SHEBANG_FILES= doc/gen-map-doc smime_keys.pl contrib/smime_keys_test.pl
GNU_CONFIGURE= yes
CONFIGURE_ARGS= --disable-fcntl --with-ssl=${OPENSSLBASE} \
--with-docdir=${DOCSDIR} --sysconfdir=${PREFIX}/etc \
--enable-external-dotlock --enable-pop --enable-imap \
--enable-compressed --enable-sidebar
INFO= ${PORTNAME}
SHEBANG_FILES= doc/gen-map-doc smime_keys.pl contrib/smime_keys_test.pl
.if defined(MUTT_CONFIGURE_ARGS)
CONFIGURE_ARGS+= ${MUTT_CONFIGURE_ARGS}
.endif
GNU_CONFIGURE= yes
CONFLICTS= ja-mutt-[0-9]* ja-mutt-devel-[0-9]* mutt-1.4* mutt-devel-lite-[0-9]* mutt-lite-[0-9]* zh-mutt-devel-[0-9]*
INFO= ${PORTNAME}
OPTIONS_SUB= yes
OPTIONS_DEFINE= AUTOCRYPT DEBUG_LOGS DOCS EXAMPLES FLOCK FORCEBASE64 GPGME \
OPTIONS_DEFINE= AUTOCRYPT DEBUG_LOGS DOCS EXAMPLES FLOCK GPGME \
GREETING_PATCH HTML ICONV IDN IFDEF_PATCH LOCALES_FIX \
MAILBOX_MANPAGES MAILDIR_MTIME_PATCH NLS QUOTE_PATCH \
REVERSE_REPLY_PATCH SASL SMIME SMART_DATE SMTP URLVIEW
OPTIONS_SINGLE= GSSAPI HCACHE SCREEN
OPTIONS_RADIO= SPELL
OPTIONS_RADIO_SPELL= ASPELL ISPELL
OPTIONS_SINGLE_GSSAPI= GSSAPI_BASE GSSAPI_HEIMDAL GSSAPI_MIT GSSAPI_NONE
OPTIONS_SINGLE_HCACHE= HCACHE_BDB HCACHE_TOKYOCABINET HCACHE_KYOTOCABINET HCACHE_NONE
OPTIONS_SINGLE_SCREEN= NCURSES SLANG
@ -60,7 +57,6 @@ OPTIONS_SINGLE_SCREEN= NCURSES SLANG
AUTOCRYPT_DESC= Convenient End-to-End Encryption
DEBUG_LOGS_DESC= Debugging capabilities
FLOCK_DESC= flock() usage
FORCEBASE64_DESC= Option to force base64 encoding for compose
GPGME_DESC= Gpgme interface
GREETING_PATCH_DESC= Greeting support
HCACHE_BDB_DESC= Use Berkeley DB (BDB)
@ -103,10 +99,6 @@ AUTOCRYPT_DEPENDS= gnupg>=2.1:security/gnupg \
AUTOCRYPT_BUILD_DEPENDS= ${AUTOCRYPT_DEPENDS}
AUTOCRYPT_RUN_DEPENDS= ${AUTOCRYPT_DEPENDS}
ASPELL_BUILD_DEPENDS= aspell:textproc/aspell
ASPELL_RUN_DEPENDS= aspell:textproc/aspell
ISPELL_BUILD_DEPENDS= ispell:textproc/aspell-ispell
ISPELL_RUN_DEPENDS= ispell:textproc/aspell-ispell
URLVIEW_RUN_DEPENDS= urlview:textproc/urlview
DEBUG_LOGS_CONFIGURE_ON= --enable-debug
@ -176,8 +168,6 @@ GPGME_CONFIGURE_ENABLE= gpgme
SMTP_CONFIGURE_ENABLE= smtp
FORCEBASE64_EXTRA_PATCHES= ${PATCHDIR}/extra-patch-forcebase64
MAILDIR_MTIME_PATCH_EXTRA_PATCHES= ${PATCHDIR}/extra-patch-maildir-mtime
GREETING_PATCH_PATCHFILES= mutt-${GREETING_PATCH_VERSION}.vc.greeting:vc
@ -187,9 +177,8 @@ QUOTE_PATCH_PATCHFILES= patch-${VVV_PATCH_VERSION}.vvv.initials.xz:vvv \
.include <bsd.port.options.mk>
# un/comment as each VERSION is created for PORTVERSION
VVV_PATCH_VERSION= 1.13.0
GREETING_PATCH_VERSION= 1.14.3
GREETING_PATCH_VERSION= 2.0.1
post-install:
${INSTALL_MAN} ${FILESDIR}/mailcap.5 ${STAGEDIR}${MANPREFIX}/man/man5
@ -216,10 +205,4 @@ post-stage::
${STAGEDIR}/${LOCALBASE}/etc/Muttrc.sample
@${RM} ${STAGEDIR}/${LOCALBASE}/etc/mime.types*
# Change default ispell
post-build-ASPELL-on:
@${REINPLACE_CMD} -e '/^# append-hook/p' \
-e 's/^# append-hook.*$$/set ispell="aspell --mode=email check"/' \
${WRKSRC}/doc/Muttrc
.include <bsd.port.mk>

View File

@ -1,8 +1,8 @@
TIMESTAMP = 1598742511
SHA256 (mutt/mutt-1.14.7.tar.gz) = e4f507b133253cb5eef27996b8668956cdf9caac622cf8adad13f0f9a4eda864
SIZE (mutt/mutt-1.14.7.tar.gz) = 5009968
SHA256 (mutt/mutt-1.14.3.vc.greeting) = c6067f19e51e99e3c981c0c45a29fb442626d8bb3f0df56736ce4ee0eb0bfa83
SIZE (mutt/mutt-1.14.3.vc.greeting) = 4472
TIMESTAMP = 1605903183
SHA256 (mutt/mutt-2.0.2.tar.gz) = 471218babe97968a45704f1e1e17523c4620ad1f92bae4143a4c9749ab1411c8
SIZE (mutt/mutt-2.0.2.tar.gz) = 5293613
SHA256 (mutt/mutt-2.0.1.vc.greeting) = 28d157df0ca36f2448dcc3d1cd19e34ec0eefe88251ebf1951e080d7178cccd2
SIZE (mutt/mutt-2.0.1.vc.greeting) = 4452
SHA256 (mutt/patch-1.13.0.vvv.initials.xz) = 8b25ad6596bd57d94f6551e7e73ceb8da620468e96fb507b2f51545d5b3eaa02
SIZE (mutt/patch-1.13.0.vvv.initials.xz) = 720
SHA256 (mutt/patch-1.13.0.vvv.quote.xz) = 788d25d1439d86d6c5007d141d1c219496e77940b5ce37819471c941f78f03e4

View File

@ -1,37 +0,0 @@
--- init.h.orig 2019-12-08 02:41:29 UTC
+++ init.h
@@ -1079,6 +1079,11 @@ struct option_t MuttVars[] = {
** sent to both the list and your address, resulting in two copies
** of the same email for you.
*/
+ { "force_base64", DT_BOOL, R_NONE, {.l=OPTFORCEBASE64}, {.l=0} },
+ /*
+ ** .pp
+ ** If you need to encode all text parts to base64, set this option.
+ */
{ "force_name", DT_BOOL, R_NONE, {.l=OPTFORCENAME}, {.l=0} },
/*
** .pp
--- mutt.h.orig 2019-12-08 02:41:29 UTC
+++ mutt.h
@@ -423,6 +423,7 @@ enum
OPTFCCCLEAR,
OPTFLAGSAFE,
OPTFOLLOWUPTO,
+ OPTFORCEBASE64,
OPTFORCENAME,
OPTFORWDECODE,
OPTFORWQUOTE,
--- sendlib.c.orig 2019-12-08 02:41:29 UTC
+++ sendlib.c
@@ -1218,7 +1218,9 @@ static void mutt_set_encoding (BODY *b, CONTENT *info)
if (b->type == TYPETEXT)
{
char *chsname = mutt_get_body_charset (send_charset, sizeof (send_charset), b);
- if ((info->lobin && ascii_strncasecmp (chsname, "iso-2022", 8)) || info->linemax > 990 || (info->from && option (OPTENCODEFROM)))
+ if (option (OPTFORCEBASE64))
+ b->encoding = ENCBASE64;
+ else if ((info->lobin && ascii_strncasecmp (chsname, "iso-2022", 8)) || info->linemax > 990 || (info->from && option (OPTENCODEFROM)))
b->encoding = ENCQUOTEDPRINTABLE;
else if (info->hibin)
b->encoding = option (OPTALLOW8BIT) ? ENC8BIT : ENCQUOTEDPRINTABLE;

View File

@ -1,25 +0,0 @@
--- muttlib.c.orig 2020-05-05 02:09:34 UTC
+++ muttlib.c
@@ -930,16 +930,15 @@ void _mutt_buffer_mktemp (BUFFER *buf, const char *pre
void _mutt_mktemp (char *s, size_t slen, const char *prefix, const char *suffix,
const char *src, int line)
{
- size_t n = snprintf (s, slen, "%s/%s-%s-%d-%d-%ld%ld%s%s",
- NONULL (Tempdir), NONULL (prefix), NONULL (Hostname),
- (int) getuid (), (int) getpid (), random (), random (),
- suffix ? "." : "", NONULL (suffix));
+ size_t n = snprintf (s, slen, "%s/mutt-%s-XXXXXXXX", NONULL (Tempdir), NONULL (Hostname));
if (n >= slen)
dprint (1, (debugfile, "%s:%d: ERROR: insufficient buffer space to hold temporary filename! slen=%zu but need %zu\n",
src, line, slen, n));
- dprint (3, (debugfile, "%s:%d: mutt_mktemp returns \"%s\".\n", src, line, s));
- if (unlink (s) && errno != ENOENT)
- dprint (1, (debugfile, "%s:%d: ERROR: unlink(\"%s\"): %s (errno %d)\n", src, line, s, strerror (errno), errno));
+ if (mktemp (s)) {
+ dprint (3, (debugfile, "%s:%d: mutt_mktemp returns \"%s\".\n", src, line, s));
+ } else {
+ dprint (1, (debugfile, "%s:%d: ERROR: mktemp(\"%s\"): %s (errno %d)\n", src, line, s, strerror (errno), errno));
+ }
}
/* these characters must be escaped in regular expressions */

View File

@ -1,37 +0,0 @@
--- mutt.h.orig 2020-05-25 22:13:51 UTC
+++ mutt.h
@@ -242,6 +242,7 @@ enum
MUTT_EXPIRED,
MUTT_SUPERSEDED,
MUTT_TRASH,
+ MUTT_THREADCOMPLETE,
/* actions for mutt_pattern_comp/mutt_pattern_exec */
MUTT_AND,
--- pattern.c.orig 2020-05-25 20:41:30 UTC
+++ pattern.c
@@ -57,6 +57,7 @@ static const struct pattern_flags
}
Flags[] =
{
+ { 'a', MUTT_THREADCOMPLETE, 0, NULL },
{ 'A', MUTT_ALL, 0, NULL },
{ 'b', MUTT_BODY, MUTT_FULL_MSG|MUTT_SEND_MODE_SEARCH, eat_regexp },
{ 'B', MUTT_WHOLE_MSG, MUTT_FULL_MSG|MUTT_SEND_MODE_SEARCH, eat_regexp },
@@ -1499,6 +1500,16 @@ mutt_pattern_exec (struct pattern_t *pat, pattern_exec
else
result = mutt_is_list_cc (pat->alladdr, h->env->to, h->env->cc);
return (pat->not ^ result);
+ case MUTT_THREADCOMPLETE:
+ { static pattern_t tmp;
+ static short pattern_set = 0;
+ if(! pattern_set) {
+ memset (&tmp, 0, sizeof (tmp));
+ tmp.op = MUTT_TAG;
+ pattern_set = 1;
+ }
+ return (pat->not ^ (h->env && match_threadcomplete(&tmp, flags, ctx, h->thread, 1, 1, 1, 1)));
+ }
case MUTT_SUBSCRIBED_LIST:
if (cache)
{

View File

@ -70,6 +70,8 @@ man/man5/muttrc.5.gz
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/iconv/iconv.solaris-2.6.rc
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/iconv/iconv.solaris-2.7.rc
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/markdown2html
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/mutt_oauth2.py
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/mutt_oauth2.py.README
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/mutt_xtitle
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/pgp2.rc
%%PORTEXAMPLES%%%%EXAMPLESDIR%%/pgp5.rc