This chapter describes how a fidoconfig config-file is written, which keywords exist and where to put the file.

Configfile location
===================

The fidoconfig library searches the config file on different locations:

linux:
     /etc/fido/config

freebsd:
     /usr/local/etc/fido/config

os2/win32/etc:
     in the current directory

If you are compile library with huskymak.cfg, the location will be overset with CFGDIR parameter.

Additionally you can set an enviroment variable called FIDOCONFIG which points to the file:

     set FIDOCONFIG=e:\bbs\fidoconfig\config

     FIDOCONFIG=~/fidoconfig/config
     export FIDOCONFIG

The config file(s) must be readable. If you plan to use the autoareacreate feature of HPT / autofilecreate featute of HTick / etc..., the config file must be writeable.

Syntax
======

All symbols are not case-sensitive.

{<whiteSpace>} at the start of the line will be ignored.

All keywords are evaluated as occurring, the first matching keyword found is valid. If there are more then one keywords of the same type allowed, the last line matching the situation is valid. Another words: second definition overwrite the previous one. If no match is found, a default-value will be used.

"#" at the start of a line or <whiteSpace>#<whiteSpace> within the line starts a comment. The comment ends with the line. Comment char "#" can be overwritten by commentChar token.

If the first word in a line is an undefined keyword, program exits with error message.

Each keyword has to start a new line.

Keyword parameters:

<integer>
     string including integer numbers, like: 1234567890

<string>
     text string

<bool>
     may be set to "1", "0", "yes", "no", "on", "off", and also without parameters (it means "on").

<addr>
     address string like zone:net/node[.point][@domain]

     example: 2:5000/117

<file>
     file name. path can be omitted.

<path>
     only path. trailing slash may be included or not.

Note! [<parameter>] means that it can be omitted.

FIDOCONFIG library can set up internal variables:

     set basedir=/home/user/fido/

[OS] variable automatically setting up for following opetaring systems:

UNIX
     All unix-like OS: Linux, *BSD, BeOS, ...

OS/2

WIN

MSDOS

You can set something like:

     if [OS]==UNIX
     tearline `uptime`
     endif

Some programs can be compiled with module variavle. It can be used for config parsing speed up:

     if [module]==htick
     include /etc/ftn/fileareas
     endif

And if HPT is running, fileareas don't parsed, because [module]==hpt.

There are following modules available:

hpt (Highy Portable Tosser)

htick (Husky Tick)

hptutil

Also external variables van be parsed:

     autoexec.bat:
     SET VAR=myvar

     fidoconfig:
     if [VAR]==myvar
     ...
     else
     ...
     endif

     ifdef UNIX
     MsgBaseDir  [home]/msgbase
     endif

You can use external programs output via `cmd`. It is available only for UNIX & OS/2+EMX:

     Name Power Station under `uname -mrs`

List of the additional commands:

     set, if, if not, else, elseif, ifdef, ifndef, endif.

Common keywords for HUSKY-programs
==================================

This keywords may be used by several programs. More specific keywords you can find in the documentation of the individual programs.

version
-------

Syntax:
     version <integer>.<integer>

Example:
     version 0.13

Here you specify to which version of fidoconfig your config belong. Currently this statement does nothing.

This statement cannot be repeated.

name
----

Syntax:
     name <string>

Example:
     name Leetebrok BBS

Here you specify your Systems name.

This statement cannot be repeated.

location
--------

Syntax:
     location <string>

Example:
     location Dusseldorf

You specify your Location here.

This statement cannot be repeated.

sysop
-----

Syntax:
     sysop <string>

Example:
     sysop Matthias Tichy

You specify your name with this keyword.

This statement cannot be repeated.

include
-------

Syntax:
     include <file>

Example:
     include /etc/fido/areas

You can include other files into your config file. For example if you would like to have different config parts, you can include a file and (via cron job or manually) change the content of this file without changing the rest of the config. Additionally you can split your config in different parts. So you can have your fileareas definition in another file than your msgareas definition. This gives your the ability to have some survey about your config.

