Koozali.org: home of the SME Server

Mail to Hylafax gateway using RelayFax Client

Duncan

Mail to Hylafax gateway using RelayFax Client
« on: September 29, 2001, 11:05:37 PM »
I have just set up the RelayFax client to send documents to Hylafax via e-mail.
Hylafax then faxes the documents to the number you supply.
It includes a cover page and fills in all the details (name, company, number etc)

It looks to be a much simpler solution than Cypheus and WHFC (although it will take more to set up) and integrates with existing Outlook and LDAP folders.

The problem is that there are a couple of bugs in the scripts that i cant work out
(scripts are borrowed from someone else), so i would like someone else to look at them.

If you are interested please leave a reply here so i can e-mail them and a description of what ive done to you.

This above solution needs no virtual domains (just a user) or any serious changes to E-smith (just setting up procmail for that user) but it would require a good understanding of linux and procmail to iron out the bugs.

Id like to see the end result posted to the how tos

Regards Duncan

Tim Litwiller

Re: Mail to Hylafax gateway using RelayFax Client
« Reply #1 on: October 02, 2001, 06:05:03 AM »
I'd like to take a look

Duncan

Re: Mail to Hylafax gateway using RelayFax Client
« Reply #2 on: October 02, 2001, 09:34:44 AM »
Ok i will send it thru later.

I have most of it working now with only a couple of problems.

Regards Duncan

Tim Litwiller

Re: Mail to Hylafax gateway using RelayFax Client
« Reply #3 on: October 04, 2001, 01:12:09 AM »
what is the procedure for this?

3) set up a user via the web interface which is set up to use

"procmail rather than qmail."

This user is where relayfax sends its faxes to.

Duncan

Qmail Procedure
« Reply #4 on: October 04, 2001, 05:36:28 AM »
I added the rpm dmc-etc and followed the instructions from here.

http://myezserver.com/docs/mitel/procmail-howto.html

I guess you could just for testing purposes just edit the .qmail file to reflect the following

| /usr/bin/procmail ~/.procmailrc

but it would be killed if the user was ever updated.


Regards Duncan

Tim Litwiller

Re: Qmail Procedure
« Reply #5 on: October 06, 2001, 03:28:58 AM »
thanks, I did that now, but still don't have it working.


here is the /var/log/maillog from a print event

Oct  5 18:26:18 bcc54 smtpd[25191]: SMTP HELO from pc-00069.e-smith.bccks.com(192.168.2.69) as "RelayFax"
Oct  5 18:26:19 bcc54 smtpd[25191]: mail from
Oct  5 18:26:19 bcc54 smtpd[25191]: smtp connection from UNKNOWN@pc-00069.e-smith.bccks.com(192.168.2.69) MAIL FROM: RCPT T
O: , allowed by line 23 of /etc/smtpd_check_rules
Oct  5 18:26:19 bcc54 smtpd[25191]: Recipient
Oct  5 18:26:20 bcc54 smtpd[25191]: Received 229412 bytes of message body from pc-00069.e-smith.bccks.com(192.168.2.69)
Oct  5 17:26:30 bcc54 smtpfwdd[25203]: forwarding to recipient faxr@nukeindex.org
Oct  5 17:26:30 bcc54 smtpfwdd[25203]: smtpd8SmBjp forwarded to 1 recipients

can you send me the log of a send event from your working setup.

Duncan

Re: Qmail Procedure
« Reply #6 on: October 06, 2001, 07:03:23 AM »
Ok here is a copy for a from my log

SMTP HELO from pc-00010.goldtel.com.au(10.0.0.10) as "RelayFax"
mail from
smtp connection from UNKNOWN@pc-00010.goldtel.com.au(10.0.0.10) MAIL FROM: RCPT TO: , allowed by line 27 of /etc/smtpd_check_rules
Recipient
Received 868 bytes of message body from pc-00010.goldtel.com.au(10.0.0.10)
forwarding to recipient test@goldtel.com.au
smtpdqaH4FA forwarded to 1 recipients

