[Dovecot] DSpam mysql-plugin (was DSpam plugin)
After wrestling with Johannes's original plugin, I had a go at the mysql plugin that Tim wrote, as described here: http://members.plug.org.au/~linuxalien/dokuwiki/projects:dovecot-mysql-dspam...
I kept getting "Error: imap dump-capability process killed with signal 11" when attempting to start dovecot with this plugin. I traced the error to line 656 of master-settings.c in the dovecot source, in the 'get_imap_capability' function. In this function, it notes: "Reloading configuration. Don't try to execute the imap process again. Too risky and the wait() call below will break it anyway. Just use the previous capability list we already had generated."
I changed the source so that the function always ran " set->imap_generated_capability = p_strdup(settings_pool, generated_capability); return TRUE;"
instead of going through the function where it had on the wait described in the comments.
Now, voila. Dovecot starts without complaint, the plugin works, the delivery and moving of email works.
I'm assuming I've screwed something up by skipping the rest of this get_imap_capability function. My C skills are a few years rusty. What are the ramifications of skipping the remainder of this function?
Thanks, Michael
On Wed, 2006-09-20 at 15:40 -0400, Michael Blinn wrote:
After wrestling with Johannes's original plugin, I had a go at the mysql plugin that Tim wrote, as described here: http://members.plug.org.au/~linuxalien/dokuwiki/projects:dovecot-mysql-dspam...
I kept getting "Error: imap dump-capability process killed with signal 11" when attempting to start dovecot with this plugin.
That's odd. Probably a programming error in the plugin?
I traced the error to line 656 of master-settings.c in the dovecot source, in the 'get_imap_capability' function. In this function, it notes: "Reloading configuration. Don't try to execute the imap process again. Too risky and the wait() call below will break it anyway. Just use the previous capability list we already had generated."
I changed the source so that the function always ran " set->imap_generated_capability = p_strdup(settings_pool, generated_capability); return TRUE;"
instead of going through the function where it had on the wait described in the comments.
Hmm.
Now, voila. Dovecot starts without complaint, the plugin works, the delivery and moving of email works.
Remember that with the mysql based dspam plugin you need a cron job to actually do the retraining, he's written that in PHP. And it looks like he's using the 'uid in signature' setting.
johannes
On 9/21/06, Johannes Berg <johannes@sipsolutions.net> wrote:
On Wed, 2006-09-20 at 15:40 -0400, Michael Blinn wrote:
After wrestling with Johannes's original plugin, I had a go at the mysql plugin that Tim wrote, as described here: http://members.plug.org.au/~linuxalien/dokuwiki/projects:dovecot-mysql-dspam...
I kept getting "Error: imap dump-capability process killed with signal 11" when attempting to start dovecot with this plugin.
That's odd. Probably a programming error in the plugin?
I'll have a look at it soon. I assume the capability function is trying to find out if the plugin gives imap any more capabilities?
<snip>
Now, voila. Dovecot starts without complaint, the plugin works, the delivery and moving of email works.
Remember that with the mysql based dspam plugin you need a cron job to actually do the retraining, he's written that in PHP. And it looks like he's using the 'uid in signature' setting.
The plan /is/ to write the retrain script in C, and link it into libdspam. If anyone gets a chance to do that, please let me know, it would be MUCH appreciated.
I do plan to continue work on the plugin, I just need to find the time with my new job.
Tim
Linux Counter user #273956 Don't email joeblogs@scouts.org.au
On Sun, 2006-09-24 at 07:27 +0800, Timothy White wrote:
I'll have a look at it soon. I assume the capability function is trying to find out if the plugin gives imap any more capabilities?
Yeah, that could be it, though usually that'd mean overriding the capability command. I haven't had time to look at it for quite a while and am still running a somewhat older rc snapshot.
The plan /is/ to write the retrain script in C, and link it into libdspam. If anyone gets a chance to do that, please let me know, it would be MUCH appreciated.
Oh, I wasn't saying that your retrain script wasn't any good, I was just trying to point out that one would have to run it too, to make the whole thing effective. Personally, I'd probably have written it in python :)
johannes
Hi,
I am trying to replace pop-before-smtp ( yes it is crap ) with Dovecot SASL. I have everything configured according to: http://www.postfix.org/SASL_README.html
But, does not allow me to SEND mail via POP3 using outlook express...
Below are my config files.
Postfix version 2.3.3 Dovecot version 1.0.rc7
dovecot.conf
auth default { mechanisms = plain login
passdb sql { args = /home/digipanel/secure/programs/dovecot/config/dovecot-mysql.conf } userdb sql { args = /home/digipanel/secure/programs/dovecot/config/dovecot-mysql.conf } socket listen { client { path = /home/digipanel/secure/programs/postfix/queue/private/auth mode = 0666 user = postfix group = postfix } } }
main.cf
smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
smtpd_sasl_auth_enable = yes broken_sasl_auth_clients = yes smtpd_sasl_type = dovecot smtpd_sasl_path = private/auth smtpd_sasl_authenticated_header = yes
Now my postconf -a yields: dovecot
So, I know postfix has compiled in Dovecot support.
My mail logs say I am not allowd to relay off the mailserver.
Matt wrote:
Hi,
I am trying to replace pop-before-smtp ( yes it is crap ) with Dovecot SASL. I have everything configured according to: http://www.postfix.org/SASL_README.html
But, does not allow me to SEND mail via POP3 using outlook express...
Below are my config files.
Postfix version 2.3.3 Dovecot version 1.0.rc7
dovecot.conf
auth default { mechanisms = plain login
passdb sql { args = /home/digipanel/secure/programs/dovecot/config/dovecot-mysql.conf } userdb sql { args = /home/digipanel/secure/programs/dovecot/config/dovecot-mysql.conf } socket listen { client { path = /home/digipanel/secure/programs/postfix/queue/private/auth mode = 0666 user = postfix group = postfix } } }
main.cf
smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
smtpd_sasl_auth_enable = yes broken_sasl_auth_clients = yes smtpd_sasl_type = dovecot smtpd_sasl_path = private/auth smtpd_sasl_authenticated_header = yes
Now my postconf -a yields: dovecot
So, I know postfix has compiled in Dovecot support.
My mail logs say I am not allowd to relay off the mailserver.
Did you set the 'mynetworks_style' in main.cf correctly? It probably needs to be 'class'.
-- Gerard
Money may not buy happiness; however, it does by beer!
Bud~Man
No that did not work.
Someone is telling me that my pop3 client is not set up correctly. Well I am using Outlook Express ( I set my pop3_client_workarounds for outlook )
I was using pop-before-smtp and was working fine. Anyone know how to use POstfix/Dovecot/sasl/outlook express with POP3? I do not want to use pop-before-smtp anymore
--- Dovecot Mailing List <gerard@seibercom.net> wrote:
Matt wrote:
Hi,
I am trying to replace pop-before-smtp ( yes it is crap ) with Dovecot SASL. I have everything configured according to: http://www.postfix.org/SASL_README.html
But, does not allow me to SEND mail via POP3 using outlook express...
Below are my config files.
Postfix version 2.3.3 Dovecot version 1.0.rc7
dovecot.conf
auth default { mechanisms = plain login
passdb sql { args = /home/digipanel/secure/programs/dovecot/config/dovecot-mysql.conf } userdb sql { args = /home/digipanel/secure/programs/dovecot/config/dovecot-mysql.conf } socket listen { client { path = /home/digipanel/secure/programs/postfix/queue/private/auth mode = 0666 user = postfix group = postfix } } }
main.cf
smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
smtpd_sasl_auth_enable = yes broken_sasl_auth_clients = yes smtpd_sasl_type = dovecot smtpd_sasl_path = private/auth smtpd_sasl_authenticated_header = yes
Now my postconf -a yields: dovecot
So, I know postfix has compiled in Dovecot support.
My mail logs say I am not allowd to relay off the mailserver.
Did you set the 'mynetworks_style' in main.cf correctly? It probably needs to be 'class'.
-- Gerard
Money may not buy happiness; however, it does by beer!
Bud~Man
Hello Matt,
Matt, 25.09.2006 (d.m.y):
Someone is telling me that my pop3 client is not set up correctly. Well I am using Outlook Express ( I set my pop3_client_workarounds for outlook )
I was using pop-before-smtp and was working fine. Anyone know how to use POstfix/Dovecot/sasl/outlook express with POP3?
postfix doesn't serve POP3.
I do not want to use pop-before-smtp anymore
Ask Google for postfix and SMTP authentication or send your questions to a mailing list where postfix questions are on topic.
And, please, don't top post.
Gruss/Regards, Christian Schmidt
-- Die Botschaft hört ich wohl, Allein mir fehlt der Glaube. -- Johann Wolfgang von Goethe (Faust I, Faust)
-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1
Matt schrieb:
No that did not work.
Someone is telling me that my pop3 client is not set up correctly. Well I am using Outlook Express ( I set my pop3_client_workarounds for outlook )
I was using pop-before-smtp and was working fine. Anyone know how to use POstfix/Dovecot/sasl/outlook express with POP3? I do not want to use pop-before-smtp anymore
--- Dovecot Mailing List <gerard@seibercom.net> wrote:
Matt wrote:
Hi,
I am trying to replace pop-before-smtp ( yes it is crap ) with Dovecot SASL. I have everything configured according to: http://www.postfix.org/SASL_README.html
But, does not allow me to SEND mail via POP3 using outlook express...
Below are my config files.
Postfix version 2.3.3 Dovecot version 1.0.rc7
dovecot.conf
auth default { mechanisms = plain login
passdb sql { args = /home/digipanel/secure/programs/dovecot/config/dovecot-mysql.conf } userdb sql { args = /home/digipanel/secure/programs/dovecot/config/dovecot-mysql.conf } socket listen { client { path = /home/digipanel/secure/programs/postfix/queue/private/auth mode = 0666 user = postfix group = postfix } } }
main.cf
smtpd_recipient_restrictions = permit_mynetworks, permit_sasl_authenticated, reject_unauth_destination
smtpd_sasl_auth_enable = yes broken_sasl_auth_clients = yes smtpd_sasl_type = dovecot smtpd_sasl_path = private/auth smtpd_sasl_authenticated_header = yes
Now my postconf -a yields: dovecot
So, I know postfix has compiled in Dovecot support.
My mail logs say I am not allowd to relay off the mailserver.
Did you set the 'mynetworks_style' in main.cf correctly? It probably needs to be 'class'.
-- Gerard
Money may not buy happiness; however, it does by beer!
Bud~Man
-- Diese Nachricht wurde auf Viren und andere gefährliche Inhalte untersucht und ist - aktuelle Virenscanner vorausgesetzt - sauber.
i am wondering , i have no failure with postfix 2.3.3 sasl mysql dovecot 1 rc7 with outlook express auth via sasl
Mit freundlichen Gruessen Best Regards Robert Schetterer
robert_at_schetterer_dot_org Munich / Bavaria / Germany https://www.schetterer.org https://www.schetterer.com/public-gpg-robert-schetterer.key -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.3 (MingW32)
iD8DBQFFGDWlNxddAhXBw7QRAoKcAJ9/BEOlRFiLJ6CmTIBwPnRyh6/ElwCgmHed qgWKtGNJ7bC1S6tCG0j4Q9U= =xZG1 -----END PGP SIGNATURE-----
-- Diese Nachricht wurde auf Viren und andere gefährliche Inhalte untersucht und ist - aktuelle Virenscanner vorausgesetzt - sauber.
participants (7)
-
Christian Schmidt
-
Dovecot Mailing List
-
Johannes Berg
-
Matt
-
Michael Blinn
-
Robert Schetterer
-
Timothy White