This statement can be repeated. But dont make recursive includes. eg include a file which includes another which includes the first. Although this will be detected and fixed many times, there is a chance that it will not be detected one time.

address
-------

Syntax:
     Address <addr>

Example:
     Address 2:2433/1245

This command specifies which akas your system has. This statement is full 5d compatible, which means you can have also addresses like 2:2433/1245.1@fidonet.org. The first address statement is your main aka which will be used by tossers on different occasions, for example if zone number could not be taken from the @INTL Kludge in netmails.

This statement can be repeated. The domain name is not full supported throughout fidoconfig

commentChar
-----------

Syntax:
     commentChar <char>

Example:
     commentChar ;

This command specifies which symbol is used to mark rest of line as comment. Default is '#'

This statement can be repeated.

outbound
--------

Syntax:
     outbound <path>

Example:
     outbound /var/spool/fido/out

This command specifies your outbound path. This outbound path is binkley-style. A binkley style outbound consists of a base path and subdirectories. Each subdirectory represents a place for all the files for one zone. The base path is the zone path for your base zone.

Example:

     /var/spool/fido/out
          This directory contains the files for your base zone.

     /var/spool/fido/out.003
          This directory contains the files for zone 3.

     /var/spool/fido/out.00A
          This directory contains the files for zone 10.

The zone directory contains the flow-files for each node. A Flow-file of a node has the name NNNNFFFF.?lo

     NNNN
          The 4-digit hex-number of the nodes netnumber.

     FFFF
          The 4-digit hex-number of the nodes nodenumber.

     ?
          Here the flavour of the mails can be chosen. h-hold, c-crash,
          f-normal, d-direct, i-immediate.

For points there is a subdirectory with nodes flowfilename with suffix.pnt. In this subdirectory the flowfiles have the names PPPPPPPP ( 8-digit point number in hex).

For a deeper background on a binkley-style outbound see the binkley-term documentation and source code.

This statement cannot be repeated.

inbound
-------

Syntax:
     inbound <path>

Example:
     inbound /var/spool/fido/in

This command specifies where your inbound files are stored. This directory is the base directory which means if you have a connection which ist not protected and the other system is not listed. The files go in here. Only netmails are tossed from this inbound.

This statement cannot be repeated.

tempDir
-------

Syntax:
     tempDir <path>

Example:
     tempDir /var/tmp

This command specifies the path where the temporary files of the fido-programs should be stored. This directory can erase in boot time.

Good idea is set it to memory disk.

This statement cannot be repeated.

logfiledir
----------

Syntax:
     logFileDir <path>

Example:
     logFileDir /var/spool/log/fido

This command specifies the path where the log-files of the fido-programs should be stored.

This statement cannot be repeated.

Some programs use logFileDir for persistent temporary/work files.

syslogfacility
--------------

Syntax:
     syslogFacility <facility>

Example:
     syslogFacility local0

Some Husky programs are able to write logs via syslogd instead of via log file. For those programs, this keyword definies which facility to use for writing to the syslog. Syslogd will use this facility name to decide which syslog logfile the log messages will go to. Common names that can be used include mail, news, uucp, local0. The exact values that can be used depend upon your operating system. Refer to the man page for syslog.conf or /usr/include/sys/syslog.h for more information.

Logging via syslogd is only supported on UNIX platforms, and currently only used by herp, but not by any other Husky program. If a Husky program logs via log file or via syslog or both depends on the program and not on your fidoconfig file. Consult the individual program's documentation.

LogLevels
---------

Syntax:
     loglevels <string>

Example:
     loglevels 345789

In example we output to log messages with levels 3,4,5,7,8,9.

The log levels are following:

1 - Program start, end;

2 - dupecheck

3 - linking messages

4 - scanning messages

5 - posting messages

6 - execute strings

7 - bundles, pkts, links, freqs, file routing, file attachs, msg packing

8 - areafix, relink, autocreate

9 - error messages (critical: exit on error)

0 - creation of file-flags

A - (reserved for) trivial error messages (print message and continue execution)

B - warnings & alerts

C - informational messages

