summaryrefslogtreecommitdiff
path: root/net-mail/vpopmail
diff options
context:
space:
mode:
authorV3n3RiX <venerix@redcorelinux.org>2019-11-18 10:15:03 +0000
committerV3n3RiX <venerix@redcorelinux.org>2019-11-18 10:15:03 +0000
commitb284a3168fa91a038925d2ecf5e4791011ea5e7d (patch)
tree16fe44748708acacd909d4e2e160a09a7f6d936a /net-mail/vpopmail
parent77398e424e45d9e98c1cef3c43bdadb9d56e81ef (diff)
gentoo resync : 18.11.2019
Diffstat (limited to 'net-mail/vpopmail')
-rw-r--r--net-mail/vpopmail/Manifest7
-rw-r--r--net-mail/vpopmail/files/vpopmail-5.4.33-check-crypt-return-value-for-NULL.patch146
-rw-r--r--net-mail/vpopmail/files/vpopmail-5.4.33-use-proper-printf-format-strings.patch217
-rw-r--r--net-mail/vpopmail/vpopmail-5.4.33-r4.ebuild1
-rw-r--r--net-mail/vpopmail/vpopmail-5.4.33-r5.ebuild250
-rw-r--r--net-mail/vpopmail/vpopmail-5.4.33.ebuild1
6 files changed, 620 insertions, 2 deletions
diff --git a/net-mail/vpopmail/Manifest b/net-mail/vpopmail/Manifest
index 68d8d4a407da..6eba9c42bc2a 100644
--- a/net-mail/vpopmail/Manifest
+++ b/net-mail/vpopmail/Manifest
@@ -1,10 +1,12 @@
AUX 99vpopmail 64 BLAKE2B ab9b8b28494fa8093f1a72e582fc10787eb1f9814b860b1c03f4e336c6a8563b50b34fcc2c33d95e45703ebad5b8155d9575551c894af4e7c12b52748b526216 SHA512 8e9323006ddafae6e4ee8da2e0c9753ce11fd3f6e7c8bb6931ccc147ab6c9782c71d704222343be902f8784aa27a4425fd04a1f11cff5421dfc25fd76d3de953
+AUX vpopmail-5.4.33-check-crypt-return-value-for-NULL.patch 4034 BLAKE2B e45135fffe507f9c55fd2742ae68724694b9c29520059301c281f4a20ab5dbd26ac1f507166b6b4adef28f7435a71bc31de59eba171a7404e822acf5dd2dec41 SHA512 4f485c9ad927a92f7900545dcef7a875e151d403c14c22cb4fa5585aedc1effadf629df6e6cb0e5364cdf9451a71d3790c2297a0cc8a54518976adf1c50e421f
AUX vpopmail-5.4.33-clean-up-calling-maildrop.patch 2382 BLAKE2B 06f7ab5f6fdbb0dbade353dce74b2be585ed5a3f1ea617491ee437838f80c38b90f9e2c1a3a89efa6f788f30228e8e7449d8fdaa9db59c26231b16b849ce3f80 SHA512 99053bf41e405b22a4594104d3fce6ed831c6f5b8f8870bde7eb0e780948990de36158d7af055d881639503be1b911106a91f1787d524fe9c84fd3ec5503b055
AUX vpopmail-5.4.33-fix-S-tag-in-case-spamassassin-changed-the-file-size.patch 3281 BLAKE2B 7eecc6c5dc2eef263d212ec6ca0534d0c00faeef04994e5410dbbff6e00beb7df249276fad928467b8cc87610d49666d9c63a629c87f8a07fb0ea5b35c298589 SHA512 1d170e611e914dc1ef5e7140b661558d93d2466fd310ebb50ecfcdadcb27cbfaa44b702ded5e02296835aea7c0a4c0d2de8ddf3cde236fe15a6fe0c37edb259a
AUX vpopmail-5.4.33-fix-those-vfork-instances-that-do-more-than-exec.patch 2150 BLAKE2B 44d3226b95e19b60516dbd2c4ace2ada5ec53ee1479f45544113e207da79b7152958d85f3b0511565e820732e49f32d73ce74ef253dd286a0f960e6b7cb39a92 SHA512 077d8b035f2ae33354c4c51d9d4c068b4de4d0f56c1a076667425c903707a39460c03b83ee9163cf8ef11b424bdb0ddcf2e716d0cfdbd3b50863069035d2a66b
AUX vpopmail-5.4.33-remove-unneeded-forward-declaration.patch 771 BLAKE2B 565944744d74b6c4077cef4534aa01c50af21fdb1f2da11fc2baf4659b953516e2b017412cfc64d1d5a06f8e6f5d7355903787188ae24f3579e0ac0d2087e369 SHA512 e1e4b2f3d0d3c51b6341dc14583f336b86766885767c0188ee170e07979fdd6d59360d1942df6593e7f11dc043f49143dff98898cca4a55ba697b429f98eb123
AUX vpopmail-5.4.33-strncat.patch 6266 BLAKE2B 98656fb8d963df082ec48fbf7918423c8aeeeab6aebaab295f819b213e09d20e7b786057bf2c2fcf0a276cf9fc65c10978957cdb37dbc7cee57c0ff3eef9e78f SHA512 831ec541a52fe5e72f97832927ce0c6b8a90c2954d715be1c088f5886bba6058b313e4364e164c0af90d1de90f0890f9a1b64d1985ef1d448ac34e5951b0a16b
AUX vpopmail-5.4.33-unistd.patch 266 BLAKE2B 19dd429573f0b45b93cd35d522787029ba445c2f363a7a270ab1c547e4f0c2a7be89c287642a3e5e8d69ea59a82271aff271670d19d3850146e92a3389aa3dc8 SHA512 1cc6e6a067cabc004224c022af8c3ee90125a3b3daa9c346ca8a57962be30681a6181605624fc09a8992a7e3d3e7b3d8d6c0ce95095399c1a5dec798e9d6f6cd
+AUX vpopmail-5.4.33-use-proper-printf-format-strings.patch 9207 BLAKE2B 78d51e71fc29ede44e76109d43a0e4dc81458cb74c0873d33efdae33d7a99321e31839eff420654868f38b7e82677c345e276375fac3d9cf13ce54310e8235a3 SHA512 453887050002fb075046637b1ace82caeefd7c2a0f587403d24da0b9d0602a580d2d6595c2ea8af42f49fedd7c2168f9de46dd24f5aee0befab2ba0c7bb4e1c5
AUX vpopmail-5.4.33-vdelivermail-add-static.patch 1017 BLAKE2B 279bd5c2b894268910a89d1df206289fce475df9b655febc27eca6f1ecf1ecd6bc55e250d0eeb5e86e89a5df0543a08af34b379888ecb4590b91ba62b521b9f2 SHA512 bcf80e30d5010decad135a84527985a29d61d054a0396af662f33bc4a63c3dc1dd0585e884376f25babf0ca263d2496991b16d1c215962a64597f4cd1cd50ca0
AUX vpopmail-5.4.9-access.violation.patch 918 BLAKE2B ebf8c80ed2668d0bc96930493bd46788abf58d45defd5cb3ebcff0b67c0c31d7473b7dbf07c958366e18dc7ca56434a6e45b9bf7c9d920da993b8d51927df95a SHA512 6587d2a4ac7b6943b07db2334750db83aaf2e974053732696ad17846da29250a82ac91598f25f0cf1caafc731fdb89ec016e7ba6ff6f70ab269af3c0a15e80b5
AUX vpopmail-Maildir-dotmaildir-fix.sh 1346 BLAKE2B efc7c1e97c201e9f36c3b817538b87c5522b0b2b16b681e0bbbf77bdd8537634d56cbe29b7eb26d657d83fb696b0fc00724dea9d03f246794c5631f8c2ca7ce1 SHA512 201ad103157add727560bc1596042ae621d1645abf912aa3b3ec1af71aaf65dff92c967f000b7a126e9f2eb5e351838c78ffee855402d93bdcf89e96ebb0d0e9
@@ -12,6 +14,7 @@ AUX vpopmail-double-free.patch 399 BLAKE2B ac2d7ad9b8b3e9cf25fbd973c7e42e48c1107
AUX vpopmail-lazy.patch 323 BLAKE2B c35a878e2aa69a9ba0e108fdf4f0f8de85965588acc8d2c3fecb1d152e2f0e9585d78b9ce5b2314735de8b70710687e0a75358ef3029dd96eaa704941df00bd7 SHA512 794ef15920ac565073d871a946df53395afb0630d561343f4d164af3287d1665e115ad42d7a2218306cedb5dc795b10d9c15852b69fd649854ddb0c18dc0b2dd
AUX vpopmail-vpgsql.patch 2668 BLAKE2B 0f69aa8642d15d740e0e5944a438854fde240831176ae2152cc805809e5a87ecd8ce5c6791f4c4e53d2027393d158e28e9dbec49d0efd7c4c2d50c9eeb4cf10d SHA512 9f02f9f9ab186791fe071ee5cb27334144727e81f0bbd6b8f5ce472368f892f5396a225c6c1af9d5b7a66bf66e7be50aef146d7635132fab9d91f265b68af1d9
DIST vpopmail-5.4.33.tar.gz 612271 BLAKE2B 1dacc512c5d64e8f73a0630209407161afd87ebec510cdf57cb8aaa8be9b911141612d69892981a2545fc263e798f6e7dc9d5a283e1177e223f4a2e1fac80017 SHA512 abd5060d709c661d95ca442c6f77c4c27cf30a3c6790fc36d76ccf379ed2e08c1f0af697b2bcc57176a2cdb2cb67f6c27236d7b3fa69a135fa87f45a5df208ab
-EBUILD vpopmail-5.4.33-r4.ebuild 7613 BLAKE2B c2da7499b508a2a9896b1ec31435b095bda6984e2d2232ee472a24c0f623fff5b36b915e2cbd8dbf14bea2c0f64266e78db54be7d423a2c0ba4eaf2e160c8925 SHA512 87f8a7ad3b266148a87dfed4a432a422469e97deb97e43aacee6bfd6e2beb9229fe40b59322d78ed099b8a45dcd9c2ce79229c3649e404b9518115040eda99ef
-EBUILD vpopmail-5.4.33.ebuild 7658 BLAKE2B 585b4301997bcc0a13c40143338e29f2a054773c7477f3106dfd4ae71f787c15152f1fb9e84cf123c71092c42e0e42e96857ac5cb2ff1d918c87ffcb6f7c30fe SHA512 04ffa6437901fdb9f7d5a7f445dd60ff5f443d8c69add9a26d28c01f777195ea4d7f57bfef988c1452553b15d9a4fb8057ace7b6a004382f71e836fa4b9f9fdc
+EBUILD vpopmail-5.4.33-r4.ebuild 7633 BLAKE2B 10489cba302f017645c50b5fc1e50455c4a18ac80407e720f804e31a6f72c75ff6ebcc7257e818c617844635fe2252bb97cb30c26d60466e1a66c5215242776c SHA512 a94cee36d0803632634124a56bec6619889725a31b7383d816d1bbfa8bdf3661bf683a522391a34bf7f79249f577c0a120b9be1c2f9490b39b775aa9945460d4
+EBUILD vpopmail-5.4.33-r5.ebuild 7517 BLAKE2B 87f180f0ff4f1f76121cae28ce0d9eba40792e8038a09a7abe9e20a57ff4d7e51d5d9ef38a6f6338f9cd7d9e20147ddcf7a2fff02e2c527c88eaaa1e77b0f9b6 SHA512 daa486928665fbc90e56cf3702d5ba1c18cadbc8341ef624c489ef18eae68fed52a2d307691565e975c0560a85e3abf04160c99642c99f1b6f03e6730be00152
+EBUILD vpopmail-5.4.33.ebuild 7678 BLAKE2B 0784b6ac7398d33dd6cb4dfd067d4778568a24ca2a1b71fbc52ff541bcbe5878056c74560270f44f7da7edb7ddb17955a4320d79ebdb92945cfddaa3f68ae372 SHA512 d0e9c724e49dda58c838c98e40da28638b8c7e5063517c03d5f26a5d471427af0795ec32c0f8711e1ae37e0e6a851807640d1081f5e834daedd89d82e4e43365
MISC metadata.xml 798 BLAKE2B 9d38645910ab93bb1557fb51895900fc5280086a702d1b561a7676206147498a6c1cba59dde1e3f320fc20d3099f304ec71056273cf4955530cc59f0cc0b4439 SHA512 b91e76e79c223a21648a2c380d4d81517b4bab65238b641734d173312e2ced4004e31b7d4aaced92962ae5cd65bfaafe7ab2f14612489d28598b8b1d0a9a5465
diff --git a/net-mail/vpopmail/files/vpopmail-5.4.33-check-crypt-return-value-for-NULL.patch b/net-mail/vpopmail/files/vpopmail-5.4.33-check-crypt-return-value-for-NULL.patch
new file mode 100644
index 000000000000..cfe5ce90e07f
--- /dev/null
+++ b/net-mail/vpopmail/files/vpopmail-5.4.33-check-crypt-return-value-for-NULL.patch
@@ -0,0 +1,146 @@
+From b3a21a4a6d7af3dc14417c89ec2ef2732a24939b Mon Sep 17 00:00:00 2001
+From: Rolf Eike Beer <eike@sf-mail.de>
+Date: Sat, 26 Oct 2019 18:14:13 +0200
+Subject: [PATCH 1/2] check crypt() return value for NULL
+
+Passing NULL to strcmp() would lead to a crash otherwise.
+---
+ vcdb.c | 7 ++++++-
+ vchkpw.c | 11 +++++++++--
+ vldap.c | 8 +++++++-
+ vmysql.c | 8 +++++++-
+ vpgsql.c | 8 +++++++-
+ vsybase.c | 8 +++++++-
+ 6 files changed, 43 insertions(+), 7 deletions(-)
+
+diff --git a/vcdb.c b/vcdb.c
+index 55c1cb5..1bf9cd8 100644
+--- a/vcdb.c
++++ b/vcdb.c
+@@ -1160,7 +1160,12 @@ void vcdb_strip_char( char *instr )
+
+ int vauth_crypt(char *user,char *domain,char *clear_pass,struct vqpasswd *vpw)
+ {
++ const char *c;
+ if ( vpw == NULL ) return(-1);
+
+- return(strcmp(crypt(clear_pass,vpw->pw_passwd),vpw->pw_passwd));
++ c = crypt(clear_pass,vpw->pw_passwd);
++
++ if ( c == NULL ) return(-1);
++
++ return(strcmp(c,vpw->pw_passwd));
+ }
+diff --git a/vchkpw.c b/vchkpw.c
+index d7d4351..a7c4b9e 100644
+--- a/vchkpw.c
++++ b/vchkpw.c
+@@ -607,6 +607,7 @@ void login_system_user()
+ struct spwd *spw;
+ #endif
+ struct passwd *pw;
++ const char *c;
+
+ if ((pw=getpwnam(TheUser)) == NULL ) {
+ snprintf(LogLine, sizeof(LogLine), "%s: system user not found %s:%s",
+@@ -626,9 +627,15 @@ void login_system_user()
+ vchkpw_exit(22);
+ }
+
+- if ( strcmp(crypt(ThePass,spw->sp_pwdp),spw->sp_pwdp) != 0 ) {
++ c = crypt(ThePass,spw->sp_pwdp);
++
++ if ( c == NULL ) vchkpw_exit(24);
++ if ( strcmp(c,spw->sp_pwdp) != 0 ) {
+ #else
+- if ( strcmp(crypt(ThePass,pw->pw_passwd),pw->pw_passwd) != 0 ) {
++ c = crypt(ThePass,pw->pw_passwd);
++
++ if ( c == NULL ) vchkpw_exit(24);
++ if ( strcmp(c,pw->pw_passwd) != 0 ) {
+ #endif
+ if (ENABLE_LOGGING==1||ENABLE_LOGGING==2) {
+ snprintf(LogLine, sizeof(LogLine), "%s: system password fail %s:%s",
+diff --git a/vldap.c b/vldap.c
+index 75329ef..5fcce99 100644
+--- a/vldap.c
++++ b/vldap.c
+@@ -1495,10 +1495,16 @@ void *safe_malloc (size_t siz) {
+ /***************************************************************************/
+
+ int vauth_crypt(char *user,char *domain,char *clear_pass,struct vqpasswd *vpw) {
++ const char *c;
++
+ if ( vpw == NULL )
+ return(-1);
+
+- return(strcmp(crypt(clear_pass,vpw->pw_passwd),vpw->pw_passwd));
++ c = crypt(clear_pass,vpw->pw_passwd);
++
++ if ( c == NULL ) return(-1);
++
++ return(strcmp(c,vpw->pw_passwd));
+ }
+
+ /***************************************************************************/
+diff --git a/vmysql.c b/vmysql.c
+index 4215a39..c5173d9 100644
+--- a/vmysql.c
++++ b/vmysql.c
+@@ -1862,7 +1862,13 @@ int vdel_limits(const char *domain)
+ /************************************************************************/
+ int vauth_crypt(char *user,char *domain,char *clear_pass,struct vqpasswd *vpw)
+ {
++ const char *c;
++
+ if ( vpw == NULL ) return(-1);
+
+- return(strcmp(crypt(clear_pass,vpw->pw_passwd),vpw->pw_passwd));
++ c = crypt(clear_pass,vpw->pw_passwd);
++
++ if ( c == NULL ) return(-1);
++
++ return(strcmp(c,vpw->pw_passwd));
+ }
+diff --git a/vpgsql.c b/vpgsql.c
+index c55b9e2..b5dd40b 100644
+--- a/vpgsql.c
++++ b/vpgsql.c
+@@ -1667,8 +1667,14 @@ void vcreate_vlog_table()
+
+ int vauth_crypt(char *user,char *domain,char *clear_pass,struct vqpasswd *vpw)
+ {
++ const char *c;
++
+ if ( vpw == NULL ) return(-1);
+
+- return(strcmp(crypt(clear_pass,vpw->pw_passwd),vpw->pw_passwd));
++ c = crypt(clear_pass,vpw->pw_passwd);
++
++ if ( c == NULL ) return(-1);
++
++ return(strcmp(c,vpw->pw_passwd));
+ }
+
+diff --git a/vsybase.c b/vsybase.c
+index c6d7234..26f7447 100644
+--- a/vsybase.c
++++ b/vsybase.c
+@@ -640,7 +640,13 @@ int vshow_ip_map( int first, char *ip, char *domain);
+
+ int vauth_crypt(char *user,char *domain,char *clear_pass,struct vqpasswd *vpw)
+ {
++ const char *c;
++
+ if ( vpw == NULL ) return(-1);
+
+- return(strcmp(crypt(clear_pass,vpw->pw_passwd),vpw->pw_passwd));
++ c = crypt(clear_pass,vpw->pw_passwd);
++
++ if ( c == NULL ) return(-1);
++
++ return(strcmp(c,vpw->pw_passwd));
+ }
+--
+2.16.4
+
diff --git a/net-mail/vpopmail/files/vpopmail-5.4.33-use-proper-printf-format-strings.patch b/net-mail/vpopmail/files/vpopmail-5.4.33-use-proper-printf-format-strings.patch
new file mode 100644
index 000000000000..a0967166c1cf
--- /dev/null
+++ b/net-mail/vpopmail/files/vpopmail-5.4.33-use-proper-printf-format-strings.patch
@@ -0,0 +1,217 @@
+From 8ebcfc44379708521c41193057bb1549a3c1a2eb Mon Sep 17 00:00:00 2001
+From: Rolf Eike Beer <eike@sf-mail.de>
+Date: Sat, 26 Oct 2019 18:25:12 +0200
+Subject: [PATCH 2/2] use proper printf format strings
+
+---
+ maildirquota.c | 4 ++--
+ vlimits.c | 8 ++++----
+ vlistlib.c | 2 +-
+ vmoddomlimits.c | 8 ++++----
+ vpopmail.c | 17 +++++++++--------
+ vpopmaild.c | 20 ++++++++++----------
+ vusagec.c | 2 +-
+ 7 files changed, 31 insertions(+), 30 deletions(-)
+
+diff --git a/maildirquota.c b/maildirquota.c
+index 1c3dd44..11a0ce3 100644
+--- a/maildirquota.c
++++ b/maildirquota.c
+@@ -400,7 +400,7 @@ static int maildirsize_read(const char *filename, /* The filename */
+ first=0;
+ continue;
+ }
+- sscanf(q, "%llu %llu", &n, &c);
++ sscanf(q, "%" PRIu64 " %" PRIu64 "", &n, &c);
+ *sizeptr += n;
+ *cntptr += c;
+ ++ *nlines;
+@@ -806,7 +806,7 @@ int n;
+ niov=2;
+ }
+
+- sprintf(u.buf, "%llu %llu\n", maildirsize_size, maildirsize_cnt);
++ sprintf(u.buf, "%" PRIu64 " %" PRIu64 "\n", maildirsize_size, maildirsize_cnt);
+ iov[niov].iov_base=u.buf;
+ iov[niov].iov_len=strlen(u.buf);
+
+diff --git a/vlimits.c b/vlimits.c
+index af336d2..c4d76ba 100644
+--- a/vlimits.c
++++ b/vlimits.c
+@@ -480,10 +480,10 @@ int vlimits_write_limits_file(const char *dir, const struct vlimits *limits)
+ fprintf(fs, "maxforwards: %d\n", limits->maxforwards);
+ fprintf(fs, "maxautoresponders: %d\n", limits->maxautoresponders);
+ fprintf(fs, "maxmailinglists: %d\n", limits->maxmailinglists);
+- fprintf(fs, "quota: %llu\n", limits->diskquota);
+- fprintf(fs, "maxmsgcount: %llu\n", limits->maxmsgcount);
+- fprintf(fs, "default_quota: %llu\n", limits->defaultquota);
+- fprintf(fs, "default_maxmsgcount: %llu\n", limits->defaultmaxmsgcount);
++ fprintf(fs, "quota: %" PRIu64 "\n", limits->diskquota);
++ fprintf(fs, "maxmsgcount: %" PRIu64 "\n", limits->maxmsgcount);
++ fprintf(fs, "default_quota: %" PRIu64 "\n", limits->defaultquota);
++ fprintf(fs, "default_maxmsgcount: %" PRIu64 "\n", limits->defaultmaxmsgcount);
+ if (limits->disable_pop) fprintf(fs, "disable_pop\n");
+ if (limits->disable_imap) fprintf(fs, "disable_imap\n");
+ if (limits->disable_dialup) fprintf(fs, "disable_dialup\n");
+diff --git a/vlistlib.c b/vlistlib.c
+index 110a93e..cbb8242 100644
+--- a/vlistlib.c
++++ b/vlistlib.c
+@@ -488,7 +488,7 @@ void ezmlm_decode( listInfoType *LI ) {
+ if( (fs=fopen(TmpBuf, "r")) !=NULL ) {
+ if(fgets(TmpBuf2, sizeof(TmpBuf2), fs)) {
+ Tmp = strtok( TmpBuf2, ":" );
+- printf( " First Token: %s Len: %d\n", Tmp, strlen( Tmp ));
++ printf( " First Token: %s Len: %zu\n", Tmp, strlen( Tmp ));
+ if( NULL != Tmp ) {
+ for(i=0; i<strlen(Tmp); i++) LI->SQLHost[i] = Tmp[i];
+ LI->SQLHost[i] = (char) 0;
+diff --git a/vmoddomlimits.c b/vmoddomlimits.c
+index cff906a..7a9c8b8 100644
+--- a/vmoddomlimits.c
++++ b/vmoddomlimits.c
+@@ -207,10 +207,10 @@ int main(int argc, char *argv[])
+ printf ((limits.perm_defaultquota & VLIMIT_DISABLE_DELETE ? "DENY_DELETE " :"ALLOW_DELETE ") );
+
+ printf("\n");
+- printf("Domain Quota: %llu MB\n", limits.diskquota);
+- printf("Default User Quota: %llu bytes\n", limits.defaultquota);
+- printf("Max Domain Messages: %llu\n", limits.maxmsgcount);
+- printf("Default Max Messages per User: %llu\n", limits.defaultmaxmsgcount);
++ printf("Domain Quota: %" PRIu64 " MB\n", limits.diskquota);
++ printf("Default User Quota: %" PRIu64 " bytes\n", limits.defaultquota);
++ printf("Max Domain Messages: %" PRIu64 "\n", limits.maxmsgcount);
++ printf("Default Max Messages per User: %" PRIu64 "\n", limits.defaultmaxmsgcount);
+ return(vexit(0));
+ }
+
+diff --git a/vpopmail.c b/vpopmail.c
+index 3b6a3e5..c389c7c 100644
+--- a/vpopmail.c
++++ b/vpopmail.c
+@@ -31,6 +31,7 @@
+ #include <fcntl.h>
+ #include <time.h>
+ #include <dirent.h>
++#include <inttypes.h>
+ #include <pwd.h>
+ #include "config.h"
+ #ifdef HAVE_ERR_H
+@@ -737,13 +738,13 @@ int vadduser( char *username, char *domain, char *password, char *gecos,
+
+ if (limits.defaultquota > 0) {
+ if (limits.defaultmaxmsgcount > 0)
+- snprintf (quota, sizeof(quota), "%lluS,%lluC", limits.defaultquota,
++ snprintf (quota, sizeof(quota), "%" PRIu64 "S,%" PRIu64 "C", limits.defaultquota,
+ limits.defaultmaxmsgcount);
+ else
+- snprintf (quota, sizeof(quota), "%lluS", limits.defaultquota);
++ snprintf (quota, sizeof(quota), "%" PRIu64 "S", limits.defaultquota);
+ } else {
+ if (limits.defaultmaxmsgcount > 0)
+- snprintf (quota, sizeof(quota), "%lluC", limits.defaultmaxmsgcount);
++ snprintf (quota, sizeof(quota), "%" PRIu64 "C", limits.defaultmaxmsgcount);
+ else
+ strcpy (quota, "NOQUOTA");
+ }
+@@ -3822,11 +3823,11 @@ static char tempquota[128];
+
+ if (quota_count == 0)
+ if (quota_size == 0) strcpy (tempquota, ""); /* invalid quota */
+- else sprintf (tempquota, "%lluS", quota_size);
++ else sprintf (tempquota, "%" PRIu64 "S", quota_size);
+ else if (quota_size == 0)
+- sprintf (tempquota, "%lluC", quota_count);
++ sprintf (tempquota, "%" PRIu64 "C", quota_count);
+ else
+- sprintf (tempquota, "%lluS,%lluC", quota_size, quota_count);
++ sprintf (tempquota, "%" PRIu64 "S,%" PRIu64 "C", quota_size, quota_count);
+
+ return tempquota;
+ }
+@@ -4050,8 +4051,8 @@ int qnprintf (char *buffer, size_t size, const char *format, ...)
+ snprintf (n, sizeof(n), "%u", va_arg (ap, unsigned int));
+ break;
+
+- case 'S':
+- snprintf(n, sizeof(n), "%llu", va_arg(ap, storage_t));
++ case 'S':
++ snprintf(n, sizeof(n), "%" PRIu64, va_arg(ap, storage_t));
+ break;
+
+ case 'l':
+diff --git a/vpopmaild.c b/vpopmaild.c
+index f257a52..9cf2981 100644
+--- a/vpopmaild.c
++++ b/vpopmaild.c
+@@ -2280,13 +2280,13 @@ int get_limits()
+ mylimits.maxautoresponders); wait_write();
+ snprintf(WriteBuf,sizeof(WriteBuf), "max_mailinglists %d" RET_CRLF,
+ mylimits.maxmailinglists); wait_write();
+- snprintf(WriteBuf,sizeof(WriteBuf), "disk_quota %llu" RET_CRLF,
++ snprintf(WriteBuf,sizeof(WriteBuf), "disk_quota %" PRIu64 RET_CRLF,
+ mylimits.diskquota); wait_write();
+- snprintf(WriteBuf,sizeof(WriteBuf), "max_msgcount %llu" RET_CRLF,
++ snprintf(WriteBuf,sizeof(WriteBuf), "max_msgcount %" PRIu64 RET_CRLF,
+ mylimits.maxmsgcount); wait_write();
+- snprintf(WriteBuf,sizeof(WriteBuf), "default_quota %llu" RET_CRLF,
++ snprintf(WriteBuf,sizeof(WriteBuf), "default_quota %" PRIu64 RET_CRLF,
+ mylimits.defaultquota); wait_write();
+- snprintf(WriteBuf,sizeof(WriteBuf), "default_maxmsgcount %llu" RET_CRLF,
++ snprintf(WriteBuf,sizeof(WriteBuf), "default_maxmsgcount %" PRIu64 RET_CRLF,
+ mylimits.defaultmaxmsgcount); wait_write();
+
+ if (mylimits.disable_pop)
+@@ -2625,9 +2625,9 @@ int get_user_size()
+
+ snprintf(WriteBuf, sizeof(WriteBuf), "%s", RET_OK_MORE);
+ wait_write();
+- snprintf(WriteBuf, sizeof(WriteBuf), "size %llu" RET_CRLF, bytes);
++ snprintf(WriteBuf, sizeof(WriteBuf), "size %" PRIu64 RET_CRLF, bytes);
+ wait_write();
+- snprintf(WriteBuf, sizeof(WriteBuf), "count %llu" RET_CRLF, cnt);
++ snprintf(WriteBuf, sizeof(WriteBuf), "count %" PRIu64 RET_CRLF, cnt);
+ wait_write();
+ snprintf(WriteBuf, sizeof(WriteBuf), "%s", "." RET_CRLF);
+
+@@ -2680,9 +2680,9 @@ int get_domain_size()
+ } else {
+ snprintf(WriteBuf, sizeof(WriteBuf), "user %s@%s" RET_CRLF, tmpvpw->pw_name, domain);
+ wait_write();
+- snprintf(WriteBuf, sizeof(WriteBuf), "size %llu" RET_CRLF, bytes);
++ snprintf(WriteBuf, sizeof(WriteBuf), "size %" PRIu64 RET_CRLF, bytes);
+ wait_write();
+- snprintf(WriteBuf, sizeof(WriteBuf), "count %llu" RET_CRLF, cnt);
++ snprintf(WriteBuf, sizeof(WriteBuf), "count %" PRIu64 RET_CRLF, cnt);
+ wait_write();
+ totalbytes += (unsigned long)bytes;
+ totalcnt += (unsigned int)cnt;
+@@ -2691,9 +2691,9 @@ int get_domain_size()
+
+ snprintf(WriteBuf, sizeof(WriteBuf), "domain %s" RET_CRLF, domain);
+ wait_write();
+- snprintf(WriteBuf, sizeof(WriteBuf), "size %llu" RET_CRLF, totalbytes);
++ snprintf(WriteBuf, sizeof(WriteBuf), "size %" PRIu64 RET_CRLF, totalbytes);
+ wait_write();
+- snprintf(WriteBuf, sizeof(WriteBuf), "count %llu" RET_CRLF, totalcnt);
++ snprintf(WriteBuf, sizeof(WriteBuf), "count %" PRIu64 RET_CRLF, totalcnt);
+ wait_write();
+ snprintf(WriteBuf, sizeof(WriteBuf), "%s", "." RET_CRLF);
+
+diff --git a/vusagec.c b/vusagec.c
+index c32c2fe..5cc6dda 100644
+--- a/vusagec.c
++++ b/vusagec.c
+@@ -67,7 +67,7 @@ int main(int argc, char *argv[])
+ if (uusage == -1)
+ printf("%s: No data available\n", argv[i]);
+ else
+- printf("%s: %llu byte(s) in %llu file(s)\n", *(argv[i]) == '@' ? (argv[i] + 1) : argv[i], uusage, musage);
++ printf("%s: %" PRIu64 " byte(s) in %" PRIu64 " file(s)\n", *(argv[i]) == '@' ? (argv[i] + 1) : argv[i], uusage, musage);
+ }
+
+ client_close(handle);
+--
+2.16.4
+
diff --git a/net-mail/vpopmail/vpopmail-5.4.33-r4.ebuild b/net-mail/vpopmail/vpopmail-5.4.33-r4.ebuild
index fc5ea8ec4219..6e9edf574f83 100644
--- a/net-mail/vpopmail/vpopmail-5.4.33-r4.ebuild
+++ b/net-mail/vpopmail/vpopmail-5.4.33-r4.ebuild
@@ -17,6 +17,7 @@ REQUIRED_USE="mysql? ( !postgres )"
DEPEND="
acct-group/vpopmail
+ acct-user/vpopmail
virtual/qmail
maildrop? ( mail-filter/maildrop )
mysql? ( dev-db/mysql-connector-c:0= )
diff --git a/net-mail/vpopmail/vpopmail-5.4.33-r5.ebuild b/net-mail/vpopmail/vpopmail-5.4.33-r5.ebuild
new file mode 100644
index 000000000000..8041e1622084
--- /dev/null
+++ b/net-mail/vpopmail/vpopmail-5.4.33-r5.ebuild
@@ -0,0 +1,250 @@
+# Copyright 1999-2019 Gentoo Authors
+# Distributed under the terms of the GNU General Public License v2
+
+EAPI=7
+
+inherit autotools fixheadtails qmail
+
+HOMEPAGE="http://www.inter7.com/index.php?page=vpopmail"
+DESCRIPTION="Collection of programs to manage virtual email on Qmail servers"
+SRC_URI="mirror://sourceforge/${PN}/${P}.tar.gz"
+
+LICENSE="GPL-2"
+SLOT="0"
+KEYWORDS="~amd64 ~arm ~hppa ~ia64 ~ppc ~ppc64 ~s390 ~sh ~sparc ~x86"
+IUSE="clearpasswd ipalias maildrop mysql postgres spamassassin"
+REQUIRED_USE="mysql? ( !postgres )"
+
+DEPEND="
+ acct-group/vpopmail
+ acct-user/vpopmail
+ virtual/qmail
+ maildrop? ( mail-filter/maildrop )
+ mysql? ( dev-db/mysql-connector-c:0= )
+ postgres? ( dev-db/postgresql:=[server] )
+ spamassassin? ( mail-filter/spamassassin )"
+RDEPEND="${DEPEND}"
+
+PATCHES=(
+ "${FILESDIR}"/${PN}-5.4.9-access.violation.patch
+ "${FILESDIR}"/${PN}-lazy.patch
+ "${FILESDIR}"/${PN}-vpgsql.patch
+ "${FILESDIR}"/${PN}-double-free.patch
+ "${FILESDIR}"/${PN}-5.4.33-vdelivermail-add-static.patch
+ "${FILESDIR}"/${PN}-5.4.33-fix-those-vfork-instances-that-do-more-than-exec.patch
+ "${FILESDIR}"/${PN}-5.4.33-remove-unneeded-forward-declaration.patch
+ "${FILESDIR}"/${PN}-5.4.33-clean-up-calling-maildrop.patch
+ "${FILESDIR}"/${PN}-5.4.33-fix-S-tag-in-case-spamassassin-changed-the-file-size.patch
+ "${FILESDIR}"/${PN}-5.4.33-strncat.patch
+ "${FILESDIR}"/${PN}-5.4.33-unistd.patch
+ "${FILESDIR}"/${PN}-5.4.33-check-crypt-return-value-for-NULL.patch
+ "${FILESDIR}"/${PN}-5.4.33-use-proper-printf-format-strings.patch
+)
+DOCS=(
+ ChangeLog
+ doc/.
+)
+HTML_DOCS=(
+ doc_html/.
+ man_html/.
+)
+
+VPOP_HOME="/var/vpopmail"
+
+pkg_setup() {
+ upgradewarning
+}
+
+src_prepare() {
+ default
+
+ echo 'install-recursive: install-exec-am' \
+ >>"${S}"/Makefile.am || die
+
+ # fix maildir paths
+ sed -i -e 's|Maildir|.maildir|g' \
+ vchkpw.c vconvert.c vdelivermail.c \
+ vpopbull.c vpopmail.c vqmaillocal.c \
+ vuserinfo.c maildirquota.c || die
+
+ # remove vpopmail advertisement
+ sed -i -e '/printf.*vpopmail/s:vpopmail (:(:' \
+ vdelivermail.c vpopbull.c vqmaillocal.c || die
+
+ # automake/autoconf
+ mv "${S}"/configure.{in,ac} || die
+ sed -i -e 's,AM_CONFIG_HEADER,AC_CONFIG_HEADERS,g' \
+ configure.ac || die
+
+ # _FORTIFY_SOURCE
+ sed -i \
+ -e 's/\(snprintf(\s*\(LI->[a-zA-Z_]\+\),\s*\)[a-zA-Z_]\+,/\1 sizeof(\2),/' \
+ vlistlib.c || die
+
+ eautoreconf
+ ht_fix_file cdb/Makefile
+}
+
+src_configure() {
+ local -a authopts
+ if use mysql; then
+ incdir=$(mysql_config --variable=pkgincludedir || die)
+ libdir=$(mysql_config --variable=pkglibdir || die)
+ authopts+=( "--enable-auth-module=mysql"
+ "--enable-incdir=${incdir}"
+ "--enable-libdir=${libdir}"
+ "--enable-sql-logging"
+ "--enable-valias"
+ "--disable-mysql-replication"
+ "--enable-mysql-limits"
+ )
+ elif use postgres; then
+ libdir=$(pg_config --libdir || die)
+ incdir=$(pg_config --pkgincludedir || die)
+ authopts+=( "--enable-auth-module=pgsql"
+ "--enable-incdir=${incdir}"
+ "--enable-libdir=${libdir}"
+ "--enable-sql-logging"
+ "--enable-valias"
+ )
+ else
+ authopts+=( "--enable-auth-module=cdb" )
+ fi
+
+ econf ${authopts[@]} \
+ --sysconfdir=${VPOP_HOME}/etc \
+ --enable-non-root-build \
+ --enable-qmaildir=${QMAIL_HOME} \
+ --enable-qmail-newu=${QMAIL_HOME}/bin/qmail-newu \
+ --enable-qmail-inject=${QMAIL_HOME}/bin/qmail-inject \
+ --enable-qmail-newmrh=${QMAIL_HOME}/bin/qmail-newmrh \
+ --enable-vpopuser=vpopmail \
+ --enable-vpopgroup=vpopmail \
+ --enable-many-domains \
+ --enable-file-locking \
+ --enable-file-sync \
+ --enable-md5-passwords \
+ --enable-logging \
+ --enable-auth-logging \
+ --enable-log-name=vpopmail \
+ --enable-qmail-ext \
+ --disable-tcpserver-file \
+ --disable-roaming-users \
+ $(use_enable ipalias ip-alias-domains) \
+ $(use_enable clearpasswd clear-passwd) \
+ $(use_enable maildrop) \
+ $(use_enable maildrop maildrop-prog /usr/bin/maildrop) \
+ $(use_enable spamassassin)
+}
+
+src_install() {
+ emake DESTDIR="${D}" install
+ keepdir "${VPOP_HOME}"/domains
+
+ # install helper script for maildir conversion
+ into "${VPOP_HOME}"
+ dobin "${FILESDIR}"/vpopmail-Maildir-dotmaildir-fix.sh
+ into /usr
+
+ mv doc/doc_html/ doc/man_html/ . || die
+ einstalldocs
+ rm -r "${D}/${VPOP_HOME}"/doc || die
+
+ # create /etc/vpopmail.conf
+ if use mysql; then
+ insinto /etc
+ newins "${D}${VPOP_HOME}"/etc/vpopmail.mysql vpopmail.conf
+ dosym ../../etc/vpopmail.conf "${VPOP_HOME}"/etc/vpopmail.mysql
+
+ sed 's/^[^#]/# &/' -i "${D}"/etc/vpopmail.conf || die
+ echo '# Read-only DB' >> "${D}"/etc/vpopmail.conf || die
+ echo 'localhost|0|vpopmail|secret|vpopmail' >> "${D}"/etc/vpopmail.conf || die
+ echo '# Write DB' >> "${D}"/etc/vpopmail.conf || die
+ echo 'localhost|0|vpopmail|secret|vpopmail' >> "${D}"/etc/vpopmail.conf || die
+
+ # lock down perms
+ fperms 640 /etc/vpopmail.conf
+ fowners root:vpopmail /etc/vpopmail.conf
+ fi
+
+ insinto "${VPOP_HOME}"/etc
+ doins vusagec.conf
+ dosym .."${VPOP_HOME}"/etc/vusagec.conf /etc/vusagec.conf
+ sed -i 's/Disable = False;/Disable = True;/g' "${D}${VPOP_HOME}"/etc/vusagec.conf || die
+
+ einfo "Installing env.d entry"
+ doenvd "${FILESDIR}"/99vpopmail
+
+ einfo "Locking down vpopmail permissions"
+ fowners -R root:0 "${VPOP_HOME}"/{bin,etc,include}
+ fowners root:vpopmail "${VPOP_HOME}"/bin/vchkpw
+ fperms 4711 "${VPOP_HOME}"/bin/vchkpw
+}
+
+pkg_postinst() {
+ if use mysql ; then
+ elog
+ elog "You have 'mysql' turned on in your USE"
+ elog "Vpopmail needs a VALID MySQL USER. Let's call it 'vpopmail'"
+ elog "You MUST add it and then specify its passwd in the /etc/vpopmail.conf file"
+ elog
+ elog "First log into mysql as your mysql root user and pass. Then:"
+ elog "> create database vpopmail;"
+ elog "> use mysql;"
+ elog "> grant select, insert, update, delete, create, drop on vpopmail.* to"
+ elog " vpopmail@localhost identified by 'your password';"
+ elog "> flush privileges;"
+ elog
+ elog "If you have problems with vpopmail not accepting mail properly,"
+ elog "please ensure that /etc/vpopmail.conf is chmod 640 and"
+ elog "owned by root:vpopmail"
+ elog
+ fi
+
+ # do this for good measure
+ if [[ -e /etc/vpopmail.conf ]]; then
+ chmod 640 /etc/vpopmail.conf || die
+ chown root:vpopmail /etc/vpopmail.conf || die
+ fi
+
+ upgradewarning
+}
+
+pkg_postrm() {
+ elog "The vpopmail DATA will NOT be removed automatically."
+ elog "You can delete them manually by removing the ${VPOP_HOME} directory."
+}
+
+upgradewarning() {
+ if has_version "<=net-mail/vpopmail-5.2.1-r8"; then
+ ewarn
+ ewarn "Massive important warning if you are upgrading to 5.2.1-r8 or older"
+ ewarn "The internal structure of the mail storage has changed for"
+ ewarn "consistancy with the rest of Gentoo! Please review and utilize the "
+ ewarn "script at ${VPOP_HOME}/bin/vpopmail-Maildir-dotmaildir-fix.sh"
+ ewarn "to upgrade your system! (It can do conversions both ways)."
+ ewarn "You should be able to run it right away without any changes."
+ ewarn
+ fi
+
+ elog
+ elog "Use of vpopmail's tcp.smtp[.cdb] is also deprecated now, consider"
+ elog "using net-mail/relay-ctrl instead."
+ elog
+
+ if use mysql; then
+ if has_version "<=net-mail/vpopmail-5.4.17"; then
+ elog
+ elog "If you are upgrading from 5.4.17 or older, you have to fix your"
+ elog "MySQL tables, please see the UPGRADE file in the documentation!"
+ elog
+ fi
+ fi
+
+ ewarn
+ ewarn "Newer versions of vpopmail contain a quota daemon called vusaged."
+ ewarn "This ebuild DOES NOT INSTALL vusaged and has therefore disabled"
+ ewarn "its usage in ${VPOP_HOME}/etc/vusagec.conf. DO NOT ENABLE!"
+ ewarn "Otherwise mail delivery WILL BREAK"
+ ewarn
+}
diff --git a/net-mail/vpopmail/vpopmail-5.4.33.ebuild b/net-mail/vpopmail/vpopmail-5.4.33.ebuild
index e91114dbf411..a38b01a00823 100644
--- a/net-mail/vpopmail/vpopmail-5.4.33.ebuild
+++ b/net-mail/vpopmail/vpopmail-5.4.33.ebuild
@@ -16,6 +16,7 @@ IUSE="clearpasswd ipalias maildrop mysql spamassassin"
DEPEND="
acct-group/vpopmail
+ acct-user/vpopmail
virtual/qmail
maildrop? ( mail-filter/maildrop )
mysql? ( virtual/mysql )