Hylafax Mailing List Archives

[Date Prev][Date Next][Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: [hylafax-users] Emailing from Scanner/Copier to hylafax]



Ranier,  Thank you for your response.

I guess I'm missing something here.  At what point does hylafax realize
the message isn't formatted correctly?  Somewhere along the way hylafax 
sees the tiff attachment and rejects it.  If I could intercept it at
that point and convert it, it would save me a lot of hassle.

I can't get Procmail (using metamail, munpack, formail, etc) to save the
attachment, convert it, and reassemble.  I just want to intercept
anything from scanner.mydomain.com, convert the tiff attachment, and
forward.  That way I don't have to do a lot of address changing.

Thanks again.  -Jeff Borders

-----Forwarded Message-----

From: Rainer Hantsch <rainer@hantsch.co.at>
To: Jeff Borders <jeff@jeffborders.com>
Cc: hylafax-users@hylafax.org <hylafax-users@hylafax.org>
Subject: Re: [hylafax-users] Emailing from Scanner/Copier to hylafax
Date: 27 Dec 2002 09:56:20 +0100

Hello, Jeff!

First, I want to wish a Happy New Year.


On 25 Dec 2002, Jeff Borders wrote:
| Hello,
| I've got hylafax working fine through postfix.  However, when scanning a
| document through our network scanner/copier and emailing it through the
| hylafax setup, I get "DISCARDED application/pdf GOES HERE".
|
| Plan A:
| I know the scanner emails documents as tiff attachments and that hylafax
| only accepts ASCI or PS files.  Where and how do I intercept this
| attachment and convert it to postscript?  It seems that if it can
| recognize an invalid attachement and discard it, why can't it go ahead
| and convert it with tiff2ps?
|
| Plan B:
| I thought of setting up and forwarding to a netfax user and doing some
| procmail stuff and then forwarding on to hylafax, but I'm not real
| strong with procmail recipes.
|
| TIA- Jeff Borders

Well, BOTH plans appear a little bit too complicated to me. I would do it in a
slightly different way by

a.) Adding an ALIAS into /etc/aliases which does a PIPE into a program or
    shell script. This is the easiest way to feed a mail into your own soft
    and I do this to send my invoices out by FAX or PDF-eMail since a long
    time. (I embed the fax-number and e-Mail address as PostScript comments
    at the top of the file and parse them out in a bash script before pro-
    cessing the PS-file)

    Here a skeleton as suggestion. This is not to be understood as a really
    usable script, but it should give you an idea on how to proceed.
    ---</etc/aliases>--------
    ...
    mailfax:  |/root/bin/sendmyfax.sh
    ...
    ---<eof>-----------------
    Then you have to create an executable /root/bin/sendmyfax.sh (regardless
    which language you use) and let it read in everything from StdIn into a
    file at the very beginning. Then it depends on you how you process this
    mail afterwards.
    ---</root/bin/sendmyfax.sh>---------
    #!/bin/sh
    PATH=/usr/bin:/usr/sbin:/bin:/sbin
    workfile="/tmp/faxwork$$.mail"
    cat - > $workfile

    # Here you do with $workfile whatever you want
    # to get out the TIF file and convert it into
    # PostScript

    sendfax .................  Here you launch the FAX
    #-eof-
    ---<eof>----------------------------

b.) In the case that you have the possibility to enter the recipient's
    FAX number on the scanner (I have absolutely no idea how your scanner
    works with mailing a FAX), you can possibly do something similar to
    a.), but through a network printer queue.


Anyway: I think that it will be much easier in handling if you control the
scanner through a PC and let WHFC or something similar do the transfer to the
FAX-Server.

mfg

  Ing. Rainer Hantsch

.---------------------------------------------------------------------.
|      \\|//              Ing. Rainer HANTSCH  -  Hardware + Software |
|      (o o)              Forget Windoze! -- We focus on L-I-N-U-X... |
|--oOOo-(_)-oOOo------------------------------------------------------|
| Ing. Rainer HANTSCH |  mail: office@hantsch.co.at                   |
| Khunngasse 21/20    |   www: http://www.hantsch.co.at               |
| A-1030 Vienna       |   tel: +43-1-79885380    fax: +43-1-798853818 |
| ** A u s t r i a ** | handy: +43-664-9194382   UID-Nr: ATU 11134002 |
'---------------------------------------------------------------------'



____________________ HylaFAX(tm) Users Mailing List _______________________
  To subscribe/unsubscribe, click http://lists.hylafax.org/cgi-bin/lsg2.cgi
 On UNIX: mail -s unsubscribe hylafax-users-request@hylafax.org < /dev/null
  *To learn about commercial HylaFAX(tm) support, mail sales@hylafax.org.*



Home
Report any problems to webmaster@hylafax.org

HylaFAX is a trademark of Silicon Graphics Corporation.
Internet connectivity for hylafax.org is provided by:
VirtuALL Private Host Services