LinFBB 7.0.10 released

  Released version 7.0.10 of Linfbb. Great news……

Download it at https://ham.packet-radio.net/packet/f6fbb/linux/recent-version/fbb-7.0.10.tar.gz
Source Link  https://sourceforge.net/projects/linfbb/files/fbb-7.0.10.tar.gz/download

Some info from Dave.

Many thanks to Brian (N1URO) for his maintenance scripts contribution and to Paul (G4APL) for his extensive tests and feedback regarding some old bugs and their fixes. Also many thanks to all other sysops using and testing the development version in the SVN repo prior to this release.

Changslog

7.0.10 (Dave van der Locht) Add date 1 Nov 2020
[r187]
- Fixed gateway using wrong FROM callsign with outgoing socket connections.
- Fixed gateway could only use port 1 to 9.
- New 20_epurmess and 20_epurwp maintenance scripts (N1URO).
- Fixed pagination issue with ? command, C (remove paging) didn't work.
- Cleaned obsolete code, fast_fwd was hard set to 1 in init.c but only used 
  in some 'if' statements. 
- Corrected satdoc.c line 384 gcc compiler warning (-Wstringop-overflow)
- Corrected behaviour of /K and /L sysop commands
- Fixed buffer overflow possibility in ibm.c getcurdir()
- Corrected several misleading indentations
- Cleaned code and comments in xfbbd.c
[r188]
- Fixed problem where inbound connections were disconnected after connect.
  with some port types when port in port.sys was higher than 9.
- Commented debugging printf code in the call_nbdos() function.
- Changed version number to 7.0.10.
[r189]
- Set SVN file properties accordingly for executable files.
- Placed autogen.sh script back in the SVN repo.
[r190]
- Fixed gateway J command only could show port 1 to 9 heard lists.
- Fixed mailbox J# command only could handle J1 to J8 (numeric) ports.
- Extended mailbox J# command (letters) a bit.
[r191]
- Detected and corrected some character encoding problems in tnc.c file.
[r192]
- Removed autotool generated files from SVN repo.
[r193]
- Accidentally removed Makefile.am. Placed back into SVN repo.
[r194]
- Fixed filename not exists error when using YAPP download command (YD).
[r195]
- Fixed housekeeping routines crashing on several newer Linux distributions.
- Changed src/Makefile.am, the -fstack-check flag conflicts with
  -fstack-clash-protection which is included by default when GCC is built with
  stack smashing protection (SSP).
- Changed README to reflect correct mailing list e-mail address.
*******************************************************************************

G0LGS LinFBB Tools

Stewart has sent me a link with the scripts and programs he wrote for LinFBB. I copied them to my own server for historical purposes. Thanks Stewart.

This is the source link

https://www.g0lgs.co.uk/MyDownloads.php?fbclid=IwAR3nXpC0ET0mBre9tFYAX0LSoW6YYOqflsEag2XF4j_1wNvUUA89JoOjK4Q

XFBB AutoResp Server 0.11 Jan 2005 XFBB AutoResp Server
XFBB m_filter and f_filter 0.60 20/03/2005 XFBB m_filter and f_filter
XFBB Event Notification system 0.14 23/04/2005 XFBB Event Notification system
XFBB BID Tool 1.00beta 31/07/2005 XFBB Bid Tool
XFBB INF Tool 0.15 Jan 2002 XFBB INF Tool
XFBB Message Renumbering tool 0.36 16/01/2005 XFBB Message Renumbering tool
XFBB Lotto number generator 0.10 13/01/2001 XFBB Lotto number generator
XFBB Multi Server 0.55 24/12/2001 XFBB Multi Server
XFBB Ping Server 0.14 02/10/2005 XFBB Ping Server
XFBB File Servers: REQDIR / REQFIL / LOCAL 0.61 03/02/2005 XFBB File Servers: REQDIR / REQFIL / LOCAL
XFBB Statis file manager 0.12 30/01/2005 XFBB Statis file manager
XFBB TeleText Server 0.24 23/12/2001 XFBB TeleText Server
XFBB WP Tool 0.33 12/07/2002 XFBB WP Tool

