Someone may want a host to accept all mails in the form of
*.abc.com,  *.*.abc.com, there IS a way to implement such
function,but it is rather annoying.

control/rcpthosts
  abc.com
  .abc.com
control/locals
  abc.com
control/virtualdomains
  .abc.com:fool
alias/.qmail-fool-default
  |/var/qmail/bin/forward $EXT2


I hacked the source code of Qmail, and it now support wildcard in
control/locals, that is ,you can set up following lines in 
control/locals and it will work. :-)
------------
.abc.com
-----------
sooooooo easy.


---------------- my patch ------------

148c148,168
<
---
> { unsigned char *pbyte;
>   unsigned int len;
>   unsigned int dot;
>   unsigned char count;
>
>   count=0;
>   pbyte=addr.s+at+1;
>   len=addr.len-at-1;
>   dot=byte_chr(pbyte,len,'.');
>   while(dot<len && count<4){
>       if(constmap(&maplocals,pbyte+dot,len-dot)){
>       if (!stralloc_cat(&rwline,&addr)) return 0;
>       if (!stralloc_0(&rwline)) return 0;
>       return 1;
>       }//if
>       pbyte=pbyte+dot+1;
>       len=len-dot-1;
>       dot=byte_chr(pbyte,len,'.');
>       count++;
>   }//while
> }


---------------- apply the patch -----
(1) save the patch above as qmail-send.patch
(2) download qmail-1.03.tar.gz
(3) tar xzvf qmail-1.03.tar.gz
(4) cd qmail-1.03 
(5) patch qmail-send.c <qmail-send.patch
(6) install qmail as stated in INSTALL file


-------------------------------------
If any problem,please contact me directly since I am not subscribed to
this mailling list


--Junwen--

Reply via email to