Bug 166488 - [PATCH] www/mod_auth_imap2: add dovecot patch
Summary: [PATCH] www/mod_auth_imap2: add dovecot patch
Status: Closed FIXED
Alias: None
Product: Ports & Packages
Classification: Unclassified
Component: Individual Port(s) (show other bugs)
Version: Latest
Hardware: Any Any
: Normal Affects Only Me
Assignee: Olli Hauer
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-03-29 12:30 UTC by Radim Kolar
Modified: 2012-08-29 13:00 UTC (History)
1 user (show)

See Also:


Attachments
ap22-mod_auth_imap-2.2.0_2.patch (1.98 KB, patch)
2012-03-29 12:30 UTC, Radim Kolar
no flags Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Radim Kolar 2012-03-29 12:30:07 UTC
Make this module to work with Dovecot
Tested against dovecot 2.0 branch

Added file(s):
- files/dovecot.patch

Port maintainer (apache@FreeBSD.org) is cc'd.

Generated with FreeBSD Port Tools 0.99_4 (mode: change, diff: ports)
Comment 1 Edwin Groothuis freebsd_committer freebsd_triage 2012-03-29 12:30:19 UTC
Responsible Changed
From-To: freebsd-ports-bugs->apache

Over to maintainer (via the GNATS Auto Assign Tool)
Comment 2 Chris Rees freebsd_committer freebsd_triage 2012-07-14 15:58:53 UTC
State Changed
From-To: open->feedback

While you're waiting for apache@ to look at it, I suggest you write the 
OPTIONS as per the Handbook (OPTIONSng).  Also, use EXTRA_PATCHES 
instead of manually writing the post-patch target.  Also, could you 
improve the OPTION description?
Comment 3 Radim Kolar 2012-07-14 17:30:00 UTC
Here is reworked patch.
Difference between this and old version is that we apply dovecot patch 
anyway because it follows IMAP4 protocol and
will not break non dovecot system.

===> Viewing diff with more
diff -ruN --exclude=CVS /usr/ports/www/mod_auth_imap2/Makefile ./Makefile
--- /usr/ports/www/mod_auth_imap2/Makefile      2011-08-20 
19:27:39.000000000 +0200
+++ ./Makefile  2012-07-14 18:14:19.337700139 +0200
@@ -7,7 +7,7 @@

  PORTNAME=      mod_auth_imap
  PORTVERSION=   2.2.0
-PORTREVISION=  1
+PORTREVISION=  2
  CATEGORIES=    www
  MASTER_SITES= http://ben.brillat.net/files/projects/mod_auth_imap2/
  DISTNAME=      mod_auth_imap2-${PORTVERSION}
@@ -16,7 +16,9 @@
  MAINTAINER=    apache@FreeBSD.org
  COMMENT=       An Apache 2 module to provide authentication via an 
IMAP mail server

-MAKE_JOBS_SAFE=  yes
+LICENSE=       GPLv2
+
+MAKE_JOBS_SAFE=        yes

  WRKSRC=                ${WRKDIR}/${PORTNAME}2-${PORTVERSION}
  USE_APACHE=    20+
diff -ruN --exclude=CVS 
/usr/ports/www/mod_auth_imap2/files/patch-dovecot ./files/patch-dovecot
--- /usr/ports/www/mod_auth_imap2/files/patch-dovecot   1970-01-01 
01:00:00.000000000 +0100
+++ ./files/patch-dovecot       2012-03-29 12:40:09.000000000 +0200
@@ -0,0 +1,23 @@
+--- mod_auth_imap.c.orig       2006-05-08 01:22:43.000000000 +0200
++++ mod_auth_imap.c    2012-03-29 12:38:30.911364281 +0200
+@@ -170,7 +170,7 @@
+     tcp_gets(Sock,result,500);
+
+     //skip lines that start with "*"
+-    if (strncmp(result,"* ",2 == 0)) {
++    if (strncmp(result,"* ",2) == 0) {
+       tcp_gets(Sock,result,500);
+     }
+
+@@ -188,6 +188,11 @@
+     tcp_puts(Sock,buf);
+     tcp_gets(Sock,result,500);
+
++    //skip lines that start with "*"
++    if (strncmp(result,"* ",2) == 0) {
++       tcp_gets(Sock,result,500);
++    }
++
+     if (strncmp(result,"A002 OK",7) == 0) {
+         if (logflag) {
+ 
ap_log_rerror(APLOG_MARK,APLOG_WARNING|APLOG_NOERRNO,0,r,"mod_auth_imap: 
Verified login for user %s.", username);
===> Done
Comment 4 Olli Hauer freebsd_committer freebsd_triage 2012-08-25 18:35:28 UTC
State Changed
From-To: feedback->open

I'll take it. 

I've send the patch upstreamso a new source can be rolled, 
waiting for upstream feedback. 

Btw. we prefer such platform independent patches are sent 
to upstream, so they can roll a new source file 




Comment 5 Olli Hauer freebsd_committer freebsd_triage 2012-08-25 18:35:28 UTC
Responsible Changed
From-To: apache->ohauer
Comment 6 dfilter service freebsd_committer freebsd_triage 2012-08-29 12:57:39 UTC
Author: ohauer
Date: Wed Aug 29 11:57:30 2012
New Revision: 303335
URL: http://svn.freebsd.org/changeset/ports/303335

Log:
  - add missing patch
  
  PR:             ports/166488
  Submitted by:   Radim Kolar <hsn@filez.com>

Added:
  head/www/mod_auth_imap2/files/
  head/www/mod_auth_imap2/files/patch-mod_auth_imap.c   (contents, props changed)

Added: head/www/mod_auth_imap2/files/patch-mod_auth_imap.c
==============================================================================
--- /dev/null	00:00:00 1970	(empty, because file is newly added)
+++ head/www/mod_auth_imap2/files/patch-mod_auth_imap.c	Wed Aug 29 11:57:30 2012	(r303335)
@@ -0,0 +1,23 @@
+--- ./mod_auth_imap.c.orig	2006-05-08 01:22:43.000000000 +0200
++++ ./mod_auth_imap.c	2012-08-25 19:06:59.000000000 +0200
+@@ -170,7 +170,7 @@
+     tcp_gets(Sock,result,500);
+ 
+     //skip lines that start with "*"
+-    if (strncmp(result,"* ",2 == 0)) {
++    if (strncmp(result,"* ",2) == 0) {
+ 	tcp_gets(Sock,result,500);
+     }
+ 
+@@ -188,6 +188,11 @@
+     tcp_puts(Sock,buf);
+     tcp_gets(Sock,result,500);
+ 
++    //skip lines that start with "*"
++    if (strncmp(result,"* ",2) == 0) {
++       tcp_gets(Sock,result,500);
++    }
++
+     if (strncmp(result,"A002 OK",7) == 0) {
+         if (logflag) {
+             ap_log_rerror(APLOG_MARK,APLOG_WARNING|APLOG_NOERRNO,0,r,"mod_auth_imap: Verified login for user %s.", username);
_______________________________________________
svn-ports-all@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/svn-ports-all
To unsubscribe, send any mail to "svn-ports-all-unsubscribe@freebsd.org"
Comment 7 Olli Hauer freebsd_committer freebsd_triage 2012-08-29 12:58:39 UTC
State Changed
From-To: open->closed

Committed, 
Thanks