[vchkpw] vchkpw works manually but not from vpopmail-authlib

2006-11-30 Thread Michael Richardson

Hello Peeps,

I thought I might drop in and bug you with a problem.  I recently upgraded
my linux packages (including mysql) and now my qmail/vpopmail/imap-courier
setup has stopped working.

When I check my mail, the email client reports Login Failed.  The server
reports:
-
Dec  2 14:13:56 mydomain pop3d-ssl: Connection, ip=[:::71.92.162.12]
Dec  2 14:13:59 mydomain pop3d-ssl: LOGIN FAILED, user=
[EMAIL PROTECTED], ip=[:::71.92.162.12]
Dec  2 14:13:59 mydomain authdaemond: received auth request, service=pop3,
authtype=login
Dec  2 14:13:59 mydomain authdaemond: authvchkpw: trying this module
Dec  2 14:13:59 mydomain authdaemond: vchkpw: user does not exist
Dec  2 14:13:59 mydomain authdaemond: authvchkpw: REJECT - try next module
Dec  2 14:13:59 mydomain authdaemond: FAIL, all modules rejected
-

However, if I run vchkpw manually, it works great:
-
mydomain new # printf [EMAIL PROTECTED] | vchkpw
`which id` 30
uid=89(vpopmail) gid=89(vpopmail)
groups=0(root),1(bin),2(daemon),3(sys),4(adm),6(disk),10(wheel),11(floppy),20(dialout),26(tape),27(video)

-

And the log reports:
-
Dec  2 15:48:14 mydomain vpopmail[5818]: vchkpw-pop3: (PLAIN) login success
[EMAIL PROTECTED]
-