D - (reserved for) statistics

E - summary

F - print program name & version

G - message send/sent

H - (reserved for) recoding operations & recoding tables read/write

I - Generate or check MSGID

J - Echomail phase

K - Filebox phase

L - Netmail phase

M - File create

N - File delete

O - operations with opened file (read, write, seek, ...)

P - Directory operations (create, delete, rename, ...)

R - Truncate file

S - File send/sent

T - Test files (exist, permittions, etc.)

U - Functions calls (enter to func & leave from it)

V - reserved

W - reserved

X - Filenames construct

Y - reserved

Z - debug messages: source lines (functions control points).

a-z - debug messages

Default value: 1234567890ABCDEF

This statement cannot be repeated.

ScreenLogLevels
---------------

Syntax:
     screenloglevels <string>

Example:
     screenloglevels 2345789

Set level of log output to screen. See loglevels for details.

This statement cannot be repeated.

link
----

Syntax:
     link <string>

Example:
     link Matthias Tichy

This statement starts a new Link-definition. All the following link-related statements change the configuration of this link until a new link statement is found. The name is the name of this link.

This statement can be repeated.

linkdefaults
------------

Syntax:
     linkdefaults [begin | end | destroy]

Example:
     linkdefaults

This statement starts section of default definitions of links. All the following link-related statements change default configuration of link until a 'link' or 'linkdefaults end' or 'linkdefaults destroy' statement is found. All parameters collected in linkdefaults sections are copied to link configuration every time when 'link' statement found in configuration file. Link-related statements after 'linkdefaults end' or 'linkdefaults destroy' or before first 'link' or 'linkdefaults' statement are treated as error. 'linkdefaults' statement without 'begin' or 'end' means 'linkdefaults begin' 'linkdefaults destroy' destroys all default definitions.

Be careful with Pause, Export, etc. ;-)

This statement can be repeated. New definitions overwrite old ones.

aka
---

Syntax:
     aka <addr>

Example:
     aka 2:2433/1245

This statement sets the aka for the current link.

This statement can only be repeated for different links.

ouraka
------

Syntax:
     ouraka <addr>

Example:
     ouraka 2:2433/1247

This statement sets the aka which is used with this link.

This statement can only be repeated for different links.

password
--------

Syntax:
     password [<string>]

Example:
     password secret

This statement sets the default password for the link. If you do not change the other passwords, they are set to this password.

This statement can only be repeated for different links.

pktpwd
------

Syntax:
     pktpwd [<string>]

Example:
     pktpwd geheim

This statement sets the pktpassword for the actual link. Only passwords with maximal 8 characters are valid because of limitations of other software packages. An empty statement is allowed.

This statement can only be repeated for different links.

ticpwd
------

Syntax:
     ticpwd [<string>]

Example:
     ticpwd geheim

This statement sets the ticcer password for the actual link. Only passwords with maximal 8 characters are valid because of limitations of other software packages. An empty statement is allowed.

This statement can only be repeated for different links.

areafixpwd
----------

Syntax:
     areafixpwd [<string>]

Example:
     areafixpwd geheim

This statement sets the areafix password for the actual link. An empty statement is allowed, but not recommended.

This statement can only be repeated for different links.

filefixpwd
----------

Syntax:
     filefixpwd [<string>]

Example:
     filefixpwd geheim

This statement sets the filefix password for the actual link. An empty statement is allowed, but not recommended.

This statement can only be repeated for different links.

bbspwd
------

Syntax:
     bbspwd [<string>]

Example:
     bbspwd geheim

This statement sets the bbs password for the actual link. An empty statement is allowed.

This statement can only be repeated for different links.

sessionpwd
----------

Syntax:
     sessionpwd [<string>]

Example:
     sessionpwd geheim

This statement sets the session password for the actual link. An empty statement is allowed.

This statement can only be repeated for different links.

handle
------

Syntax:
     handle <name>

Example:
     handle eddie

This statements gives a link a nickname. This statement is supposed for bbs systems.

This statement can only be repeated for different links.

packer
------

Syntax:
     packer <packer>

