Skip to content
Snippets Groups Projects
  1. Mar 25, 2023
    • Rob Swindell's avatar
    • Rob Swindell's avatar
      Create the "Servers" configuration sub-menu, currently read-only · 00f971d7
      Rob Swindell authored
      I'm surprised more people haven't wondered aloud: why are all the Synchronet
      server settings in this huge sbbs.ini file? Well... this kind of answers that
      question: it's a hell of a lot of settings! And this isn't even everything
      (several advanced/rarely-used/borderline-deprecated settings aren't included)!
      
      As part of this change, I've replaced the old date/time display with the
      current config file path/name that's being edited (more or less). This will
      help when a sysop has multiple sbbs.*.ini files and makes it clear if you have
      multiple sbbs installs (like me), which one you're editing at any given time.
      
      I have not implemented any of the server setting edits (other than a couple
      simple toggles) or help text yet and this does not detect changes or save them
      to the sbbs.ini file, but I wanted to get this committed at this stage anyway.
      If you're running sbbsctrl.exe (or maybe even gtkmonitor), then maybe this is
      completely redundant and unnecessary, but I figured it was good to have these
      settings in one edit find/edit platform-agnostic location anyway. Hoepfully
      this will (when its done) make SBBS for *nix just that much easier for a newbie
      sysop/sysadmin.
      00f971d7
  2. Mar 24, 2023
    • Rob Swindell's avatar
      Set initial state of 'data_event' and 'highwater_event' to *not* signaled · 834d89ea
      Rob Swindell authored
      Since commit fd90eec6 (2 months ago), the Synchronet Web Server on
      my Windows systems has occasionally gone into a state where every HTTP session
      thread was causing 100% CPU utilization and each new HTTP session thread
      would just exacerbate the problem eventually leading to complete system
      instability/unresponsiveness until the sbbs instance was terminated. This was
      more readily reproducible on a Win7-32 VM, but would occasionally, though
      much less frequently, happen in a native instance on Win10-64 as well.
      
      Using the VisualStudio debugger, I was able to narrow it down to this:
      
      Each new HTTP thread (eventually, hundreds of such threads) would get stuck
      in this loop in http_output_thread():
      
          while(session->socket!=INVALID_SOCKET) {
      
      		/* Wait for something to output in the RingBuffer */
      		if((avail=RingBufFull(obuf))==0) {	/* empty */
      			if(WaitForEvent(obuf->data_event, 1000) != WAIT_OBJECT_0)
      				continue;
      			/* Check for spurious sem post... */
      			if((avail=RingBufFull(obuf))==0)
      				continue; // <--- data_event signaled, but never cleared
      		}
      
      There appears to be a race condition where this logic could be executed
      immediately after the output ringbuf was created, but before writebuf() was
      ever called (which would have actually placed data in the output buffer),
      causing a potential high-utilization infinite loop: the data_event is signaled
      but there is no data and the event is never reset and nothing can ever add
      data to the ringbuf due to starvation of CPU cycles.
      
      Uses of ringbuf's data_event elsewhere in Synchronet don't seem to be subject
      to this issue since they always call RingBufRead after, which will clear the
      data_event when the ringbuf is actually empty (no similar loops to this one).
      
      The root cause just appears to be a simple copy/paste issue in the code added
      to RingBufInit(): the preexisting 'empty_event' was initialized with a
      correct initiate state of 'signaled' (because by default a ringbuf is empty)
      but the newly added events (data_event and highwater_event) should *not* be
      initially-signaled because... the ringbuf is empty. So I added some parameter
      comments to these calls to CreateEvent() to hopefully make that more clear
      and prevent similar mistakes in the future.
      
      Relieved to have this one resolved finally.
      834d89ea
    • Rob Swindell's avatar
    • Rob Swindell's avatar
      Merge branch 'dd_msg_reader_multiple_msg_delete_hdr_fix' into 'master' · 529d67ca
      Rob Swindell authored
      DDMsgReader: Bug fix for deleting multiple selected messages
      
      See merge request !271
      529d67ca
    • Eric Oulashin's avatar
      DDMsgReader: Bug fix for deleting multiple selected messages · cb31b8e9
      Eric Oulashin authored and Rob Swindell's avatar Rob Swindell committed
      cb31b8e9
  3. Mar 23, 2023
    • Rob Swindell's avatar
      Don't clear the line counter after executing string commands · 4207f5fd
      Rob Swindell authored
      This resolves the issue of the results of string commands not being visible
      in novice menu mode. I don't see this issue when running default.bin.
      
      ┌────────────────────────····
      │ Subj: nlog
      │ Attr: Replied
      │ To  : All
      │ From: Greg Meckel (1:153/143)
      │ Date: Wed Mar 22 2023 10:40 am UTC-9:00 (22.7 hours ago)
      └───────────────────────────────────────────────······
      
      I attempted to check my node log this morning using ;nlog but it only flashed
      on the screen briefly and was gone. Do I possibly have something set wrong?
      4207f5fd
  4. Mar 22, 2023
  5. Mar 21, 2023
  6. Mar 20, 2023
  7. Mar 19, 2023
  8. Mar 18, 2023
    • Rob Swindell's avatar
      Add InactivityAlert · 62bbc911
      Rob Swindell authored
      62bbc911
    • Rob Swindell's avatar
    • Rob Swindell's avatar
      Apply inactive_hangup option (for dumb terminals) using max_socket_inactivity · 3c8de965
      Rob Swindell authored
      this insures that inactive dumb (bot) connections will be disconnected even
      when using a script (e.g. animated pause prompt) that doesn't time-out.
      
      Also, if the connected node is the last node (for this sbbs instance), divide
      the socket inactivity timeout value in half.
      
      These changes (along with sbbs v3.20) should help with DOS (denial-of-service,
      not MS-DOS) prevention.
      
      Mainly for Krueger.
      3c8de965
    • Rob Swindell's avatar
      A few help text fixups. · b48da1c0
      Rob Swindell authored
      b48da1c0
    • Rob Swindell's avatar
      Add terminal-client socket inactivity detection/disconnection · 53b26318
      Rob Swindell authored
      - New keys in [BBS] section of sbbs.ini:
        MaxLoginInactivity (default: 10 minutes)
        MaxNewUserInactivity (default: 60 minutes)
        MaxSessionInactivity (default: none/unlimited)
      - Each configured external program/door in SCFG can have its own maximum inactivity setting (or else the session max inactivity is applied)
      - moved node-specific sec_hangup to system-wide/shared max_getkey_inactivity (configured in SCFG->System->Advanced)
      - moved node-specific sec_warn (seconds of inactivity before sending warning) to inactivity_warn (a percentage of elapsed max inactivity before sending warning), also configured in SCFG->System->Advanced and used for both socket and getkey inactivity detection
      - Renamed JS console.inactivity_hangup to console.max_getkey_inactivity (old name remains as alias)
      - Renamed JS console.timeout to console.last_getkey_activity (old name remains as alias)
      - Removed JS console.inactivity_warning
      - Added JS console.max_socket_inactivity (current input_thread inactivity threshold)
      - New text.dat string: InactivityAlert (just contains 3 ^G/BELLs by default) used for non-visual inactive-user warning
      
      The MaxLoginInactivity setting in particular solves the problem of custom scripts (e.g. animated pause prompts) that just poll indefinitely for user input and never time-out  - these will no longer cause nodes to be tied-up with inactive/bot users at login.
      
      You may ask yourself, how did I get here? No, you may ask yourself: why configure these socket inactivity max values in sbbs.ini? The reason is consistency: sbbs.ini is where the MaxInactivity is configured for all the other TCP servers and services.
      
      This fixes issue #534 for Krueger in #synchronet
      53b26318
    • Rob Swindell's avatar
      Use const doubles for time durations · 8ff65a19
      Rob Swindell authored
      Instead of copy/pasta. No change in function,.
      8ff65a19
  9. Mar 16, 2023
  10. Mar 15, 2023
  11. Mar 14, 2023
Loading