Fbb problem showing .HLP and .ENT file

Donnie WD1F has some trouble to get the english.hlp and the english.ent files to show up in fbb. He found the solution.

connecting from remote TNC...
cmd:c wd1f-7
*** CONNECTED to WD1F-7
S (H for help) >
rm
There are no such messages (message choice: *).
(1) WD1F BBS (H for help) >
H
{nothing happens}

All the files are there with the right permissions.

root@ks1r:/etc/ax25/fbb/lang# strace -e open -p 2457 
strace: Process 2457 attached 
open("/var/ax25/fbb/inf.sys", O_RDWR)   = 10 
open("/var/ax25/fbb/wp/wp.sys", O_RDWR) = 10 
open("/etc/ax25/fbb/lang/english.ent", O_RDONLY) = 10 
open("/etc/ax25/fbb/lang/english.hlp", O_RDONLY) = 10
Dir of /etc/ax25/fbb/lang
root@ks1r:/etc/ax25/fbb/lang# l 
total 248 
-rw-r--r-- 1 root root   179 Feb  6 11:29 english.ent 
-rw-r--r-- 1 root root   179 Feb  6 11:13 english.ent.sample 
-rw-r--r-- 1 root root 62459 Feb  6 11:13 english.hlp 
-rw-r--r-- 1 root root 62459 Feb  6 11:26 ENGLISH.hlp 
-rw-r--r-- 1 root root   743 Feb  6 11:13 english.inf 
-rw-r--r-- 1 root root 12428 Feb  6 11:13 english.txt 
-rw-r--r-- 1 root root 12428 Feb  6 11:26 ENGLISH.txt 
-rw-r--r-- 1 root root   155 Feb  6 11:13 francais.ent.sample 
-rw-r--r-- 1 root root 51417 Feb  6 11:13 francais.hlp 
-rw-r--r-- 1 root root   777 Feb  6 11:13 francais.inf 
-rw-r--r-- 1 root root 14783 Feb  6 11:13 francais.txt 
root@ks1r:/etc/ax25/fbb/lang#

I found my problem and it wasn’t easy. In case others have this issue…
The issue was: Pressing H would not give me the help file. After getting it working I see I was missing other things as well like lots of the welcome text.

