The qpopper list archive ending on 27 Sep 1999


Topics covered in this issue include:

  1. Re: Stuck pop files
       "S. Faruque Ahmed" <sfque at texasgroup dot net>
       Sat, 18 Sep 1999 02:32:35 +0600
  2. Re: .user.pop lock busy! Is another session active?
       "Jerry O'Brien" <jobrien at cuttingedge dot net>
       Fri, 17 Sep 1999 12:32:37 -0500
  3. .user.pop lock busy! Is another session active?
       "Marcelo dos S. Tavares" <mtavares at argo.com dot br>
       Fri, 17 Sep 1999 18:06:06 -0400
  4. RE: .user.pop lock busy! Is another session active?
       "Brunette, Jason" <jbrunette at excel dot net>
       Fri, 17 Sep 1999 17:32:17 -0500
  5. Re: .user.pop lock busy! Is another session active?
       Alan Brown <alan at manawatu.gen dot nz>
       Sat, 18 Sep 1999 20:58:55 +1200 (NZST)
  6. RE: .user.pop lock busy! Is another session active?
       Alan Brown <alan at manawatu.gen dot nz>
       Sat, 18 Sep 1999 21:15:44 +1200 (NZST)
  7. RE: .user.pop lock busy! Is another session active?
       Alan Brown <alan at manawatu.gen dot nz>
       Sat, 18 Sep 1999 21:25:05 +1200 (NZST)
  8. RE: .user.pop lock busy! Is another session active?
       Carrer Yuri <yurj at dns.alfa dot it>
       Sat, 18 Sep 1999 13:12:49 +0200 (MET DST)
  9. Re: .user.pop lock busy! Is another session active?
       Carrer Yuri <yurj at dns.alfa dot it>
       Sat, 18 Sep 1999 13:19:00 +0200 (MET DST)
 10. Re: Stuck pop files
       Carrer Yuri <yurj at dns.alfa dot it>
       Sat, 18 Sep 1999 13:14:05 +0200 (MET DST)
 11. RE: .user.pop lock busy! Is another session active?
       Admin Mailing Lists <mlist at intergrafix dot net>
       Sat, 18 Sep 1999 13:22:48 -0400 (EDT)
 12. Antivirus mail configuration
       Jithender Tiwari <jtiwari at infotech.stph dot net>
       Sun, 19 Sep 1999 18:40:54
 13. Need Help With Install
       "James Hicks" <jlrh at lcc dot net>
       Sun, 19 Sep 1999 18:29:55 -0500
 14. Re: .user.pop lock busy! Is another session active?
       Mark van Walraven <markv at wave.co dot nz>
       Mon, 20 Sep 1999 12:35:10 +1200
 15. Re: Need Help With Install
       Wayne Heming <wheming at hemnet.com dot au>
       Mon, 20 Sep 1999 18:36:16 +1000
 16. Re: Need Help With Install
       "M. Edward Wilborne III" <wilborne at gamewood dot net>
       Mon, 20 Sep 1999 09:04:47 -0400
 17. Re: Need Help With Install
       Wayne Heming <wheming at hemnet.com dot au>
       Tue, 21 Sep 1999 06:07:41 +1000
 18. Re: Polling control
       Randall Gellens <rg=public.1 at worldmail1.qualcomm dot com>
       Mon, 20 Sep 1999 16:08:42 -0700
 19. Relaying
       dandrews at mpiua dot com
       Tue, 21 Sep 1999 10:37:51 -0400
 20. Re: Relaying
       Admin Mailing Lists <mlist at intergrafix dot net>
       Tue, 21 Sep 1999 11:23:04 -0400 (EDT)
 21. Re: Relaying
       Rex Sanders <rex at octopus.wr.usgs dot gov>
       Tue, 21 Sep 1999 08:36:41 -0700
 22. Install problems.
       Chimera <chimera at DarkMUX dot net>
       Tue, 21 Sep 1999 15:11:26 -0500 (CDT)
 23. Re: Relaying
       Jithender Tiwari <jtiwari at infotech.stph dot net>
       Fri, 22 Sep 2000 09:49:37
 24. Re: Relaying
       pestilence <pestilence at netplan dot gr>
       Wed, 22 Sep 1999 09:36:35 +0300
 25. Re: Relaying
       Alan Brown <alan at manawatu.gen dot nz>
       Wed, 22 Sep 1999 18:36:44 +1200 (NZST)
 26. Re: Relaying
       pestilence <pestilence at netplan dot gr>
       Wed, 22 Sep 1999 10:03:10 +0300
 27. Re: Relaying
       Alan Brown <alan at manawatu.gen dot nz>
       Wed, 22 Sep 1999 18:52:05 +1200 (NZST)
 28. Re: Relaying
       pestilence <pestilence at netplan dot gr>
       Wed, 22 Sep 1999 10:13:33 +0300
 29. Re: Install problems.
       Bestia <root at linux.avcentrum.com dot pl>
       Wed, 22 Sep 1999 14:46:58 +0200 (CEST)
 30. APOP problem
       Edward Kaftan <kaftan at hermen.physiol.washington dot edu>
       Wed, 22 Sep 1999 16:36:13 -0700 (PDT)
 31. Re: Install problems.
       Jonathan Benson <sysadmin at ocean.com dot au>
       Thu, 23 Sep 1999 10:26:26 +1000
 32. limitation on the nbre of users ??
       Clara Hatem <clara at inco.com dot lb>
       Thu, 23 Sep 1999 20:20:08 +0300
 33. RE: limitation on the nbre of users ??
       dandrews at mpiua dot com
       Thu, 23 Sep 1999 13:51:05 -0400
 34. RE: limitation on the nbre of users ??
       "Louis A. DeRobertis" <louis at suffolk.lib.ny dot us>
       Thu, 23 Sep 1999 14:21:51 -0400 (EDT)
 35. Qpopper 2.53
        <gavin at imagine.math.ou dot edu>
       Thu, 23 Sep 1999 14:03:58 -0500 (CDT)
 36. What is the problem?
       cache <cache at iname dot com>
       Fri, 24 Sep 1999 07:24:17 +0800
 37. Re: What is the problem?
       "Jeremy C. Reed" <reed at wcug.wwu dot edu>
       Thu, 23 Sep 1999 16:50:35 -0700 (PDT)
 38. Re: What is the problem?
       Rodrigo Luiz Anami <rodrigoa at bestway.com dot br>
       Fri, 24 Sep 1999 09:55:01 -0300 (EST)
 39. Bulletins
       Eduardo Marcel Macan <macan at colband.com dot br>
       Fri, 24 Sep 1999 10:51:13 -0300
 40. Re: Bulletins
       Mikolaj Rydzewski <miki at ceti.com dot pl>
       Fri, 24 Sep 1999 16:31:03 +0200 (CEST)
 41. Solaris 2.7 Compile Problem
       Rob Imerson <rob at masktech.nsc dot com>
       Fri, 24 Sep 1999 08:39:51 -0700
 42. RE: .user.pop lock busy! Is another session active?
       Listmaster <listmaster at lists.pensive dot org>
       Fri, 24 Sep 1999 09:26:45 -0700
 43. Re: Qpopper 2.53
       =?iso-8859-1?Q?Buzón?= auxiliar <aux at aitemin dot es>
       Fri, 24 Sep 1999 19:01:59 +0200
 44. Re: Bulletins
       Fergal Daly <fergal at esatclear dot ie>
       Fri, 24 Sep 1999 19:32:49 +0100
 45. Solaris Compile Problem
       Rob Imerson <rob at masktech.nsc dot com>
       Fri, 24 Sep 1999 13:53:25 -0700
 46. Radius
       "Franco Catena" <catena at langnet.com dot br>
       Fri, 24 Sep 1999 17:12:03 -0300
 47. Re: Bulletins
       "James Nelson" <james at digit.bloomnet dot com>
       Fri, 24 Sep 1999 19:09:47 -0500
 48. Resent: Qpopper3.0 Question
       rlau2 at csc dot com
       Sun, 26 Sep 1999 09:31:18 +0930
 49. Qpopper3.0 Question
       rlau2 at csc dot com
       Sun, 26 Sep 1999 09:26:57 +0930
 50. Qpopper 2.53 and RH 6.0
       cache <cache at iname dot com>
       Mon, 27 Sep 1999 08:56:53 +0800

Date: Sat, 18 Sep 1999 02:32:35 +0600
From: "S. Faruque Ahmed" <sfque at texasgroup dot net>
Subject: Re: Stuck pop files

Gentlemen,

Here's a thought, and a possible solution ...I quote from Qualcomm's site
for the new Qpopper 3.0 Public Beta at
http://www.eudora.com/freeware/qpop.html#BETA

"New features and bug fixes include: ...
A failure at some point in a transaction now releases all locks
explicitly...."

Although it is beta, you might want to give it a shot?

SFQ

At 18:58 17/09/99 +0200, Carrer Yuri wrote:
>
>> Anyone have any idea why pop files would get stuck stuck stuck for a long
>> time?  I have customers that call occasionally saying that they can't get
>> their mail, so they disconnect, call me, and I look, and there's still a 
>> .username.pop file from like 5 minutes before.  I can sit there and wait
>> and it doesn't go away.  Eventually, later in the day I check and it's
>> gone.
>> 
>> My line from inetd.conf is as follow:
>> 
>> pop     stream  tcp     nowait  root    /usr/libexec/tcpd       popper
-T 60 -b /var/mail/bulldir
>> 
>> I'd be cool to know why they're sticking, but it'd also be cool to know
>> how to kill the pop process so that it doesn't generate the poplock busy
>> when they're not even checking (like 30 minutes later!)  Any help would be
>> appreciated...
>
> Heh, I'm not alone :-) I'm planning to switch to cucipop. Qpopper is too
> "corporate". :)
>
>								Yuri
>
>

From: "Jerry O'Brien" <jobrien at cuttingedge dot net>
Subject: Re: .user.pop lock busy! Is another session active?
Date: Fri, 17 Sep 1999 12:32:37 -0500

OE5's server time-out is set to 1 min. by default. That's only enough for a
couple hundred Kb mailbox on a typical modem connection.

Increase the time-out or tell the pop-up you want to continue to wait for
the server.

Jerry O'Brien


----- Original Message -----
From: Leonard Hermens <Leonard.Hermens at rcity dot com>
To: <qpopper at lists.pensive.org>; Steven Fletcher <stevenf at shellnet dot co dot uk>
Sent: Friday, September 17, 1999 11:53 AM
Subject: RE: .user.pop lock busy! Is another session active?


> > >  Baing seriously, there's a bad interaction somewhere between Outlook
> > > Express and qpopper.
> >
> >uuuh....Why would it matter if the POP3 client was Outlook, Agent,
> >fetchmail, or anything for that matter? POP3 is POP3, nothing will change
> >that.
> >
> >More than likely people are simply timing out and trying to connect again
> >before your server times out. I would look at Qpopper's -T option.
> >
> >Steven Fletcher
> >stevenf at shellnet.co dot uk
>
> I can confirm that Outlook clients in the past (don't know about
> version 5) have caused a hang that Eudora (for example) did not
> exhibit when downloading a large attachment or when certain header
> lines were blank. This would lead to a SIGHUP on the qpopper because
> the Outlook client did/could not exit gracefully.
>
> -- Leonard
>
>
>



Date: Fri, 17 Sep 1999 18:06:06 -0400
From: "Marcelo dos S. Tavares" <mtavares at argo.com dot br>
Subject: .user.pop lock busy! Is another session active?

>  Yes, dump qpopper and use another pop server.
>
>  Baing seriously, there's a bad interaction somewhere between Outlook
> Express and qpopper.

OK!
Do you know another POP3 server with support hash spool ?? The mail
spool of the user is located in /var/spool/mail/u/s/user.
Example: User peter -- /var/spool/mail/p/e/peter

We used CUCIPOP. But it seems does not have support hash spool mail.

Very Thanks!

PS: Automatic translated by http://translator.go.com/


From: "Brunette, Jason" <jbrunette at excel dot net>
Subject: RE: .user.pop lock busy! Is another session active?
Date: Fri, 17 Sep 1999 17:32:17 -0500

I'm surprised by how many people believe this way.  Why would the author of
a mail program set a limit on the amount of time you spend actively
downloading a batch of mail?

The "Server timeouts" refers to inactivity.  If Outlook Express, when
attempting to connect to or is connected to a server to send or receive
mail, doesn't receive a response from the server within the time specified
in "Server timeouts", the Outlook Express pops up an error.

============================================================================
Jason Brunette              Excel.Net, Inc.            Phone: (920) 452-0455
jbrunett at excel dot net "Your excellent Internet provider"    Fax: (920) 452-8118
                        http://www.excel.net/      Toll Free: (888) 489-9995
----------------------------------------------------------------------------


> -----Original Message-----
> From: Jerry O'Brien [mailto:jobrien at cuttingedge dot net]
> Sent: Friday, September 17, 1999 12:33 PM
> To: qpopper at lists.pensive dot org; Steven Fletcher; Leonard Hermens
> Subject: Re: .user.pop lock busy! Is another session active?
> 
> 
> OE5's server time-out is set to 1 min. by default. That's 
> only enough for a
> couple hundred Kb mailbox on a typical modem connection.
> 
> Increase the time-out or tell the pop-up you want to continue 
> to wait for
> the server.
> 
> Jerry O'Brien

