Re: Sieve forwarding loop destroys e-mail

2008-03-30 Thread Alain Spineux
On Mon, Mar 17, 2008 at 5:39 PM, Gary Mills [EMAIL PROTECTED] wrote:
 Once again, we had somebody use the sieve facility to redirect e-mail
  back to the same mailbox and then go on vacation.  This sets up a
  forwarding loop which cyrus breaks by discarding the e-mail.  During
  this vacation, all of the person's e-mail disappeared.

If you force a keep in your sieve script, the mail will be delivered
at least once in
the mailbox

  Shouldn't we have a better solution to this problem?  Some people
  expect that forwarding e-mail to yourself should work; nobody expects
  the messages to vanish without a trace.

You must enforce this at sieve script creation, because sieve and even cyrus
dont know about yourself. They dont know if the forwarding address is
not an alias or even an external address with a forwarding to the cyrus mailbox.


  Once the message has been `seen' and is about to be forwarded again,
  it would be better to deliver the message into the mailbox, rather
  than deleting it.  Is this possible with the current design of the
  duplicate delivery database?

How can a message be 'seen' if it is not in the mailbox, and how can
the mailbox owner read this message if he is in vacation ?
Or you mean 'seen', already in the delivered db ? But then this
is the job of the delivered db to drop the email to avoid loop.

enforce a keep in the sieve script is a good solution.

Reagrds


  --
  -Gary Mills--Unix Support--U of M Academic Computing and Networking-
  
  Cyrus Home Page: http://cyrusimap.web.cmu.edu/
  Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
  List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html




-- 
Alain Spineux
aspineux gmail com
May the sources be with you

Cyrus Home Page: http://cyrusimap.web.cmu.edu/
Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html


Re: error when applying UoA patches to cyrus-imapd 2.3.11

2008-03-30 Thread Aristotelis
David Newman wrote:
 Greetings. I'm building a 2.3.11 server from ports on FreeBSD 7.0/i386. 
 I'm also using these two University of Athens patches:
 
 http://email.uoa.gr/download/cyrus/cyrus-imapd-2.3.11/cyrus-imapd-2.3.11-autocreate-0.10-0.diff
 
 http://email.uoa.gr/download/cyrus/cyrus-imapd-2.3.11/cyrus-imapd-2.3.11-autosieve-0.6.0.diff
 
 The following steps produced the error output pasted below. Thanks in 
 advance for any help in understanding what's wrong.
 
 cd /usr/ports/mail/cyrus-imapd23/
 make patch
 cd work/cyrus-imapd-2.3.11/
 patch -p1  ~/cyrus-imapd-2.3.11-autocreate-0.10-0.diff
 patch -p1  ~/cyrus-imapd-2.3.11-autosieve-0.6.0.diff
 cd ../..
 make
 
 snip

  Hello,
thanks for using our patch.

  This is a bit of a known issue. The FreeBSD ports system changes the 
Makefiles for their own build system, and the autocreate patch has to 
change the makefiles since the sieve libraries are needed also in other 
places (because of the autocreate functionality).  If you follow the 
normal patch procedure and you add the autocreate patch in the patches 
that are in the ports build system, then the autocreate patch will not 
be applied successfully since there will be conflicts in the makefiles 
again.  (The rules apply also to autosieve if i remember correctly).

  Unfortunately i don't have a freeBSD system at hand to see the changed 
that are needed (which are not backward compatible with the vanilla 
cyrus distribution), and it is quite hard for us to produce different 
patches for different operating systems. (that's why we have all the uoa 
patches against the vanilla cyrus distribution).

Best regards,
Aristotelis

Cyrus Home Page: http://cyrusimap.web.cmu.edu/
Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html


Re: Sieve forwarding loop destroys e-mail

2008-03-30 Thread Joseph Brennan


--On Sunday, March 30, 2008 2:27 PM +0100 Alain Spineux 
[EMAIL PROTECTED] wrote:

  Shouldn't we have a better solution to this problem?  Some people
  expect that forwarding e-mail to yourself should work; nobody expects
  the messages to vanish without a trace.

 You must enforce this at sieve script creation,


No, it is just totally wrong that an action other than 'discard' will
result in mail silently vanishing.  Maybe this is what does happen, but
it is not what _should_ happen as was asked.  It _should_ either go to
inbox (grounds: ignore a bad rule) or back to sender (grounds: not
deliverable as configured).

Joseph Brennan
Columbia University Information Technology



Cyrus Home Page: http://cyrusimap.web.cmu.edu/
Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html


Re: Sieve forwarding loop destroys e-mail

2008-03-30 Thread Jo Rhett
Joseph Brennan wrote:
 No, it is just totally wrong that an action other than 'discard' will
 result in mail silently vanishing.  Maybe this is what does happen, but
 it is not what _should_ happen as was asked.  It _should_ either go to
 inbox (grounds: ignore a bad rule)

You are assuming that a bad rule is something a computer program can 
figured out.  I would ask that you spend some time determining how the 
program could determine it is a bad rule, and provide a patch to fix 
this behavior.  (in short -- it's harder than you think)

  or back to sender (grounds: not deliverable as configured).

Only if you want to become a source for backscatter.

-- 
Jo Rhett
Net Consonance ... net philanthropy, open source and other randomness

Cyrus Home Page: http://cyrusimap.web.cmu.edu/
Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html


IMAPS problem

2008-03-30 Thread Bernhard D Rohrer
Hi all

I have created my TLS cert according to these instructions:

openssl req -new -nodes -out req.pem -keyout key.pem  
openssl rsa -in key.pem -out new.key.pem
openssl x509 -in req.pem -out ca-cert -req \
-signkey new.key.pem -days 999 

mkdir /var/imap

cp new.key.pem /var/imap/server.pem
rm new.key.pem
cat ca-cert  /var/imap/server.pem

chown cyrus:mail /var/imap/server.pem
chmod 600 /var/imap/server.pem # Your key should be protected

echo tls_ca_file: /var/imap/server.pem  /etc/imapd.conf
echo tls_cert_file: /var/imap/server.pem  /etc/imapd.conf
echo tls_key_file: /var/imap/server.pem  /etc/imapd.conf

[EMAIL PROTECTED]:/usr/lib/ssl# ls -al im*
-rw--- 1 cyrus mail 5219 2008-03-31 00:12 imap.pem

and I am getting this error:

Mar 31 01:33:41 collab cyrus/imaps[12733]: unable to get certificate 
from '/usr/lib/ssl/imap.pem'
Mar 31 01:33:41 collab cyrus/imaps[12733]: TLS server engine: cannot 
load cert/key data, may be a cert/key mismatch?
Mar 31 01:33:41 collab cyrus/imaps[12733]: error initializing TLS
Mar 31 01:33:41 collab cyrus/imaps[12733]: Fatal error: tls_init() failed
Mar 31 01:33:41 collab cyrus/imaps[12733]: DBERROR: error exiting 
application: Invalid argument

help??

thanks

Bernhard

-- 
Graylion's Fetish  Fashion Store
Goth and Kinky Boots, Clothing and Jewellery
http://www.graylion.net


Cyrus Home Page: http://cyrusimap.web.cmu.edu/
Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html


Re: IMAPS problem

2008-03-30 Thread Patrick Boutilier
Bernhard D Rohrer wrote:
 Hi all
 
 I have created my TLS cert according to these instructions:
 
 openssl req -new -nodes -out req.pem -keyout key.pem  
 openssl rsa -in key.pem -out new.key.pem
 openssl x509 -in req.pem -out ca-cert -req \
 -signkey new.key.pem -days 999 
 
 mkdir /var/imap
 
 cp new.key.pem /var/imap/server.pem
 rm new.key.pem
 cat ca-cert  /var/imap/server.pem
 
 chown cyrus:mail /var/imap/server.pem
 chmod 600 /var/imap/server.pem # Your key should be protected
 
 echo tls_ca_file: /var/imap/server.pem  /etc/imapd.conf
 echo tls_cert_file: /var/imap/server.pem  /etc/imapd.conf
 echo tls_key_file: /var/imap/server.pem  /etc/imapd.conf
 
 [EMAIL PROTECTED]:/usr/lib/ssl# ls -al im*
 -rw--- 1 cyrus mail 5219 2008-03-31 00:12 imap.pem
 
 and I am getting this error:
 
 Mar 31 01:33:41 collab cyrus/imaps[12733]: unable to get certificate 
 from '/usr/lib/ssl/imap.pem'
 Mar 31 01:33:41 collab cyrus/imaps[12733]: TLS server engine: cannot 
 load cert/key data, may be a cert/key mismatch?
 Mar 31 01:33:41 collab cyrus/imaps[12733]: error initializing TLS
 Mar 31 01:33:41 collab cyrus/imaps[12733]: Fatal error: tls_init() failed
 Mar 31 01:33:41 collab cyrus/imaps[12733]: DBERROR: error exiting 
 application: Invalid argument
 
 help??


unable to get certificate from '/usr/lib/ssl/imap.pem'

Look in /etc/imapd.conf and make sure you don't have tls_cert_file 
defined twice.


 
 thanks
 
 Bernhard
 


Cyrus Home Page: http://cyrusimap.web.cmu.edu/
Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html


Re: IMAPS problem

2008-03-30 Thread Alain Spineux
On Mon, Mar 31, 2008 at 2:37 AM, Bernhard D Rohrer [EMAIL PROTECTED] wrote:
 Hi all

  I have created my TLS cert according to these instructions:

  openssl req -new -nodes -out req.pem -keyout key.pem
  openssl rsa -in key.pem -out new.key.pem
  openssl x509 -in req.pem -out ca-cert -req \
  -signkey new.key.pem -days 999

  mkdir /var/imap

  cp new.key.pem /var/imap/server.pem
  rm new.key.pem
  cat ca-cert  /var/imap/server.pem

  chown cyrus:mail /var/imap/server.pem
  chmod 600 /var/imap/server.pem # Your key should be protected

  echo tls_ca_file: /var/imap/server.pem  /etc/imapd.conf
  echo tls_cert_file: /var/imap/server.pem  /etc/imapd.conf
  echo tls_key_file: /var/imap/server.pem  /etc/imapd.conf

  [EMAIL PROTECTED]:/usr/lib/ssl# ls -al im*
  -rw--- 1 cyrus mail 5219 2008-03-31 00:12 imap.pem

  and I am getting this error:

  Mar 31 01:33:41 collab cyrus/imaps[12733]: unable to get certificate
  from '/usr/lib/ssl/imap.pem'
  Mar 31 01:33:41 collab cyrus/imaps[12733]: TLS server engine: cannot
  load cert/key data, may be a cert/key mismatch?
  Mar 31 01:33:41 collab cyrus/imaps[12733]: error initializing TLS
  Mar 31 01:33:41 collab cyrus/imaps[12733]: Fatal error: tls_init() failed
  Mar 31 01:33:41 collab cyrus/imaps[12733]: DBERROR: error exiting
  application: Invalid argument

Maybe a problem with your tls_session.db file,
delete it and let cyrus create a new one. This is probably not the solution but
so easy to try.


  help??

  thanks

  Bernhard

  --
  Graylion's Fetish  Fashion Store
  Goth and Kinky Boots, Clothing and Jewellery
  http://www.graylion.net

  
  Cyrus Home Page: http://cyrusimap.web.cmu.edu/
  Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
  List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html




-- 
Alain Spineux
aspineux gmail com
May the sources be with you

Cyrus Home Page: http://cyrusimap.web.cmu.edu/
Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html


Re: Sieve forwarding loop destroys e-mail

2008-03-30 Thread Gary Mills
On Sun, Mar 30, 2008 at 02:27:29PM +0100, Alain Spineux wrote:
 On Mon, Mar 17, 2008 at 5:39 PM, Gary Mills [EMAIL PROTECTED] wrote:
  Once again, we had somebody use the sieve facility to redirect e-mail
   back to the same mailbox and then go on vacation.  This sets up a
   forwarding loop which cyrus breaks by discarding the e-mail.  During
   this vacation, all of the person's e-mail disappeared.
 
 If you force a keep in your sieve script, the mail will be delivered
 at least once in
 the mailbox

It's perfectly valid to have nothing but a `forward' in a sieve
script.  People do this all the time when they don't want to keep
a copy for themselves.  Unfortunately, some also forward e-mail to
themselves, expecting that to work.

   Once the message has been `seen' and is about to be forwarded again,
   it would be better to deliver the message into the mailbox, rather
   than deleting it.  Is this possible with the current design of the
   duplicate delivery database?
 
 How can a message be 'seen' if it is not in the mailbox, and how can
 the mailbox owner read this message if he is in vacation ?
 Or you mean 'seen', already in the delivered db ? But then this
 is the job of the delivered db to drop the email to avoid loop.

I suppose I mean `delivered'.  Yes, it will be discarded the next time
it's delivered.  That's the problem.  There needs to be some
connection between delivery and the forwarding process.  Of course,
it's impossible to distinguish between a forwarding loop and a real
duplicate unless another `Received' header is added to the message
header.

-- 
-Gary Mills--Unix Support--U of M Academic Computing and Networking-

Cyrus Home Page: http://cyrusimap.web.cmu.edu/
Cyrus Wiki/FAQ: http://cyrusimap.web.cmu.edu/twiki
List Archives/Info: http://asg.web.cmu.edu/cyrus/mailing-list.html