[PREVIOUS CHAPTER] [NEXT CHAPTER]

2 Brief Overview of FML functions

    Please see the file INSTALL.en for the detail on installation, how to
    create mailing lists...

    2.1	Directory structure

    Directory's FML uses consists of two regions. One ($EXEC_DIR in
    makefml) is where executables and libraries exist and another ($ML_DIR
    in makefml) is one under which each ML's home directories. You can
    change these variables when "makefml install".

    	1 $EXEC_DIR in makefml
    	  executable and libraries (e.g. /usr/local/fml)

    	2 $ML_DIR (e.g. /var/spool/ml)

    	2 $ML_DIR (e.g. /var/spool/ml)
              each ML's spool (/var/spool/ml/each-ml)

    	   /var/spool/ml/elena/		(elena ML)
    	   /var/spool/ml/mirei/		(mirei ML)
    	   /var/spool/ml/Freekick/	(Freekick ML)
    	   /var/spool/ml/sakura/	(sakura ML)
    	   /var/spool/ml/tomoyo/	(tomoyo ML)
    	   /var/spool/ml/kerochan/	(kerochan ML)
    	   ...

    /var/spool/ml/elena has config.ph (configuration files), log files,
    spools related to "elena" ML exist only under it.  One directory is
    for one ML. It is closed. We call the directory the ML's home
    (directory).

    2.2	Installer

    "makefml" is simple CUI interface for you. It is an installer and
    configure which provides typical settings. Please see INSTALL.en for
    more details for fundamental settings.  This document is for more
    advanced settings than INSTALL.

    Almost all user defined variables are shown in FML configuration
    file "config.ph". You can control FML by config.ph.

    2.3	On documents

    All documents of plain text version are bundled in a FML distribution
    package. HTML version documents except this "op.*" documents are also
    bundled in it since "op.*" are very large.

    Latest version of documents are available in

    http://www.fml.org/fml/

    2.4	Non-privileged user

    We recommend FML runs as a non-privileged user prepared for this
    purpose. The privileged user should NOT be used as could as
    possible. If you use sendmail, "include" file's owner is the process
    owner of FML (fml.pl).

    MTA runs fml.pl as a user process using setuid() call. The user fml.pl
    switches to the owner of "include" file. MTA must run as a root under
    POSIX standard basis, such as 4.4BSD basis OS's.
    FML trusts MTA can switch to a user. So :include: style is in default.

    If MTA cannot do setuid(), you can use C wrapper. On 4.3BSD, you can
    make C wrapper at the ML's home directory by

    	(shell prompt)% make fml

    fml is setuid()'ed to you (the owner ran "make"). You can have two
    "fml" and "fml-ctl" executables by make. "fml" is a wrapper for the
    address for post, "fml-ctl" is one for command.

    On the other hand on POSIX basis OS's, only "root" process can do
    setuid() call. You need to set up root-setuid()'ed C wrappers. THIS IS
    VERY DANGEROUS. Please set up them with consulting administrators on
    that such as the location of C wrapper ...

    2.5	Dynamic library loading

    FML uses a lot of dynamic loading libraries via perl "require"
    statement. It enables extensions, independent customization, separation
    of maintenance. Libraries are named lib"module-name".pl such as
    libsmtp.pl (SMTP library).

    In default "makefml install" installs executables and libraries to
    one directory e.g. /usr/local/fml. "makefml newml elena" makes a
    mailing list. The home directory is e.g. /var/spool/ml/elena. When FML
    runs, /usr/local/fml/fml.pl runs by reading the configuration
    /var/spool/ml/elena/config.ph and libraries /usr/local/fml/lib*pl.

    2.6	configuration file (config.ph)

    FML provides a lot of variables. You can only configure them in
    config.ph (configuration file). FML provides an interactive interface
    "makefml". You can configure representative variables with "makefml".

    2.7	Access control and automatic registration

    The top menu of "makefml config" shows

       1    POLICY OF ACCESS (WHO CAN POST AND USE COMMANDS)

            [POST]
              PERMIT_POST_FROM                 members_only
              WHEN POST FROM NOT MEMBER        reject

            [COMMAND]
              PERMIT_COMMAND_FROM              members_only
              WHEN COMMAND FROM NOT MEMBER     reject

    	.....

    You can choice the following values for
        * PERMIT POST or COMMANDS FROM WHOM ?
        * IF MAIL COMES FROM NOT MEMBER, WHAT FML DOES?

    The choice for "* PERMIT POST or COMMANDS FROM WHOM ?" is one of

    	anyone
    	members_only	(default)

    The choice of function for "* IF MAIL COMES FROM NOT MEMBER, WHAT
    FML DOES?" is one of

    	reject		(default)
    	auto_regist
    	ignore

    FML checks in-coming mail is from a member or not. It is default. If
    from not member, FML reject the mail and notifies it to the sender. If
    from not member and automatic registrable (auto_regist is selected),
    FML try to do automatic registration.

    2.8	File Operations

    "get", "mget" and "digest" delivery provides a lot of formats. The
    following formats of mails is available.

    	PLAIN TEST
    		UNIX FROM
    		RFC934
    		RFC1153
    		MIME/Multipart

    	COMPRESSED FILE
    		gzip UNIX FROM file
    		tar + gzip
    		uuencode

    	   (used only in Japanese ?)
    		lha + ish
    		lha + uuencode

    FML scans $SPOOL_DIR, @ARCHIVE_DIR for files of target for "mget".

    "library" command enables "put" and "get" via FML whereas "library"
    command permits only "number" as the file name to put.

    2.9	MIME and Base64 decoding

    Fundamentally FML passes MIME header fields through. FML decodes
    Subject: and save it in the summary file (default). If a base64
    decoder is defined, FML decodes the base64 part in mail when a HTML
    article is created.

    2.10	Remote administration

    In default FML disables remote administration.
    If you use remote administration, please set

    	$REMOTE_ADMINISTRATION  = 1;

    You can change this with "makefml config". We check whether the
    command is from an administrator or not with one or mixed ones of
    methods:

    	From: address
    	password authentication
    	PGP authentication

    In default we check a set of "From: address" and "password"
    authentication. If possible, we recommend PGP authentication.

    2.11	.forward

    When you cannot edit /etc/aliases, you can set up an account as a
    mailing list. In that case .forward is "include" file itself.
    It is useful???

    2.12	Listserv/Majordomo

    fmlserv.pl provides listserv(majordomo) style interface such as.

    	command	<ML> command options
    e.g.
    	get elena last:10 mp

    get the latest 10 articles of elena ML with the MIME/multipart format.

    2.13	Communication with MTA (e.g. sendmail)

    FML communicates with MTA via SMTP (Simple Mail Transfer Protocol) to
    deliver a distribution mail. The default configuration is

    	$Envelope{'mci:mailer'} = 'ipc'; (default)

    is 'ipc'. FML makes a connection via SMTP to MTA and sends mail to
    it. If 'prog' is defined, fml.pl executes sendmail ($SENDMAIL) as a
    program and injects the mail to it.

    	$Envelope{'mci:mailer'} = 'prog';

    The default MTA is 'localhost' MTA. Hosts defined in $HOST and @HOSTS
    are also available as a MTA. FML connects via SMTP. If no host runs
    MTA, use 'prog'.

    2.14	When your machine which FML runs on cannot receive mail

    How FML receives mail is a problem. For security some sites prohibit
    MTA to run a program. If so, you can use popfml.pl. popfml.pl connects
    a POP server via POP3, receives mail for a ML and injects it to
    fml.pl.

    2.15	Security

    See 9.0 for more details, e.g.
    	mail traffic monitor to reject mail bombs
    	filtering based on keywords in fields of a header and body

    2.16	Others

    Other topics:

    	* flock(2), If flock(2) does not work, link(2) lock.
    	* relaying. Today relaying is not used.
    	* Automatic expiration, archiving
    	* Newsyslog
    	* crosspost
    	* Star Trek Stardate:

[PREVIOUS CHAPTER] [NEXT CHAPTER]