open("/usr/local/etc/ax25/fbb/lang/english.hlp", O_RDONLY) = 8 
fstat(8, {st_mode=S_IFREG|0644, st_size=62459, ...}) = 0 
mmap(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f2bba612000 
read(8, "################################"..., 4096) = 4096 
read(8, "erver menu, and continue from\nth"..., 4096) = 4096 
read(8, "information on one special comma"..., 4096) = 4096 
read(8, "   -  Download a file with AUTOB"..., 4096) = 4096 
read(8, "he current line.  The number can"..., 4096) = 4096 
read(8, "T new in 5.15b\n@@ 9 BGET\n\nComman"..., 4096) = 4096 
close(8)                                = 0 
munmap(0x7f2bba612000, 4096)            = 0 
lseek(4, 0, SEEK_SET)                   = 0 
read(4, "MemTotal:       32896168 kB\nMemF"..., 999) = 999 
write(3, "\r- Type ? [COMMAND] for the HELP"..., 250) = -1 EMSGSIZE (Message too long)

duckduckgo.com search showed EMSGSIZE (Message too long) had to do with packet sizes allowed. Made me think it may relate to max packet length setting in axports
The fix was:

in /etc/ax25/axports…
name Call speed paclen window desctiption
1 WD1F-1 9600 128 2 144.01 MHz (1200 bps)

I had to set paclen to 255 like this:
1 WD1F-1 9600 255 2 144.01 MHz (1200 bps)

Linfbb maintenance scripts modified.

Brain n1uro has write a script to getting reports sent to you nightly from your maintenance.

/usr/local/lib/fbb/script/maintenance/20_epurmess

#!/bin/bash
LIBDIR=/usr/local/lib/fbb
SYSOP=`/usr/local/sbin/fbbgetconf sysmail`
HADD=`/usr/local/sbin/fbbgetconf call`
MAIL=/usr/local/var/ax25/fbb/mail/mail.in

echo
echo "--- Running epurmess"
echo

$LIBDIR/tool/epurmess
ret=$?

echo "SP $SYSOP@$HADD" >> $MAIL
echo "MSG MAINT at $HADD" >> $MAIL
cat /usr/local/var/ax25/fbb/epurmess.res >> $MAIL
echo "/EX" >> $MAIL
exit $ret

/usr/local/lib/fbb/script/maintenance/20_epurwp

#!/bin/bash
LIBDIR=/usr/local/lib/fbb
MAIL=/usr/local/var/ax25/fbb/mail/mail.in
SYSOP=`/usr/local/sbin/fbbgetconf sysmail`
HADD=`/usr/local/sbin/fbbgetconf call`

echo
echo "--- Running epurwp"
echo

$LIBDIR/tool/epurwp 40 90
ret=$?

echo "SP $SYSOP@$HADD" >> $MAIL
echo "WP MAINT at $HADD" >> $MAIL
cat /usr/local/var/ax25/fbb/epurwp.res >> $MAIL
echo "/EX" >> $MAIL
exit $ret

I have some trouble to get things going so i change some line in the scipt.

I have change the line

SYSOP=`/usr/local/sbin/fbbgetconf sysmail`
HADD=`/usr/local/sbin/fbbgetconf call`

to

SYSOP=`/usr/local/sbin/fbbgetconf -f /usr/local/etc/ax25/fbb/fbb.conf sysop`
HADD=`/usr/local/sbin/fbbgetconf -f /usr/local/etc/ax25/fbb/fbb.conf call`

fbbgetconf needs a option.

Output off the script.

R:180115/0001Z @:PI8LAP.#ZL.NLD.EURO #:20813 [Kortgene] $:20813_PI8LAP

From: PI8LAP@PI8LAP.#ZL.NLD.EURO
To  : PD2LT@

1515974462

File cleared  :   33 private message(s)    
              : 5664 bulletin message(s)   
              : 4665 active message(s)     
              : 1032 killed message(s)     
              : 5697 total message(s)      
              :    8 archived message(s)   
              :   44 destroyed message(s)  
              :    0 Timed-out message(s)  
              :    0 No-Route message(s)   

Start computing     : 18-01-15 02:01
End computing       : 18-01-15 02:01
R:180115/0001Z @:PI8LAP.#ZL.NLD.EURO #:20814 [Kortgene] $:20814_PI8LAP

From: PI8LAP@PI8LAP.#ZL.NLD.EURO
To  : PD2LT@

1515974462

WP updated :   249 total record(s)      
           :     0 updated record(s)    
           :     1 deleted records(s)   
           :     0 WP update line(s)    

Start computing     : 18-01-15 01:01
End computing       : 18-01-15 01:01

 

fbb start file for linux

Fbb start file

#! /bin/bash
### BEGIN INIT INFO
# Provides:          F6FBB Start-up
# Required-Start:    $remote_fs $syslog $network
# Required-Stop:     $remote_fs $syslog $network
# Default-Start:     2 3 4 5
# Default-Stop:      0 1 6
# Short-Description: FBB start up
# Description:       This script provides the start/stop control
#                    for the FBB BBS Packet Radio BBS.
### END INIT INFO

export PATH=/bin:/usr/bin:/sbin:/usr/sbin:/usr/local/bin:/etc/ax25:/usr/local/etc/ax25:/usr/local/xnet

base=${0##*/}
link=${base#*[SK][0-9][0-9]}

test $link = $base && START_FBB=yes
test "$START_FBB" = yes || exit 0
test -x /usr/local/sbin/fbb || exit 0

return="Done"
case "$1" in
start)
        echo "Starting FBB daemon "
        if [ -f /usr/local/etc/ax25/fbb/fbb.conf ] ; then
                /usr/local/sbin/fbb -s -a -l /etc/ax25/fbb.log || return=$rc_failed
        else
                echo  "/usr/local/etc/ax25/fbb/fbb.conf file not found"
                return="Failed"
        fi
        echo  " $1 $return"
        ;;
stop)
        echo "Shutting down FBB script"
        killall -KILL fbb || return="Failed"
        echo "Shutting down FBB daemon"
        killall -KILL xfbbd || return="Failed"
        sleep 4
        echo  " $1 $return"
        ;;
restart|reload)
        $0 stop && $0 start
        ;;
