Re: [Dovecot] Resend: How do I configure sendmail to accept emails for dovecot when dovecot has sql auth/user db.

2007-08-06 Thread Steffen Kaiser

-BEGIN PGP SIGNED MESSAGE-
Hash: SHA1

On Thu, 2 Aug 2007, Stewart Dean wrote:

I don't regard myself as much of an expert, but this is NOT a Dovecot 
question, rather one relating to sendmail or your O/S native authentication

functionality.  Speaking for myself, I run NIS/yp on my mailserver and then


Well, one could make it a Dovecot-question:

Is there somebody thinking about to develop a Dovecot-SASL patch for 
sendmail.


;-)

Bye.

- -- 
Steffen Kaiser

-BEGIN PGP SIGNATURE-
Version: GnuPG v1.4.6 (GNU/Linux)

iQEVAwUBRrcjwy9SORjhbDpvAQIbJQf/RJt8QInz6qRJWR9mTt09Er6eW6ZgGy8N
9vt2eLqMmdhUEcjuuqCsxNE82YgHSwzcykaU5uLIkjUnl74tYakquv7HPar/T8wM
x+X7tnjtef0n8MEXh7pEYkVWdwQn+z44L9rwbnVwVqRUXfUL3aMpwZVXnIEfsUY+
QLif3LNJg9jVPIaVaYNohRUyeLbr8cY/V+4iITID98rcILt1CJHvFwKNbz1/3okv
BXLHY0FpLlqIsg363K9F2KXwkVGQWsLk6MfDNMzl5zCo7q5sNTjbyRtppCIVmV2B
Tm8MRFXF4yZhhfalCafMqjvltZQSp5AJ1y6MMB/EmzcHvYtZM5EJNw==
=/tyx
-END PGP SIGNATURE-


Re: [Dovecot] Resend: How do I configure sendmail to accept emails for dovecot when dovecot has sql auth/user db.

2007-08-02 Thread Scott Silva
Joseph Silverman spake the following on 8/1/2007 5:24 PM:
 Apologies for resending this, I am not sure it made it through the first
 time..
 ---
 
 Included below are my config files: sendmail.mc, dovecot.m4,
 dovecot.conf, dovecot-sql.conf.  Whenever I try to send email into this
 system, it rejects it with user does not exist, however, the user does
 exist as far as dovecot (imap) is concerned, it is in the database.
 
 THANKS - Yossie
It came through the first time, but nobody has answered you yet. I don't have
a good answer either, but you need to find a way for sendmail to use the same
auth database, or replicate it somehow into virtualusers system.
-- 

MailScanner is like deodorant...
You hope everybody uses it, and
you notice quickly if they don't



Re: [Dovecot] Resend: How do I configure sendmail to accept emails for dovecot when dovecot has sql auth/user db.

