[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'
+ '['