status)
        echo -n "Checking for FBB daemon: "
        PID=`/bin/pidof -x xfbbd`
        if [ -n "$PID" ]; then
                echo  "FBB is up"
         else
                echo "No FBB daemon"
        fi
        ;;


*)
        echo "Usage: $0 {start|stop|status|restart}"
        exit 1
esac

exit 0

Linfbb port.sys

Voorbeeld van port.sys die ik gebruik voor pi8lap

# BBS port.sys
#
# Number of Com Ports (not including Com 0) and TNCs
  3      10
#
# Interface 7 = TCPIP
# Interface 9 = LINUX
#
#Com Interface Adress (Hex)  Baud
 1   9           0       115200
 2   9        189C         0
 3   9        189D:189E:77       0
#
# Maxframe: The maximum number of frames the TNC will send at a time.
# NbFwd   : Number of channels for OUTGOING forward at the same time.
# MxBloc  : Size of forward-block in Kb.
#
# M/P-Fwd : Minute of the hour for start of forward, and period
#           (how many minutes between each forward-start).
# Mode    : One of these:
#           B : BBS-mode.
#           G : "Guest"-mode.
#           U : Normal-mode.
# Type host-mode, one of these:
#           D : WA8DED
#           K : KAM hostmode.
#           M : Telephone-modem.
#           P : PK-232
#           Q : BPQ v 4.x
# Addition: One of these letters can be used too:
#           L : Send unproto beacon after each arriving mail.
#           Y : Yapp allowed on this QRG.
#           W : Gateway allowed TO this QRG.
#           R : Read-Only acces.
#           E : Recommanded by JP F6FBB
#
# Freq.   : Text to describe this port (max 9 characters, no space)
# Same number of lines as number of TNCs.
#
#TNC NbCh Com MultCh   Pacln Maxfr NbFwd MxBloc M/P-Fwd  Mode  Freq
  0   0    0   0        0     0     0     0      00/01   ----  File-fwd.
  1   4    1   ax0      128   4     2     10     15/60   XULWY 144.850
  2   4    1   ax1      128   4     2     10     15/60   XULWY 430.950
  3   4    1   ax2      128   4     2     10     15/60   XULWY Node
  4   10   2   0        250   7     4     10     15/15   TUY   Telnet
  5   10   1   nr1      250   4     2     10     30/15   XUWY  NetRom
  6   10   3   0        250   7     4     10     00/10   SU    Pop/smtp
  7   10   1   rose0    250   4     4     10     30/15   XUWY  Rose
  8   10   1   ax4      250   4     4     10     30/15   XUWY  Axudp
  9   10   1   ax5      250   4     4     10     30/15   XUWY  Axip
 10   10   1   ax6      250   4     4     10     30/15   XUWY  Jnos
#
# Special callsigns and modes for some channels
# TNC Nbs Callsign-SSID Mode
# 1    2   XXXXX-1       B
#
# End of file

 

Monitor script F6fbb

Brain N1URO has written a script to see if fbb is still running.
I saved this script in the fbb directory.
/usr/local/etc/ax25/fbb

Have it saved as “fbbcheck” now it is possible to call it via a cronjob every hour.

Edit the /etc/crontab file and add the following.

15 *    * * *   root    /usr/local/etc/ax25/fbb/fbbcheck

Now, every 15 minutes after the full hour, it is checked whether fbb is still running, otherwise it will be restarted.

Here under the “fbbcheck” script.

#! /bin/sh

. /lib/lsb/init-functions

