[vchkpw] [chkuser] Enable '' char in CHKUSER_ALLOW_RCPT_CHAR_

2006-12-05 Thread Staff Polesine Innovazione

Hello everybody,

as in subject I would enable the '' in CHKUSER_ALLOW_RCPT_CHAR_ , I know is 
possible because I'd read this 
http://wiki.qmailtoaster.com/index.php/QTP_Wish_List#chkuser_settings.h_changes
I use the VM found at 
http://devel.qmailtoaster.com/info/QmailToaster.zip.html .
To change the chkuser_settings.h I use the tip found at 
http://wiki.qmailtoaster.com/index.php/Chkuser , but when I change

this

--snip--
#define CHKUSER_ALLOW_RCPT_CHAR_1 '$'
/* #define CHKUSER_ALLOW_RCPT_CHAR_2 '%' */
/* #define CHKUSER_ALLOW_RCPT_CHAR_3 '' */
/* #define CHKUSER_ALLOW_RCPT_CHAR_4 '?' */
#define CHKUSER_ALLOW_RCPT_CHAR_5 '*'
--snip--

with this

--snip--
#define CHKUSER_ALLOW_RCPT_CHAR_1 '$'
#define CHKUSER_ALLOW_RCPT_CHAR_2 ''
/* #define CHKUSER_ALLOW_RCPT_CHAR_3 '' */
/* #define CHKUSER_ALLOW_RCPT_CHAR_4 '?' */
#define CHKUSER_ALLOW_RCPT_CHAR_5 '*'
--snip--

or simply (only for test) with this:

--snip--
#define CHKUSER_ALLOW_RCPT_CHAR_1 '$'
#define CHKUSER_ALLOW_RCPT_CHAR_2 '%'
/* #define CHKUSER_ALLOW_RCPT_CHAR_3 '' */
/* #define CHKUSER_ALLOW_RCPT_CHAR_4 '?' */
#define CHKUSER_ALLOW_RCPT_CHAR_5 '*'
--snip--

the process fail with this error (full transcript in footer):

--cut--
./compile qmail-smtpd.c
In file included from qmail-smtpd.c:65:
tls.h:11:1: warning: _exit redefined
In file included from qmail-smtpd.c:42:
chkuser.h:50:1: warning: this is the location of the previous definition
qmail-smtpd.c: In function `main':
qmail-smtpd.c:1343: warning: return type of 'main' is not `int'
./compile spf.c
./compile chkuser.c
chkuser.c: In function `check_rcpt_address_format':
chkuser.c:321: error: `CHKUSER_ALLOW_SENDER_CHAR_2' undeclared (first use in 
this function)

chkuser.c:321: error: (Each undeclared identifier is reported only once
chkuser.c:321: error: for each function it appears in.)
make: *** [chkuser.o] Error 1
--cut--

Any idea?
Thanks
 Davide

full transcript of: 'rpmbuild -bb --with cnt40 qmail-toaster.spec '

Esecuzione(%prep) in corso: /bin/sh -e /var/tmp/rpm-tmp.12849
+ umask 022
+ cd /usr/src/redhat/BUILD
+ LANG=C
+ export LANG
+ unset DISPLAY
+ cd /usr/src/redhat/BUILD
+ rm -rf qmail-1.03
+ /usr/bin/bzip2 -dc /usr/src/redhat/SOURCES/qmail-1.03.tar.bz2
+ tar -xf -
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd qmail-1.03
++ /usr/bin/id -u
+ '[' 0 = 0 ']'
+ /bin/chown -Rhf root .
++ /usr/bin/id -u
+ '[' 0 = 0 ']'
+ /bin/chgrp -Rhf root .
+ /bin/chmod -Rf a+rX,u+w,g-w,o-w .
+ echo 'Patch #0 (qmailtoaster-1.3.1.patch.bz2):'
Patch #0 (qmailtoaster-1.3.1.patch.bz2):
+ /usr/bin/bzip2 -d
+ patch -p0 -s
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ echo 'Patch #1 (qmail-chkuser.patch.bz2):'
Patch #1 (qmail-chkuser.patch.bz2):
+ /usr/bin/bzip2 -d
+ patch -p1 -s
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ /usr/bin/perl -pi -e 's|\#define AUTHCRAM||g' qmail-smtpd.c
+ /usr/bin/perl -pi -e 's|LDK_PATH|/usr/lib/libdomainkeys.a|g' Makefile
+ '[' -f /var/tmp/qmail-1.03-gcc ']'
+ rm -f /var/tmp/qmail-1.03-gcc
+ echo gcc
+ '[' -f /var/tmp/qmail-1.03-show_flags ']'
+ rm -f /var/tmp/qmail-1.03-show_flags
+ cat
+ chmod u+x /var/tmp/qmail-1.03-show_flags
+ /var/tmp/qmail-1.03-show_flags


 RPM RELEASE: qmail-toaster-1.03-1.3.6
 OS TYPE IS : CentOS 4 Linux 
 BUILD DATE : Sat Sep 09 2006 
 CCFLAGS: 