Example:
     packer zip

This statement sets the packer for the link. You can use the packer which you has set up using the pack statement. If you omit this statement or set packer none no mail will be packed. The pkt´s will be put in the outbound.

This statement can only be repeated for different links.

badarea
-------

Syntax:
     BadArea <name> <file> [-b <msgbase>] [Options]

Example:
     BadArea badarea /var/spool/fido/msgb/bad -b Squish

This statement specifies the BadArea. Read documentation of HPT for details.

This statement cannot be repeated.

dupearea
--------

Syntax:
     dupeArea <name> <file> [-b <msgbase>] [Options]

Example:
     dupeArea dupeArea  /var/spool/fido/msgb/dupes -b Squish

This statement specifies the DupeArea. Read documentation of HPT for details.

This statement cannot be repeated.

echoarea
--------

Syntax:
     EchoArea <name> <file> [-b <msgbase>] [Options] [linkAKAs] [linkOptions]

Example:
     EchoArea linux.develop.ger /var/spool/fido/msgb/linux.develop.ger -b Squish -a 2:2433/1247 -g A -dupeCheck move -dupehistory 11 -d "Linux development" 2:2433/1245 -def

This statement specifies the echoareas. Read documentation of HPT for details.

This statement can be repeated.

netmailarea
-----------

Syntax:
     NetmailArea <name> <file> [-b <msgbase>] [Options]

Example:
     NetmailArea netmail /var/spool/fido/msgb/netmail -b Squish

This statement specifies the NetMailArea. Read documentation of HPT for details.

This statement can be repeated.

localarea
---------

Syntax:
     LocalArea <name> <file> [-b <msgbase>] [Options]

Example:
     LocalArea MyBBSarea /var/spool/fido/msgb/MyBBS -b Squish

This statement specifies the LocalArea: messages area in BBS. Read documentation of HPT for details.

filearea
--------

Syntax:
     FileArea <name> <fileareapath> <uplink> [options] [<downlinks>]

Example:
     filearea Photoes /var/spool/fido/fileecho/Photoes 2:50/1 -d "Sysop photoes"

This statement specifies the FileArea: fileecho definition. (Read documentation of HTick for details.)

bbsarea
-------

Syntax:
     bbsarea <name> <bbsareapath>

Example:
     BBSarea Incoming /var/spool/fido/BBS/incoming

This statement specifies the BBSArea: BBS file area definition. It's use for filelist building. Read documentation of HTick for details.

High Portable Tosser keywords
=============================

This section contains only keyword-list. Read HPT Manual for more info.

          [file keywords.hpt not included]

NLTools keywords
================

nodelistDir
-----------

Syntax:
     nodelistDir <path>

Example:
     nodelistDir /var/spool/fido/nodelist

This command specifies the path where the actual nodelists are or should be written to. This path contains the raw nodelist (see nodelist). Also, compiled nodelists like the FIDOUSER.LST will be stored here.

This statement cannot be repeated.

fidoUserList
------------

Syntax:
     fidoUserList <filename>

Example:
     fidoUserList fidouser.lst

If this keyword is present, the nodelist compiler (e.g. ulc) is instructed to build a user list file with the given filename in the nodelist directory (see nodelistdir). This is a simple text file with fixed line length that contains user names (nodes, points) and their corresponding node or pointnumbers. The file is sorted alphabetically by user name (case insensitive), so that it can be bsearched to implement a quick node numer lookup functinality. The fido user list file format is understood by msged, for example.

nodelist
--------

Syntax:
     Nodelist <name>

Example:
     Nodelist nodelist or Nodelist points24

This statement starts a new nodelist definition. All the following nodelist-related stamtements change the configuration of this nodelist until a new nodelist statement is found.

The name that you specify must match the base name (without extension and without pathname) of the raw, unpacked, nodelist file. The husky tools ulc and nlupdate math the file name case-insensitively, but other tools may need the exact spelling. The raw nodelist file is expected to reside in the nodelist directory (see nodelistdir).

diffupdate
----------

Syntax:
     DiffUpdate <path_and_basname>

