faxspool - queue and convert files for faxing with sendfax(8)
faxspool [options] phone-number files...
Queue the named files for later transmission with sendfax(8) . The input files are converted to G3 fax files, spooled to /var/spool/fax/outgoing/<dir>/f*.g3, and queued for transmsssion to the fax address “phone-number".
On top of each page, faxspool puts a header line, telling the other side the number of pages, your fax id, ..., whatever you like. The format of this line is configurable via the file /usr/local/etc/mgetty+sendfax/faxheader and per-user via the file $HOME/.faxheader. (you can select another one with the “-h” option, for example, one for your business faxes and one for the private stuff).
This file should contain a few lines of text, normally only one line, but more than one line is permitted. The text may use the tokens @T@ for the remote telephone number, @U@ for the sending user name, @N@ for his full name (fifth field of /etc/passwd, if not given with “-F"), @P@ for the page number and @M@ for the total number of pages. @D@ will be replaced by the string specified with the “-D” option (see below), @DATE@ will be substituted by the output of the ‘date‘ command, and @ID@ stands for the sender’s fax number (FAX_STATION_ID). Finally, @S@ will be substituted by the JOB ID (Fxxxxxx).
If “phone-number” contains non-numeric characters, faxspool interprets it as an alias and tries to look it up in the files /usr/local/etc/mgetty+sendfax/faxaliases and $HOME/.faxnrs. These files have a very simple format: one line per alias, alias name first, whitespace (tab or blank), phone number. Optionally, you can place a short description of the receiver after the phone number, this will be used as if it had been specified with “-D” (an explicit “-D” flag overrides this).
Example: gert 0893244814 Gert Doering
Access control is handled similar to the way “crontab” does it: if a file /usr/local/etc/mgetty+sendfax/fax.allow exists, only those users listed in that file (one name per line) may use the fax service. If it does not exist, but a file /usr/local/etc/mgetty+sendfax/fax.deny exists, all users but those listed in that file may use faxspool(1) , and if neither file exists, only root may send faxes. (Note: if the user name in the fax.allow file is followed by a blank, the rest of that line is ignored. Some other fax spooling software uses this to store additional information about the user sending the request).
Optionally, faxspool can generate user-customizable fax cover pages. It is quite easy to set up: if a file /usr/local/lib/mgetty+sendfax/make.coverpg exists and is executable, it is run with all relevant source/destination data on the command line, and its output is sent as the first page of the resulting fax. If $HOME/.make.coverpg exists, this file is used instead. See coverpg(1) for details.
The special program name “-” is used to specify “no coverpage at all".
No message is issued if the program isn’t found, or cannot be executed, faxspool will simply queue the fax without cover page.
The default cover page program used is $HOME/.make.coverpg; if this file doesn’t exist /usr/local/lib/mgetty+sendfax/make.coverpg is used. (However, if $HOME/.make.coverpg exists, but is not executable, no coverpage is used at all.)
fax spool directory
global fax alias file
private fax alias file
list of allowed users
list of denied users
default fax page header
program to create fax cover page (see coverpg(1) ).
/usr/local/etc/mgetty+sendfax/faxspool.rules program to control which file extentions are recognized (.txt, .ps, ...) and how those file formats should be converted to G3.
this a small C helper program that facilitates access to the fax spool queue (which is since mgetty 1.1.29 no longer world-writeable)
faxspool is not too smart about recognizing file types
Use of faxspool -n with bitmap files may give wrong results, depending on the aspect ratio of the input files.
Multicasting with the -m and -M options is not implemented yet.
g3cat(1) , pbm2g3(1) , sendfax(8) , faxrunq(1) , faxrunqd(8) , faxq(1) , faxqueue(5) , coverpg(1)
faxspool is Copyright (C) 1993-2002 by Gert Doering, <firstname.lastname@example.org>. Access control and alias handling suggested by Caz Yokoyama, <email@example.com>.
Table of Contents