-O2 -g -pipe -m32 -march=i386 -mtune=pentium4 -DTLS=20060104  
-I/home/vpopmail/include 
 LDFLAGS: 
-O2 -g -pipe -m32 -march=i386 -mtune=pentium4 



+ '[' -f /var/tmp/qmail-1.03-show_flags ']'
+ rm -f /var/tmp/qmail-1.03-show_flags
+ exit 0
Esecuzione(%build) in corso: /bin/sh -e /var/tmp/rpm-tmp.36342
+ umask 022
+ cd /usr/src/redhat/BUILD
+ cd qmail-1.03
+ LANG=C
+ export LANG
+ unset DISPLAY
+ '[' -n /var/tmp/qmail-toaster-1.03 -a /var/tmp/qmail-toaster-1.03 '!=' / 
']'

+ rm -rf /var/tmp/qmail-toaster-1.03
+ mkdir -p /var/tmp/qmail-toaster-1.03
++ /usr/bin/id -g nofiles
+ '[' -z '' ']'
+ /usr/sbin/groupadd -g 2107 -r nofiles
groupadd: group nofiles exists
+ :
++ /usr/bin/id -g qmail
+ '[' -z '' ']'
+ /usr/sbin/groupadd -g 2108 -r qmail
groupadd: group qmail exists
+ :
++ /usr/bin/id -u alias
+ '[' -z 7790 ']'
++ /usr/bin/id -u qmaild
+ '[' -z 7791 ']'
++ /usr/bin/id -u qmaill
+ '[' -z 7792 ']'
++ /usr/bin/id -u qmailp
+ '[' -z 7793 ']'
++ /usr/bin/id -u qmailq
+ '[' -z 7794 ']'
++ /usr/bin/id -u qmailr
+ '[' -z 7795 ']'
++ /usr/bin/id -u qmails
+ '[' -z 7796 ']'
++ cat /var/tmp/qmail-1.03-gcc
+ echo 
'gcc -O2 -g -pipe -m32 -march=i386 -mtune=pentium4 -DTLS=20060104 -I/home/vpopmail/include'