MYFBB=`ps ax|grep fbb|grep xfbbd|grep sbin|awk '{ print $1 }'`
PID=`ps ax|grep fbb|grep xfbbd|grep sbin|awk '{ print $1 }'`

if [ -z $MYFBB ]
  then
   log_warning_msg "FBB BBS not found running"
   sleep 2
   log_action_msg "Reloading FBB... "
   sleep 2
   /usr/local/sbin/fbb -s -a
   log_daemon_msg "FBB Reloaded" "done"
   log_end_msg 0

exit 1
fi
  log_action_msg "FBB PBBS is running on pid: $PID"
  exit 0

Tnx to Brain N1URO
http://n1uro.ampr.org/

I made a small addition to the script myself. Now I can also see how long fbb has been running and when fbb has been started. (just fun )

#! /bin/sh

. /lib/lsb/init-functions

MYFBB=`ps ax|grep fbb|grep xfbbd|grep sbin|awk '{ print $1 }'`
PID=`ps ax|grep fbb|grep xfbbd|grep sbin|awk '{ print $1 }'`
UPTIME=`ps -p $PID -o %t | tail -1|awk '{ print $1 }'`
START=`ps -p $PID -o lstart=`

if [ -z $MYFBB ]
  then
   log_warning_msg "FBB BBS not found running"
   sleep 2
   log_action_msg "Reloading FBB... "
   sleep 2
   /usr/local/sbin/fbb -s -a
   log_daemon_msg "FBB Reloaded" "done"
   log_end_msg 0

exit 1
fi
  log_action_msg "FBB BBS PI8LAP is running on pid : $PID"
  log_action_msg "FBB BBS PI8LAP is Started on : $START"
  log_action_msg "FBB BBS PI8LAP is running for : $UPTIME dd:hh:mm:ss"
exit 0

Looks like this.

root@pi1lap-base:/usr/local/etc/ax25/fbb# ./fbbcheck
[info] FBB BBS PI8LAP is running on pid : 2573.
[info] FBB BBS PI8LAP is Started on : Sat Sep  2 06:23:02 2017.
[info] FBB BBS PI8LAP is running for : 01:10:44 dd:hh:mm:ss.
root@pi1lap-base:/usr/local/etc/ax25/fbb#

Examples forward JNOS/BPQ/LinFBB

Here below some examples how the configuration of the forward in different systems works.

Thanks in particular to Bob (VE3TOK) and Gus (I0OJJ) for example configs !

Copyright ©  http://www.langelaar.net/jnos2/