Date: Sat, 18 Sep 1999 20:58:55 +1200 (NZST)
From: Alan Brown <alan at manawatu.gen dot nz>
Subject: Re: .user.pop lock busy! Is another session active?

On Fri, 17 Sep 1999, Marcelo dos S. Tavares wrote:

> Do you know another POP3 server with support hash spool, i.e., the mail
> spool of
> the user is located in /var/spool/mail/u/s/user.
> Example: User peter -- /var/spool/mail/p/e/peter

Does anyone know how to make sendmail deliver to such mailboxes?

AB


Date: Sat, 18 Sep 1999 21:15:44 +1200 (NZST)
From: Alan Brown <alan at manawatu.gen dot nz>
Subject: RE: .user.pop lock busy! Is another session active?

On Fri, 17 Sep 1999, Carrer Yuri wrote:

>  Is not Outlook crashing, is qpopper not acting well sometimes. Is has to
>  delete the .user.pop lock file if the tcp/ip connection drop. Instead I
> suspect it crashes and leaves the lock. Ant way to check if qpopper
> crash?

It does check to see if the lockfile is held by an active process and
will delete it with a warning about stale lockfiles if the process which
made the lockfile no longer exists.

AB



Date: Sat, 18 Sep 1999 21:25:05 +1200 (NZST)
From: Alan Brown <alan at manawatu.gen dot nz>
Subject: RE: .user.pop lock busy! Is another session active?

On Fri, 17 Sep 1999, Brunette, Jason wrote:

> I'm surprised by how many people believe this way.  Why would the author of
> a mail program set a limit on the amount of time you spend actively
> downloading a batch of mail?

Various reasons.

Eudora (v3 upwards) has "connect" and "collect" timeouts to allow a
short time to actually connect to the server vs longer periods to
collect each message.

They default to 60 seconds though. About 40% of _all_ our helpdesk calls
are people on dialins who keep timing out because their settings are at
defaults while they have a 1MB+ message to collect.

AB


Date: Sat, 18 Sep 1999 13:12:49 +0200 (MET DST)
From: Carrer Yuri <yurj at dns.alfa dot it>
Subject: RE: .user.pop lock busy! Is another session active?

On Fri, 17 Sep 1999, Admin Mailing Lists wrote:

> I posted a patch a while back for the popper.
> When you connect it checks if your username has a popper process open, if
> you do, popper kills the former cleanly, then automatically opens a new
> one for you in the current session. Saves admins having to clean any
> stale pop files.

 Wow :) Can you send me? Other patches out there?



Date: Sat, 18 Sep 1999 13:19:00 +0200 (MET DST)
From: Carrer Yuri <yurj at dns.alfa dot it>
Subject: Re: .user.pop lock busy! Is another session active?


On Fri, 17 Sep 1999, Jerry O'Brien wrote:

> OE5's server time-out is set to 1 min. by default. That's only enough for a
> couple hundred Kb mailbox on a typical modem connection.
> 
> Increase the time-out or tell the pop-up you want to continue to wait for
> the server.
> 

 I don't understand what is the purpouse of this "timeout".

								Yuri



Date: Sat, 18 Sep 1999 13:14:05 +0200 (MET DST)
From: Carrer Yuri <yurj at dns.alfa dot it>
Subject: Re: Stuck pop files

On Sat, 18 Sep 1999, S. Faruque Ahmed wrote:

> Gentlemen,
> 
> Here's a thought, and a possible solution ...I quote from Qualcomm's site
> for the new Qpopper 3.0 Public Beta at
> http://www.eudora.com/freeware/qpop.html#BETA
> 
> "New features and bug fixes include: ...
> A failure at some point in a transaction now releases all locks
> explicitly...."

 No, because it had loosen a 14 MB mailbox :-) and would like it more
 stable. 

								Yuri



Date: Sat, 18 Sep 1999 13:22:48 -0400 (EDT)
From: Admin Mailing Lists <mlist at intergrafix dot net>
Subject: RE: .user.pop lock busy! Is another session active?

Someone said my attached patch file was MIME encoded. I just use Pine to
send files as I always have. Anyway, below is the file attached as plain
text. For instructions, see previous post or email me.

-Cygnus
.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-.
Anthony J. Biacco                       Network Administrator/Engineer
admin at intergrafix dot net                    Intergrafix Internet Services

    "Dream as if you'll live forever, live as if you'll die today"
http://cygnus.ncohafmuta.com                http://www.intergrafix.net
.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-.

/*
 * Copyright (c) 1989 Regents of the University of California.
 * All rights reserved.  The Berkeley software License Agreement
 * specifies the terms and conditions for redistribution.
 */

/*
 * Copyright (c) 1998 Qualcomm Incorporated. All rights reserved.
 *
 * Revisions : 
 *  6/22/98  [py]
 *         - Added kludge for NULLs in message content(suggested by 
 *           Mordechai T.Abzug).
 *           Uidl to contain From Envelope in non-mmdf, and length check.
 *  3/18/98  [py]
 *         - Reviewed the code, added DEBUG macros, corrected the 
 *            resources that are not closed.
 */

/*
 * When adding each line length into the size of the message and the maildrop,
 * increase the character count by one for the <cr> added when sending the
 * message to the mail client.  All lines sent to the client are terminated
 * with a <cr><lf>.
 */

#include <config.h>

#include <errno.h>
#include <stdio.h>
#include <sys/types.h>
#include <ctype.h>
#include <string.h>
#include <flock.h>

#if HAVE_UNISTD_H
# include <unistd.h>
#endif

#if HAVE_SYS_UNISTD_H
# include <sys/unistd.h>
#endif

#ifndef HAVE_INDEX
#  define	index(s,c)		strchr(s,c)
#  define	rindex(s,c)		strrchr(s,c)
# endif
#if HAVE_STRINGS_H
# include <strings.h>
#endif
#include <sys/stat.h>
#include <sys/file.h>
#include <pwd.h>
#include <popper.h>

#ifdef MAILOCK
# ifdef HAVE_MAILLOCK
#  include <maillock.h>
# endif
# define MAILUNLOCK() mailunlock()
#else 
# define MAILUNLOCK()
#endif

#define MIN_UIDL_LENGTH 5     /* There is no particular reason to have this */
#define MAX_UIDL_LENGTH 70

/* This macro comes from Mark Crispin's c-client code */

/* Validate line
 * Accepts: pointer to candidate string to validate as a From header
 *	    return pointer to end of date/time field
 *	    return pointer to offset from t of time (hours of ``mmm dd hh:mm'')
 *	    return pointer to offset from t of time zone (if non-zero)
 * Returns: t,ti,zn set if valid From string, else ti is NIL
 */

#define PS_COMMAND	"ps ux"	/* this command is run as the username */
				/* and should show process names,pids, */
				/* and the process owner	       */
				/* ps ux works for linux for sure      */
#define PS_SEARCH	"popper" /* name the popper process runs as    */
				 /* as shown in the process list       */
void clear_old(POP *p);

#define VALID(s,x,ti,zn) {						\
  ti = 0;								\
  if ((*s == 'F') && (s[1] == 'r') && (s[2] == 'o') && (s[3] == 'm') &&	\
      (s[4] == ' ')) {							\
    for (x = s + 5; *x && *x != '\n'; x++);				\
    if (x) {								\
      if (x - s >= 41) {						\
	for (zn = -1; x[zn] != ' '; zn--);				\
	if ((x[zn-1] == 'm') && (x[zn-2] == 'o') && (x[zn-3] == 'r') &&	\
	    (x[zn-4] == 'f') && (x[zn-5] == ' ') && (x[zn-6] == 'e') &&	\
	    (x[zn-7] == 't') && (x[zn-8] == 'o') && (x[zn-9] == 'm') &&	\
	    (x[zn-10] == 'e') && (x[zn-11] == 'r') && (x[zn-12] == ' '))\
	  x += zn - 12;							\
      }									\
      if (x - s >= 27) {						\
	if (x[-5] == ' ') {						\
	  if (x[-8] == ':') zn = 0,ti = -5;				\
	  else if (x[-9] == ' ') ti = zn = -9;				\
	  else if ((x[-11] == ' ') && ((x[-10]=='+') || (x[-10]=='-')))	\
	    ti = zn = -11;						\
	}								\
	else if (x[-4] == ' ') {					\
	  if (x[-9] == ' ') zn = -4,ti = -9;				\
	}								\
	else if (x[-6] == ' ') {					\
	  if ((x[-11] == ' ') && ((x[-5] == '+') || (x[-5] == '-')))	\
	    zn = -6,ti = -11;						\
	}								\
	if (ti && !((x[ti - 3] == ':') &&				\
		    (x[ti -= ((x[ti - 6] == ':') ? 9 : 6)] == ' ') &&	\
		    (x[ti - 3] == ' ') && (x[ti - 7] == ' ') &&		\
		    (x[ti - 11] == ' '))) ti = 0;			\
      }									\
    }									\
  }									\
  else if ((*s == 'r') && (s[1] == 'o') && (s[2] == 'm') && (s[3] == ' ')) {	\
    for (x = s + 4; *x && *x != '\n'; x++);				\
    if (x) {								\
      if (x - s >= 41) {						\
	for (zn = -1; x[zn] != ' '; zn--);				\
	if ((x[zn-1] == 'm') && (x[zn-2] == 'o') && (x[zn-3] == 'r') &&	\
	    (x[zn-4] == 'f') && (x[zn-5] == ' ') && (x[zn-6] == 'e') &&	\
	    (x[zn-7] == 't') && (x[zn-8] == 'o') && (x[zn-9] == 'm') &&	\
	    (x[zn-10] == 'e') && (x[zn-11] == 'r') && (x[zn-12] == ' '))\
	  x += zn - 12;							\
      }									\
      if (x - s >= 27) {						\
	if (x[-5] == ' ') {						\
	  if (x[-8] == ':') zn = 0,ti = -5;				\
	  else if (x[-9] == ' ') ti = zn = -9;				\
	  else if ((x[-11] == ' ') && ((x[-10]=='+') || (x[-10]=='-')))	\
	    ti = zn = -11;						\
	}								\
	else if (x[-4] == ' ') {					\
	  if (x[-9] == ' ') zn = -4,ti = -9;				\
	}								\
	else if (x[-6] == ' ') {					\
	  if ((x[-11] == ' ') && ((x[-5] == '+') || (x[-5] == '-')))	\
	    zn = -6,ti = -11;						\
	}								\
	if (ti && !((x[ti - 3] == ':') &&				\
		    (x[ti -= ((x[ti - 6] == ':') ? 9 : 6)] == ' ') &&	\
		    (x[ti - 3] == ' ') && (x[ti - 7] == ' ') &&		\
		    (x[ti - 11] == ' '))) ti = 0;			\
      }									\
    }									\
  }									\
}

/* You are not expected to understand this macro, but read the next page if
 * you are not faint of heart.
 *
 * Known formats to the VALID macro are:
 * 		From user Wed Dec  2 05:53 1992
 * BSD		From user Wed Dec  2 05:53:22 1992
 * SysV		From user Wed Dec  2 05:53 PST 1992
 * rn		From user Wed Dec  2 05:53:22 PST 1992
 *		From user Wed Dec  2 05:53 -0700 1992
 *		From user Wed Dec  2 05:53:22 -0700 1992
 *		From user Wed Dec  2 05:53 1992 PST
 *		From user Wed Dec  2 05:53:22 1992 PST
 *		From user Wed Dec  2 05:53 1992 -0700
 * Solaris	From user Wed Dec  2 05:53:22 1992 -0700
 *
 * Plus all of the above with `` remote from xxx'' after it. Thank you very
 * much, smail and Solaris, for making my life considerably more complicated.
 */


int newline = 1;

/*
 *  0 for not a from line
 *  1 for is a from line
 */

/* Valid UUCP From lines:
 *
 *	From Address [tty] date
 *	From [tty] date
 *
 *	"From [tty] date" is probably valid but I'm too lazy at this
 *	time to add the code.
 *
 */
int
isfromline(cp)
char	*cp;
{
    int ti, zn;
    char *x;

    /* If the previous line was not a newline then just return */
    /* From message separators are preceeded by a newline */ 
    if (*cp == '\n') {
	newline = 1;
	return(0);
    } else if (!newline) {
	return(0);
    } else
	newline = 0;

    VALID(cp, x, ti, zn);
    return(ti != 0);
}


/*
 * Base 80 encoding of 16byte MD5 hash. This is about the smalles encoding
 * possible for the MD5 hash using the chars allowed for UIDLs. 
 * (93 ASCII values are available and 19^93 < 2^128 < 20^93)
 * This implementation isn't exact about MSBs and LSB, but it is unique..
 */

char *base80(char *output, char *digest)
{
  unsigned long v, n, j;
  int i, k;

  for(i = 0 ; i < 16; ) {
    v = 0L;
    do {
      v = (v << 4) + digest[i++];
    } while(i%4);
    for(k = 0; k < 5; k++) {
      j = v % 80;
      v = (v - j)/80;
      *output = 0x21 + j;
      /* Avoid . altgother to avoid having to stuff it */
      if(*output == '.')
        *output = '~';
      output++;
    }
  }
  *output = '\0';
  return(output);
}