It looks like you are using a different box for your faxserver. Have you checked the procmail log file to see whats happening to the e-mail when it arrives.

On another note i have had some ideas on refining the system to include

Max faxouts based on mailing lists ie subject - FAXLIST No 1
Some method of least cost routing whereby the script looks at the number and forwards the e-mail to another box (anywhere in the world) if there is a match for that area code.

Regards Duncan

Tim Litwiller

Re: Qmail Procedure
« Reply #7 on: October 06, 2001, 08:30:28 AM »
> It looks like you are using a different box for your
> faxserver. Have you checked the procmail log file to see
> whats happening to the e-mail when it arrives.

It never logs anything, so it must not be making it that far.

Tim Litwiller

Re: Qmail Procedure
« Reply #8 on: October 06, 2001, 09:30:43 AM »
hmm..  question.

since the procmail link on the dmc site is broken, and I used a procmail from rpmfind.net do you suppose that it is delivering mail differently.   But then it should still be getting in the log file and the procmail log file never gets anything.

Tim Litwiller

Re: Qmail Procedure
« Reply #9 on: October 06, 2001, 09:30:47 AM »
hmm..  question.

since the procmail link on the dmc site is broken, and I used a procmail from rpmfind.net do you suppose that it is delivering mail differently.   But then it should still be getting in the log file and the procmail log file never gets anything.

Duncan

Re: Qmail Procedure
« Reply #10 on: October 06, 2001, 12:41:11 PM »
Ok, i am assuming you can send an email from tim@bccks.com to
"anotheruser"@nukeindex.org and that works correctly. If your faxr@nukeindex.org
server is local why not point the relay fax client directly to that server using its ip address..

In your /path to users/faxr account you should have the following

.qmail file that reads

#------------------------------------------------------------
# DO NOT MODIFY THIS FILE! It is updated automatically by the
# e-smith server and gateway software. Instead, modify the source
# template in the /etc/e-smith/templates directory. For more
# information, see http://www.e-smith.org.
#
# copyright (C) 1999-2001 e-smith, inc.
#------------------------------------------------------------
| /usr/bin/procmail ~/.procmailrc

#------------------------------------------------------------
# TEMPLATE END
#------------------------------------------------------------

You should have a .procmailrc file, .faxitrc file, faxuserlist and /faxtmp folder.

Regards Duncan

Tim Litwiller

Re: Qmail Procedure
« Reply #11 on: October 06, 2001, 07:52:08 PM »
Yes, nukeindex. is a virutal domain on the same machine, but
after some
reading last night it seems procmail doesn't work correctly with
vitual
domains and the bccks.com has to pass thru to an exchange server
for some
other applications that our company is still stuck with.

When I get my home e-smith hooked up again, then I'll retry this
with only
one domain on the machine or at least the machine domainname
available to use for this.

Eric Ng

Re: Qmail Procedure
« Reply #12 on: April 03, 2003, 11:07:34 AM »
Hi Duncan,

     Do you have the working copy of .procmailrc & .faxitrc ? I am suspecting the ones that I have downloaded from hylafax.org having some problems as the following errors always recorded in my procmail log:

[root@fax relayfax]# procmail: Match on ! "^X-Loop"
        echo "FAX ERROR: You do not have permission to fax.") | $SENDMAIL -t"
procmail: Error while writing to " (formail -r -A"X-Loop: $USER@$FAXHOST" ; \
        echo "FAX ERROR: You do not have permission to fax.") | $SENDMAIL -t"
procmail: Assigning "LASTFOLDER= (formail -r -A"X-Loop: $USER@$FAXHOST" ; \
        echo "FAX ERROR: You do not have permission to fax.") | $SENDMAIL -t"


   Anyone can forward the help will be of greatly appreciated.

   Many thanks in advance




Eric Ng

Duncan

Re: Qmail Procedure
« Reply #13 on: April 28, 2003, 04:26:51 PM »
Not sure. Havnt used this set up for some time. I will have a look around and see if i can find anything.

Regards Duncan