Date: Mon, 12 Mar 2012 20:26:19 +0700 From: kamolpat <kamolpat@dmaccess.net> To: Matthew Seaman <matthew@FreeBSD.org> Cc: freebsd-questions@FreeBSD.org Subject: Re: question about SMTP-authentication (2nd ) Message-ID: <4F5DF97B.7070306@dmaccess.net> In-Reply-To: <4F58ED8A.7050602@FreeBSD.org> References: <4F58D68D.2060700@dmaccess.net> <4F58ED8A.7050602@FreeBSD.org>
next in thread | previous in thread | raw e-mail | index | archive | help
Dear Matthew, According to your recommendation .... (as following). When I do make at /usr/src/sur.sbin/sendmail it show as following. ns1:kamolpat:/usr/src/usr.sbin/sendmail>make clean rm -f sm_os.h sendmail alias.o arpadate.o bf.o collect.o conf.o control.o convtime.o daemon.o deliver.o domain.o envelope.o err.o headers.o macro.o main.o map.o mci.o milter.o mime.o parseaddr.o queue.o ratectrl.o readcf.o recipient.o savemail.o sasl.o sfsasl.o shmticklib.o sm_resolve.o srvrsmtp.o stab.o stats.o sysexits.o timers.o tls.o trace.o udb.o usersmtp.o util.o version.o mailq.1.gz newaliases.1.gz aliases.5.gz sendmail.8.gz mailq.1.cat.gz newaliases.1.cat.gz aliases.5.cat.gz sendmail.8.cat.gz ns1:kamolpat:/usr/src/usr.sbin/sendmail>make ln -sf /usr/src/usr.sbin/sendmail/../../contrib/sendmail/include/sm/os/sm_os_freebsd.h sm_os.h cc -O2 -pipe -I/usr/src/usr.sbin/sendmail/../../contrib/sendmail/src -I/usr/src/usr.sbin/sendmail/../../contrib/sendmail/include -I. -DNEWDB -DNIS -DTCPWRAPPERS -DMAP_REGEX -DDNSMAP -DNETINET6 -DSTARTTLS -D_FFR_TLS_1 -I/usr/local/include/sasl -DSASL=2 -std=gnu99 -fstack-protector -c /usr/src/usr.sbin/sendmail/../../contrib/sendmail/src/alias.c In file included from /usr/src/usr.sbin/sendmail/../../contrib/sendmail/src/alias.c:14: /usr/src/usr.sbin/sendmail/../../contrib/sendmail/src/sendmail.h:135:25: error: sasl/sasl.h: No such file or directory /usr/src/usr.sbin/sendmail/../../contrib/sendmail/src/sendmail.h:136:29: error: sasl/saslutil.h: No such file or directory In file included from /usr/src/usr.sbin/sendmail/../../contrib/sendmail/src/alias.c:14: /usr/src/usr.sbin/sendmail/../../contrib/sendmail/src/sendmail.h:607: error: expected '=', ',', ';', 'asm' or '__attribute__' before ':' token /usr/src/usr.sbin/sendmail/../../contrib/sendmail/src/sendmail.h:691: error: expected specifier-qualifier-list before 'sasl_conn_t' *** Error code 1 Stop in /usr/src/usr.sbin/sendmail. ======================================== then I try to find where is sasl.h ns1:kamolpat:/usr>find . -name "sasl.h" ./local/include/sasl/sasl.h ./ports/security/cyrus-sasl2/work/cyrus-sasl-2.1.25/include/sasl.h ./ports/security/cyrus-sasl2-saslauthd/work/cyrus-sasl-2.1.25/include/sasl.h What should I do next? Shold I just copy the sasl.h to /usr/src/contrib/sendmail/src/sendmail ? Thanks Kamolpat On 3/9/2012 12:34 AM, Matthew Seaman wrote: > On 08/03/2012 15:55, kamolpat wrote: >> Setup Reference >> ============== >> 1. I read the how to setup from FreeBSD Handbook (online)-> Chapter 29 >> Electronic Mail -> 29.10 SMTP Authentication from freebsd.org >> 2. setup for cyrus-sasl2 was fine (setup via >> usr/ports/security/cyrus-sasl2) >> 3. setup for openssl was 90% fine (setup via port) reference to FreeBSD >> Handbook (online)->Chapter 15 Security -> 15.8 OpenSSL >> accept the "STARTTLS" line doesn't appear as mention on the last >> part of article. >> > Did you rebuild sendmail with the right flags so that it would enable > all the SASL bits? Apart from that you seem to have done all the right > stuff that I can see. > > You need to add this to /etc/make.conf: > > SENDMAIL_CFLAGS=-I/usr/local/include -DSASL=2 > SENDMAIL_LDFLAGS=-L/usr/local/lib > SENDMAIL_LDADD=-lsasl2 > > and then rebuild sendmail -- assuming you have system sources installed: > > # cd /usr/src/usr.sbin/sendmail > # make clean > # make > # make install > > If you haven't got the system sources installed, then you can get them > easily enough with csup(1) or freebsd-update(8) or several other ways. > Or you could just install sendmail from ports -- obviously, make sure to > choose the option to enable SASL in the config dialogue. If you use the > ports sendmail, so long as you set up mailer.conf(5) to point to the > ports version -- like so: > > lucid-nonsense:/etc/mail:% cat mailer.conf > # $FreeBSD: stable/8/etc/mail/mailer.conf 93858 2002-04-05 04:25:14Z > gshapiro $ > # > # Execute the "real" sendmail program, named /usr/local/sbin/sendmail > # > sendmail /usr/local/sbin/sendmail > send-mail /usr/local/sbin/sendmail > mailq /usr/local/sbin/sendmail > newaliases /usr/local/sbin/sendmail > hoststat /usr/local/sbin/sendmail > purgestat /usr/local/sbin/sendmail > > and put the following in /etc/make.conf so it uses the latest > configuration file bits: > > SENDMAIL_CF_DIR= /usr/local/share/sendmail/cf > MAKEMAP= /usr/local/sbin/makemap > > then the ports sendmail is pretty much a drop-in replacement for the > system one, and you can use all the config bits in /etc/mail in exactly > the same way as normal. > > Cheers, > > Matthew > E-mail message checked by Internet Security (7.0.0.508) Database version: 6.19440 http://www.pctools.com/en/internet-security/
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?4F5DF97B.7070306>