Additionally, email is going into the account fine.  I just can't check it :
(

I have posted exhaustive details about the config files and system info, if
you are interested:  http://forums.gentoo.org/viewtopic-t-520747.html

Any thoughts on how I might troubleshoot this?  Two days of google, forums,
upgrades and tweaking config vars have not produced a single clue or change
in the behavior.

Thanks, in advance.


Re: [vchkpw] vchkpw works manually but not from vpopmail-authlib

2006-11-30 Thread John Simpson

On 2006-11-30, at 1639, Michael Richardson wrote:


I thought I might drop in and bug you with a problem.  I recently  
upgraded
my linux packages (including mysql) and now my qmail/vpopmail/imap- 
courier

setup has stopped working.

When I check my mail, the email client reports Login Failed.  The  
server

reports:
-
Dec  2 14:13:56 mydomain pop3d-ssl: Connection, ip=[::: 
71.92.162.12]

Dec  2 14:13:59 mydomain pop3d-ssl: LOGIN FAILED, user=
[EMAIL PROTECTED], ip=[:::71.92.162.12]
Dec  2 14:13:59 mydomain authdaemond: received auth request,  
service=pop3,

authtype=login
Dec  2 14:13:59 mydomain authdaemond: authvchkpw: trying this module
Dec  2 14:13:59 mydomain authdaemond: vchkpw: user does not exist
Dec  2 14:13:59 mydomain authdaemond: authvchkpw: REJECT - try next  
module

Dec  2 14:13:59 mydomain authdaemond: FAIL, all modules rejected
-


what userid is authdaemond running as?

does this userid have read access to ~vpopmail/domains/*/vpasswd.cdb ?

if it can't read the files, then EVERYTHING will



However, if I run vchkpw manually, it works great:


that's nice, but it has nothing to do with the problem at hand.

authdaemond doesn't work by running vchkpw. when you compile courier- 
authlib, it uses the vpopmail headers and libraries, and in fact  
calls the same internal functions that vchkpw does (i.e. vauth_getpw 
() and friends) which means that those functions are running, and the  
files they read are accessed, as whatever userid that authdaemond  
itself is running as.


and if authdaemond isn't running as either root or the vpopmail user,  
this is what happens.


when i first ran into this, i wanted to fix authdaemond so that it  
has different error messages for unable to access the vpasswd.cdb  
file and userid does not exist.


however, the vauth_getpw() function isn't written with a way for the  
caller to tell the difference. the way it was written, if the userid  
is found, it returns a pointer to their information in memory.  
otherwise (and this word otherwise is a very big term- it could  
mean user not found, it could mean file not found, it could mean  
can't read the file because the permissions are wrong, it could  
mean the file is corrupt, it could mean low-level disk I/O  
error...) it returns a NULL pointer (i.e. the number zero.)


this isn't something which can be fixed with a quick patch- it's a  
fundamental error in how the vpopmail API was originally designed.  
it's something that people (myself included) have been dealing with  
for several years. if somebody seriously wanted to fix it, they would  
basically have to start over and write a new generation of vpopmail  
from scratch... certainly a bigger project than i want to tackle on  
my own.


--
| John M. Simpson - KG4ZOW - Programmer At Large |
| http://www.jms1.net/   [EMAIL PROTECTED] |
--
| Mac OS X proves that it's easier to make UNIX  |
| pretty than it is to make Windows secure.  |
--




PGP.sig
Description: This is a digitally signed message part


Re: [vchkpw] vchkpw works manually but not from vpopmail-authlib

2006-11-30 Thread Tom Collins

On Nov 30, 2006, at 1:39 PM, Michael Richardson wrote:

However, if I run vchkpw manually, it works great:


vpopmail-authlib from Courier-IMAP doesn't actually run the vchkpw  
program.


Make sure you compiled authlib AFTER compiling and installing vpopmail.

If you changed anything in your vpopmail config, you need to  
recompile and reinstall authlib.


--
Tom Collins  -  [EMAIL PROTECTED]
Vpopmail - virtual domains for qmail: http://vpopmail.sf.net/
QmailAdmin - web interface for Vpopmail: http://qmailadmin.sf.net/




Re: [vchkpw] vchkpw works manually but not from vpopmail-authlib

2006-11-30 Thread Rick Macdougall

Tom Collins wrote:

On Nov 30, 2006, at 1:39 PM, Michael Richardson wrote:

However, if I run vchkpw manually, it works great:


vpopmail-authlib from Courier-IMAP doesn't actually run the vchkpw program.

Make sure you compiled authlib AFTER compiling and installing vpopmail.

If you changed anything in your vpopmail config, you need to recompile 
and reinstall authlib.




Or courier-imap if you are running an older version.

Off Topic:  Tom: Did that qmail patch for simscan work for you when your 
server gets overloaded (regarding duplicate messages when simscan takes 
to long to get back to the remote server and the remote server times out ?)


Regards,

Rick



[vchkpw] qmail-ext doesn't work

2006-11-30 Thread Zeno

Hi list,
I am wondering if there is anything wrong with my setting.
I use netqmail-1.0.5, chkuser-2.0.8b,
netqmail-1.05-tls-smtpauth-20060105.patch and 
vpopmail-5.4.12 with MySQL

4.0.24-10sarge auth backend in Debian Sarge 3.1r3 AMD64.
I compiled vpopmail with:
./configure --enable-roaming-users --enable-logging=p 
--disable-ip-alias-domains --disable-passwd
--disable-clear-passwd --disable-domain-quotas 
--enable-auth-module=mysql --disable-many-domains
--enable-auth-logging --enable-sql-logging --enable-valias 
--disable-mysql-limits --enable-libdir=/usr/include/mysql

--enable-qmail-ext=y

I unremark these settings in my chkuser_settings.h:
#define CHKUSER_ENABLE_ALIAS_DEFAULT
#define CHKUSER_ENABLE_USERS_EXTENSIONS
and recompile netqmail.

I make extension address for (example) user dave in
~vpopmail/domains/mydomain.com/dave/.qmail-try, just to 
try my ext address

work:
| forward [EMAIL PROTECTED]
and change the file owner to vpopmail:vchkpw.

But when I try to send an email to [EMAIL PROTECTED], 
it doesn't work like
I hope. It doesn't forward the email to me (not read 
.qmail-extaddr?), but

still deliver to dave (still read .qmail-default?).

Any ideas?

Regards
Zeno

Selamat bagi para pemenang Grand Prize Netkuis Ramadhan 1427 H
 


Re: [vchkpw] qmail-ext doesn't work

2006-11-30 Thread Remo Mattei
check the toaster from Bill
shupp.org it will give you the step by step setup for your settings..
just my 2 cents,
Remo

Zeno wrote:
 Hi list,
 I am wondering if there is anything wrong with my setting.
 I use netqmail-1.0.5, chkuser-2.0.8b,
 netqmail-1.05-tls-smtpauth-20060105.patch and vpopmail-5.4.12 with MySQL
 4.0.24-10sarge auth backend in Debian Sarge 3.1r3 AMD64.
 I compiled vpopmail with:
 ./configure --enable-roaming-users --enable-logging=p
 --disable-ip-alias-domains --disable-passwd
 --disable-clear-passwd --disable-domain-quotas
 --enable-auth-module=mysql --disable-many-domains
 --enable-auth-logging --enable-sql-logging --enable-valias
 --disable-mysql-limits --enable-libdir=/usr/include/mysql
 --enable-qmail-ext=y
 
 I unremark these settings in my chkuser_settings.h:
 #define CHKUSER_ENABLE_ALIAS_DEFAULT
 #define CHKUSER_ENABLE_USERS_EXTENSIONS
 and recompile netqmail.
 
 I make extension address for (example) user dave in
 ~vpopmail/domains/mydomain.com/dave/.qmail-try, just to try my ext address
 work:
 | forward [EMAIL PROTECTED]
 and change the file owner to vpopmail:vchkpw.
 
 But when I try to send an email to [EMAIL PROTECTED], it doesn't
 work like
 I hope. It doesn't forward the email to me (not read .qmail-extaddr?), but
 still deliver to dave (still read .qmail-default?).
 
 Any ideas?
 
 Regards
 Zeno
 
 
 Selamat bagi para pemenang Grand Prize Netkuis Ramadhan 1427 H
 
 
 !DSPAM:456fb315301664975420232!