Yahoo Groups archive

Milter-greylist

Index last updated: 2026-04-28 23:32 UTC

Thread

Ldap and milter-greylist

Ldap and milter-greylist

2007-04-14 by Net_Guru_2U

When I tried to run ./configure I kept getting the "Required libmilter
not found. Use --with-libmilter" error even when I supplied the
correct path.  So, I started looking through the config.log and found
that libmilter uses some stuff from ldap if you compile sendmail with
ladp.  So not knowing much about automake I just tweaked the configure
to include -lldap -llber in two places.  One so the configure would
work and one so the compile would work.  Something like this:

# Check for libmilter. For sendmail-8.12.1, -lsm is required too.
# This uses a gross hack on the second AC_CHECK_LIB first argument,
but using
# [-lsm] in the optionnal 5th argument does not seems to help at all.
echo "$as_me:$LINENO: checking for smfi_register in -lmilter" >&5
echo $ECHO_N "checking for smfi_register in -lmilter... $ECHO_C" >&6
if test "${ac_cv_lib_milter_smfi_register+set}" = set; then
  echo $ECHO_N "(cached) $ECHO_C" >&6
else
  ac_check_lib_save_LIBS=$LIBS
LIBS="-lmilter -lldap -llber $LIBS"
cat >conftest.$ac_ext <<_ACEOF
/* confdefs.h.  */
_ACEOF
cat confdefs.h >>conftest.$ac_ext
cat >>conftest.$ac_ext <<_ACEOF
/* end confdefs.h.  */


And then:


echo "${ECHO_T}$ac_cv_lib_milter_smfi_register" >&6
if test $ac_cv_lib_milter_smfi_register = yes; then
  LIBS="$LIBS -lmilter -lldap -llber"

After that everything went well and except for when I try to use spf
it runs stable.  Hopefully you uber coders should be able to modify
the configure.ac appropriately so I don't have to learn automake.  The
spf problem probably has to do with the resolver or bind or something
like that since I am compiling this on some servers that have been in
service for many years and probably have very old and not thread safe
libraries.

Re: [milter-greylist] Ldap and milter-greylist

2007-04-14 by manu@netbsd.org

Net_Guru_2U <markham@...> wrote:

> When I tried to run ./configure I kept getting the "Required libmilter
> not found. Use --with-libmilter" error even when I supplied the
> correct path.  So, I started looking through the config.log and found
> that libmilter uses some stuff from ldap if you compile sendmail with
> ladp.

You mean libmilter require -lldap and -llber to link with
milter-greylist?

-- 
Emmanuel Dreyfus
http://hcpnet.free.fr/pubz
manu@...

Re: Ldap and milter-greylist

2007-04-14 by Net_Guru_2U

--- In milter-greylist@yahoogroups.com, manu@... wrote:
>
> Net_Guru_2U <markham@...> wrote:
> 
> > When I tried to run ./configure I kept getting the "Required libmilter
> > not found. Use --with-libmilter" error even when I supplied the
> > correct path.  So, I started looking through the config.log and found
> > that libmilter uses some stuff from ldap if you compile sendmail with
> > ladp.
> 
> You mean libmilter require -lldap and -llber to link with
> milter-greylist?
> 
> -- 
> Emmanuel Dreyfus
> http://hcpnet.free.fr/pubz
> manu@...
>

