Main issueshttps://gitlab.synchro.net/groups/main/-/issues2024-03-22T07:20:15Zhttps://gitlab.synchro.net/main/sbbs/-/issues/698Standardize on bool/true/false (lowercase) in the C source2024-03-22T07:20:15ZRob SwindellStandardize on bool/true/false (lowercase) in the C sourceWe still build some components (e.g. xpdev) with pre-C99 Borland C, so we still use BOOL/TRUE/FALSE in these source/header files for that reason. Since we know that bool/true/false is the actual/future standard (C23), it'll be safe to us...We still build some components (e.g. xpdev) with pre-C99 Borland C, so we still use BOOL/TRUE/FALSE in these source/header files for that reason. Since we know that bool/true/false is the actual/future standard (C23), it'll be safe to use those keywords and macro-wrappers for any compiler (e.g. Borland C) that doesn't have native support.
This will make editing the C source files simpler since we'll know to always use the lowercase variant, regardless of which module/lib, without any surprises (e.g. when the CI pipeline builds code with Borland C).
Need to make sure the Borland C wrapper for `bool` will be the same size as the C99 `stdbool.h/_Bool` type.Rob SwindellRob Swindellhttps://gitlab.synchro.net/main/sbbs/-/issues/697Add @-code formatting to text.dat/ini strings2024-01-25T13:02:21ZNigel ReedAdd @-code formatting to text.dat/ini stringsPer IRC discussion. Please consider adding formatting for @-codes in text.in files
For example @NODE|Z2@
To make things easier, @INCLUDE @JSEXEC and others that could be a security issue could be excluded.
Thanks.Per IRC discussion. Please consider adding formatting for @-codes in text.in files
For example @NODE|Z2@
To make things easier, @INCLUDE @JSEXEC and others that could be a security issue could be excluded.
Thanks.Rob SwindellRob Swindellhttps://gitlab.synchro.net/main/sbbs/-/issues/696Add support for @-codes in text.ini2024-03-22T07:20:15ZNigel ReedAdd support for @-codes in text.iniI want to do be able to do something like this without having to go into the code and change the lines manually.
```
NodeLoggedOff: "\1_\1w\1hNode %2d: \1g%s\1n\1g logged off @DATE @TIME\r\n\1n"
NodeLoggedOnAtNbps: "\1_\1w\1hNode %2d: ...I want to do be able to do something like this without having to go into the code and change the lines manually.
```
NodeLoggedOff: "\1_\1w\1hNode %2d: \1g%s\1n\1g logged off @DATE @TIME\r\n\1n"
NodeLoggedOnAtNbps: "\1_\1w\1hNode %2d: \1g%s\1n\1g logged on @DATE @TIME\r\n\1n"
```https://gitlab.synchro.net/main/sbbs/-/issues/695Stopping a server doesn't (usually/always) put its MQTT state to "stopped"2024-01-13T00:27:44ZRob SwindellStopping a server doesn't (usually/always) put its MQTT state to "stopped"Appears to be a race condition during shutdown of a server. The will status of "DISCONNECTED" does get set, but the transition to stopped doesn't get recorded (i.e. in server/state/stopped topic).Appears to be a race condition during shutdown of a server. The will status of "DISCONNECTED" does get set, but the transition to stopped doesn't get recorded (i.e. in server/state/stopped topic).Rob SwindellRob Swindellhttps://gitlab.synchro.net/main/sbbs/-/issues/694ciolib-win32-gdi divide by zero crash in 43-line/EGA mode (run with '-l43' co...2024-01-04T23:21:06ZRob Swindellciolib-win32-gdi divide by zero crash in 43-line/EGA mode (run with '-l43' command-line option)> Unhandled exception at 0x005BCADF in scfg.exe: 0xC000041D: An unhandled exception was encountered during a user callback.
Problem/crash does not happen 100% of the time.
The line of code in scale.c where the exception occurs is
```
...> Unhandled exception at 0x005BCADF in scfg.exe: 0xC000041D: An unhandled exception was encountered during a user callback.
Problem/crash does not happen 100% of the time.
The line of code in scale.c where the exception occurs is
```
// If x/y scaling isn't a simple multiple, block scale everything...
if ((total_yscaling % total_xscaling) == 0) {
```
total_xscaling 0 int
total_yscaling 1 int
Backtrace:
```
scfg.exe!do_scale(rectlist * rect, int fwidth, int fheight) Line 249
at c:\sbbs\src\conio\scale.c(249)
scfg.exe!gdi_handle_wm_paint(HWND__ * hwnd) Line 296
at c:\sbbs\src\conio\win32gdi.c(296)
scfg.exe!gdi_WndProc(HWND__ * hwnd, unsigned int msg, unsigned int wParam, long lParam) Line 579
at c:\sbbs\src\conio\win32gdi.c(579)
[External Code]
[Frames below may be incorrect and/or missing, no symbols loaded for user32.dll]
scfg.exe!gdi_thread(void * arg) Line 874
at c:\sbbs\src\conio\win32gdi.c(874)
scfg.exe!invoke_thread_procedure(void(*)(void *) procedure, void * const context) Line 82
at d:\th\minkernel\crts\ucrt\src\appcrt\startup\thread.cpp(82)
scfg.exe!thread_start<void (__cdecl*)(void *)>(void * const parameter) Line 115
at d:\th\minkernel\crts\ucrt\src\appcrt\startup\thread.cpp(115)
[External Code]
scfg.exe!__crt_stdio_input::input_processor<wchar_t,__crt_stdio_input::string_input_adapter<wchar_t>>::process_state() Line 1122
at d:\th\minkernel\crts\ucrt\inc\corecrt_internal_stdio_input.h(1122)
```
Stepping through the code, I see this calculation:
```
int yscale = fheight / rect->rect.height;
```
Results in yscale = 0 (350 / 400).
And then in the `if (xscale > yscale) {` block, the `yscale` value (0) is assigned to `xscale` which is then later assigned to `total_xscaling`.
Why this problem doesn't happen 100% of the time, I don't know. Perhaps the `rect` object is shared with another thread?
When it doesn't crash, the `fheight` parameter value is 400, so `yscale` is assigned 1 and no divide by zero happens.DeucеDeucеhttps://gitlab.synchro.net/main/sbbs/-/issues/693gopher error when accessing empty subgroups2024-01-01T13:02:19ZNigel Reedgopher error when accessing empty subgroupsI saw this request come through
Dec 31 14:46:23 bbs synchronet: srvc 0059 Gopher [93.157.51.147] Logging in Guest
Dec 31 14:46:23 bbs synchronet: srvc 0059 Gopher client request: 'sub:il_desktop'
Which casued
Sun Dec 31 14:46:23 2023 m...I saw this request come through
Dec 31 14:46:23 bbs synchronet: srvc 0059 Gopher [93.157.51.147] Logging in Guest
Dec 31 14:46:23 bbs synchronet: srvc 0059 Gopher client request: 'sub:il_desktop'
Which casued
Sun Dec 31 14:46:23 2023 master/2ac985843 endofthelinebbs.com srvc 0059 Gopher <Guest> !JavaScript /sbbs/exec/gopherservice.js line 289: Type: hdr_list is null
The il_desktop subgroup is empty, no posts, so I guess that needs to be checked.Rob SwindellRob Swindellhttps://gitlab.synchro.net/main/sbbs/-/issues/692JSexec doesn't connect to MQTT broker2023-12-29T07:49:18ZRob SwindellJSexec doesn't connect to MQTT brokerSome JS stuff (e.g. `system.node_list, User.downloaded_file()`) automatically publishes to MQTT topics, but if JSexec is used, this doesn't happen.
Consider a command-line option and/or jsexec.ini setting that causes it to create an MQT...Some JS stuff (e.g. `system.node_list, User.downloaded_file()`) automatically publishes to MQTT topics, but if JSexec is used, this doesn't happen.
Consider a command-line option and/or jsexec.ini setting that causes it to create an MQTT connection to the configured broker.Rob SwindellRob Swindellhttps://gitlab.synchro.net/main/sbbs/-/issues/691Questions regarding Zmodem download/upload reliability for linux hosts on bot...2024-02-01T22:02:14ZAlex AckermannQuestions regarding Zmodem download/upload reliability for linux hosts on both endsHi, in my recent testing ``zmodem-streaming`` between ``git.synchro.net`` and my Debian 12 linux powered by lrzsz+zssh failed after transferring few files (check attachment-1, it just messed up the whole screen). Luckily ``zmodem-windowe...Hi, in my recent testing ``zmodem-streaming`` between ``git.synchro.net`` and my Debian 12 linux powered by lrzsz+zssh failed after transferring few files (check attachment-1, it just messed up the whole screen). Luckily ``zmodem-windowed`` didn't fail (I have tested only once though). ``-windowed`` did print error message (``Retry 0: Got ERROR``), but I am not sure if that's false alarm from rz command on client side (check attachment-2).
Sexyz wiki [section on streaming](http://wiki.synchro.net/util:sexyz#zmodem_streaming) mentions that "SEXYZ supports the following ZMODEM streaming modes, in order of decreasing successful data transfer assurance". Does that apply also apply to connections between Synchronet BBS server talking to a Linux/Windows machine running programs like ``rz`` over zssh/ztelnet, or just when Synchronet is connected to a old-style modem? (am pretty new to BBSing, please pardon my lack of understanding).
The reason I ask is: I want to setup a BBS for modern Linux geeks, and would want to provide only the most reliable download experience (as in our times it is unheard of to have download/upload failures). Is unreliability indispensable when communicating over zmodem protocol between Linux remote server and client? Does synchronet plan to support sftp for downloads? Is there a recommended streaming mode that linux clients powered by zssh+lrzsz use when dealing with downloads/uploads? One thing that would really help is to document expected/mandatory flags for ``rz`` and ``sz`` commands for all the respective streaming modes. IMHO, newbies from Linux land like me who are new to BBSing do not really understand if/when to pass any flags when talking to BBS servers. Here's the Debian documentation for lrzrz's [rz](https://manpages.debian.org/bookworm/lrzsz/rz.1.en.html) and [sz](https://manpages.debian.org/bookworm/lrzsz/sz.1.en.html) commands. Would having sexyz on both client and server improve reliability? For such a setting (where both sides are sexyz), could sexyz support a modern or exclusive-to-sexyz file transfer protocol that would ensure 100% reliability? That would be a welcome addition among groups who don't want to think much about reliability in our times.
1) zmodem_streaming, garbled text in upper tmux pane:
![zmodem_streaming](/uploads/9b373b455568d8d8f3522d459aef63fe/zmodem_streaming.png)
2) zmodem_windowed, ``Retry 0: Got ERROR`` in upper tmux pane:
![zmodem_windowed](/uploads/1b3b6027e571e8bf1de825710c29ceef/zmodem_windowed.png)https://gitlab.synchro.net/main/sbbs/-/issues/690Separate XYZ modem repo, or provide a different make file that just builds XY...2024-01-25T00:18:47ZAlex AckermannSeparate XYZ modem repo, or provide a different make file that just builds XYZ modemI have had difficulty using various BBS software's zmodems to work correctly in all test situations. On one end is ztelnet using lrzsz package on macOS, and on the other end is a Synchronet or Mystic BBS running in a VM on my laptop or a...I have had difficulty using various BBS software's zmodems to work correctly in all test situations. On one end is ztelnet using lrzsz package on macOS, and on the other end is a Synchronet or Mystic BBS running in a VM on my laptop or a production BBS running on a remote machine. Some ztelnet <-> BBS connections that work smoothly for upload/download become unreliable when a socat-based encrypted port tunnel is added between them (only zmodem download/upload is affected, while rest of the BBS UI works as expected). Note: ztelnet just looks for rz/sz commands, so I would guess it can be hooked to sexyz like you describe in your Mystic BBS config for sexyz.
In my test matrix, one thing I have not been able to do is have sexyz transmitting and receiving on both ends. But to build sexyz standalone (on Linux and macOS) seems a pain, file dependencies are spread in different directories (read "conios", etc) of main Synchronet repo. It would be great if you could provide sexyz as a separate repo/package (like lrzsz is available for open source unix community), so one can easily build it on different platforms and test . Or perhaps please add a separate build script that builds just sexyz from your repo (though that might won't work for macOS...). I really want BBSes to work on Linuxes, and ztelnet-able/zssh-able from macOS/Linux. Though downloads/uploads don't always work, which really limits BBS use to messaging and browsing... Homebrew macOS packages for [ztelent/zssh](https://formulae.brew.sh/formula/zssh), and [lrzsz](https://formulae.brew.sh/formula/lrzsz). Homebrew packages are also available for 64-bit Linux, search "linux" on those links. Though I have tested on macOS. As an example, I tried zssh-ing to one of the premier and latest Synchronet BBSes, but zmodem transfers didn't work always.
Sidenote: Synchronet wiki talks about sexyz being a 32-bit program... Does that mean it needs something special to build on 64-bit linux/macOS platforms?https://gitlab.synchro.net/main/sbbs/-/issues/689preformat gopher results to assist broken clients2023-12-31T22:46:49ZNigel Reedpreformat gopher results to assist broken clientsI've tried 4 different clients and each of them render the gopher results differently. It would help to pre-format the article so maybe help some of these clients.
post in the BBS:
![image](/uploads/16e974a426da120aa6a0983ba492b927/imag...I've tried 4 different clients and each of them render the gopher results differently. It would help to pre-format the article so maybe help some of these clients.
post in the BBS:
![image](/uploads/16e974a426da120aa6a0983ba492b927/image.png)
Post in lynx via putty 80x24:
![image](/uploads/93fa14b0aba14eebbebfad2f1af251ff/image.png)
Post in Gophie:
![image](/uploads/9bf3c647f3a58b0c4ef3aa9bd5100bde/image.png)
Post in Gopher Browser (just one very long line)
![image](/uploads/192d90196ba9dfad90489cef89bce932/image.png)
Post in Simple Gopher Client
![image](/uploads/84dd308a6764635014c506c18f2d4b0b/image.png)https://gitlab.synchro.net/main/sbbs/-/issues/688gopher: leading / causes requests to fail.2023-12-22T13:02:17ZNigel Reedgopher: leading / causes requests to fail.Two windows client I tried will send a client request such as '/grp:local' and those will fail and not return anything. Client that send 'grp:local" succeed.
I was able to confirm just by adding
```
if(request==='/grp:local')
req...Two windows client I tried will send a client request such as '/grp:local' and those will fail and not return anything. Client that send 'grp:local" succeed.
I was able to confirm just by adding
```
if(request==='/grp:local')
request='grp:local';
```
and this is fine. So it looks like the / needs to be stripped or handled.https://gitlab.synchro.net/main/sbbs/-/issues/687BinkIT case sensitivity2023-12-21T08:06:08ZChris JohnsonBinkIT case sensitivityBinkIT requires lower case alpha characters when considering FLO/CLO/HLO etc. It requires lower case in both the name and extension.
Using a utility like Joe DeRosa's 'Please', which creates the FLO/CLO/HLO files in upper case, BinkIt ...BinkIT requires lower case alpha characters when considering FLO/CLO/HLO etc. It requires lower case in both the name and extension.
Using a utility like Joe DeRosa's 'Please', which creates the FLO/CLO/HLO files in upper case, BinkIt will produce the following error:
"Unexpected file path 'C:\sbbs\echo\outbound\00DA0370.FLO expected C:\sbbs\outbound\00da0370.FLO'"
Renaming the file to the 'expected' name of 00da0370.FLO produces the following error:
"Unknown flow file flavour 'C:\sbbs\echo\outbound\00da0370.FLO'"
Renaming the file to 00da0370.flo produces a successful callout.
The wiki currently states that "Hexadecimal numbers can be made from either upper or lower case letters (A-F), so case is not significant.", but the binkit.js lists this as a known limitation.https://gitlab.synchro.net/main/sbbs/-/issues/686IMAPS TLS ERROR2023-12-21T14:05:29ZKeyop TroyIMAPS TLS ERRORSince recent changes to TLS operation within SBBS, IMAPS service is now reporting issues. Here are some examples:
Wed Dec 20 19:33:27 2023 master/0ece22907
srvc 0100 IMAPS TLS ERROR 'Bad argument, parameter 3' (-3) setting private key...Since recent changes to TLS operation within SBBS, IMAPS service is now reporting issues. Here are some examples:
Wed Dec 20 19:33:27 2023 master/0ece22907
srvc 0100 IMAPS TLS ERROR 'Bad argument, parameter 3' (-3) setting private key
Wed Dec 20 19:33:27 2023 master/0ece22907
srvc 0100 IMAPS TLS ERROR 'Data has not been initialised' (-11) setting session activeDeucеDeucеhttps://gitlab.synchro.net/main/sbbs/-/issues/685sbbs binary: Debian Linux AARCH64 sigfault or permission denied2023-12-28T00:45:39ZAlex Ackermannsbbs binary: Debian Linux AARCH64 sigfault or permission deniedI was successfully able to build Synchronet on Debian Linux 12 aarch64 (arm64). The configuration command ``scfg`` works, but ``sbbs`` fails with either ``segmentation fault`` (when run without sudo permission), or ``permission denied to...I was successfully able to build Synchronet on Debian Linux 12 aarch64 (arm64). The configuration command ``scfg`` works, but ``sbbs`` fails with either ``segmentation fault`` (when run without sudo permission), or ``permission denied to ctrl/*`` when run as sudo. This same behavior is observed even when all server ports are changed to non-privileged ports (like ``2323``, etc). It is also observed on the tag sbbs319b.
```
debianlinuxexp% uname -a
Linux debianlinuxexp 6.1.0-16-arm64 #1 SMP Debian 6.1.67-1 (2023-12-12) aarch64 GNU/Linux
```
1) Log for segfault (when run as non-root):
```
% SBBSCTRL=/home/aackmann/sbbs/ctrl SBBSEXEC=/home/aackmann/sbbs/exec XDG_RUNTIME_DIR=/home/aackmann/.cache/sbbs /home/aackmann/sbbs/exec/sbbs
Synchronet Console for Linux-armv8 Version 3.20a Copyright 2022 Rob Swindell
Reading /home/aackmann/sbbs/ctrl/sbbs.ini
Loading configuration files from /home/aackmann/sbbs/ctrl
!Started as non-root user (id 1000): May fail to bind TCP/UDP ports below 1024
12/19 10:42:37 term Synchronet Terminal Server Version 3.20a
12/19 10:42:37 term Compiled master/ded39adbd Dec 19 2023 08:10:52 with GCC 12.2.0
12/19 10:42:37 term Initializing on Tue Dec 19 10:42:37 2023 with options: 1022
12/19 10:42:37 term Loading configuration files from /home/aackmann/sbbs/ctrl
12/19 10:42:37 web Synchronet Web Server Version 3.20a
12/19 10:42:37 web Compiled master/ded39adbd Dec 19 2023 08:11:29 with GCC 12.2.0
12/19 10:42:37 web Initializing on Tue Dec 19 10:42:37 2023 with options: 8a0
12/19 10:42:37 web Loading configuration files from /home/aackmann/sbbs/ctrl
12/19 10:42:37 term Verifying/creating data directories
12/19 10:42:37 term Verifying/creating node directories
12/19 10:42:37 term Telnet Server listening on socket 0.0.0.0 port 2323
12/19 10:42:37 term Telnet Server listening on socket :: port 2323
12/19 10:42:37 term RLogin Server listening on socket 0.0.0.0 port 2325
12/19 10:42:37 term RLogin Server listening on socket :: port 2325
12/19 10:42:37 term SSH Server listening on socket 0.0.0.0 port 2324
12/19 10:42:37 term SSH Server listening on socket :: port 2324
12/19 10:42:37 web Web Server listening on socket 0.0.0.0 port 2400
12/19 10:42:37 web Web Server listening on socket :: port 2400
12/19 10:42:37 web Secure Web Server listening on socket 0.0.0.0 port 2401
12/19 10:42:37 evnt BBS Events BBS Events thread started
12/19 10:42:37 web Secure Web Server listening on socket :: port 2401
12/19 10:42:37 web Web Server thread started
12/19 10:42:37 term Node 1 local spy using socket /home/aackmann/.cache/sbbs/localspy1.sock
[Threads: 6 Sockets: 10 Clients: 0 Served: 0 Errors: 0] (?=Help): zsh: segmentation fault SBBSCTRL=/home/aackmann/sbbs/ctrl SBBSEXEC=/home/aackmann/sbbs/exec =
```
2) Permission issues when run as sudo:
```
% SBBSCTRL=/home/aackmann/sbbs/ctrl SBBSEXEC=/home/aackmann/sbbs/exec XDG_RUNTIME_DIR=/home/aackmann/.cache/sbbs sudo -E /home/aackmann/sbbs/exec/sbbs
[sudo] password for aackmann:
Synchronet Console for Linux-armv8 Version 3.20a Copyright 2022 Rob Swindell
Reading /home/aackmann/sbbs/ctrl/sbbs.ini
Loading configuration files from /home/aackmann/sbbs/ctrl
Current usr ids: ruid - 0, euid - 0, suid - 0
Current grp ids: rgid - 0, egid - 0, sgid - 0
The process 11317 was given capabilities =ep
Setting initial privileges
No password name for:
Successfully changed user-id to
Setting minimum privileges
Current usr ids: ruid - 0, euid - 0, suid - 0
Current grp ids: rgid - 0, egid - 0, sgid - 0
The process 11317 was given capabilities cap_net_bind_service,cap_sys_resource=ep
WARNING: No user account specified, running as root!
12/19 10:45:37 web Synchronet Web Server Version 3.20a
12/19 10:45:37 web Compiled master/ded39adbd Dec 19 2023 08:11:29 with GCC 12.2.0
12/19 10:45:37 web Initializing on Tue Dec 19 10:45:37 2023 with options: 8a0
12/19 10:45:37 term Synchronet Terminal Server Version 3.20a
12/19 10:45:37 term Compiled master/ded39adbd Dec 19 2023 08:10:52 with GCC 12.2.0
12/19 10:45:37 term Initializing on Tue Dec 19 10:45:37 2023 with options: 1022
12/19 10:45:42 web !ERROR 13 (Permission denied) changing directory to: /home/aackmann/sbbs/ctrl
12/19 10:45:42 web Loading configuration files from /home/aackmann/sbbs/ctrl
12/19 10:45:42 term !ERROR 13 (Permission denied) changing directory to: /home/aackmann/sbbs/ctrl
12/19 10:45:42 term Loading configuration files from /home/aackmann/sbbs/ctrl
12/19 10:45:52 term !ERROR 13 (Permission denied) opening /home/aackmann/sbbs/ctrl/main.ini
12/19 10:45:57 web !ERROR 13 (Permission denied) opening /home/aackmann/sbbs/ctrl/msgs.ini
12/19 10:45:57 term !FAILED to load configuration files
12/19 10:45:57 term Terminal Server thread terminating
12/19 10:45:57 term Terminal Server thread terminated (0 clients served)
12/19 10:46:02 web !FAILED to load configuration files
12/19 10:46:02 web #### Web Server thread terminated (0 clients served, 0 concurrently)
[Threads: 2 Sockets: 0 Clients: 0 Served: 0 Errors: 6] (?=Help): q
```https://gitlab.synchro.net/main/sbbs/-/issues/684feature request: add more columns to uedit2023-12-15T20:20:19ZFernando Toledofeature request: add more columns to ueditPlease, support to show more columns to uedit like security level, las login, netmail at the user listing.
Also maybe sorting by id / realname / alias will be useful
![imagen](/uploads/82f38a7ddb08b57382863ada43e417ec/imagen.png)
thanks!Please, support to show more columns to uedit like security level, las login, netmail at the user listing.
Also maybe sorting by id / realname / alias will be useful
![imagen](/uploads/82f38a7ddb08b57382863ada43e417ec/imagen.png)
thanks!https://gitlab.synchro.net/main/sbbs/-/issues/683Node Spy: screens keep jumping around.2023-12-15T15:01:41ZNigel ReedNode Spy: screens keep jumping around.![image](/uploads/4357f7147e4c68dc06cbbd89d55c227f/image.png)
It started off with node 3 under node 1 but once a few things got displayed it moved.
Can't seem to get it to move back. This happens with both Firefox and Brave (Chromium b...![image](/uploads/4357f7147e4c68dc06cbbd89d55c227f/image.png)
It started off with node 3 under node 1 but once a few things got displayed it moved.
Can't seem to get it to move back. This happens with both Firefox and Brave (Chromium based).Rick ParrishRick Parrishhttps://gitlab.synchro.net/main/sbbs/-/issues/682sbbs still keeps log file open after logrotate2023-12-15T23:50:31ZFernando Toledosbbs still keeps log file open after logrotateI have sbbs running with systemd on debian
use rsyslog with the following config (according to rsyslog.d/sbbslog.conf) to generate /var/log/sbbs.log
```
local3.* /var/log/sbbs.log
```
I also have a setup the rotate:
```
/var/log/sbbs....I have sbbs running with systemd on debian
use rsyslog with the following config (according to rsyslog.d/sbbslog.conf) to generate /var/log/sbbs.log
```
local3.* /var/log/sbbs.log
```
I also have a setup the rotate:
```
/var/log/sbbs.log {
weekly
maxsize 1G
missingok
rotate 10
notifempty
create 640 root adm
maxage 90
}
```
The rotation works ok, but sbbs keeps writing the previous file
![imagen](/uploads/417648d4f7864a9f0f27afe9391e2bb8/imagen.png)
What is the best way to add a postrotate to tell the sbbs process to reopen the log files via systemd reload / kill etc ?
```
...
sharedscripts
postrotate
systemctl restart sbbs > /dev/null
endscript
....
```
Is it possible for this to happen without restarting the bbs?https://gitlab.synchro.net/main/sbbs/-/issues/681USER_DELETED not defined2023-12-15T13:02:21ZNigel ReedUSER_DELETED not definedJust saw this pass by as I was shutting down my BBS
```
12/14 03:53:00 srvc 0103 ActiveUser-UDP !JavaScript /sbbs/exec/load/presence_lib.js line 8: Error: symbol 'USER_DELETED' not defined by script 'sbbsdefs.js'
```
I did delete a us...Just saw this pass by as I was shutting down my BBS
```
12/14 03:53:00 srvc 0103 ActiveUser-UDP !JavaScript /sbbs/exec/load/presence_lib.js line 8: Error: symbol 'USER_DELETED' not defined by script 'sbbsdefs.js'
```
I did delete a user earlier today.Rob SwindellRob Swindellhttps://gitlab.synchro.net/main/sbbs/-/issues/680sbbs SEGV with mqtt TSL enabled.2023-12-14T13:02:18ZNigel Reedsbbs SEGV with mqtt TSL enabled.I'm assuming there's a certificate issue but I could do with help in trying to determine what might be wrong here.
```
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
--Type <RET> for more, q to quit, c to con...I'm assuming there's a certificate issue but I could do with help in trying to determine what might be wrong here.
```
Using host libthread_db library "/lib/x86_64-linux-gnu/libthread_db.so.1".
--Type <RET> for more, q to quit, c to continue without paging--c
Core was generated by `/sbbs/exec/sbbs d'.
Program terminated with signal SIGSEGV, Segmentation fault.
#0 0x00007ff1704d815a in sanityCheckBignum () from /home/bbs/sbbs-git/src/sbbs3/gcc.linux.x64.lib.debug/libsbbs.so
[Current thread is 1 (Thread 0x7ff156ffd640 (LWP 1352))]
(gdb) bt
#0 0x00007ff1704d815a in sanityCheckBignum () from /home/bbs/sbbs-git/src/sbbs3/gcc.linux.x64.lib.debug/libsbbs.so
#1 0x00007ff1704d820d in BN_clear () from /home/bbs/sbbs-git/src/sbbs3/gcc.linux.x64.lib.debug/libsbbs.so
#2 0x00007ff1704d82cd in BN_free () from /home/bbs/sbbs-git/src/sbbs3/gcc.linux.x64.lib.debug/libsbbs.so
#3 0x00007ff16f3fc838 in ?? () from /lib/x86_64-linux-gnu/libssl.so.3
#4 0x00007ff16f3d6735 in ?? () from /lib/x86_64-linux-gnu/libssl.so.3
#5 0x00007ff16f3e9e3e in SSL_free () from /lib/x86_64-linux-gnu/libssl.so.3
#6 0x00007ff16f883afb in ?? () from /usr/lib/x86_64-linux-gnu/libmosquitto.so.1
#7 0x00007ff16f883fc2 in mosquitto_destroy () from /usr/lib/x86_64-linux-gnu/libmosquitto.so.1
#8 0x00007ff170030638 in js_finalize_mqtt (cx=0x7ff148071f30, obj=0x7ff155e2f4c8) at js_mqtt.c:46
#9 0x00007ff1701d1bdc in JSObject::finalize (cx=0x7ff148071f30, this=0x7ff155e2f4c8)
at /home/bbs/sbbs-test/repo/3rdp/src/mozjs/js-1.8.5/js/src/jsobjinlines.h:137
#10 FinalizeArenaList<JSObject> (comp=0x7ff148093120, cx=0x7ff148071f30, thingKind=0) at jsgc.cpp:1944
#11 0x00007ff1701cface in JSCompartment::finalizeObjectArenaLists (this=0x7ff148093120, cx=0x7ff148071f30) at jsgc.cpp:2005
#12 0x00007ff1701d0a91 in MarkAndSweep (cx=0x7ff148071f30, gckind=GC_NORMAL) at jsgc.cpp:2471
#13 0x00007ff1701d1199 in GCUntilDone (cx=0x7ff148071f30, comp=0x0, gckind=GC_NORMAL) at jsgc.cpp:2755
#14 0x00007ff1701d135d in js_GC (cx=0x7ff148071f30, comp=0x0, gckind=GC_NORMAL) at jsgc.cpp:2824
#15 0x00007ff17014411b in JS_GC (cx=0x7ff148071f30) at jsapi.cpp:2670
#16 0x00007ff16ff6b043 in sbbs_t::js_execfile (this=0x7ff15c120390, cmd=0x7ff15c1332ee "mqtt_stats", startup_dir=0x7ff15c283d81 "/sbbs/exec/",
scope=0x0, js_cx=0x7ff148071f30, js_glob=0x7ff155e03048) at exec.cpp:706
#17 0x00007ff170117905 in sbbs_t::external (this=0x7ff15c120390, cmdline=0x7ff15c1332ed "?mqtt_stats", mode=256,
startup_dir=0x7ff15c283d81 "/sbbs/exec/") at xtrn.cpp:1116
#18 0x00007ff170086208 in event_thread (arg=0x7ff15c120390) at main.cpp:3296
#19 0x00007ff16fbd0ac3 in start_thread (arg=<optimized out>) at ./nptl/pthread_create.c:442
#20 0x00007ff16fc62660 in clone3 () at ../sysdeps/unix/sysv/linux/x86_64/clone3.S:81
```
This is probably overkill but I am working on automating so...
I added my bbs user to the mosquitto group and made sure it had access to /etc/mosquitto/certs
Create a p12 version of the letsyncrypt certificates
# jsexec certtool --export-pkcs12 /sbbs/ctrl/sbbs.p12
Create individual certs
# openssl pkcs12 -in /tmp/sbbs.p12 -nocerts -nodes -out /sbbs/ctrl/sbbs.private_key.pem -passin 'pass:xxxxxx'
# openssl pkcs12 -in /tmp/sbbs.p12 -clcerts -nokeys -out /sbbs/ctrl/sbbs.cert.pem -passin 'pass:xxxxxx'
Download the Lets Encrypt root cert.
# wget https://letsencrypt.org/certs/lets-encrypt-r3.pem
Put all three .pem certificates in /etc/mosquitto/certs and make sure the mosquitto group has read access to all 3 files.
(I may be using the wrong cert from Let's Encrypt, I don't know!)
Configure sbbs as follows
```
[MQTT]
Enabled=true
Verbose=true
Broker_addr=127.0.0.1
Broker_port=8883
Protocol_version=5
Keepalive=11
Publish_QOS=0
Subscribe_QOS=2
Username=bbs
Password=xxxxxxxxxxx
LogLevel=Debugging
TLS_mode=1
TLS_cafile=/etc/mosquitto/certs/lets-encrypt-r3.pem
TLS_certfile=/etc/mosquitto/certs/sbbs.cert.pem
TLS_keyfile=/etc/mosquitto/certs/sbbs.private_key.pem
TLS_keypass=
TLS_psk=
TLS_identity=
```
I don't think a keypass is needed since I can view details of the private_key without entering one.
I have cores from most all the services, depending which one it hits first.https://gitlab.synchro.net/main/sbbs/-/issues/679If not connected to mqtt broker, don't send mqtt messages2023-12-14T13:02:18ZNigel ReedIf not connected to mqtt broker, don't send mqtt messagesDec 13 17:06:50 bbs synchronet: mail MQTT lib: mosquitto 2.0.11
Dec 13 17:06:50 bbs synchronet: mail MQTT connecting to broker 127.0.0.1:8883
Dec 13 17:06:50 bbs synchronet: mail MQTT broker-connect (127.0.0.1:8883) failure: 3
The conne...Dec 13 17:06:50 bbs synchronet: mail MQTT lib: mosquitto 2.0.11
Dec 13 17:06:50 bbs synchronet: mail MQTT connecting to broker 127.0.0.1:8883
Dec 13 17:06:50 bbs synchronet: mail MQTT broker-connect (127.0.0.1:8883) failure: 3
The connection failed while I'm working on getting secure connections configured
but sbbs is trying to push messages
Dec 13 17:06:59 bbs synchronet: term Node 2 ERROR 4 (0) publishing node output (11 bytes): node/2/output
Dec 13 17:06:59 bbs synchronet: term Node 2 ERROR 4 (0) publishing node output (26 bytes): node/2/output
Dec 13 17:06:59 bbs synchronet: term Node 2 ERROR 4 (0) publishing node output (48 bytes): node/2/output
Can we please not log messages due to failed connections, other than the failed mqtt connection itself?Rob SwindellRob Swindell