2007-08-02 Thread Stewart Dean
I don't regard myself as much of an expert, but this is NOT a Dovecot 
question, rather one relating to sendmail or your O/S native 
authentication functionality.  Speaking for myself, I run NIS/yp on my 
mailserver and then restrict login...this supplies authentication to all 
users receiving mail.  I might (but don't) run LDAP as the primary 
authentication resource on this AIX box, in which case I could then use  
LDAP when receiving mail.  Understand: Dovecot doesn't receive mail, 
sendmail does.


Scott Silva wrote:

Joseph Silverman spake the following on 8/1/2007 5:24 PM:
  

Apologies for resending this, I am not sure it made it through the first
time..
---

Included below are my config files: sendmail.mc, dovecot.m4,
dovecot.conf, dovecot-sql.conf.  Whenever I try to send email into this
system, it rejects it with user does not exist, however, the user does
exist as far as dovecot (imap) is concerned, it is in the database.

THANKS - Yossie


It came through the first time, but nobody has answered you yet. I don't have
a good answer either, but you need to find a way for sendmail to use the same
auth database, or replicate it somehow into virtualusers system.
  


--

Stewart Dean, Unix System Admin, Henderson Computer Resources 
Center of Bard College, Annandale-on-Hudson, New York  12504  
[EMAIL PROTECTED]  voice: 845-758-7475, fax: 845-758-7035




[Dovecot] Resend: How do I configure sendmail to accept emails for dovecot when dovecot has sql auth/user db.

2007-08-01 Thread Joseph Silverman
Apologies for resending this, I am not sure it made it through the  
first time..

---

Included below are my config files: sendmail.mc, dovecot.m4,  
dovecot.conf, dovecot-sql.conf.  Whenever I try to send email into  
this system, it rejects it with user does not exist, however, the  
user does exist as far as dovecot (imap) is concerned, it is in the  
database.


THANKS - Yossie

# for i in /etc/dovecot/dovecot.conf /etc/dovecot/dovecot-sql.conf / 
usr/share/sendmail-cf/mailer/dovecot.m4 /etc/mail/sendmail.mc; do  
echo FILE: $i; echo ===; echo ; egrep -v '^ *(#|$)' $i; echo ;  
echo ; done



FILE: /etc/dovecot/dovecot.conf
===

listen = [::]
disable_plaintext_auth = no
ssl_disable = yes
ssl_cert_file = /etc/ssl/dovecot/server.pem
ssl_key_file = /etc/ssl/dovecot/server.key
mail_location = maildir:~/.maildir
namespace private {
separator = .
inbox = yes
hidden = no
}
namespace private {
separator = .
prefix = INBOX.
inbox = no
hidden = yes
}
first_valid_uid = 0
protocol imap {
}
protocol pop3 {
}
protocol lda {
  postmaster_address = [EMAIL PROTECTED]
  main_plugin_dir = /usr/lib/dovecot/lda
  mail_plugins = cmusieve quota
}
auth default {
  mechanisms = plain
  passdb sql {
args = /etc/dovecot/dovecot-sql.conf
  }
  userdb sql {
args = /etc/dovecot/dovecot-sql.conf
  }
  user = root
  socket listen {
master {
  path = /var/run/dovecot/auth-master
  mode = 0666
}
client {
  path = /var/run/dovecot/auth-client
  mode = 0666
}
  }
}
dict {
}
plugin {
}


FILE: /etc/dovecot/dovecot-sql.conf
===

driver = mysql
connect = host=localhost dbname=dovecot user=root
default_pass_scheme = PLAIN
password_query = SELECT userPassword as password, user, concat(/var/ 
spool/dovecot/,substr(user,1,1),/user/,user) as userdb_home, 97 as  
userdb_uid, 97 as userdb_gid FROM authdb WHERE user = '%n' and  
userPassword = '%w'
user_query = SELECT concat(/var/spool/imap/,substr(user,1,1),/ 
user/,user) as home, 97 as uid, 97 as gid FROM authdb WHERE user = '%n'



FILE: /usr/share/sendmail-cf/mailer/dovecot.m4
===

Mdovecot,   P=/usr/libexec/dovecot/deliver, F=DFMPhnu9,
S=EnvFromSMTP/HdrFromSMTP, R=EnvToSMTP/HdrFromSMTP,
T=DNS/RFC822/X-Unix,
A=deliver -d $u


FILE: /etc/mail/sendmail.mc
===

divert(-1)
dnl This is the macro config file used to generate the /etc/sendmail.cf
dnl file. If you modify the file you will have to regenerate the
dnl /etc/sendmail.cf by running this macro config through the m4
dnl preprocessor:
dnl
dnlm4 /etc/mail/sendmail.mc  /etc/mail/sendmail.cf
dnl
dnl You will need to have the sendmail-cf package installed for this to
dnl work.
include(`/usr/share/sendmail-cf/m4/cf.m4')dnl
define(`confDEF_USER_ID',``mail:mail'')dnl
OSTYPE(`linux')dnl
undefine(`UUCP_RELAY')dnl
undefine(`BITNET_RELAY')dnl
define(`confALIAS_WAIT', `30')dnl
define(`confTO_CONNECT', `1m')dnl
define(`confTRY_NULL_MX_LIST',true)dnl
define(`confDONT_PROBE_INTERFACES',true)dnl
define(`PROCMAIL_MAILER_PATH',`/usr/bin/procmail')dnl
dnl define delivery mode: interactive, background, or queued
dnl define(`confDELIVERY_MODE', `i')
MASQUERADE_AS(`ford.qa.laszlosystems.com')dnl
FEATURE(`limited_masquerade')dnl
FEATURE(`masquerade_envelope')dnl
FEATURE(`smrsh',`/usr/sbin/smrsh')dnl
FEATURE(mailertable)dnl
dnl virtusertable: redirect incoming mail to virtual domain to  
particular user or domain

FEATURE(`virtusertable',`hash -o /etc/mail/virtusertable')dnl
dnl genericstable: rewrite sender address for outgoing mail
FEATURE(genericstable)dnl
FEATURE(always_add_domain)dnl
FEATURE(redirect)dnl
FEATURE(use_cw_file)dnl
FEATURE(local_procmail)dnl
FEATURE(`access_db')dnl
FEATURE(`blacklist_recipients')dnl
FEATURE(`relay_based_on_MX')dnl
dnl FEATURE(dnsbl, `blackholes.mail-abuse.org', `Rejected - see   
http://www.mail-abuse.org/rbl/')dnl
dnl FEATURE(dnsbl, `dialups.mail-abuse.org', `Dialup - see http:// 
www.mail-abuse.org/dul/')dnl
dnl FEATURE(dnsbl, `relays.mail-abuse.org', `Open spam relay - see  
http://www.mail-abuse.org/rss/')dnl

FEATURE(`delay_checks')dnl
FEATURE(`stickyhost')dnl
dnl SASL Configuration
dnl extract from http://www.sendmail.org/~ca/email/auth.html
dnl
dnl Next two lines are for SMTP Authentication
TRUST_AUTH_MECH(`LOGIN PLAIN')dnl
define(`confAUTH_MECHANISMS', `LOGIN PLAIN')dnl
dnl
dnl Next line stops sendmail from allowing auth without encryption
define(`confAUTH_OPTIONS', `Apy')dnl
dnl
dnl STARTTLS configuration
dnl extract from http://www.sendmail.org/~ca/email/starttls.html
dnl
define(`CERT_DIR', `/etc/ssl/sendmail')dnl
define(`confCACERT_PATH', `CERT_DIR')dnl
define(`confCACERT', `CERT_DIR/CAcert.pem')dnl
define(`confSERVER_CERT', `CERT_DIR/MYcert.pem')dnl
define(`confSERVER_KEY', `CERT_DIR/MYkey.pem')dnl
define(`confCLIENT_CERT', `CERT_DIR/MYcert.pem')dnl
define(`confCLIENT_KEY', `CERT_DIR/MYkey.pem')dnl
dnl
dnl Uncomment next lines to hide identity of mail serve