/* Hashing to a spool directory helps reduce the lookup time for sites
 * with thousands of mail spool files.  Unix uses a linear list to
 * save directory information and the following methods attempt to
 * improve the performance.
 *
 * Method 1 - add the value of the first 4 chars mod 26 and open the
 *	      spool file in the directory 'a' - 'z'/user.
 *	      Brian Buhrow <buhrow at cats.ucsc dot edu>
 *
 * Method 2 - Use the first 2 characters to determine which mail spool
 *	      to open.  Eg: /usr/spool/u/s/user.
 *	      Larry Schwimmer <rosebud at cyclone.stanford dot edu>
 *
 * All these methods require that local mail delivery and client programs
 * use the same algorithm.  Only one method to a customer :-)
 */

#if (HASH_SPOOL == 1)

int
genpath(p)
POP *p;
{
    int seed = 0;
    char dirchar[4];

    if (!p->user || *p->user == '\0')
	return(NULL); /*bogus login name*/

    /*Now, perform the hash*/

    switch(strlen(p->user)) {
	   case 1:
	   seed = (p->user[0]);
	   break;
	   case 2:
	   seed = (p->user[0] + p->user[1]);
	   break;
	   case 3:
	   seed = (p->user[0] + p->user[1] + p->user[2]);
	   break;
	   case 4:
	   seed = (p->user[0] + p->user[1] + p->user[2]+p->user[3]);
	   break;
	   default:
	   seed = (p->user[0] + p->user[1] + p->user[2]+p->user[3]+p->user[4]);
	   break;
    }
    dirchar[0] = '/';
    dirchar[1] = (char)((seed % 26) + 'a');
    dirchar[2] = '/';
    dirchar[3] = '\0';
    strncpy(p->drop_name, POP_MAILDIR, sizeof(p->drop_name));
    strncat(p->drop_name, dirchar, sizeof(p->drop_name) - strlen(p->drop_name));
    strncat(p->drop_name, p->user, sizeof(p->drop_name) - strlen(p->drop_name));

    return(1);
}

#endif
#if (HASH_SPOOL == 2)

int
genpath(p)
POP *p;
{
    static char pathstr[256];

    if (!p->user || *p->user == '\0')
	return(NULL);
    
    sprintf(pathstr, "/%c/%c/%s",
		    *p->user, *(p->user+1) ? *(p->user+1) : *p->user, p->user);

    strncpy(p->drop_name, POP_MAILDIR, sizeof(p->drop_name));
    strncat(p->drop_name, pathstr, sizeof(p->drop_name) - strlen(p->drop_name));

    return(1);
}

#endif
#if (HASH_SPOOL != 1 && HASH_SPOOL != 2)

int
genpath(p)
POP *p;
{
    struct passwd *pwp;

#ifdef HOMEDIRMAIL
    if ((pwp = getpwnam(p->user)) == NULL) {
	pop_log(p, POP_FAILURE, "unable to retrieve users password entry");
	return(-1);
    }
    strncpy(p->drop_name, pwp->pw_dir, sizeof(p->drop_name));
    strncat(p->drop_name, "/.mail",sizeof(p->drop_name) - strlen(p->drop_name));
#else
    strncpy(p->drop_name, POP_MAILDIR, sizeof(p->drop_name));
    strncat(p->drop_name, "/", sizeof(p->drop_name) - strlen(p->drop_name));
    strncat(p->drop_name, p->user, sizeof(p->drop_name) - strlen(p->drop_name));
#endif

    return(1);
}

#endif /* HASH_SPOOL */

  

/* 
 * Build the Msg_info_list from the temp_drop in case the previous session
 * failed to truncate. init_dropinfo and do_drop_copy differ in that
 * do_drop_copy would copy all the messages from source file to destination
 * file while it generates the Msg_info_list.
 */
int init_dropinfo(p)
POP *p;
{
    MsgInfoList         *   mp;         /* Pointer to message info list */
    int			    msg_num;	/* Current message number */
    int			    nchar;
    int			    inheader;
    int			    uidl_found;
    int			    expecting_trailer;
    int			    content_length, content_nchar, cont_len;
    char                    buffer[MAXLINELEN];		/*  Read buffer */
    char                    frombuf[MAXLINELEN];        /* From Envelope of each
							 * message is saved, for
							 * adding it to UIDL
							 * computation */
    MD5_CTX		    mdContext;
    unsigned char	    digest[16];
    long unique_num = time(0);

    DEBUG_LOG1(p,"DROPINFO Checking for old .%s.pop file", p->user);


#ifdef NULLKLUDGE
    {
	/* Eat NULLs at the beginning of the mailspool */
	char tempchar;
	while ((tempchar = getc(p->drop)) == 0);
	ungetc(tempchar, p->drop);
    }
#endif

    if (mfgets(buffer, MAXMSGLINELEN, p->drop) == NULL) {
	DEBUG_LOG1(p, "Drop file empty intially : %s", p->temp_drop);
	return(POP_SUCCESS);    
    }

    /* Is this an MMDF file? */
    if (*buffer == MMDF_SEP_CHAR) {
	p->mmdf_separator = (char *)strdup(buffer);
    } else if (!isfromline(buffer)) {
	return pop_msg (p,POP_FAILURE,
	  "Unable to process From lines (envelopes) in %s.",p->temp_drop);
    }

    newline = 1;
    rewind(p->drop);

    inheader = 0;
    msg_num = 0;
    uidl_found = 0;
    expecting_trailer = 0;
    content_length = 0;
    content_nchar = 0;
    cont_len = 0;
    p->msg_count = ALLOC_MSGS;


#ifdef NULLKLUDGE
    {
	/* Eat NULLs at the beginning of the mailspool */
	char tempchar;
	while ((tempchar = getc(p->drop)) == 0);
	ungetc(tempchar, p->drop);
    }
#endif

    DEBUG_LOG1(p,"Building the Message Information list from %s",p->temp_drop);

    for (mp=p->mlp - 1; mfgets(buffer, MAXMSGLINELEN, p->drop);) {
	nchar = strlen(buffer);

	if ((content_nchar >= content_length) &&
	    (p->mmdf_separator ? !strcmp(p->mmdf_separator, buffer) :
	    isfromline(buffer))) {
            /* ---- A message boundary ----- */
            /* ---- Tidy up previous message (if there was one) ---- */
	    if (expecting_trailer) {
		/* skip over the MMDF trailer */
		expecting_trailer = 0;
		continue;
	    }

	    if(!p->mmdf_separator) {
		strcpy(frombuf,buffer); /* Preserved From envelope */
	    }
            /* ------ Get ready for the next message ----- */
	    MD5Init (&mdContext);
	    MD5Update(&mdContext,(unsigned char *)buffer,strlen(buffer));
            /* Include a unique number in case everything else is not */
            unique_num++;
            MD5Update(&mdContext,(unsigned char *)&unique_num, sizeof(long));

	    if (!inheader) {
		if (++msg_num > p->msg_count) {
		    p->mlp = (MsgInfoList *) realloc(p->mlp,
			(p->msg_count += ALLOC_MSGS) * sizeof(MsgInfoList));
		    if (p->mlp == NULL){
			p->msg_count = 0;
			return pop_msg (p, POP_FAILURE,
			    "Can't build message list for '%s': Out of memory",
				    p->user);
		    }
		    mp = p->mlp + msg_num - 2;
		}
		if(msg_num != 1){
		    DEBUG_LOG5(p,"Msg %d uidl %s at offset %d is %d octets long and has %u lines.",
			       mp->number, mp->uidl_str, mp->offset, 
			       mp->length, mp->lines);
		}
		else
		    pop_log(p,POP_DEBUG, "Found top of first message");
		++mp;

	    } 
	    else { 
		pop_log(p,POP_DEBUG,
		    "Msg %d corrupted, ignoring previous header information.",
		     mp->number);
	    }
	    mp->number = msg_num;
	    mp->length = 0;
	    mp->lines = 0;
	    mp->body_lines = 0;
	    mp->offset = ftell(p->drop) - nchar;
	    mp->del_flag = FALSE;
	    mp->retr_flag = FALSE;
	    mp->orig_retr_state = FALSE;
	    mp->uidl_str = "\n";
	    DEBUG_LOG1(p,"Msg %d being added to list %x", mp->number);
	    inheader = 1;
	    uidl_found = 0;
	    content_nchar = 0;
	    content_length = 0;
	    cont_len = 0;
	    if (p->mmdf_separator)
		expecting_trailer = 1;

	    continue;	/* Don't count message separator in total size */
	}
	
	if (inheader) {
	    if (*buffer == '\n') {
		inheader = 0;
		content_length = cont_len;
		mp->body_lines = 1;  /* Count newline as the first body line */
		if (!uidl_found) {
		    char	*cp;
		    int		i;

		    MD5Update(&mdContext, (unsigned char *)frombuf, 
			      strlen(frombuf));
		    MD5Final (digest, &mdContext);
		    cp = mp->uidl_str = (char *)malloc((DIG_SIZE * 2) + 2);
		    cp = base80(cp, digest);
		    *cp++ = '\n';
		    *cp   = '\0';

		    mp->length += strlen("X-UIDL: ") + strlen(mp->uidl_str) + 1;
		    p->drop_size += strlen("X-UIDL: ") + strlen(mp->uidl_str)+1;

	/* New UIDs do not dirty the mailspool if NO_STATUS is set.  They
	   are just recalculated each time the popper is run or LMOS is
	   set and the mail spool is updated.
	 */
#ifndef NO_STATUS
		    p->dirty = 1;
#endif
		}

	    } else if (CONTENT_LENGTH && !strncmp(buffer, "Content-Length:", 15)) {
		cont_len = atoi(buffer + 15);
		MD5Update(&mdContext,(unsigned char *)buffer,strlen(buffer));
		mp->lines++;
		continue;	/* not part of the message size */
	    } else if (!uidl_found && (!strncasecmp("Received:", buffer, 9) ||
				       !strncasecmp("Date:", buffer, 5) ||
				       !strncasecmp("Message-Id:",buffer, 11) ||
				       !strncasecmp("Subject:",buffer, 8)
				       )) {
		MD5Update(&mdContext,(unsigned char *)buffer,strlen(buffer));
	    } else if (!strncasecmp("X-UIDL:", buffer, 7)) {
		if (!uidl_found) {
		    char *cp;
		    int len;

		    /* Skip over header string */
		    cp = buffer;
		    if (cp = index(buffer, ':')) {
			cp++;
			while (*cp && (*cp == ' ' || *cp == '\t')) cp++;
		    } else
			cp = "";

		    if( (len = strlen(cp)) > MIN_UIDL_LENGTH && len < MAX_UIDL_LENGTH ) {
			uidl_found++;
			mp->uidl_str = (char *)strdup(cp);
			mp->length += nchar + 1;
			p->drop_size += nchar + 1;
		    }
		}
		mp->lines++;
		continue;  /* Do not include this value in the message size */
	    } else if ((strncasecmp(buffer,"Status:",7) == 0)) {
		if (index(buffer, 'R') != NULL) {
		    mp->retr_flag = TRUE;
		    mp->orig_retr_state = TRUE;
		}
	    }
	} else {
	    content_nchar += nchar;
	    mp->body_lines++;
	}
       
	mp->length += nchar + 1;
	p->drop_size += nchar + 1;
	mp->lines++;
    }

    p->msg_count = msg_num;

    return(POP_SUCCESS);
}


/* 
 *  use to be dropinfo:   Extract information about the POP maildrop and store 
 *  it for use by the other POP routines.
 *
 *  Now, the copy and info collection are done at the same time.
 */

