ftpd conversions database
The conversions known by
and their attributes are stored in an ASCII file that
is structured as follows:
Each line in the file provides a description for a single
The colon-separated fields have the following meanings:
Prefix and postfix
The prefix fields are not currently supported.
The postfix fields define extensions to be added or removed from
The addon postfix field is
assumed to have been appended to a real filename and is
removed prior to looking up the file.
The strip postfix field is appended to the user-supplied filename
before looking up the file.
The filename that results is available for use in the
external command field by using the magic cookie ``%s''.
The external command must be specified using an absolute pathname.
For anonymous users to be able to execute the command, it must be
present in the home directory hierarchy of the anonymous user.
The following types are defined:
These types may be used prevent the
transfer of compressed files in ASCII mode
or attempts to compress directories.
allow ASCII transfer of a file resulting from a conversion
allow directories to be converted
allow regular files to be converted
More than one type may be specified by separating them with
the ``|'' character.
The following built-in options are known to the FTP server
and will cause special information to be displayed in the
FTP server log file (see
if transfers are being logged.
More than one option may be specified by using the
``|'' character to separate the options.
file was compressed during transfer
file was tar'ed during transfer
file was uncompressed during transfer
The following example shows a conversion that causes files
whose names end in .tar to have their suffix removed.
The resulting filename is used as an argument to the
The transfer is not allowed to be performed in
ASCII mode (T_ASCII is not specified)
and a special ``TAR'' flag will be
written to the transfer log.
: : :.tar:/usr/bin/tar -cf - %s:T_REG|T_DIR:O_TAR:TAR
Operations other than archival and compression are possible.
The next example shows a conversion that causes the contents of
a file whose name ends with the extension .txt
to be converted from code set 88591 to PC850.
This produces a file with the same name but with the
extension .850 instead of .txt.
Note that this transfer is also not allowed to be
performed in ASCII mode.
:.txt: :.850:/usr/bin/iconv -f 88591 -t PC850 %s:T_REG:O_COMPRESS:ICONV
© 2004 The SCO Group, Inc. All rights reserved.
UnixWare 7 Release 7.1.4 - 25 April 2004