1 |
commit: 2fd41b355486a055f724150695e1cca74d0fdade |
2 |
Author: Thomas Deutschmann <whissi <AT> gentoo <DOT> org> |
3 |
AuthorDate: Sat Sep 5 23:19:23 2020 +0000 |
4 |
Commit: Thomas Deutschmann <whissi <AT> gentoo <DOT> org> |
5 |
CommitDate: Sat Sep 5 23:45:17 2020 +0000 |
6 |
URL: https://gitweb.gentoo.org/repo/gentoo.git/commit/?id=2fd41b35 |
7 |
|
8 |
net-mail/dovecot: fix auth mech APOP |
9 |
|
10 |
Closes: https://bugs.gentoo.org/739504 |
11 |
Package-Manager: Portage-3.0.4, Repoman-3.0.1 |
12 |
Signed-off-by: Thomas Deutschmann <whissi <AT> gentoo.org> |
13 |
|
14 |
net-mail/dovecot/dovecot-2.3.11.3.ebuild | 2 + |
15 |
.../dovecot/files/dovecot-2.3.11.3-apop-fix.patch | 60 ++++++++++++++++++++++ |
16 |
2 files changed, 62 insertions(+) |
17 |
|
18 |
diff --git a/net-mail/dovecot/dovecot-2.3.11.3.ebuild b/net-mail/dovecot/dovecot-2.3.11.3.ebuild |
19 |
index 28775017b56..386cbfb5c53 100644 |
20 |
--- a/net-mail/dovecot/dovecot-2.3.11.3.ebuild |
21 |
+++ b/net-mail/dovecot/dovecot-2.3.11.3.ebuild |
22 |
@@ -69,6 +69,8 @@ RDEPEND="${DEPEND} |
23 |
acct-user/dovenull |
24 |
net-mail/mailbase" |
25 |
|
26 |
+PATCHES=( "${FILESDIR}"/${P}-apop-fix.patch ) |
27 |
+ |
28 |
pkg_setup() { |
29 |
if use managesieve && ! use sieve; then |
30 |
ewarn "managesieve USE flag selected but sieve USE flag unselected" |
31 |
|
32 |
diff --git a/net-mail/dovecot/files/dovecot-2.3.11.3-apop-fix.patch b/net-mail/dovecot/files/dovecot-2.3.11.3-apop-fix.patch |
33 |
new file mode 100644 |
34 |
index 00000000000..667b4829f1c |
35 |
--- /dev/null |
36 |
+++ b/net-mail/dovecot/files/dovecot-2.3.11.3-apop-fix.patch |
37 |
@@ -0,0 +1,60 @@ |
38 |
+From 3c5917d1abee8f4af43b5016ddb897154912eb8d Mon Sep 17 00:00:00 2001 |
39 |
+From: Aki Tuomi <aki.tu...@××××××××××××.com> |
40 |
+Date: Thu, 13 Aug 2020 19:13:49 +0300 |
41 |
+Subject: [PATCH 2/2] auth: test-mech - Fix type mismatch |
42 |
+ |
43 |
+--- |
44 |
+ src/auth/test-mech.c | 4 ++-- |
45 |
+ 1 file changed, 2 insertions(+), 2 deletions(-) |
46 |
+ |
47 |
+diff --git a/src/auth/test-mech.c b/src/auth/test-mech.c |
48 |
+index 0a030a2be0..0a22ff46d0 100644 |
49 |
+--- a/src/auth/test-mech.c |
50 |
++++ b/src/auth/test-mech.c |
51 |
+@@ -192,7 +192,7 @@ static void test_mech_handle_challenge(struct auth_request *request, |
52 |
+ } |
53 |
+ |
54 |
+ static inline const unsigned char * |
55 |
+-test_mech_construct_apop_challenge(unsigned int connect_uid, unsigned long *len_r) |
56 |
++test_mech_construct_apop_challenge(unsigned int connect_uid, size_t *len_r) |
57 |
+ { |
58 |
+ string_t *apop_challenge = t_str_new(128); |
59 |
+ |
60 |
+@@ -323,7 +323,7 @@ static void test_mechs(void) |
61 |
+ struct test_case *test_case = &tests[running_test]; |
62 |
+ const struct mech_module *mech = test_case->mech; |
63 |
+ struct auth_request *request; |
64 |
+- const char *testname = t_strdup_printf("auth mech %s %d/%lu", |
65 |
++ const char *testname = t_strdup_printf("auth mech %s %d/%zu", |
66 |
+ mech->mech_name, |
67 |
+ running_test+1, |
68 |
+ N_ELEMENTS(tests)); |
69 |
+-- |
70 |
+2.11.0 |
71 |
+ |
72 |
+From 47ebfeef07d0908ba6b66344b0f630a21b81bcab Mon Sep 17 00:00:00 2001 |
73 |
+From: Aki Tuomi <aki.tu...@××××××××××××.com> |
74 |
+Date: Thu, 13 Aug 2020 19:13:04 +0300 |
75 |
+Subject: [PATCH 1/2] auth: test-mech - Fix APOP challenge format |
76 |
+ |
77 |
+--- |
78 |
+ src/auth/test-mech.c | 4 ++-- |
79 |
+ 1 file changed, 2 insertions(+), 2 deletions(-) |
80 |
+ |
81 |
+diff --git a/src/auth/test-mech.c b/src/auth/test-mech.c |
82 |
+index cf05370035..0a030a2be0 100644 |
83 |
+--- a/src/auth/test-mech.c |
84 |
++++ b/src/auth/test-mech.c |
85 |
+@@ -196,8 +196,8 @@ test_mech_construct_apop_challenge(unsigned int connect_uid, unsigned long *len_ |
86 |
+ { |
87 |
+ string_t *apop_challenge = t_str_new(128); |
88 |
+ |
89 |
+- str_printfa(apop_challenge,"<%lx.%u.%"PRIdTIME_T"", (unsigned long) getpid(), |
90 |
+- connect_uid, process_start_time+10); |
91 |
++ str_printfa(apop_challenge,"<%lx.%lx.%"PRIxTIME_T".", (unsigned long)getpid(), |
92 |
++ (unsigned long)connect_uid, process_start_time+10); |
93 |
+ str_append_data(apop_challenge, "\0testuser\0responseoflen16-", 26); |
94 |
+ *len_r = apop_challenge->used; |
95 |
+ return apop_challenge->data; |
96 |
+-- |
97 |
+2.11.0 |