do_drop_copy(p, mfd, dfd)
int	mfd, dfd;
POP	*p;
{
    char                    buffer[MAXLINELEN];     /*  Read buffer */
    char                    frombuf[MAXLINELEN];    /*  To save From Envelope */
    MsgInfoList         *   mp;                     /*  Pointer to message 
                                                        info list */
    int                     nchar;                  /*  Bytes written/read */
    int			    inheader;		    /*  Header section flag */
    int			    uidl_found;		    /*  UIDL header flag */
    int			    msg_num;
    int			    expecting_trailer;
    int			    content_length, content_nchar, cont_len;
    MD5_CTX		    mdContext;
    unsigned char	    digest[16];
    int                     mangled_one;
    FILE		    *mail_drop;		    /*  Streams for fids */
    long unique_num = time(0);

    DEBUG_LOG0(p,"DROPCOPY: Reading the Mail Drop box.");
    /*  Acquire a stream pointer for the maildrop */
    if ( (mail_drop = fdopen(mfd,"r")) == NULL ) {
        return pop_msg(p,POP_FAILURE,"Cannot assign stream for %s (%d)",
		       p->drop_name, errno);
    }

    rewind (mail_drop);
#ifdef NULLKLUDGE
    {/* Eat NULLs at the beginning of the mailspool */
        char tempchar ;
	while ((tempchar = getc(p->drop)) == 0);
	ungetc(tempchar, p->drop);
    }
#endif
    if (mfgets(buffer, MAXMSGLINELEN, mail_drop) == NULL) {
	return(POP_SUCCESS);
    }

    /* Is this an MMDF file? */
    if (*buffer == MMDF_SEP_CHAR) {
	if (!p->mmdf_separator)
	    p->mmdf_separator = (char *)strdup(buffer);
    } else if (!isfromline(buffer)) {
	DEBUG_LOG1(p,"buffer checked %s", buffer);
	return pop_msg (p,POP_FAILURE,
	 "Unable to process From lines (envelopes), change recognition modes.");
    }

    newline = 1;
    rewind (mail_drop);

    /*  Scan the file, loading the message information list with 
        information about each message */

    inheader = 0;
    uidl_found = 0;
    expecting_trailer = 0;
    msg_num = p->msg_count;
    content_length = 0;
    content_nchar = 0;
    cont_len = 0;
    mangled_one = 0;
    p->msg_count = (((p->msg_count - 1) / ALLOC_MSGS) + 1) * ALLOC_MSGS;
#ifdef NULLKLUDGE
    {/* Eat NULLs at the beginning of the mailspool if any.*/
	char tempchar;
	while ((tempchar = getc(p->drop)) == 0);
	ungetc(tempchar, p->drop);
    }
#endif
    for (mp = p->mlp + msg_num - 1; mfgets(buffer,MAXMSGLINELEN,mail_drop);) {

	nchar = strlen(buffer);

	if (fputs(buffer, p->drop) == EOF) {
	    if (errno == EDQUOT)
		return pop_msg (p,POP_FAILURE,
		    "Unable to copy mail spool file, quota exceeded (%d)",
			errno);
	    return pop_msg (p,POP_FAILURE,
		"Unable to copy mail spool file to temp pop dropbox %s (%d)",
		    p->temp_drop, errno);
	}
	/* End of previous message */
	if ((content_nchar >= content_length) &&
	    (p->mmdf_separator ? !strcmp(p->mmdf_separator, buffer) :
	    isfromline(buffer))) {
            /*=== Matched separator, tie of last message, start new one ===*/


	    if (expecting_trailer) {
		expecting_trailer = 0;
		continue;
	    }

	    if( !p->mmdf_separator ) {
		strcpy(frombuf, buffer);
	    }

            /*=== Starting new message ===*/
	    MD5Init (&mdContext);
	    MD5Update(&mdContext,(unsigned char *)buffer,strlen(buffer));
            /* Include a unique number in case everything else is not */
            unique_num++;
            MD5Update(&mdContext,(unsigned char *)&unique_num, sizeof(long));

	    if (!inheader) {
		if (++msg_num > p->msg_count) {
		    p->mlp=(MsgInfoList *) realloc(p->mlp,
			(p->msg_count+=ALLOC_MSGS)*sizeof(MsgInfoList));
		    if (p->mlp == NULL) {
			p->msg_count = 0;
			return pop_msg (p,POP_FAILURE,
			    "Can't build message list for '%s': Out of memory",
				p->user);
		    }
		    mp = p->mlp + msg_num - 2;
		}
		if( msg_num != 1)
		    DEBUG_LOG5(p,"Msg %d uidl %s at offset %d is %d octets long and has %u lines.",
			      mp->number,mp->uidl_str,mp->offset,mp->length,
			      mp->lines);
		++mp;

	    } else {
		pop_log(p,POP_DEBUG,"Msg %d corrupted, ignoring previous header information.",
		     mp->number);
	    }

            mp->number = msg_num;
            mp->length = 0;
            mp->lines = 0;
            mp->body_lines = 0;
            mp->offset = ftell(p->drop) - nchar;
            mp->del_flag = FALSE;
            mp->retr_flag = FALSE;
            mp->orig_retr_state = FALSE;
	    mp->uidl_str = "\n";

	    DEBUG_LOG1(p,"Msg %d being added to list.", mp->number);
	    inheader = 1;
	    content_length = 0;
	    content_nchar = 0;
	    cont_len = 0;
	    uidl_found = 0;
	    if (p->mmdf_separator)
		expecting_trailer = 1;


	    continue;	/* Do not include From separator in message size */
        }

        /* ====== Handle header and body of message here ==== */
	if (inheader) {
            /* ===== Handle the header of a message ==== */
	    if (*buffer == '\n') {
                /* === Encountered transition to body ====*/
		inheader = 0;
		mp->body_lines = 1;
		content_length = cont_len;

		if (!uidl_found) {
		    char *cp;
		    int  i;

		    MD5Update(&mdContext, (unsigned char *)frombuf,
			      strlen(frombuf));
		    MD5Final (digest, &mdContext);
		    cp = mp->uidl_str = (char *)malloc((DIG_SIZE * 2) + 2);
                    cp = base80(cp, digest);
		    *cp++ = '\n';
		    *cp   = '\0';
                    DEBUG_LOG1(p, "UIDL -%s-", mp->uidl_str);

		    mp->length += strlen("X-UIDL: ") + strlen(mp->uidl_str) + 1;
		    p->drop_size += strlen("X-UIDL: ") + strlen(mp->uidl_str)+1;

                    /* New UIDs do not dirty the mailspool if NO_STATUS is
                       set.  They are just recalculated each time the
                       popper is run or LMOS is set and the mail spool
                       is updated. */
#ifndef NO_STATUS
		    p->dirty = 1;
#endif
		}

	    } else if(CONTENT_LENGTH && !strncmp(buffer,"Content-Length:",15)){
                /*=== Handle content_length if we do that sort of thing ===*/
		cont_len = atoi(buffer + 15);
		MD5Update(&mdContext,(unsigned char *)buffer,strlen(buffer));
		mp->lines++;
		continue;  /* Not included in message size */

	    } else if (!uidl_found && (!strncasecmp("Received:", buffer, 9) ||
				       !strncasecmp("Date:", buffer, 5) ||
				       !strncasecmp("Message-Id:",buffer, 11) ||
				       !strncasecmp("Subject:",buffer, 8)
				       )) {
                /* === Accumuate certain header we might see for UIDL ===*/
		MD5Update(&mdContext,(unsigned char *)buffer,strlen(buffer));
	    } else if (!strncasecmp("X-UIDL:", buffer, 7)) {
              /* ==== Do the UIDL header ==== */
		if (!uidl_found) {
		    char *cp;
		    int len;

		    /* Skip over header */
		    cp = buffer;
		    if (cp = index(buffer, ':')) {
			cp++;
			while (*cp && (*cp == ' ' || *cp == '\t')) cp++;
		    } else
			cp = "";

		    if( (len = strlen(cp)) > MIN_UIDL_LENGTH && len < MAX_UIDL_LENGTH ) {
			uidl_found++;
			mp->uidl_str = (char *)strdup(cp);
			mp->length += nchar + 1;
			p->drop_size += nchar + 1;
		    }
		}
		mp->lines++;
		continue;  /* Do not include this value in the message size */
	    } else if (!strncasecmp(buffer,"Status:",7)) {
                /* === Do the status header === */
		if (index(buffer, 'R') != NULL) {
		    mp->retr_flag = TRUE;
		    mp->orig_retr_state = TRUE;
		}
	    }
	} else {
            /* ==== Handle the body of a message (not much to do) === */
	    content_nchar += nchar;
	    mp->body_lines++;
	}

        mp->length += nchar + 1;
        p->drop_size += nchar + 1;
        mp->lines++;
    }

    p->msg_count = msg_num;

#ifdef DEBUG
    if(p->debug && msg_num > 0) {
        register    i;
        for (i = 0, mp = p->mlp; i < p->msg_count; i++, mp++)
            pop_log(p,POP_DEBUG,
	    "Msg %d uidl %s at offset %d is %d octets long and has %u lines.",
	    mp->number,mp->uidl_str,mp->offset,mp->length,mp->lines);
    }
#endif

    if (fflush(p->drop) == EOF)
        return pop_msg(p,POP_FAILURE,"Flush of temp pop dropbox %s failed (%d)",
	    p->temp_drop, errno);

    return(POP_SUCCESS);
}

/* 
 *  dropcopy:   Make a temporary copy of the user's mail drop and 
 *  save a stream pointer for it.
 */

pop_dropcopy(p, pwp)
POP     *   p;
struct passwd	*	pwp;
{
    int                     mfd;                    /*  File descriptor for 
                                                        the user's maildrop */
    int                     dfd;                    /*  File descriptor for 
                                                        the SERVER maildrop */
    FILE		    *tf;		    /*  The temp file */
    int			    tfn;		    
    char                    buffer[MAXLINELEN];     /*  Read buffer */
    char		    mess[256];		/* CYGNUS */
    long                    offset;                 /*  Old/New boundary */
    int                     nchar;                  /*  Bytes written/read */
    struct stat             mybuf;                  /*  For fstat() */

    if (genpath(p) < 0)
	return(pop_msg(p, POP_FAILURE, "Unable to create temporary drop name"));

    /*  Create a temporary maildrop into which to copy the updated maildrop */
    (void)sprintf(p->temp_drop, POP_DROP, p->user);

    DEBUG_LOG1(p,"Creating temporary maildrop '%s'",p->temp_drop);

#ifdef BULLDB
    if (p->bulldir) {
	char bull_db[MAXLINELEN];

#ifdef BULLDBDIR
	sprintf(bull_db, "%s/bulldb", BULLDBDIR);
#else
	sprintf(bull_db, "%s/bulldb", p->bulldir);
#endif
#ifdef GDBM
	if ((p->bull_db = gdbm_open (bull_db, 512, GDBM_WRCREAT, 0600, 0)) == NULL)
#else
        if ((p->bull_db = dbm_open (bull_db, O_RDWR | O_CREAT, 0600)) == NULL) 
#endif
		{
		    pop_log(p,POP_PRIORITY,"gdbm_open failed : %s (%d)",
			    sys_errlist[errno],errno);
		    return(pop_msg(p, POP_FAILURE,
				   "Unable to open Bulletin database, contact your administrator"));
		}
    }
#endif

    /* Here we work to make sure the user doesn't cause us to remove or
     * write over existing files by limiting how much work we do while
     * running as root.
     */

#ifdef BINMAIL_IS_SETGID
# if BINMAIL_IS_SETGID > 1
    pwp->pw_gid = (gid_t)BINMAIL_IS_SETGID;
# else
    if (!stat(POP_MAILDIR, &mybuf))
	pwp->pw_gid = mybuf.st_gid;
# endif
#endif

    /* Now we run as the user. */
    (void) setgid((GID_T)pwp->pw_gid);
    /* Set the supplementary groups list */
    (void) setgroups(1,(GID_T *)&pwp->pw_gid); 
    (void) setuid((UID_T)pwp->pw_uid);

    DEBUG_LOG2(p,"uid = %d, gid = %d",getuid(),getgid());

/* START CYGNUS */
STARTOPEN:
mess[0]=0;
/* END CYGNUS */
    if ((dfd = open(p->temp_drop, O_RDWR | O_CREAT, 0600)) == -1) {
        pop_log(p, POP_PRIORITY,
            "Unable to open temporary maildrop '%s': %s (%d)",p->temp_drop,
                (errno < sys_nerr) ? sys_errlist[errno] : "", errno) ;
        return pop_msg(p,POP_FAILURE,
   	   "Failed to create %s with uid %d, gid %d. Change permissions.",
		       p->temp_drop,pwp->pw_uid, pwp->pw_gid);
    }

    fstat(dfd, &mybuf);
    if (mybuf.st_uid != pwp->pw_uid) {
	close(dfd);
	return(pop_msg(p, POP_FAILURE,"Temporary drop file not owned by %s.",
		       p->user));
    }
#ifdef NEXT
    if (mybuf.st_mode & (0x7))
#else
    if (mybuf.st_mode & (S_IWOTH | S_IROTH))
#endif
    {
	close(dfd);
	return(pop_msg(p, POP_FAILURE,
	  "Your temporary file %s is accessible by others.  This must be fixed",
	    p->temp_drop));
    }
    /* Make sure the mailspool is not a hard link */
    if (mybuf.st_nlink != 1) {
	close(dfd);
	return(pop_msg(p, POP_FAILURE,
	    "Your temporary file appears to have more than one link."));
    }

    /* If the temporary popdrop is not empty, revert to regular mode. */
    if (mybuf.st_size != 0)
	p->server_mode = 0;

    /*  Lock the temporary maildrop. Locking is just to check for single
     *  pop session per user.
     */
    if ( flock (dfd, LOCK_EX|LOCK_NB) == -1 ) {
	switch(errno) {
	    case EWOULDBLOCK:
		/* START CYGNUS */
		pop_log(p,POP_PRIORITY,"Found locked spool for %s!",p->user);
		clear_old(p); /* kill user process if there is one */
		/* print_lock_dir(p); */
		pop_log(p,POP_PRIORITY,"Unlocking lock file for %s",p->user);
		/* unlock the drop file */
	    	if (flock(dfd, LOCK_UN)==-1) {
		pop_log(p,POP_PRIORITY,"Cant unlock lock file for %s! (%s)",p->user,strerror(errno));
		pop_log(p,POP_PRIORITY,"Closing drop file for %s!",p->user);
		close(dfd); /* close the drop file */
		pop_log(p,POP_PRIORITY,"CLOSED drop file for %s!",p->user);
		goto STARTEND;
		}
		pop_log(p,POP_PRIORITY,"UNLOCKED lock file for %s",p->user);
		pop_log(p,POP_PRIORITY,"Closing drop file for %s!",p->user);
		close(dfd); /* close the drop file */
		pop_log(p,POP_PRIORITY,"CLOSED drop file for %s!",p->user);
		pop_log(p,POP_PRIORITY,"Removing drop file for %s!",p->user);
		(void)unlink(p->temp_drop); /* remove the drop file */
		pop_log(p,POP_PRIORITY,"REMOVED drop file for %s!",p->user);
		goto STARTOPEN;
		STARTEND:
		/* END CYGNUS */
		return pop_msg(p,POP_FAILURE,
		     "[IN-USE] %s lock busy!  Is another session active? (%d)",
							p->temp_drop, errno);
	    default:
		close(dfd);
		return pop_msg(p,POP_FAILURE,"flock: '%s': %s (%d)",
			       p->temp_drop, (errno < sys_nerr) ? 
			       sys_errlist[errno] : "", errno);
	}
    }
    
#ifndef KEEP_TEMP_DROP
    /* check for race conditions involving unlink.  See pop_updt.c */
    /* s-dorner at uiuc dot edu, 12/91 */
    {
      struct stat byName, byFd;
      if (stat(p->temp_drop, &byName) || fstat(dfd, &byFd) ||
	  byName.st_ino != mybuf.st_ino)
      {
        return pop_msg(p,POP_FAILURE,
		"Maildrop being unlocked; try again.");
      }
    }
#endif
    