Example Configuration for JNOS 2.0k side
   ----------------------------------------

      a) autoexec.nos

         # regular listener (no IAC) for remote JNOS and BPQ systems
         start telnet

         # another listener (IAC) on different port for LINFBB and OBCM systems
         start telnet 6300 iac

         # for winlink secure login, you have to configure your callsign
         mbox winlinkcall ve4klm

      b) spool/forward.bbs

         -------
         ve3tok
         # Here we are talking to a remote LINFBB system
         telnet 44.x.y.z 6300 iac
         +Callsign :
         .ve4klm
         +Password :
         .BLAHBLAHBLAH
         ve3tok
         -------
         va3tok
         # Here we are talking to a remote BPQ system
         telnet 44.x.y.z 8011 cronly
         .ve4klm
         .BLAHBLAHBLAH
         +BPQ
         .BPQBBS
         va3tok
         -------
         wl2k
         # Here we are talking to Winlink CMS server
         telnet winlink.org 8772 cronly
         +Callsign :
         ..VE4KLM
         +Password :
         .BLAHBLAH
         wl2k
         -------
         i0ojj 0023 P
         # Here we are talking to obcm v1.07b12
         # NOTE : OBCM supports FC proposal, so it will use B2F, but wonder if
         # I should force a B1F response so RLINE and Headers work properly ?
         telnet 44.x.y.z 4719 iac
         @10
         +login:
         .ve4klm
         @10
         +password:
         .BLAHBLAH
         @10
         <areas to forward>
         -------
         ir0aab 0023 P
         # Here we are talking to linfbb v7.0.8-beta2
         telnet 44.x.y.z 6300 iac
         @
         +Callsign :
         .ve4klm
         +Password :
         .BLAHBLAH
         @
         <areas to forward>
         -------

      c) setting up MY winlink authentication

         cd /jnos

         mkdir users		* you only need to do this one time

         ./jnospwmgr -a <callsign> -w

         it will ask you to enter the phrase that you would have received
         from your winlink notice (the challenge/response phrase).         

       * for now please read release notes (search December 8) for more info.

   Remote LINFBB host
   ------------------

     For forwarding to VE4KLM I added the following line to 'bbs.sys' :

       < FWD\VE4KLM

     A forward file for that particular bbs is placed in FBB's 'fwd' directory,
     so an example of forward file, 've4klm' (contents might be different for
     other FBB owners.)

       A VE4KLM

         P A
         C C ve4klm ve4klm.ampr.org 6300
         V login$Wpassword$W

       #  Forward file -- To VE4KLM BBS (JNOS)
       #
       #  Personal mail
       #
       B VE4KLM
       F VE4KLM
       #
       # Reverse fowarding to take place
       R
       # Forward rest of North-America to VE4KLM
       H  VE4KLM.#WPG.MB.CAN.NOAM
       H *.NOAM
       #

   Remote BPQ host
   ---------------

     This is needed as telnet connect script for bpq in forwarding with jnos.
     It is entered in the "connect script" box of the forwarding config web
     page of the bpq mail server.

       TIMES 0000-2359
       Idletime 60
       attach 3
       c ve4klm.ampr.org 23 NEEDLF .login pass

     General:

       attach p - p is a port number cfg'd as telnet port in your bpq32.cfg

       c Hostname TCPport [NEEDLF] User Password [Command]

     Here :

       attached 3 - I configured port 3 as telnet port
       NEEDLF     - Causes a Line Feed to be sent after user and password.
       .login     - The period before the login user name will tell jnos to use
                    a transparent TCP session instead of ordinary telnet.

     See: http://www.cantab.net/users/john.wiseman/Documents/TelnetServer.htm

     This example line below is needed in bpq32.cfg so that jnos can login into
     bpq and initiate forwarding as bbs.
 
       USER=ve4klm,password,login,BBS

   Remote OBCM host
   ----------------

     ; From obcm v1.07b12
     ;
     ; INIT IR0RM file (JNOS-2.0k+)
     ;          0                  1                  2
     ;          012345678901234567890123
     IR0RM PPPPPPPPPPPPPPPPPPPPPPPP TELNET:44.x.y.z:6300
      -d -k -l -o -u
     ;

   Remote LINFBB host
   ------------------

     # From linfbb v7.0.8-beta2
     #
     IF H 00-23
      S connected failure busy
      C C IR0RM-1 44.x.y.z 6300
      V i0ojj$Wpassword$W
     ENDIF
     #

 

F6fbb port.sys (smtp/pop/nntp)

With f6fbb it is possible to use the software as smtp, pop and nntp server. Below is a small example of how you can make that possible.

# /usr/local/etc/ax25/fbb/port.sys
# FBB 7.07
#
#
# Number of Com Ports and TNCs (not) including TNC 0
             2            2
#
# Interface 6 = Windows
# Interface 7 = TCPIP
# Interface 8 = TFWin.dll
# Interface 9 = LINUX
#
#Com Interface Adress (Hex)   Baud
  2    9        189C               0
  3    9        189D:189E:77       0
#TNC NbCh Com MultCh   Pacln Maxfr NbFwd MxBloc M/P-Fwd  Mode  Freq
  0   0    0   0        0     0     0     0      00/01   ----  File-fwd.
  1   10   2   0        250   2     4     10     00/60   TUWY  Telnet
  2   4    3   0        250   2     4     10     00/10   SU    Pop/smtp
#
# End of file.
#

If you look at the HEX addresses, the smpt port on 6302 and the pop port on 6301 the nntp port just on 119. Now it is possible to set your mail program and read your mail in your mail package.

Email address comes with one with your packet address (pd9q@pi8lap.#zl.nld.euro)