Morgan Systems
Find 
  Development Notes and Bugfixes  
   

Select Article

We burn the midnight oil so you don't have to.
 
   
   
   
   
   
   
   
   
   
   
   
   








 

POP Before SMTP/Whoson

POP Before SMTP/IMAP/Whoson Integration

UW IMAP Modifications
QPopper Modifications

UW IMAP Modifications
Rev: 10/12/2005
Ref: version IMAP 2004e, 2004g
  1. Copy whoson.h into src/imapd
  2. Modify src/imapd/imapd.c
    Add #include
    at the top, under #include
  3. Modify src/imapd/imapd.c
    add:
    /* WHOSON Login */
    wso_login ( tcp_clientaddr (), user, NULL, 0 );

    under:

    response = (response == altwin) ? logwinalt : logwin;
    syslog (LOG_INFO,"Authenticated user=%.80s host=%.80s",
      user,tcp_clienthost ());


    and:

    response = (response == altwin) ? logwinalt : logwin;
    syslog (LOG_INFO,"Login user=%.80s host=%.80s",user,
      tcp_clienthost ());
  4. Modify src/imapd/Makefile to include the path to libwhoson:
    modify this:
    LDFLAGS = $(CCLIENTLIB) `cat $C/LDFLAGS`
    to this:
    LDFLAGS = $(CCLIENTLIB) /usr/local/lib/libwhoson.a `cat $C/LDFLAGS`
  5. make as per uw included instructions
QPopper Modifications
Re: QPopper Version 4.0.8
Rev: 08/03/2005

  1. Modify popper/banner.h to include modified by message in both string declarations
  2. Place whoson.h in popper/
    Note - for the moment, whoson is implemented with the LOG_LOGIN compiler directive - therefore this directive must be included at compile time.
  3. Modify pop_log.c
    add to include section:
    #ifdef LOG_LOGIN
    #include
    #endif /* whoson */

    Near bottom, beneath:
    pop_log ( p, POP_PRIORITY, HERE, str,   ptrs [ 0 ], ptrs [ 1 ], ptrs [ 2 ], ptrs [ 3 ] );

    add:
    #ifdef LOG_LOGIN
    /* WHOSON Login */
    wso_login ( p->ipaddr, p->user, NULL, 0 );
    #endif /* whoson */
  4. Run ./configure with desired options
  5. Modify popper/Makefile to include the path to libwhoson:
  6. popper: ${OBJS} mangler_library common_library   ${CC} ${OBJS} -o popper ${mmangle_dir}/libmangle.a \
      -I${common_srcdir} ${common_dir}/libcommon.a \
      ${LIBS} ${LDFLAGS} \
      /usr/local/lib/libwhoson.a
  7. Build/install as per docs

Comments

Add your comments

Name:
E-Mail:   We will not display your email address.
Comments: