[xmail] Re: problem with cron daemon

2003-09-04 Thread Sönke Ruempler

 You're a PITA :) ... done.

thx, but what the hell is PITA? i only know PITA gyros, a greek food ;-)

could you give me the source code of sendmail?


-
To unsubscribe from this list: send the line unsubscribe xmail in
the body of a message to [EMAIL PROTECTED]
For general help: send the line help in the body of a message to
[EMAIL PROTECTED]



[xmail] Re: problem with cron daemon

2003-09-04 Thread Davide Libenzi

On Thu, 4 Sep 2003, [iso-8859-1] S=F6nke Ruempler wrote:


  You're a PITA :) ... done.

 thx, but what the hell is PITA? i only know PITA gyros, a greek food ;-)

Pain In The Ass


 could you give me the source code of sendmail?

Don't you have it ?



- Davide

-
To unsubscribe from this list: send the line unsubscribe xmail in
the body of a message to [EMAIL PROTECTED]
For general help: send the line help in the body of a message to
[EMAIL PROTECTED]



[xmail] Re: problem with cron daemon

2003-09-04 Thread Sönke Ruempler

 Don't you have it ?

i meant the new binary with the new function ;-)

is it in the pre version?
-
To unsubscribe from this list: send the line unsubscribe xmail in
the body of a message to [EMAIL PROTECTED]
For general help: send the line help in the body of a message to
[EMAIL PROTECTED]



[xmail] Re: problem with cron daemon

2003-09-04 Thread Davide Libenzi

On Thu, 4 Sep 2003, [iso-8859-1] S=F6nke Ruempler wrote:


  Don't you have it ?

 i meant the new binary with the new function ;-)

Here you go.
You need to set DEFAULT_DOMAIN in the environment (or registry for
Windows). You can export DEFAULT_DOMAIN in the sendmail script if you
want.



- Davide






/*
 *  SendMail by Davide Libenzi ( sendmail replacement for XMail )
 *  Copyright (C) 1999  Davide Libenzi
 *
 *  This program is free software; you can redistribute it and/or modify
 *  it under the terms of the GNU General Public License as published by
 *  the Free Software Foundation; either version 2 of the License, or
 *  (at your option) any later version.
 *
 *  This program is distributed in the hope that it will be useful,
 *  but WITHOUT ANY WARRANTY; without even the implied warranty of
 *  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
 *  GNU General Public License for more details.
 *
 *  You should have received a copy of the GNU General Public License
 *  along with this program; if not, write to the Free Software
 *  Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  U=
SA
 *
 *  Davide Libenzi [EMAIL PROTECTED]
 *
 */

#if defined(WIN32)

#include windows.h
#include stdio.h
#include io.h
#include direct.h
#include stdlib.h
#include string.h
#include time.h
#include AppDefines.h




#define SYS_SLASH_CHAR  '\\'
#define SYS_SLASH_STR   \\
#define SYS_MAX_PATH256

#define SysSNPrintf _snprintf

#define Sign(v) (((v)  0) ? -1: +1)
#define Min(a, b)   (((a)  (b)) ? (a): (b))
#define Max(a, b)   (((a)  (b)) ? (a): (b))
#define Abs(v)  (((v)  0) ? (v): -(v))




int SysFileSync(FILE *pFile)
{

if (fflush(pFile) || _commit(_fileno(pFile)))
return (-1);

return (0);

}

int SysPathExist(char const *pszPathName)
{

return ((_access(pszPathName, 0) =3D=3D 0) ? 1 : 0);

}

int SysMakeDir(char const *pszPathName)
{

return ((_mkdir(pszPathName) =3D=3D 0) ? 1 : 0);

}

int SysErrNo(void)
{

return (errno);

}

char const *SysErrStr(void)
{

return (strerror(errno));

}

unsigned long   SysGetProcessId(void)
{

return ((unsigned long) GetCurrentThreadId());

}

int SysMoveFile(char const *pszOldName, char const *pszNewName)
{

if (!MoveFileEx(pszOldName, pszNewName, MOVEFILE_REPLACE_EXISTING | MOV=
EFILE_COPY_ALLOWED))
return (-1);

return (0);

}

int SysGetHostName(char *pszHostName, int iNameSize)
{

DWORD   dwSize =3D (DWORD) iNameSize;

GetComputerName(pszHostName, dwSize);

return (0);

}

voidSysMsSleep(int iMsTimeout)
{

Sleep(iMsTimeout);

}

char   *SysGetEnv(const char *pszVarName)
{

charszRKeyPath[256] =3D ;

sprintf(szRKeyPath, SOFTWARE\\%s\\%s, APP_PRODUCER, APP_NAME_STR);

HKEYhKey;

if (RegOpenKeyEx(HKEY_LOCAL_MACHINE, szRKeyPath, 0, KEY_QUERY_VALUE,
 hKey) =3D=3D ERROR_SUCCESS)
{
charszKeyValue[2048] =3D ;
DWORD   dwSize =3D sizeof(szKeyValue),
dwKeyType;

if (RegQueryValueEx(hKey, pszVarName, NULL, dwKeyType, (u_char *) =
szKeyValue,
dwSize) =3D=3D ERROR_SUCCESS)
{
RegCloseKey(hKey);

return (strdup(szKeyValue));
}

RegCloseKey(hKey);
}

const char *pszValue =3D getenv(pszVarName);

return ((pszValue !=3D NULL) ? strdup(pszValue) : NULL);

}

#else   // #if defined(WIN32)
#if defined(__LINUX__) || defined(__SOLARIS__) || defined(__BSD__)

#include sys/stat.h
#include stdio.h
#include stdlib.h
#include string.h
#include ctype.h
#include time.h
#include fcntl.h
#include unistd.h
#include errno.h
#include dirent.h



#define SYS_SLASH_CHAR  '/'
#define SYS_SLASH_STR   /
#define SYS_MAX_PATH256

#define SysSNPrintf snprintf
#define stricmp strcasecmp
#define strnicmpstrncasecmp

#define Sign(v) (((v)  0) ? -1: +1)
#define Min(a, b)   (((a)  (b)) ? (a): (b))
#define Max(a, b)   (((a)  (b)) ? (a): (b))
#define Abs(v)  (((v)  0) ? (v): -(v))




int SysFileSync(FILE *pFile)
{

if (fflush(pFile) || fsync(fileno(pFile)))
return (-1);

return (0);

}

int SysPathExist(char const *pszPathName)
{

return ((access(pszPathName, 0) =3D=3D 0) ? 1 : 0);

}

int SysMakeDir(char const *pszPathName)
{

return ((mkdir(pszPathName, 0700) =3D=3D 0) ? 1 : 0);

}

int SysErrNo(void)
{

return (errno);

}

char const *SysErrStr(void)
{

return (strerror(errno));

}

unsigned long   SysGetProcessId(void)
{


[xmail] Re: problem with cron daemon

2003-09-01 Thread Davide Libenzi

On Mon, 1 Sep 2003, [iso-8859-1] S=F6nke Ruempler wrote:


  Davide, only the server that has xmail as MTA, is affected cause the ot=
her
  servers with sendmail set the MAIL_FROM to user@hostname, maybe you
  could change the sendmail code that it does the same if NO -f is
 specified??

 Davide, what about that?

How about you wrapping sendmail with a perl script in such machine ?



- Davide

-
To unsubscribe from this list: send the line unsubscribe xmail in
the body of a message to [EMAIL PROTECTED]
For general help: send the line help in the body of a message to
[EMAIL PROTECTED]



[xmail] Re: problem with cron daemon

2003-09-01 Thread Davide Libenzi

On Mon, 1 Sep 2003, [iso-8859-1] S=F6nke Ruempler wrote:

  How about you wrapping sendmail with a perl script in such machine ?

 mhm i think xmail's sendmail should behave like the real sendmail? a perl
 script would make the chain to the real sendmail binary longer, now there
 already a bash script that passes everything to the sendmail binary.

 and i think this is a generous problem because it happens in a XMail-only
 environment (think of it)

You're a PITA :) ... done.



- Davide

-
To unsubscribe from this list: send the line unsubscribe xmail in
the body of a message to [EMAIL PROTECTED]
For general help: send the line help in the body of a message to
[EMAIL PROTECTED]



[xmail] Re: problem with cron daemon

2003-08-29 Thread Sönke Ruempler

 You should have it inside the source disk of your preferred distro.


ftp://rpmfind.net/linux/engarde/Community/SRPMS/vixie-cron-3.0.1-1.3.0.src.=
 rpm

Davide, only the server that has xmail as MTA, is affected cause the other
servers with sendmail set the MAIL_FROM to user@hostname, maybe you
could change the sendmail code that it does the same if NO -f is specified??

-
To unsubscribe from this list: send the line unsubscribe xmail in
the body of a message to [EMAIL PROTECTED]
For general help: send the line help in the body of a message to
[EMAIL PROTECTED]



[xmail] Re: problem with cron daemon

2003-08-28 Thread Sönke Ruempler

 It does not seem to be programmable. Get the cron source and make it
 programmable :)