    /*  Acquire a stream pointer for the temporary maildrop */
    if ( (p->drop = fdopen(dfd,"r+")) == NULL ) {
        (void)close(dfd) ;
        return pop_msg(p,POP_FAILURE,"Cannot assign stream for %s (%d)",
		       p->temp_drop, errno);
    }
    /*  Allocate memory for message information structures and this is
     *  is not deleted since a failure, for some reason in this function
     *  would result in process death. */
    p->mlp = (MsgInfoList *)calloc((unsigned)ALLOC_MSGS,sizeof(MsgInfoList));
    if (p->mlp == NULL){
        return pop_msg (p,POP_FAILURE,
            "Can't allocate memory for message list.");
    }
    p->msg_count = 0;
    p->drop_size = 0;

    if (mybuf.st_size != 0) { /* Mostly this is for regular mode. */
	if (init_dropinfo(p) != POP_SUCCESS) {
	    /* Occurs on temp_drop corruption */
	    flock(dfd, LOCK_UN);
	    close(dfd);
	    return(POP_FAILURE);
	}
	/* Sync with stdio; should be at end anyway */
	(void)fseek(p->drop, 0L, SEEK_END);
	offset = ftell(p->drop);
    }

#ifdef MAILOCK
    /* SYSV locking for users mailbox.*/
    if (maillock(p->user,1) != 0)
            return pop_msg(p,POP_FAILURE, "maillock: '%s'", p->temp_drop);
#endif

    /*  Open the user's maildrop, If this fails,  no harm in assuming empty */
    /* <todo> Mail drop has to be created if one doesn't exist for server_mode.
     * Because p->drop is used for bulletins. Right now it reverts back to 
     * regular mode if drop box open fails. </todo>
     */
    if ((mfd = open(p->drop_name, O_RDWR)) > 0) {
        /* Lock the maildrop */
        if (flock (mfd,LOCK_EX) == -1) {
            (void)close(mfd) ;
	    MAILUNLOCK();
            return pop_msg(p,POP_FAILURE, "flock: '%s': %s (%d)", p->drop_name,
			   (errno < sys_nerr) ? sys_errlist[errno] : "", errno);
        }

	if (!p->server_mode) {
	    /* New routine to copy and get dropbox info all at the same time */
	    nchar = do_drop_copy(p, mfd, dfd);

	    if ( nchar != POP_SUCCESS ) {
		/* pop_dropcopy has integrated the info gathering pass into
		   the copy pass so now the information of the dropfile is
		   inconsistent if there is an error.  Now we exit instead
		   of trying to continue with what is available.
		*/
		(void)ftruncate(dfd, (OFF_T)offset) ;
		goto bailout;
	    } 
	    else {
		/* Mail transferred!  Zero the mail drop NOW,  that we
		   do not have to do gymnastics to figure out what's new
		   and what is old later */
		(void)ftruncate(mfd, (OFF_T)0) ;
	    }

	    /* Unlock and close the actual mail drop */
	    flock(mfd, LOCK_UN);
	    (void)close (mfd);
	} 
	else { /* SERVER_MODE */
	    /* Save the temporary drop FILE and fid values */
	    p->hold = p->drop;
	    if ((p->drop = fdopen(mfd,"r+")) == NULL) {
		pop_msg(p,POP_FAILURE,"Cannot assign stream for %s (%d)",
			p->drop_name, errno);
		goto bailout;
	    }
	    if (init_dropinfo(p) != POP_SUCCESS)
		goto bailout;
	}
    }
    else {
	/* Revert to regular operation when there are no mails in
	 * users mail box. This is for the sake of any bulletins, 
	 * which uses p->drop (temp_drop) and to allow pop_updt to
	 * copy back to original mail box.*/
	if(p->server_mode) {
	    p->server_mode = 0; 
	}
    }

    if (p->bulldir) {
	/* Recalculate offset */
	(void)fseek(p->drop, 0L, SEEK_END);
	offset = ftell(p->drop);
	/* In Server_mode, p->drop can be 
	 * null(no mails), pop_bull requires a drop handle. </bug> */
	if(pop_bull(p, pwp) != POP_SUCCESS){
	    /* Return pop drop back to what it was before the bulletins */
	    (void)ftruncate(p->server_mode ? 
			    ((mfd == -1)?dfd:mfd):dfd, (OFF_T)offset);
	}
    }
#ifdef BULLDB
#ifdef GDBM
    gdbm_close(p->bull_db);
#else
    dbm_close(p->bull_db);
#endif
#endif

    (void)fseek(p->drop, 0L, SEEK_END);
    p->spool_end = ftell(p->drop);

#ifdef DEBUG
    if(p->debug && p->msg_count > 0) {
        register    i;
	MsgInfoList *mp;                    
        for (i = 0, mp = p->mlp; i < p->msg_count; i++, mp++)
            pop_log(p,POP_DEBUG,
	    "Msg %d uidl %s at offset %d is %d octets long and has %u lines.",
		    mp->number,mp->uidl_str,mp->offset,mp->length,mp->lines);
    }
#endif
    MAILUNLOCK();

    if (p->server_mode)
        flock(mfd, LOCK_UN);

    return(POP_SUCCESS);

 bailout:
    MAILUNLOCK();
    flock(mfd, LOCK_UN);
    flock(dfd, LOCK_UN);
    close(mfd);
    close(dfd);
    return(POP_FAILURE);
}

/*
 * This function emulates fgets() except that it replaces the NULLs with
 * SPACEs
 */

char *
mfgets( s, size, stream )
char *s;
int size;
FILE *stream;
{
    int c;
    char *p = s;
    if( size <= 0 ) {
	return NULL;
    }
    while( --size && ((c = getc(stream)) != EOF) ) {
	if( (*p = (char)c) == '\0' ) *p = ' ';
	if( *p++ == '\n' ) break;
    }
    if( p == s ) return NULL;
    *p = '\0';
    return s;
}

/* START CYGNUS */

void clear_old(POP *p)
{
int psfound=0;
char psline[257];
char pspid_str[10];
pid_t pspid=-1;
FILE *pp;

psline[0]=0;
pspid_str[0]=0;
pp=popen(PS_COMMAND,"r");
while (fgets(psline,256,pp) != NULL) {
	if (strstr(psline,PS_SEARCH)) {
		remove_first(psline);
		sscanf(psline,"%s ",pspid_str);
		pspid=(pid_t)atoi(pspid_str); 
		if (getpid()==pspid) {
			psline[0]=0;
			pspid_str[0]=0;
			continue;
		  }
		psfound=1;
		break;
	}
 } /* end of while */
pclose(pp);
if (psfound==1) {
 /* send SIGTERM */
 pop_log(p,POP_PRIORITY,"Got pid %s for user %s",pspid_str,p->user);
 if (kill(pspid,15) < 0) {
  pop_log(p,POP_PRIORITY,"FAILED sending TERM signal to popper process %u for %s (%s)",(unsigned int)pspid,p->user,strerror(errno));
 }
 else {
  pop_log(p,POP_PRIORITY,"Sent TERM signal to popper process %u for %s",(unsigned int)pspid,p->user);
  sleep(2);
  }
 } /* end of if psfound */
else {
 pop_log(p,POP_PRIORITY,"No open popper process found for %s",p->user);
 }

}


/*** removes first word at front of string and moves rest down ***/
remove_first(inpstr)
char *inpstr;
{
int newpos,oldpos;

newpos=0;  oldpos=0;
/* find first word */
while(inpstr[oldpos]==' ') {
        if (!inpstr[oldpos]) { inpstr[0]=0;  return; }
        oldpos++;
        }
/* find end of first word */
while(inpstr[oldpos]!=' ') {
        if (!inpstr[oldpos]) { inpstr[0]=0;  return; }
        oldpos++;
        }
/* find second word */
while(inpstr[oldpos]==' ') {
        if (!inpstr[oldpos]) { inpstr[0]=0;  return; }
        oldpos++;
        }
while(inpstr[oldpos]!=0)
        inpstr[newpos++]=inpstr[oldpos++];
inpstr[newpos]='\0';
}

/* END CYGNUS */



Date: Sun, 19 Sep 1999 18:40:54
From: Jithender Tiwari <jtiwari at infotech.stph dot net>
Subject: Antivirus mail configuration

Hello all

I am facing some problem while installing the antivirus in our RH 5.0 mail
server. The mail software is qpopper 2.5. Hope I get some help becoz I got
information from here about the software and procedure.

My requirements are as follows:

1) I want to send an automatic reply to the sender about his infected mail
from where it has come.

2) An automatic message to my local Email user that the infected mail has
come and is sent back giving the senders email address to him.

3) Automatically clean the virus otherwise and inform  my local email user
who receives it that it was infected and is cleaned.

I have made a beginning and this is what I have done.

I installed sophos eval antivirus software. Thanks to the people who posted
the information here. While compiling it gave a warning that

"CCLIENT.TAR or iclient .tar does not exist in your install directory .
Files for Intercheck clients will not be installed"

But still I was able to scan using sweep the particular directories i
mentioned(ofcourse in mailserver). The command used is 
" sweep -c directoryname"

I then Installed AMaVis. It got compiled and I feel it has installed. But
for testing when I read the help it is written to make " eicar.com"
file,which is a test pattern that triggers the alert. So, I created in
windows this file and sent it as an email attachment to my email address. I
could download the mail without any problems. Can you please tell me how I
can check or is there any wrong thing I have done.

And when I downloaded sophos eval software the archive did not contain
CClient.TAR nor iclient.tar. 

Where can I find the file and how I can configure the above?

All suggestions are welcome.

Thanks in advance


Jithu

From: "James Hicks" <jlrh at lcc dot net>
Subject: Need Help With Install
Date: Sun, 19 Sep 1999 18:29:55 -0500

Hello,

This is my first time to ever install Qpopper 2.53.
I am installing it on FreeBSD ( latest stable )
I am kinda puzzled to how to setup individual mail boxes.

I have several domains on the webserver and want 2 or 3 email addresses
 webmaster & support ) for each domain( domain1.com and domain2.com)

Could someone point me to the right place to get this info.  I have been
searching all weekend and I finally came across the mailing list.  The
install notes didnt hit up on this topic and the search thru the engines
just throws me in circles.

All Help Is Appreciated
James Hicks


Date: Mon, 20 Sep 1999 12:35:10 +1200
From: Mark van Walraven <markv at wave.co dot nz>
Subject: Re: .user.pop lock busy! Is another session active?

On Sat, Sep 18, 1999 at 08:58:55PM +1200, Alan Brown wrote:
> On Fri, 17 Sep 1999, Marcelo dos S. Tavares wrote:
> 
> > Do you know another POP3 server with support hash spool, i.e., the mail
> > spool of
> > the user is located in /var/spool/mail/u/s/user.
> > Example: User peter -- /var/spool/mail/p/e/peter
> 
> Does anyone know how to make sendmail deliver to such mailboxes?
> 
> AB

Try procmail as your local delivery agent.  You need to re-compile
procmail with (I think) just a minor change to a header file.  I've done
this and it works very well.  I also hacked qpopper to merge mailboxes
in the old spool with boxes in the new layout, on the fly.

More recently, I switched to having procmail (vanilla, unmodified) deliver
into home directories (e.g., /home/f/r/fred/.mail).  This makes it easy
to add disks and move directories (e.g., /home1/s/t/stan) without having
to alter qpopper or fetchmail.

Either way, be careful that procmail and qpopper use the same locking
convention ...

Date: Mon, 20 Sep 1999 18:36:16 +1000
From: Wayne Heming <wheming at hemnet.com dot au>
Subject: Re: Need Help With Install

This should be the same on most UNIX, but this works on FreeBSD

This makes webmaster at primarydomain dot com, webmaster at domain1 dot com, 
webmaster at domain2.com, support@primarydomain dot com, support at domain1 dot com, 
support at domain2 dot com all equal to realname at primarydomain dot com


In
sendmail.cw file in /etc

primarydomain.com
domain1.com
domain2.com

then restart sendmail

then in aliases file /etc

webmaster:      realmailname
support:        realmailname

then run newaliases