Example:
     DiffUpdate /var/spool/filebase/nodediff/nodediff

Here you can specify the base filename of nodelist difference files (nodediffs) that are used to keep the corresponding nodelist up to date. The argument to the DiffUpdate is the full file name with path of a difference file, without the file extension. For example, if you have a file area at /var/spool/filebase/24000, where your ticker places the updates for the German Pointlist, and those update files are called points24.a26, points24.a33, and so on, you would use

     DiffUpdate /var/spool/filebase/24000/points24

The Diffupdate keyword is used by nlupdate, for example. The nodelist updater will unpack the difference file (if it is archived, of course, unpacked diffs are also supported), apply the diff to the corresponding nodelist, and delete the temporary unpacked diff again.

fullupdate
----------

Syntax:
     FullUpdate <path_and_basname>

Example:
     FullUpdate /var/spool/filebase/nodelist/nodelist

This statement works like DiffUpdate (see diffupdate). The difference is that here you don't specify the location of a nodelist difference file, but the locations where complete nodelist files/archives can be found. Some othernets do not (regularly) distribute a nodediff file, but just hatch a new nodelist every few weeks. In this case, you need the FullUpdate statement.

defaultzone
-----------

Syntax:
     DefaultZone <zone>

Example:
     DefaultZone 2

Some nodelist files do not start with a Zone entry. This is the case for the German Points24 list, for example, but could also happen for othernets that only have one zone. In this case, you can use the DefaultZone keyword to specify the default zone number for all nodes listed in this nodelist.

nodelistformat
--------------

Syntax:
     Nodelistformat <format>

Example:
     NodelistFormat standard or NodelistFormat Points24

Here you can specify the format of the unpacked nodelist. The default is standard; this is the normal Fidonet nodelist format. You can also specify points24, which is needed for the nodelist compiler to recognise a point list in the German points24 format as such, so that it can see the proper 5D point numbers instead of the fakenet numbers.

EmailPkt keywords
=================

email
-----

Syntax:
     sendMailCmd string

Example:
     sendMailCmd /usr/sbin/sendmail $a <$f

This keyword is used to define send mail command & it's parameters. Macro '$a' specify position of the recipient e-mail address; macro '$f' specify position for name of file with message body. If '$f' omitted then message body to be directed to stdin.

This statement can't be repeated.

email
-----

Syntax:
     email <email-address>

Example:
     email eddie@ironmaiden.com

This keyword is used to set the email-address for the link. This can be used to send pkts via email.

This statement can only be repeated for different links.

emailFrom
---------

Syntax:
     emailFrom <email-address>

Example:
     emailFrom fred@ironmaiden.com

This keyword is used to set the email-address used as sender address for outgoing emails to this link.

This statement can only be repeated for different links.

emailSubj
---------

Syntax:
     emailSubj <subject>

Example:
     emailSubj Fido over EMail message in UUE format

This keyword is used to set the subject for emails to and from this link. It may be ignored by some encodings (e.g. SEAT).

This statement can only be repeated for different links.

email
-----

Syntax:
     emailEncoding (MIME | SEAT | UUE)

Example:
     emailEncoding MIME

This keyword is used to set the encoding for outgoing emails to this link.

This statement can only be repeated for different links.

BSOpack keywords
================

This section contains only keyword-list. Read BsoPack Manual for more info.

          [file keywords.bp not included]

herp keywords
=============

Herp is the Husky External file Request Processor. The following fidoconfig keywords are specific to herp. Some programs of herp, in particular herpidx, also use part of the htick configuration, i.E. filearea definitions.

reqidxdir
---------

Syntax:
     reqidxDir <path>

Example:
     reqidxDir /var/spool/fido/reqidx

This command specifies a subdirectory which will be used to store the request index generated by herpidx. This subdirectory should be writable for the herpidx process and at least readable for the user under which your mailer and herp will be run. herpidx will place various request index files here. The subdirectory should not be used for any other purposes. The index can become rather large, so plan for enough free disk space.

Working sample config
=====================

          [file config not included]