I don't find the source code of vixie cron? Does anybody know?

Btw, filters aren't processed with local delivery, are they? So chaning the
source code of Cron would be the only alternative.

-
To unsubscribe from this list: send the line unsubscribe xmail in
the body of a message to [EMAIL PROTECTED]
For general help: send the line help in the body of a message to
[EMAIL PROTECTED]



[xmail] Re: problem with cron daemon

2003-08-28 Thread Davide Libenzi

On Thu, 28 Aug 2003, [iso-8859-1] S=F6nke Ruempler wrote:


  It does not seem to be programmable. Get the cron source and make it
  programmable :)

 I don't find the source code of vixie cron? Does anybody know?

You should have it inside the source disk of your preferred distro.

ftp://rpmfind.net/linux/engarde/Community/SRPMS/vixie-cron-3.0.1-1.3.0.src.=
rpm


 Btw, filters aren't processed with local delivery, are they? So chaning t=
he
 source code of Cron would be the only alternative.

Filters are executed even with local delivery. Local delivery does not
drop the message inside the target mailbox but it drops it inside the
spool like if it was coming from remote SMTP.



- Davide

-
To unsubscribe from this list: send the line unsubscribe xmail in
the body of a message to [EMAIL PROTECTED]
For general help: send the line help in the body of a message to
[EMAIL PROTECTED]



[xmail] Re: problem with cron daemon

2003-08-22 Thread Bill Healy

On linux edit /etc/crontab and change the MAILTO=3D variable.

Bill

--
From:  S=F6nke Ruempler[SMTP:[EMAIL PROTECTED]
Sent:  Friday, August 22, 2003 12:24 AM
To:[EMAIL PROTECTED]
Subject:   [xmail] problem with cron daemon


hi,

my the crond on our fallback mailserver sends mails with MAIL_FROM
CronDaemon - the xmail server relays that to the main xmail server =
and
that says ESYNTAX for MAIL_FROM - so how can i tell crond to use =
another
MAIL_FROM ?!

--

Soenke.

-
To unsubscribe from this list: send the line unsubscribe xmail in
the body of a message to [EMAIL PROTECTED]
For general help: send the line help in the body of a message to
[EMAIL PROTECTED]


-
To unsubscribe from this list: send the line unsubscribe xmail in
the body of a message to [EMAIL PROTECTED]
For general help: send the line help in the body of a message to
[EMAIL PROTECTED]



[xmail] Re: problem with cron daemon

2003-08-22 Thread Sönke Ruempler

 On linux edit /etc/crontab and change the MAILTO=3D variable.

i meant MAIL_FROM, not the RCPT ...
-
To unsubscribe from this list: send the line unsubscribe xmail in
the body of a message to [EMAIL PROTECTED]
For general help: send the line help in the body of a message to
[EMAIL PROTECTED]



[xmail] Re: problem with cron daemon

2003-08-22 Thread Davide Libenzi

On Fri, 22 Aug 2003, [iso-8859-1] S=F6nke Ruempler wrote:


 hi,

 my the crond on our fallback mailserver sends mails with MAIL_FROM
 CronDaemon - the xmail server relays that to the main xmail server and
 that says ESYNTAX for MAIL_FROM - so how can i tell crond to use anothe=
r
 MAIL_FROM ?!

It does not seem to be programmable. Get the cron source and make it
programmable :)



- Davide

-
To unsubscribe from this list: send the line unsubscribe xmail in
the body of a message to [EMAIL PROTECTED]
For general help: send the line help in the body of a message to
[EMAIL PROTECTED]