++ cat /var/tmp/qmail-1.03-gcc
+ echo 'gcc -s -O2 -g -pipe -m32 -march=i386 -mtune=pentium4'
+ '[' -f /var/tmp/qmail-1.03-gcc ']'
+ rm -f /var/tmp/qmail-1.03-gcc
+ make clean
rm -f `cat TARGETS`
+ make compile makelib
( cat warn-auto.sh; \
echo CC=\'`head -1 conf-cc`\'; \
echo LD=\'`head -1 conf-ld`\' \
)  auto-ccld.sh
cat auto-ccld.sh make-compile.sh  

Re: [vchkpw] [chkuser] Enable '' char in CHKUSER_ALLOW_RCPT_CHAR_

2006-12-05 Thread tonix (Antonio Nati)

This is a known error.

Because of a cut'n'paste error the check_rcpt_address_format() 
routine uses wrong constants.


Inside check_rcpt_address_format() change all
CHKUSER_ALLOW_SENDER_CHAR_x
to
CHKUSER_ALLOW_RCPT_CHAR_x

Ciao,

Tonino

At 12.43 05/12/2006, you wrote:

Hello everybody,

as in subject I would enable the '' in CHKUSER_ALLOW_RCPT_CHAR_ , I 
know is possible because I'd read this 
http://wiki.qmailtoaster.com/index.php/QTP_Wish_List#chkuser_settings.h_changes
I use the VM found at 
http://devel.qmailtoaster.com/info/QmailToaster.zip.html .
To change the chkuser_settings.h I use the tip found at 
http://wiki.qmailtoaster.com/index.php/Chkuser , but when I change

this

--snip--
#define CHKUSER_ALLOW_RCPT_CHAR_1 '$'
/* #define CHKUSER_ALLOW_RCPT_CHAR_2 '%' */
/* #define CHKUSER_ALLOW_RCPT_CHAR_3 '' */
/* #define CHKUSER_ALLOW_RCPT_CHAR_4 '?' */
#define CHKUSER_ALLOW_RCPT_CHAR_5 '*'
--snip--

with this

--snip--
#define CHKUSER_ALLOW_RCPT_CHAR_1 '$'
#define CHKUSER_ALLOW_RCPT_CHAR_2 ''
/* #define CHKUSER_ALLOW_RCPT_CHAR_3 '' */
/* #define CHKUSER_ALLOW_RCPT_CHAR_4 '?' */
#define CHKUSER_ALLOW_RCPT_CHAR_5 '*'
--snip--

or simply (only for test) with this:

--snip--
#define CHKUSER_ALLOW_RCPT_CHAR_1 '$'
#define CHKUSER_ALLOW_RCPT_CHAR_2 '%'
/* #define CHKUSER_ALLOW_RCPT_CHAR_3 '' */
/* #define CHKUSER_ALLOW_RCPT_CHAR_4 '?' */
#define CHKUSER_ALLOW_RCPT_CHAR_5 '*'
--snip--

the process fail with this error (full transcript in footer):

--cut--
./compile qmail-smtpd.c
In file included from qmail-smtpd.c:65:
tls.h:11:1: warning: _exit redefined
In file included from qmail-smtpd.c:42:
chkuser.h:50:1: warning: this is the location of the previous definition
qmail-smtpd.c: In function `main':
qmail-smtpd.c:1343: warning: return type of 'main' is not `int'
./compile spf.c
./compile chkuser.c
chkuser.c: In function `check_rcpt_address_format':
chkuser.c:321: error: `CHKUSER_ALLOW_SENDER_CHAR_2' undeclared 
(first use in this function)

chkuser.c:321: error: (Each undeclared identifier is reported only once
chkuser.c:321: error: for each function it appears in.)
make: *** [chkuser.o] Error 1
--cut--

Any idea?
Thanks
 Davide

full transcript of: 'rpmbuild -bb --with cnt40 qmail-toaster.spec '

Esecuzione(%prep) in corso: /bin/sh -e /var/tmp/rpm-tmp.12849
+ umask 022
+ cd /usr/src/redhat/BUILD
+ LANG=C
+ export LANG
+ unset DISPLAY
+ cd /usr/src/redhat/BUILD
+ rm -rf qmail-1.03
+ /usr/bin/bzip2 -dc /usr/src/redhat/SOURCES/qmail-1.03.tar.bz2
+ tar -xf -
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd qmail-1.03
++ /usr/bin/id -u
+ '[' 0 = 0 ']'
+ /bin/chown -Rhf root .
++ /usr/bin/id -u
+ '[' 0 = 0 ']'
+ /bin/chgrp -Rhf root .
+ /bin/chmod -Rf a+rX,u+w,g-w,o-w .
+ echo 'Patch #0 (qmailtoaster-1.3.1.patch.bz2):'
Patch #0 (qmailtoaster-1.3.1.patch.bz2):
+ /usr/bin/bzip2 -d
+ patch -p0 -s
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ echo 'Patch #1 (qmail-chkuser.patch.bz2):'
Patch #1 (qmail-chkuser.patch.bz2):
+ /usr/bin/bzip2 -d
+ patch -p1 -s
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ /usr/bin/perl -pi -e 's|\#define AUTHCRAM||g' qmail-smtpd.c
+ /usr/bin/perl -pi -e 's|LDK_PATH|/usr/lib/libdomainkeys.a|g' Makefile
+ '[' -f /var/tmp/qmail-1.03-gcc ']'
+ rm -f /var/tmp/qmail-1.03-gcc
+ echo gcc
+ '[' -f /var/tmp/qmail-1.03-show_flags ']'
+ rm -f /var/tmp/qmail-1.03-show_flags
+ cat
+ chmod u+x /var/tmp/qmail-1.03-show_flags
+ /var/tmp/qmail-1.03-show_flags


[40m[001;031m RPM RELEASE: [40m[001;033mqmail-toaster-1.03-1.3.6[0m
[40m[001;031m OS TYPE IS : [40m[001;033mCentOS 4 Linux [0m
[40m[001;031m BUILD DATE : [40m[001;033mSat Sep 09 2006 [0m
[40m[001;031m CCFLAGS: [40m[001;033m-O2 -g -pipe -m32 
-march=i386 -mtune=pentium4 -DTLS=20060104

-I/home/vpopmail/include [0m
[40m[001;031m LDFLAGS: [40m[001;033m-O2 -g -pipe -m32 
-march=i386 -mtune=pentium4 [0m



+ '[' -f /var/tmp/qmail-1.03-show_flags ']'
+ rm -f /var/tmp/qmail-1.03-show_flags
+ exit 0
Esecuzione(%build) in corso: /bin/sh -e /var/tmp/rpm-tmp.36342
+ umask 022
+ cd /usr/src/redhat/BUILD
+ cd qmail-1.03
+ LANG=C
+ export LANG
+ unset DISPLAY
+ '[' -n /var/tmp/qmail-toaster-1.03 -a /var/tmp/qmail-toaster-1.03 '!=' / ']'
+ rm -rf /var/tmp/qmail-toaster-1.03
+ mkdir -p /var/tmp/qmail-toaster-1.03
++ /usr/bin/id -g nofiles
+ '[' -z '' ']'
+ /usr/sbin/groupadd -g 2107 -r nofiles
groupadd: group nofiles exists
+ :
++ /usr/bin/id -g qmail
+ '[' -z '' ']'
+ /usr/sbin/groupadd -g 2108 -r qmail
groupadd: group qmail exists
+ :
++ /usr/bin/id -u alias
+ '[' -z 7790 ']'
++ /usr/bin/id -u qmaild
+ '[' -z 7791 ']'
++ /usr/bin/id -u qmaill
+ '[' -z 7792 ']'
++ /usr/bin/id -u qmailp
+ '[' -z 7793 ']'
++ /usr/bin/id -u qmailq
+ '[' -z 7794 ']'
++ /usr/bin/id -u qmailr
+ '[' -z 7795 ']'
++ /usr/bin/id -u qmails
+ '[' -z 7796 ']'
++ cat /var/tmp/qmail-1.03-gcc
+ echo 'gcc -O2 -g -pipe -m32 -march=i386 -mtune=pentium4 
-DTLS=20060104 -I/home/vpopmail/include'

++ cat /var/tmp/qmail-1.03-gcc
+ echo 'gcc -s -O2 -g -pipe -m32 -march=i386 -mtune=pentium4'
+ '[' 

Re: [vchkpw] root owned maildirsize revisited

2006-12-05 Thread Tom Collins

On Dec 4, 2006, at 5:27 PM, Charles Sprickman wrote:
vdelivermail, maildrop, qmail-local - none are setuid root.  I see  
this on users that have pop/imap access closed off.  So I think  
that means we're talking about something doing the delivery is  
doing this.


So how do they pick up their email?  Or are you saying that it  
happens on accounts where no one could possibly pick up the messages?


What version of vpopmail are you using?  I made some major changes to  
vdelivermail around 5.4.12 (or so) that may have improved handling of  
the maildirsize file, but since vdelivermail never runs as root, I  
don't see how it could rebuild the maildirsize file as root.


To the best of my limited knowledge, vdelivermail will change  
maildirsize, as will the POP or IMAP server, but not much else.


EXCEPT, vmoduser and some of the other command-line tools.  Is it  
possible that an admin on the box is running one of the command-line  
tools to modify the user, resulting in the maildirsize file getting  
rebuilt?


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




Re: [vchkpw] duplicate emails in simscan when remote server times out

2006-12-05 Thread Tom Collins

On Nov 30, 2006, at 4:27 PM, Rick Macdougall wrote:
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 ?)


I thought it did, but I just got a message that seems to indicate  
that it didn't.  Someone emailing me got this error:


Message delivery to the host '123.45.67.89' failed while delivering  
to the remote domain 'domain.com' for the following reason: The  
semaphore timeout period has expired.


I checked my logs, and the virus scan took 12 seconds.  Most of that  
(11s) was scanning the msg file, so I assume it took another 11s to  
ripmime it before calling clamav.  I guess 23 seconds is a long time  
to wait for a response after ending the DATA part of an SMTP  
conversation.


It could just be a bad timing thing where the other end drops the  
connection and simscan replies that it was received OK before it  
knows the connection closed.


It might need some further testing by the simscan developers to find  
additional failure points.


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




Re: [vchkpw] duplicate emails in simscan when remote server times out

2006-12-05 Thread Rick Macdougall

Tom Collins wrote:

On Nov 30, 2006, at 4:27 PM, Rick Macdougall wrote:
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 ?)


I thought it did, but I just got a message that seems to indicate that 
it didn't.  Someone emailing me got this error:


Message delivery to the host '123.45.67.89' failed while delivering to 
the remote domain 'domain.com' for the following reason: The semaphore 
timeout period has expired.


I checked my logs, and the virus scan took 12 seconds.  Most of that 
(11s) was scanning the msg file, so I assume it took another 11s to 
ripmime it before calling clamav.  I guess 23 seconds is a long time to 
wait for a response after ending the DATA part of an SMTP conversation.


It could just be a bad timing thing where the other end drops the 
connection and simscan replies that it was received OK before it knows 
the connection closed.


It might need some further testing by the simscan developers to find 
additional failure points.




Interesting.  Do you have any idea what the remote email server was ? 
(The actual MTA I mean).


Regards,

Rick



Re: [vchkpw] duplicate emails in simscan when remote server times out

2006-12-05 Thread Tom Collins

On Dec 5, 2006, at 4:13 PM, Rick Macdougall wrote:
Interesting.  Do you have any idea what the remote email server  
was ? (The actual MTA I mean).


Microsoft ESMTP MAIL Service, Version: 6.0.3790.1830

Maybe an older version of Exchange that needs to be updated?

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