• ctrl/sbbs.ini docs/v322_n

    From Rob Swindell (on Debian L@VERT to Git commit to main/sbbs/m on Sat Aug 1 00:24:00 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/3cd05185ae71b03a3971332f
    Modified Files:
    ctrl/sbbs.ini docs/v322_new.md exec/load/sbbsini.js src/sbbs3/websrvr.cpp websrvr.h
    Log Message:
    websrvr: stop advertising TLS-PSK in the default Authentication list

    The web server cannot perform TLS-PSK: the code that would register the user/password pairs with the TLS session, and the code that would read the negotiated username back off it, are both compiled out. They have been
    disabled since dbbfabf1b1 (funky-27-foam, 2015-08-20), the commit that first added TLS support here, so the mechanism has never functioned.

    Offering it by default meant a sysop who followed the shipped list and set Authentication = TLS-PSK for a directory got a location nobody could authenticate to, with no diagnostic explaining why.

    Drop it from the default in all three places the string is spelled: the compiled-in WEB_DEFAULT_AUTH_LIST, the stock ctrl/sbbs.ini (which has carried it since 4cf1839fce, service-28-when, 2016-11-28), and the JavaScript mirror
    of the default in exec/load/sbbsini.js.

    Correcting the default does not reach an install whose own sbbs.ini already names TLS-PSK, since an explicit key always wins over the compiled default,
    so also log a warning at web server startup when the configured list still names it.

    The disabled TLS-PSK code is left in place for the day the web server gains
    an additional or alternative crypto backend; this changes what is advertised, not the dormant support.

    GitLab #1206

    Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Debian L@VERT to Git commit to main/sbbs/m on Sun Nov 8 17:22:00 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/75463dc5d2fbe6a79d522659
    Modified Files:
    ctrl/sbbs.ini docs/v322_new.md src/sbbs3/logfile.cpp main.cpp src/sbbs3/scfg/scfgindex.h scfgsrvr.c scfgsys.c src/sbbs3/startup.h
    Log Message:
    Add NO_EVENT_LOG_FILE option to stop writing data/events*.log

    The event thread's log file duplicates what the server log already holds
    on systems that log to syslog, and it can only be bounded by the size
    limit it shares with the much smaller error logs. Setting EventLogLevel
    to 0 kept the file from being written, but that level also gates the
    server log, so it silenced event output there as well.

    The new Terminal Server option (SCFG: Event Log File) stops the file
    only. Nothing in the stock install reads it.

    With a size limit but max_logs_kept=0, fopenlog() never rotates, yet fprintlog() still closed the file at the limit, so every further line
    paid for a close and reopen. Close only when rotation can happen. SCFG
    already displays that combination as Unlimited; its help now says so,
    and also lists events.log among the size-limited logs.

    Fixes #1086

    Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Debian L@VERT to Git commit to main/sbbs/m on Sat Nov 21 19:18:00 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/c5a3b3a971e567e7b19eee9d
    Modified Files:
    ctrl/sbbs.ini docs/v322_new.md src/sbbs3/sbbs_ini.c src/sbbs3/scfg/scfgindex.h scfgsrvr.c src/sbbs3/userdat.c userdat.h websrvr.cpp websrvr.h
    Log Message:
    Web Server: trusted reverse proxies, and filter the forwarded address

    RemoteIPHeader (7712fdfa3e, receptors-12-suggestion, 2025-11-11) lets a
    site behind a reverse proxy or CDN, such as Cloudflare
    (CF-Connecting-IP), see each client's own address. Two problems
    remained.

    Any client could set that header (#1283). The new [Web]
    RemoteIPHeaderTrust setting lists the proxy addresses or CIDR ranges (comma-separated, the .can/.cfg pattern syntax) whose RemoteIPHeader is believed; the header from any other connection is ignored. Left blank,
    any client's header is believed, as before, so an upgraded proxied site
    keeps working, and a warning is logged at startup. A comma-separated
    value, or the same header given more than once (X-Forwarded-For), yields
    its right-most address that is not a trusted proxy, the address the
    outermost trusted proxy received the request from; before, a list was
    rejected as invalid.

    The address-based checks ran before the header was applied (#1389). The
    request rate limiter and its exemption check ran in get_req(), before parse_headers(), so on a connection's first request they acted on the
    proxy: with the proxy exempt (the stock ipfilter_exempt.cfg exempts
    loopback and private ranges) those requests skipped the limiter, and
    with it not exempt every client counted against, and could get filtered,
    the proxy's own address. ip.can was checked only when a connection was accepted, against the proxy, so an ip.can entry for a forwarded client, including one the rate limiter or web_block.ini wrote, never refused it.
    Now, after parse_headers(), each request is checked against ipfilter_exempt.cfg, and a forwarded address against ip-silent.can
    (connection dropped) and ip.can (403), then web_block.ini, then the rate limiter. Internal redirects are not counted as requests. A forwarded
    client's checks and filter entries no longer use the proxy's hostname.

    Failed web logins were counted, and temporary bans checked, against the connecting address: behind an exempt proxy no client was ever banned for guessing passwords, and behind one that was not exempt, one client's
    failures banned everyone. They are now counted against the request's
    client, and a forwarded address under a temporary ban is refused (403); loginBannedAddr() is loginBanned() for an address rather than a socket.

    Each request on a kept-alive connection now starts from the connection's
    own address, so a request without the header no longer keeps the
    address an earlier request forwarded.

    In the access log's CustomLogFormat, %a is now the request's client (the forwarded address), as Apache's is with a trusted proxy, and the new
    %{c}a is the connecting address, as in Apache. %h was already the
    forwarded address.

    SCFG: Web Server > Reverse Proxy holds Client IP Header (RemoteIPHeader,
    until now set only in sbbs.ini) and Trusted Proxies.

    web_startup_t gained a member, so sbbsctrl.exe must be rebuilt.

    Tested on Linux against an isolated test server with RemoteIPHeader = X-Forwarded-For: the startup warning with no trust list; a header from a
    peer not in the list ignored; with 127.0.0.0/8 trusted, the right-most untrusted address of a list and of two header lines; an invalid value
    ignored; a kept-alive second request without the header logged under the connection's address; forwarded addresses in ip.can (403) and
    ip-silent.can (dropped); the rate limiter counting a forwarded client
    from its first request (429 on the 4th of 3 allowed) while another
    client and the exempt proxy itself were not limited; web_block.ini
    blocking and filtering a forwarded client; three wrong passwords from a forwarded client temporarily banning it (403 with the right password)
    while another forwarded client and a direct one logged in; %a, %{c}a and
    %h in a custom log format. SCFG built, not exercised.

    Fixes #1283
    Fixes #1389
    Fixes #280

    Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net
  • From Rob Swindell (on Debian L@VERT to Git commit to main/sbbs/m on Sat Nov 21 21:22:00 2026
    https://gitlab.synchro.net/main/sbbs/-/commit/03be043f226cebb6feb33535
    Modified Files:
    ctrl/sbbs.ini docs/v322_new.md src/sbbs3/main.cpp sbbs_ini.c src/sbbs3/scfg/scfgindex.h scfgsrvr.c src/sbbs3/startup.h websrvr.cpp websrvr.h src/xpdev/multisock.c multisock.h
    Log Message:
    PROXY protocol: believe the header only from TrustedProxies

    With HAPROXY_PROTO (Web and Terminal Servers), xpms_accept() read a
    PROXY protocol header from every connection and used the address it
    gave, whoever sent it: a client that could reach the port directly
    could claim any address, evading ip.can, the rate limiters and login
    bans, posing as an exempt address, or getting another address filtered
    (#1391).

    The proxies are now listed in a TrustedProxies setting, in [BBS] and
    [Web]. In [Web] it replaces RemoteIPHeaderTrust, added hours earlier
    for #1283 and never in a release, so it also decides whose
    RemoteIPHeader is believed.
    xpms_set gained a proxy_trusted() callback, which each server sets: a
    peer it does not trust is an ordinary direct connection, with no header expected or read, so direct and proxied clients can share a port; a
    trusted peer must still send the header. A blank list keeps the
    previous behavior (every peer must send a header, and it is believed),
    with a warning logged at startup.

    SCFG: the Reverse Proxy sub-menu is now shared, as a view, by the Web
    Server (Client IP Header, PROXY Protocol, Trusted Proxies) and the
    Terminal Server (PROXY Protocol, Trusted Proxies; #1392); the PROXY
    Protocol toggle (HAPROXY_PROTO, until now set only in sbbs.ini) is in
    both. Trusted Proxies is editable when either method is in use.

    bbs_startup_t gained a member, so sbbsctrl.exe must be rebuilt.

    Tested on Linux against isolated Web and Terminal Servers with
    HAPROXY_PROTO and TrustedProxies: with the peer trusted, a v1 header's
    address was used and a connection without one was dropped; with the
    peer not trusted, a connection without a header was served under its
    own address, and a header it sent anyway was not believed (the Web
    Server read it as the request); with a blank list, the warning was
    logged and the header honored. RemoteIPHeader was ignored from a peer
    not in TrustedProxies and honored from one in it. The SCFG menus were
    built, not exercised.

    Fixes #1391
    Fixes #1392

    Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>

    ---
    þ Synchronet þ Vertrauen þ Home of Synchronet þ [vert/cvs/bbs].synchro.net