all works for me.

wayne

At 06:29 PM 19-09-99 -0500, you wrote:
>Hello,
>
>This is my first time to ever install Qpopper 2.53.
>I am installing it on FreeBSD ( latest stable )
>I am kinda puzzled to how to setup individual mail boxes.
>
>I have several domains on the webserver and want 2 or 3 email addresses
>  webmaster & support ) for each domain( domain1.com and domain2.com)
>
>Could someone point me to the right place to get this info.  I have been
>searching all weekend and I finally came across the mailing list.  The
>install notes didnt hit up on this topic and the search thru the engines
>just throws me in circles.
>
>All Help Is Appreciated
>James Hicks



From: "M. Edward Wilborne III" <wilborne at gamewood dot net>
Subject: Re: Need Help With Install
Date: Mon, 20 Sep 1999 09:04:47 -0400

The way we do this has nothing to do with qpopper at all...

For example, lets say you have a domain called bristolnews.com, and one
called ci.danville.va.us and you want the same mail server to accept e-mail
to webmaster at bristolnews dot com and stick it in an e-mail box, and
webmaster at ci.danville.va dot us and stick it in a different e-mail box.

We modified /etc/sendmail.cf in rule:    SParse0

And added the following lines to the beginning of the rule BEFORE the
default rules that are there:

Rwebmaster < @ bristolnews . com . >    $#local $: bristol
Rpostmaster < @ bristolnews . com . >    $#local $: bristol
R$* < @ bristolnews . com . >    $#local $: $1
Rwebmaster < @ ci . danville . va . us . >    $#local $: $1
R$* < @ ci . danville . va . us . >    $#local $: $1

As you can see from the rules above, messages to webmaster at bristolnews dot com,
or postmaster at bristolnews dot com actually get put into the mail box "bristol",
which is the user name of the person responsible for e-mail for these
accounts.  Then anything else that gets sent to * at bristolnews dot com gets
delivered into the appropriate corresponding local mail box.  This rule may
be redundant but, we like it there so that we know what is going on.
(Please note you can't simply cut and paste those rules above...  there
should be a tab between the > chracter and the $...  The rest are separated
with spaces.)

I don't think aliases can help you with this situation because you can't
have webmaster at anydomain dot com going to one mail box while
webmaster at someotherdomain dot com goes to some other mail box on the same server
using just the aliases feature (hence our changes to the sendmail
configuration).

Of course, sendmail is complicated, and our solution to the problem may not
be the best, or necessarily correct, but it does seem to work.

Ed

----- Original Message -----
From: James Hicks <jlrh at lcc dot net>
To: Subscribers of Qpopper <qpopper at lists.pensive dot org>
Sent: Sunday, September 19, 1999 7:29 PM
Subject: Need Help With Install


> Hello,
>
> This is my first time to ever install Qpopper 2.53.
> I am installing it on FreeBSD ( latest stable )
> I am kinda puzzled to how to setup individual mail boxes.
>
> I have several domains on the webserver and want 2 or 3 email addresses
>  webmaster & support ) for each domain( domain1.com and domain2.com)
>
> Could someone point me to the right place to get this info.  I have been
> searching all weekend and I finally came across the mailing list.  The
> install notes didnt hit up on this topic and the search thru the engines
> just throws me in circles.
>
> All Help Is Appreciated
> James Hicks
>


Date: Tue, 21 Sep 1999 06:07:41 +1000
From: Wayne Heming <wheming at hemnet.com dot au>
Subject: Re: Need Help With Install

Re the statement.

I don't think aliases can help you with this situation because you can't
have webmaster at anydomain dot com going to one mail box while
webmaster at someotherdomain dot com goes to some other mail box on the same server
using just the aliases feature (hence our changes to the sendmail
configuration).

I have this working on FreeBSD 2.2.8 using the sendmail.cw file and aliases 
as per my previous email.
If you look in the sendmail.cf file for the sendmail.cw rule you will see

Cwlocalhost
# file containing names of hosts for which we receive email
Fw-o /etc/sendmail.cw

then the aliases just works on the username part of the email.

As I said I have it working.

wayne


At 09:04 AM 20-09-99 -0400, M. Edward Wilborne III wrote:
>The way we do this has nothing to do with qpopper at all...
>
>For example, lets say you have a domain called bristolnews.com, and one
>called ci.danville.va.us and you want the same mail server to accept e-mail
>to webmaster at bristolnews dot com and stick it in an e-mail box, and
>webmaster at ci.danville.va dot us and stick it in a different e-mail box.
>
>We modified /etc/sendmail.cf in rule:    SParse0
>
>And added the following lines to the beginning of the rule BEFORE the
>default rules that are there:
>
>Rwebmaster < @ bristolnews . com . >    $#local $: bristol
>Rpostmaster < @ bristolnews . com . >    $#local $: bristol
>R$* < @ bristolnews . com . >    $#local $: $1
>Rwebmaster < @ ci . danville . va . us . >    $#local $: $1
>R$* < @ ci . danville . va . us . >    $#local $: $1
>
>As you can see from the rules above, messages to webmaster at bristolnews dot com,
>or postmaster at bristolnews dot com actually get put into the mail box "bristol",
>which is the user name of the person responsible for e-mail for these
>accounts.  Then anything else that gets sent to * at bristolnews dot com gets
>delivered into the appropriate corresponding local mail box.  This rule may
>be redundant but, we like it there so that we know what is going on.
>(Please note you can't simply cut and paste those rules above...  there
>should be a tab between the > chracter and the $...  The rest are separated
>with spaces.)
>
>I don't think aliases can help you with this situation because you can't
>have webmaster at anydomain dot com going to one mail box while
>webmaster at someotherdomain dot com goes to some other mail box on the same server
>using just the aliases feature (hence our changes to the sendmail
>configuration).
>
>Of course, sendmail is complicated, and our solution to the problem may not
>be the best, or necessarily correct, but it does seem to work.
>
>Ed
>
>----- Original Message -----
>From: James Hicks <jlrh at lcc dot net>
>To: Subscribers of Qpopper <qpopper at lists.pensive dot org>
>Sent: Sunday, September 19, 1999 7:29 PM
>Subject: Need Help With Install
>
>
> > Hello,
> >
> > This is my first time to ever install Qpopper 2.53.
> > I am installing it on FreeBSD ( latest stable )
> > I am kinda puzzled to how to setup individual mail boxes.
> >
> > I have several domains on the webserver and want 2 or 3 email addresses
> >  webmaster & support ) for each domain( domain1.com and domain2.com)
> >
> > Could someone point me to the right place to get this info.  I have been
> > searching all weekend and I finally came across the mailing list.  The
> > install notes didnt hit up on this topic and the search thru the engines
> > just throws me in circles.
> >
> > All Help Is Appreciated
> > James Hicks
> >



Date: Mon, 20 Sep 1999 16:08:42 -0700
From: Randall Gellens <rg=public.1 at worldmail1.qualcomm dot com>
Subject: Re: Polling control

At 10:35 AM -0400 9/15/99, Michael D. Sofka wrote:

>Then, the parent can simply not process more than, say, one request
>per minute for any giver person, or no more than 1000 requests
>per day, or some other metric.   ... and popper can just
>silently lie about the results of excessive polls.  That is,
>if can just say ``you have zero new messages''' if the polling
>is excessive.  :-)

You can use the new CAPA response tags and error response codes to do 
more than just lie about this,

You can cause qpopper to report the minimum poll frequency through 
the CAPA tag LOGIN-DELAY by using the -e login_delay=nn command-line 
option.

If you patch qpopper to reject more frequent login attempts, you can 
use the [LOGIN_DELAY] error response code to let them know why.  Or, 
to rub it in, don't use any response code but use an -ERR response to 
the login.  That usually causes the client to put up a dialog asking 
for the password.


--
Randall Gellens
rg=public.1 at worldmail1.qualcomm dot com
Opinions are personal;     facts are suspect;     I speak for myself only

From: dandrews at mpiua dot com
Subject: Relaying
Date: Tue, 21 Sep 1999 10:37:51 -0400

Hello all,

Does anyone know where I might look to solve the problem of  a "Relaying
Denied" error when a mail client tries to send mail to my Linux machine?  My
hosts.allow file has an ALL: x.x.x.x  entry for my mail client.  Why is this
service being denied?

Any help appreciated.

David Andrews
dandrews at mpiua dot com


Date: Tue, 21 Sep 1999 11:23:04 -0400 (EDT)
From: Admin Mailing Lists <mlist at intergrafix dot net>
Subject: Re: Relaying

hosts.allow is just for accepting connections..relaying is a part of mail
after the connection is already established to port 25.
most likely you have to include your client's ips, line by line, in the
relaying allow file. On redhat i think it's /etc/mail/allow (I run 
caldera)
Then rebuild the allow db and restart sendmail.
See http://www.sendmail.org for specific instructions as I dont use the
default method for doing these things.

-Cygnus
.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-.
Anthony J. Biacco                       Network Administrator/Engineer
admin at intergrafix dot net                    Intergrafix Internet Services

    "Dream as if you'll live forever, live as if you'll die today"
http://cygnus.ncohafmuta.com                http://www.intergrafix.net
.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-._.-.

On Tue, 21 Sep 1999 dandrews at mpiua dot com wrote:

> Hello all,
> 
> Does anyone know where I might look to solve the problem of  a "Relaying
> Denied" error when a mail client tries to send mail to my Linux machine?  My
> hosts.allow file has an ALL: x.x.x.x  entry for my mail client.  Why is this
> service being denied?
> 
> Any help appreciated.
> 
> David Andrews
> dandrews at mpiua dot com
> 


Date: Tue, 21 Sep 1999 08:36:41 -0700
From: Rex Sanders <rex at octopus.wr.usgs dot gov>
Subject: Re: Relaying

You probably have a recent release of Sendmail, which has stronger default
anti-relay capabilities.

For more information, see:

  http://www.sendmail.org/tips/relaying.html

The simplest (not always best) solution is to enable key domains to relay
through your host by adding domain names to /etc/mail/relay-domains.

You *don't* want to enable the whole Internet to relay through your
machine.  That enables spammers to use your machine (CPU cycles &
bandwidth), and gets you a bad reputation -- which gets you added to
various black lists.

-- Rex

At 10:37 AM -0400 9/21/99, dandrews at mpiua dot com wrote:
>Hello all,
>
>Does anyone know where I might look to solve the problem of  a "Relaying
>Denied" error when a mail client tries to send mail to my Linux machine?  My
>hosts.allow file has an ALL: x.x.x.x  entry for my mail client.  Why is this
>service being denied?
>
>Any help appreciated.
>
>David Andrews
>dandrews at mpiua dot com




Date: Tue, 21 Sep 1999 15:11:26 -0500 (CDT)
From: Chimera <chimera at DarkMUX dot net>
Subject: Install problems.

Okay.  I am running RedHat 6.0, and am trying to install QPopper3.0
without any luck.  From the README and INSTALL files, I assume that all I
have to do is:

    ./configure [options]
    make

and everything will work like a dream.  You know.  Everything will be in
it's place, then I configure inetd.conf and services, and off we go.
Right?

Wrong. 

I do the above, then, out of curiousity why it wasn't working, tried:

   ls -la /usr/local/lib

the directory is empty.  Am I supposed to move things to where they are
supposed to be?  I -am- running this as root, so there shouldn't be any
permission issues.  

I need help.  Somebody?  Probably something simple, but I am too
frustrated after nuking things a few times and trying it over and over.  I
even tried using [./configure --prefix=/usr/local].  No go.


chimera at darkmux dot net


Date: Fri, 22 Sep 2000 09:49:37
From: Jithender Tiwari <jtiwari at infotech.stph dot net>
Subject: Re: Relaying

At 10:37 AM 09/21/1999 -0400, dandrews at mpiua dot com wrote:
>Hello all,
>
>Does anyone know where I might look to solve the problem of  a "Relaying
>Denied" error when a mail client tries to send mail to my Linux machine?  My
>hosts.allow file has an ALL: x.x.x.x  entry for my mail client.  Why is this
>service being denied?

Just go to /etc/mail. If the file ip_allow is there put all your mail Ips
in it. One IP in one line. If the file is not there create it manually. The
same you can do for relay_allow in the same directory. This should solve
your problem. Dont forget to reboot the system or restart sendmail again.

Cheers

Jithu





>
>Any help appreciated.
>
>David Andrews
>dandrews at mpiua dot com
>
>

Date: Wed, 22 Sep 1999 09:36:35 +0300
From: pestilence <pestilence at netplan dot gr>
Subject: Re: Relaying

1) Relaying has nothing to do with TCP wrappers.
2) Sendmail is a stand alone daemon (well it didn't used to be...but
that was a time long far away..in a galaxy far far away), so
tcp-wrappers are useless with it.
3) Relaying is all part of the files:
/etc/sendmail.cw or any other relay file that you might have included.


-- 
Kostas Petrakis aka Pestilence
Head admin of Netplan LTD.
http://www.netplan.gr
pestilence at netplan dot gr
=-=-=-=-=-=-=-=-=-=-=-=-=-=
Rewted Network Security Labs
http://www.rewted.org
pestilen at rewted dot org

Date: Wed, 22 Sep 1999 18:36:44 +1200 (NZST)
From: Alan Brown <alan at manawatu.gen dot nz>
Subject: Re: Relaying

On Wed, 22 Sep 1999, pestilence wrote:

> 2) Sendmail is a stand alone daemon (well it didn't used to be...but
> that was a time long far away..in a galaxy far far away), so
> tcp-wrappers are useless with it.

That depends whether you start it out of inetd (it's still capable of
this mode of operation) or compile with -DTCPWRAP flags.

AB




Date: Wed, 22 Sep 1999 10:03:10 +0300
From: pestilence <pestilence at netplan dot gr>
Subject: Re: Relaying

Yes but the usuall method is standalone.


-- 
Kostas Petrakis aka Pestilence
Head admin of Netplan LTD.
http://www.netplan.gr
pestilence at netplan dot gr
=-=-=-=-=-=-=-=-=-=-=-=-=-=
Rewted Network Security Labs
http://www.rewted.org
pestilen at rewted dot org

Date: Wed, 22 Sep 1999 18:52:05 +1200 (NZST)
From: Alan Brown <alan at manawatu.gen dot nz>
Subject: Re: Relaying

On Wed, 22 Sep 1999, pestilence wrote:

> Yes but the usuall method is standalone.

I run my sendmail standalone and still use hosts.allow/deny for real
problem sites, thanks to the -DTCPWRAP flag.

AB


Date: Wed, 22 Sep 1999 10:13:33 +0300
From: pestilence <pestilence at netplan dot gr>
Subject: Re: Relaying

You can always use a firewall which is much better than the use of
tcp-wrappers.
Anywayz hehe this list is not for the discussion of such things.

-- 
Kostas Petrakis aka Pestilence
Head admin of Netplan LTD.
http://www.netplan.gr
pestilence at netplan dot gr
=-=-=-=-=-=-=-=-=-=-=-=-=-=
Rewted Network Security Labs
http://www.rewted.org
pestilen at rewted dot org

Date: Wed, 22 Sep 1999 14:46:58 +0200 (CEST)
From: Bestia <root at linux.avcentrum.com dot pl>
Subject: Re: Install problems.

Just copy qpopper binary file to directory, which you have
in inetd.conf file. This shoud work fine.
Adam



Date: Wed, 22 Sep 1999 16:36:13 -0700 (PDT)
From: Edward Kaftan <kaftan at hermen.physiol.washington dot edu>
Subject: APOP problem

I recently installed qpopper 3.0b18 on a linux machine, slackware kernel
2.0. I am using Eudora (various versions) as a client. Regular user/pass
authorization works fine however APOP has problems. It appears that APOP
authorization is occuring correctly, just that the connection hangs or is
killed before mail is transferred. Below is an example of an exchange;

+OK QPOP (version 3.0b18) at machine.domain.com starting
<crypticnumbers at machine.domain dot com

APOP user crypticPW

+OK user has 1 message(s) (666 octets)

STAT
 a few small packets are passed back and forth here, the new freeware
version of Eudora will hang and time out, Eudora Pro 3.02 will send a QUIT
and give "Error reading from network  Cause:connection reset by remote
side (10054).
During this time the temp mailbox .user.pop is created but mail is not
transferred and so the temp mailbox remains.

As far as I can tell all permissions are properly set.
Any ideas?

-Ed Kaftan



Date: Thu, 23 Sep 1999 10:26:26 +1000
From: Jonathan Benson <sysadmin at ocean.com dot au>
Subject: Re: Install problems.

OK, go here:
http://www.ubiobio.cl/~gpoo/linux/

Grab the source RPM (SRPMS).

Install it.

Apply the patches.

Use:
./configure --prefix=/usr --enable-servermode --with-pam
(obviously servermode is optional)

Then copy the binary to /usr/sbin and configure inetd.conf.

Then do:
/etc/rc.d/init.d/inet reload

Worked for me.

Jon

Chimera wrote:

> Okay.  I am running RedHat 6.0, and am trying to install QPopper3.0
> without any luck.  From the README and INSTALL files, I assume that all I
> have to do is:
>
>     ./configure [options]
>     make
>
> and everything will work like a dream.  You know.  Everything will be in
> it's place, then I configure inetd.conf and services, and off we go.
> Right?
>
> Wrong.

--
Jonathan Benson
Systems Administrator
Ocean Internet
http://www.ocean.com.au/




Date: Thu, 23 Sep 1999 20:20:08 +0300
From: Clara Hatem <clara at inco.com dot lb>
Subject: limitation on the nbre of users ??

Hello,

I have a SUN Sparc server running Solaris 2.5.1 and QPOPPER version 2.53

The entry for QPOPPER on /etc/inetd.conf is the following:
pop3    stream  tcp     nowait  root    /usr/local/lib/popper   popper -s
-d -t /var/log/pop3.log -T 240


Lately, many customers have been complaining of timeouts when popping their
mail, The email client would stay "connecting to the POP server: or logging
into POP server" . cancelling the POP session and logging again usually
solves the problem.

I have today 28000 users on the POP server. Could this problem be caused by
a limitation on the number of 
users that can be handled by QPOPPER ??

In the QPOPPER log file there are many errors like follows:
Thu Sep 23 17:14:34 1999 [3974] (v2.53) Unable to get canonical name of
client, err = 0

Also in the system log (/var/adm/messages), errors that look like: 
Sep 23 14:40:58 nethopper inetd[157]: accept: Protocol error


anyone has ever faced this problem ? Any other idea of what could be
causing it ???


Thank you for your feedback
Clara Hatem.



     `\|||/            
      (@@)	
  ooO_(_)_Ooo________________________________
  _____|_____|_____|_____|_____|_____|_____|_____|
___|____|_____|_____|_____|_____|_____|_____|____
_____|_____|_____|_____Have a Nice Day __|__|____|

Clara Hatem
Network Administrator
Network Operation Center
IncoNet sal
Beirut - LEBANON

Phone (Home): 	 961 1  584913
Mobile:		 961 3  278216
Phone(Office):   961 1  255696 ext 707
Email: clara at inco.com dot lb
P.O.Box: 16-6928 Beirut - LEBANON
___|____|_____|_____|_____|_____|_____|_____|____|





From: dandrews at mpiua dot com
Subject: RE: limitation on the nbre of users ??
Date: Thu, 23 Sep 1999 13:51:05 -0400

>> Thu Sep 23 17:14:34 1999 [3974] (v2.53) Unable to get
>> canonical name of client, err = 0

Up front, I really have no idea what Im talking about, Im a Linux and
Qpopper newbie.  I did however have this exact error logging also.  I
believe it is a result of qpoppers unsuccessful attempt to obtain a the
clients name doing a DNS reverse look up of thier IP address.  because my
server was not on the Net and was for a small office, I solved it by adding
the IP address of my POP users in the /etc/hosts file.  Your problem may
have something to do with your DNS server.

I hope this babble has made you any dumber?  :)

David


Date: Thu, 23 Sep 1999 14:21:51 -0400 (EDT)
From: "Louis A. DeRobertis" <louis at suffolk.lib.ny dot us>
Subject: RE: limitation on the nbre of users ??

I have around 80,000 users on a machine running Solaris 2.6 x86 and it's
not an issue.

For the resolving canonical hostnames, check to make sure that there is an
/etc/resolv.conf file with the domain name and DNS servers, and that there
is an entry in /etc/nsswitch.conf that looks up hostnames via dns or
something like this:

hosts:	dns [NOTFOUND=return] files

I've found that qpopper runs much nicer when I've recompiled using
--enable servermode - but could just be my perception :)

Regards -

Lou


--------------------
Louis DeRobertis
Network Administrator
Suffolk Cooperative Library System


On Thu, 23 Sep 1999 dandrews at mpiua dot com wrote:

> >> Thu Sep 23 17:14:34 1999 [3974] (v2.53) Unable to get
> >> canonical name of client, err = 0
> 
> Up front, I really have no idea what Im talking about, Im a Linux and
> Qpopper newbie.  I did however have this exact error logging also.  I
> believe it is a result of qpoppers unsuccessful attempt to obtain a the
> clients name doing a DNS reverse look up of thier IP address.  because my
> server was not on the Net and was for a small office, I solved it by adding
> the IP address of my POP users in the /etc/hosts file.  Your problem may
> have something to do with your DNS server.
> 
> I hope this babble has made you any dumber?  :)
> 
> David
> 


Date: Thu, 23 Sep 1999 14:03:58 -0500 (CDT)
From:  <gavin at imagine.math.ou dot edu>
Subject: Qpopper 2.53

Hello,

I decided to try out the qpopper in order to use its APOP authentication.
I configured the server with the following:

./configure --enable-apop=/etc/pop.auth --with-popuid=pop

I set the correct permissions on /etc/pop.auth as instructed.
I also changed the owner of popauth and set the SUID bit as instructed.

However, when I try to set up a user I get the following error: 

Changing POP password for gavin.
New password:
Retype new password:
./popauth: /etc/pop.auth: unable to open POP authorization DB

apperently the call to gdbm_open() is failing. Any clues?

The system is running the slackware 4 linux distro.

-Gavin


Date: Fri, 24 Sep 1999 07:24:17 +0800
From: cache <cache at iname dot com>
Subject: What is the problem?

Hi!

I had install qpopper 2.53 in my RH linux 6 at localhost,but it
seems can not work well.

When I connect to the 110 port,

telnet localhost 110

Trying 127.0.0.1...
Connected to localhost.
Escape character is '^]'.
+OK QPOP (version 2.53) at localhost starting.
user root
+OK Password required for root.
pass testpass
-ERR Access is blocked for UIDs below 10
+OK Pop server at localhost signing off.

What is the problem?
Thank you for feedback.

Best regards,
 Cache                          mailto:cache at iname dot com



Date: Thu, 23 Sep 1999 16:50:35 -0700 (PDT)
From: "Jeremy C. Reed" <reed at wcug.wwu dot edu>
Subject: Re: What is the problem?

On Fri, 24 Sep 1999, cache wrote:
> -ERR Access is blocked for UIDs below 10
> +OK Pop server at localhost signing off.
> 
> What is the problem?

The problem was in your question!
Use a test user who has a larger UID. Usually these low UIDs are for
daemons, root etc.
(My linux adds normal users starting with UIDs of 1000.)

  Jeremy C. Reed
------------------------------------------------------------
                           http://www.reedmedia.net




Date: Fri, 24 Sep 1999 09:55:01 -0300 (EST)
From: Rodrigo Luiz Anami <rodrigoa at bestway.com dot br>
Subject: Re: What is the problem?

Users that have uid bellow 10, i. e., administrative users are not allowed
to connect on popper, for security reasons.

Regards, 

-------------------------------------------------------------------------
Rodrigo Luiz Anami                                rodrigoa at bestway.com dot br
Best Way Internet Provider                         Atendimento ao Cliente
http://www.bestway.com.br                       (019) 254.6263 (Campinas)
webmaster at bestway.com dot br                 0800.112262 (Outras Localidades)
-------------------------------------------------------------------------

On Fri, 24 Sep 1999, cache wrote:

> Hi!
> 
> I had install qpopper 2.53 in my RH linux 6 at localhost,but it
> seems can not work well.
> 
> When I connect to the 110 port,
> 
> telnet localhost 110
> 
> Trying 127.0.0.1...
> Connected to localhost.
> Escape character is '^]'.
> +OK QPOP (version 2.53) at localhost starting.
> user root
> +OK Password required for root.
> pass testpass
> -ERR Access is blocked for UIDs below 10
> +OK Pop server at localhost signing off.
> 
> What is the problem?
> Thank you for feedback.
> 
> Best regards,
>  Cache                          mailto:cache at iname dot com
> 
> 


Date: Fri, 24 Sep 1999 10:51:13 -0300
From: Eduardo Marcel Macan <macan at colband.com dot br>
Subject: Bulletins

	Hello All, I needed to implement bulletins on my site, but we do
not have a home directory for each user, so I have modified pop_bull.c
in qpopper 2.53 to use BULLDIR/counters/popbull-username to store the 
counters (formerly ~/.popbull). I think it may be useful for others too.
Whom should I contact to suggest these modifications?

	Thank you.

--
Eduardo Marcel Macan.
macan at debian dot org
macan at thecore.com dot br
macan at colband.com dot br

Date: Fri, 24 Sep 1999 16:31:03 +0200 (CEST)
From: Mikolaj Rydzewski <miki at ceti.com dot pl>
Subject: Re: Bulletins

On Fri, 24 Sep 1999, Eduardo Marcel Macan wrote:

> 	Hello All, I needed to implement bulletins on my site, but we do
> not have a home directory for each user, so I have modified pop_bull.c
> in qpopper 2.53 to use BULLDIR/counters/popbull-username to store the 
> counters (formerly ~/.popbull). I think it may be useful for others too.

Well, I'm thinking about something different. I'd like to have several
bull directories per different user groups. For example different
bulletins for staff and students. Have you heard about such a patch? I
don't know if I have to write by my own :)

-- 
Mikolaj Rydzewski    <miki at ceti.com.pl>   http://www.ceti.com dot pl/~miki/
                       ICQ  #14597472         PGP KeyID: e17c4bd5
There are three kinds of people: men, women, and unix.


Date: Fri, 24 Sep 1999 08:39:51 -0700
From: Rob Imerson <rob at masktech.nsc dot com>
Subject: Solaris 2.7 Compile Problem

I'm trying to get my Sun Ultra5 with Solaris 2.7 set up. Most things
seemed to be coming together nicely until I tried to create a new
qpopper. I'm currently running qpopper2.2 on an Ultra 5 with Solaris
2.6.

I haven't been able to get qpopper2.52 to compile.

Below are the messages I get when I do "make".
I assume I edit the "Makefile" but I'm hardly an expert.

Maybe my gnu stuff is old. I see a directory in /usr/local/gnu called
sparc-sun-solaris2.5.

Any suggestions would be appreciated.

Thanks,
Rob

scmmj5# make
gcc -c -I. -I. -g -O2 -fstrength-reduce -fpcc-struct-return
-DHAVE_CONFIG_H -DSO
LARIS2 -DAUTH_SPECIAL -DGNU_PASS -DNO_GETLINE -DCONTENT_LENGTH=1 flock.c
-o floc
k.o
In file included from
/usr/local/gnu/lib/gcc-lib/sparc-sun-solaris/2.7.2/include
/time.h:90,
                 from /usr/include/sys/time.h:405,
                 from /usr/include/sys/select.h:17,
                 from
/usr/local/gnu/lib/gcc-lib/sparc-sun-solaris/2.7.2/include
/sys/types.h:278,
                 from
/usr/local/gnu/lib/gcc-lib/sparc-sun-solaris/2.7.2/include
/unistd.h:15,
                 from flock.c:28:
/usr/include/sys/siginfo.h:74: parse error before `pthread_attr_t'
/usr/include/sys/siginfo.h:74: warning: no semicolon at end of struct or
union
/usr/include/sys/siginfo.h:76: parse error before `}'
*** Error code 1
make: Fatal error: Command failed for target `flock.o'
scmmj5#


-- 
Rob Imerson National Semiconductor Mask Technology Group 408-721-6727
NSC internal - http://www-mask.nsc.com/ 
Personal - http://home.pacbell.net/rimerson/
Windows NT - Resistance is futile. Prepare for reboot.  8-\

Date: Fri, 24 Sep 1999 09:26:45 -0700
From: Listmaster <listmaster at lists.pensive dot org>
Subject: RE: .user.pop lock busy! Is another session active?

At 1:56 PM -0400 9/17/99, Admin Mailing Lists wrote:

>the attached text file

Please don't send large files to a mailing list.  If you want to make 
a patch or patched file available, either post it on a web or FTP 
server, or mail it to people on request,

There are a *lot* of people on this mailing list, and not every one 
of them wants this file.  It also bloats the archives, especially 
when the file is sent more than once (as in this case).

I've avoided setting restrictions in the list software, because there 
may be times when it is helpful to illustrate a point by sending a 
very small text file (for example, 10 or 12 lines from a log), and 
I'd like to believe that people are reasonable and use common sense.

Date: Fri, 24 Sep 1999 19:01:59 +0200
From: =?iso-8859-1?Q?Buzón?= auxiliar <aux at aitemin dot es>
Subject: Re: Qpopper 2.53

Hello Gavin,

I had exactly the same problem with Red Hat 5.2, and tried everything I
could think of, without any success. Then I decided to give Qpopper
3.0b18 a chance, and, to my surprise, it worked! I could add users to
the popauth database, and APOP worked flawlessly (at least with Eudora
Light 3.0.5 clients).

My only concern is that once you add a pop user to the popauth database,
you _have_ to use APOP from any mail client accessing that mailbox.
E-mail clients without APOP capabilities can no longer be used to read
the mail.

Juan Carlos

gavin at imagine.math.ou dot edu wrote:
> 
> Hello,
> 
> I decided to try out the qpopper in order to use its APOP authentication.
> I configured the server with the following:
> 
> ./configure --enable-apop=/etc/pop.auth --with-popuid=pop
> 
> I set the correct permissions on /etc/pop.auth as instructed.
> I also changed the owner of popauth and set the SUID bit as instructed.
> 
> However, when I try to set up a user I get the following error:
> 
> Changing POP password for gavin.
> New password:
> Retype new password:
> ./popauth: /etc/pop.auth: unable to open POP authorization DB
> 
> apperently the call to gdbm_open() is failing. Any clues?
> 
> The system is running the slackware 4 linux distro.
> 
> -Gavin

Date: Fri, 24 Sep 1999 19:32:49 +0100
From: Fergal Daly <fergal at esatclear dot ie>
Subject: Re: Bulletins

At 16:31 24/09/99 +0200, Mikolaj Rydzewski wrote:
>On Fri, 24 Sep 1999, Eduardo Marcel Macan wrote:
>
>> 	Hello All, I needed to implement bulletins on my site, but we do
>> not have a home directory for each user, so I have modified pop_bull.c
>> in qpopper 2.53 to use BULLDIR/counters/popbull-username to store the 
>> counters (formerly ~/.popbull). I think it may be useful for others too.
>
>Well, I'm thinking about something different. I'd like to have several
>bull directories per different user groups. For example different
>bulletins for staff and students. Have you heard about such a patch? I
>don't know if I have to write by my own :)

Have a look at http://www.esatclear.ie/~fergal/qpopper/ for a patch that
allows you to do this sort of thing. Basically it calls a program before it
tries to deliver a bulletin if the program exits with return code 0 then
the bulletin is delivered otherwise it's not. You just have to apply the
patch and configure with

--enable-wantsbull=/where/is/the/program

The way I use the patch is that I name the bulletins according to their
type eg 0001.newsletter.1-Sep or
0002.announce.2-Sep the program is passed the username and the name of the
bulletin (in that order). It uses these to decide what to do (it actually
checks for a file in the homedir of the user but you can have it make it's
decision any way you want),

Fergal



Date: Fri, 24 Sep 1999 13:53:25 -0700
From: Rob Imerson <rob at masktech.nsc dot com>
Subject: Solaris Compile Problem

I attempted to compile qpopper2.53 on a different computer with Solaris
2.6.

I got these messages -

OLARIS2 -DAUTH_SPECIAL -DGNU_PASS -DNO_GETLINE -DCONTENT_LENGTH=1
pop_get_subcommand.c -o pop_get_subcommand.o
gcc -c -I. -I. -g -O2 -fstrength-reduce -fpcc-struct-return 
-DHAVE_CONFIG_H-D
SOLARIS2 -DAUTH_SPECIAL -DGNU_PASS -DNO_GETLINE -DCONTENT_LENGTH=1
pop_init.c -o pop_init.o
In file included from pop_init.c:25:
/usr/include/arpa/inet.h:46: warning: `struct in_addr' declared inside
parameter
 list
/usr/include/arpa/inet.h:46: warning: its scope is only this definition
or
decla
ration,
/usr/include/arpa/inet.h:46: warning: which is probably not what you
want.
/usr/include/arpa/inet.h:46: warning: parameter has incomplete type
/usr/include/arpa/inet.h:49: warning: parameter has incomplete type
/usr/include/arpa/inet.h:50: warning: parameter has incomplete type
pop_init.c: In function `pop_init':
pop_init.c:129: storage size of `cs' isn't known
pop_init.c:275: type of formal parameter 1 is incomplete
make: *** [pop_init.o] Error 1

Any suggestions? Isn't this stuff just supposed to compile and run
without having to hack with the code?

Thanks,
Rob

-- 
Rob Imerson National Semiconductor Mask Technology Group 408-721-6727
NSC internal - http://www-mask.nsc.com/ 
Personal - http://home.pacbell.net/rimerson/
Windows NT - Resistance is futile. Prepare for reboot.  8-\

From: "Franco Catena" <catena at langnet.com dot br>
Subject: Radius
Date: Fri, 24 Sep 1999 17:12:03 -0300

Hi,

Do you know if Qpoppoer can auth users from Radius server???? If not have
somebody some idea about how to do this???


From: "James Nelson" <james at digit.bloomnet dot com>
Subject: Re: Bulletins
Date: Fri, 24 Sep 1999 19:09:47 -0500

If there is such a patch or if you write such a patch let us know-- we
are VERY interested in this.

Thanks.

--James
-----Original Message-----
From: Mikolaj Rydzewski <miki at ceti.com dot pl>
To: Subscribers of Qpopper <qpopper at lists.pensive dot org>
Date: Friday, September 24, 1999 9:29 AM
Subject: Re: Bulletins


|On Fri, 24 Sep 1999, Eduardo Marcel Macan wrote:
|
|> Hello All, I needed to implement bulletins on my site, but we do
|> not have a home directory for each user, so I have modified
pop_bull.c
|> in qpopper 2.53 to use BULLDIR/counters/popbull-username to store
the
|> counters (formerly ~/.popbull). I think it may be useful for others
too.
|
|Well, I'm thinking about something different. I'd like to have
several
|bull directories per different user groups. For example different
|bulletins for staff and students. Have you heard about such a patch?
I
|don't know if I have to write by my own :)
|
|--
|Mikolaj Rydzewski    <miki at ceti.com dot pl>
http://www.ceti.com.pl/~miki/
|                       ICQ  #14597472         PGP KeyID: e17c4bd5
|There are three kinds of people: men, women, and unix.
|


Date: Fri, 24 Sep 1999 20:19:33 -0400 (EDT)
From: Eric Jacobs <ejacobs at inotech dot com>
Subject: Proper Popper Performance

Say THAT three times fast ...

We seem to be getting bogged down by the popper process.  We have a fair 
number of pop3 clients configured to grab email and leave a copy on our
HPUX server (D3xx, HPUX 10.20), thus creating fair sized (5 - 30+ Mb) 
mail directories.  It seems that when a client is retrieving its email 
and it kicks-off the popper process, popper seems to take a long time and 
a good chunk of CPU to go through the mail on the server to figure out 
what to send to the client.  Worse than that, it also creates a lock file 
while it's working to prevent new emails from slipping in while it's working.

The combination of lock files and length of time popper(s) is/are running 
then causes email to bounce back with a directory locked message.

Any ideas/experience ?

TIA

Eric Jacobs
ejacobs at inotech dot com




Date: Fri, 24 Sep 1999 20:19:33 -0400 (EDT)
From: Eric Jacobs <ejacobs at inotech dot com>
Subject: Proper Popper Performance

Say THAT three times fast ...

We seem to be getting bogged down by the popper process.  We have a fair 
number of pop3 clients configured to grab email and leave a copy on our
HPUX server (D3xx, HPUX 10.20), thus creating fair sized (5 - 30+ Mb) 
mail directories.  It seems that when a client is retrieving its email 
and it kicks-off the popper process, popper seems to take a long time and 
a good chunk of CPU to go through the mail on the server to figure out 
what to send to the client.  Worse than that, it also creates a lock file 
while it's working to prevent new emails from slipping in while it's working.

The combination of lock files and length of time popper(s) is/are running 
then causes email to bounce back with a directory locked message.

Any ideas/experience ?

TIA

Eric Jacobs
ejacobs at inotech dot com




From: rlau2 at csc dot com
Date: Sun, 26 Sep 1999 09:31:18 +0930
Subject: Resent: Qpopper3.0 Question



I'm new to the mail-list. I suspect the mail I've just sent did not get through,
so here is the re-send.
===========================
Hi,

I've downloaded the lastest release of qpopper, I created the Makefile and
compiled successfully by following the instructions included in the distribution
directories.

However, there is nowhere in the documentation mentioned how to intall the
executable and man-pages. I inspect the
Makefile in all directories, there is no target for me to do a "make install" or
similar.

1.   Can you point me some directions on how to do a INSTALL after configure and
compile successfully.

2.   We are using NIS on a Sun environment, how will I be able to integrate
(passwd map) in NIS instead of /etc/passwd file for pop3 user authetication.

Many thanks in advance.

Regards,
Raymond Lau
__________________________________________________
CSC
Module 2, Endeavour House, Fourth Avenue, Technology Park, Mawson Lakes, SA 5095
Email: rlau2 at csc.com dot au



From: rlau2 at csc dot com
Date: Sun, 26 Sep 1999 09:26:57 +0930
Subject: Qpopper3.0 Question

Hi all,

I've downloaded the lastest release of qpopper, I created the Makefile and
compiled successfully by following the instructions included in the distribution
directories.

However, there is nowhere in the documentation mentioned how to intall the
executable and man-pages. I inspect the
Makefile in all directories, there is no target for me to do a "make install" or
similar.

1.   Can you point me some directions on how to do a INSTALL after configure and
compile successfully.

2.   We are using NIS on a Sun environment, how will I be able to integrate
(passwd map) in NIS instead of /etc/passwd file for pop3 user authetication.

Many thanks in advance.
Raymond Lau

CSC
Module 2, Endeavour House, Fourth Avenue, Technology Park, Mawson Lakes, SA 5095
Email: rlau2 at csc.com dot au



Date: Mon, 27 Sep 1999 08:56:53 +0800
From: cache <cache at iname dot com>
Subject: Qpopper 2.53 and RH 6.0

Hi!

Qpopper 2.53 can not run in RH6.0 ?

When I telnet localhost 110
user test1
pass test1234
qpopper told me the passwd was not correct! But test1234 is user
test1(uid 501)'s login passwd. And I did not use apop mode.

Why?

In my system, the passwd use shadow file, can it be the reason?

Thanks in advance.

Best regards,
 Cache                            mailto:cache at iname dot com