Yes.  I had to add -lldap and -llber to the LIBS variable where it was
checking for smfi_register in -lmilter in ./configure to make it
configure and compile.  Apparently when libmilter is built with
APPENDDEF(`confENVDEF', `-DLDAPMAP') and APPENDDEF(`confLIBS',
`-lldap') in the sendmail site.config.m4 you need to include the ldap
stuff for anything else you do with libmilter.

Mark

Re: [milter-greylist] Re: Ldap and milter-greylist

2007-04-15 by manu@netbsd.org

Net_Guru_2U <markham@...> wrote:

> Yes.  I had to add -lldap and -llber to the LIBS variable where it was
> checking for smfi_register in -lmilter in ./configure to make it
> configure and compile.  Apparently when libmilter is built with
> APPENDDEF(`confENVDEF', `-DLDAPMAP') and APPENDDEF(`confLIBS',
> `-lldap') in the sendmail site.config.m4 you need to include the ldap
> stuff for anything else you do with libmilter.

How do other milter solve this problem? Obviously having to test random
libraries that were linked with libmilter is not the right way, it's
like a cat and mouse game where the milter can never test anything that
must be tested. There must be something more clever to do.

-- 
Emmanuel Dreyfus
http://hcpnet.free.fr/pubz
manu@...

Re: [milter-greylist] Ldap and milter-greylist

2007-04-16 by manu@netbsd.org

Net_Guru_2U <markham@...> wrote:

> When I tried to run ./configure I kept getting the "Required libmilter
> not found. Use --with-libmilter" error even when I supplied the
> correct path.  So, I started looking through the config.log and found
> that libmilter uses some stuff from ldap if you compile sendmail with
> ladp.  So not knowing much about automake I just tweaked the configure
> to include -lldap -llber in two places. 

Please send me config.log, I'd like to undertsand what symbol can be
missing here.

-- 
Emmanuel Dreyfus
http://hcpnet.free.fr/pubz
manu@...

Re: [milter-greylist] Ldap and milter-greylist

2007-04-17 by manu@netbsd.org

Emmanuel Dreyfus <manu@...> wrote:

> > When I tried to run ./configure I kept getting the "Required libmilter
> > not found. Use --with-libmilter" error even when I supplied the
> > correct path.  So, I started looking through the config.log and found
> > that libmilter uses some stuff from ldap if you compile sendmail with
> > ladp.  So not knowing much about automake I just tweaked the configure
> > to include -lldap -llber in two places. 
> 
> Please send me config.log, I'd like to undertsand what symbol can be
> missing here.

Quick poll: shall I hold 4.0alpha2 on this problem or roll it out right
now?

-- 
Emmanuel Dreyfus
http://hcpnet.free.fr/pubz
manu@...

Re: [milter-greylist] Ldap and milter-greylist

2007-04-17 by Mark Hamilton

Here is the config.log that failed and the one from my modified configure.

manu@... wrote:
Show quoted textHide quoted text
>
> Emmanuel Dreyfus <manu@... <mailto:manu%40netbsd.org>> wrote:
>
> > > When I tried to run ./configure I kept getting the "Required libmilter
> > > not found. Use --with-libmilter" error even when I supplied the
> > > correct path. So, I started looking through the config.log and found
> > > that libmilter uses some stuff from ldap if you compile sendmail with
> > > ladp. So not knowing much about automake I just tweaked the configure
> > > to include -lldap -llber in two places.
> >
> > Please send me config.log, I'd like to undertsand what symbol can be
> > missing here.
>
> Quick poll: shall I hold 4.0alpha2 on this problem or roll it out right
> now?
>
> -- 
> Emmanuel Dreyfus
> http://hcpnet.free.fr/pubz <http://hcpnet.free.fr/pubz>
> manu@... <mailto:manu%40netbsd.org>
>
>

Re: [milter-greylist] Ldap and milter-greylist

2007-04-17 by Emmanuel Dreyfus

On Tue, Apr 17, 2007 at 08:18:13AM -0700, Mark Hamilton wrote:
> > > > When I tried to run ./configure I kept getting the "Required libmilter
> > > > not found. Use --with-libmilter" error even when I supplied the
> > > > correct path. So, I started looking through the config.log and found
> > > > that libmilter uses some stuff from ldap if you compile sendmail with
> > > > ladp. So not knowing much about automake I just tweaked the configure
> > > > to include -lldap -llber in two places.

Here is the relevant snipet:
configure:7710: gcc -o conftest -g -O2 -Wall   conftest.c -lmilter   -lpthread -
lresolv -lnsl >&5
/usr/lib/gcc/i486-slackware-linux/3.4.6/../../../libmilter.a(errstring.o)(.text+
0xda): In function `sm_errstring':
: undefined reference to `ldap_err2string'

I'm more and more convinced this is a problem with your libmilter build: 
libmilter is a static library (.a), which should include all the symbols it
needs. For instance, sm_errstring is in libsm, but libmilter includes it.

So IMO, it should also include ldap_err2string from libldap.

Anyone has an opinion on this topic? Can you talk to your package maintainer
to get some insightful opinions?

-- 
Emmanuel Dreyfus
manu@...

Re: Ldap and milter-greylist

2007-04-17 by Net_Guru_2U

--- In milter-greylist@yahoogroups.com, Emmanuel Dreyfus <manu@...> wrote:
>
> On Tue, Apr 17, 2007 at 08:18:13AM -0700, Mark Hamilton wrote:
> > > > > When I tried to run ./configure I kept getting the "Required
libmilter
> > > > > not found. Use --with-libmilter" error even when I supplied the
> > > > > correct path. So, I started looking through the config.log
and found
> > > > > that libmilter uses some stuff from ldap if you compile
sendmail with
> > > > > ladp. So not knowing much about automake I just tweaked the
configure
> > > > > to include -lldap -llber in two places.
> 
> Here is the relevant snipet:
> configure:7710: gcc -o conftest -g -O2 -Wall   conftest.c -lmilter 
 -lpthread -
> lresolv -lnsl >&5
>
/usr/lib/gcc/i486-slackware-linux/3.4.6/../../../libmilter.a(errstring.o)(.text+
> 0xda): In function `sm_errstring':
> : undefined reference to `ldap_err2string'
> 
> I'm more and more convinced this is a problem with your libmilter
build: 
> libmilter is a static library (.a), which should include all the
symbols it
> needs. For instance, sm_errstring is in libsm, but libmilter
includes it.
> 
> So IMO, it should also include ldap_err2string from libldap.
> 
> Anyone has an opinion on this topic? Can you talk to your package
maintainer
> to get some insightful opinions?
> 
> -- 
> Emmanuel Dreyfus
> manu@...
>


This sendmail was not sent in a package.  I downloaded the latest and
one a few versions back source code from sendmail.org.  I compiled it
to support ldap and milter using the instructions they provide in
their readme and other docs.  Interestingly enough I also put in the
milter for clamav on a machine compiled the same way.  The configure
on it did not require any tweaks.  Now that I think about it though, I
compiled libmilter on that machine and was using the milter before I
recompiled with ldap support.  I will try on a spare machine to
recompile clamav milter with a recompiled libmilter which includes the
ldap stuff.

Mark

Re: Ldap and milter-greylist

2007-04-17 by Net_Guru_2U

--- In milter-greylist@yahoogroups.com, Emmanuel Dreyfus <manu@...> wrote:
>
> On Tue, Apr 17, 2007 at 08:18:13AM -0700, Mark Hamilton wrote:
> > > > > When I tried to run ./configure I kept getting the "Required
libmilter
> > > > > not found. Use --with-libmilter" error even when I supplied the
> > > > > correct path. So, I started looking through the config.log
and found
> > > > > that libmilter uses some stuff from ldap if you compile
sendmail with
> > > > > ladp. So not knowing much about automake I just tweaked the
configure
> > > > > to include -lldap -llber in two places.
> 
> Here is the relevant snipet:
> configure:7710: gcc -o conftest -g -O2 -Wall   conftest.c -lmilter 
 -lpthread -
> lresolv -lnsl >&5
>
/usr/lib/gcc/i486-slackware-linux/3.4.6/../../../libmilter.a(errstring.o)(.text+
> 0xda): In function `sm_errstring':
> : undefined reference to `ldap_err2string'
> 
> I'm more and more convinced this is a problem with your libmilter
build: 
> libmilter is a static library (.a), which should include all the
symbols it
> needs. For instance, sm_errstring is in libsm, but libmilter
includes it.
> 
> So IMO, it should also include ldap_err2string from libldap.
> 
> Anyone has an opinion on this topic? Can you talk to your package
maintainer
> to get some insightful opinions?
> 
> -- 
> Emmanuel Dreyfus
> manu@...
>

Ok, I recompiled the libmilter for sendmail on a spare machine with
the ldap stuff in the siteconfig for sendmail and it had the same
problem that milter-greylist had.  I added the -lldap -llber to the
configure file and it worked fine.  This looks like a problem that
needs to be taken up with sendmail since they are the ones putting in
the extra dependencies when sendmail is compiled to support ldap.  You
are probably correct that they should not be added to a static library
and they apparently are not needed to make libmilter work with ldap
since I am using a version of libmilter on 2 machines compiled without
ldap when sendmail itself is using ldap.  Anyway, I guess it is not
really a milter-greylist problem and I know how to get around it easy
enough.

Mark

mxsync and logging

2007-04-18 by Ethan Burnside

Greetings,

     Love milter-greylist, especially the mxsync feature.

     We have many (say 'X') servers in a cluster using mxsync on v3.0.

     All of the servers send their logs over the network to a logging 
server where mail logs are analyzed for the cluster as a whole.

     Every mxsync generates 'X' entries in the logs on the logging 
server.  'X' is not an insignificant amount.

     Is there an easy way to quell the mxsync log entries, but keep all 
of the rest of the logging?

Thanks!

~Ethan B.

Re: [milter-greylist] mxsync and logging

2007-04-18 by manu@netbsd.org

Ethan Burnside <burnside@...> wrote:

>      Is there an easy way to quell the mxsync log entries, but keep all
> of the rest of the logging?

Sure: remove it from the sources and rebuild, it's quite easy...

-- 
Emmanuel Dreyfus
http://hcpnet.free.fr/pubz
manu@...

Move to quarantaine

This moves the raw source file on disk only. The archive index is not changed automatically, so you still need to run a manual refresh afterward.