1. 24 Feb, 2022 17 commits
  2. 23 Feb, 2022 11 commits
  3. 22 Feb, 2022 3 commits
    • Rob Swindell's avatar
      Fix network user/address look-up (using qnet/users.dat) · c7b1bed6
      Rob Swindell authored
      The QWKnet user look-up feature was broken as of commit e4fc5d04 (a year ago).
      Just noticed this regression as Andre asked in IRC about looking up network users for netmail. This feature worked for QWKnet users/addresses, at least, and now will work again.
    • Rob Swindell's avatar
      Display a different prompt for sysops (that includes the [D]elete option) · 9aaaef9a
      Rob Swindell authored
      This addresses the gitlab issue #130.
      Also, prompt for confirmation when [D]eleting the file.
      Also, allow modopts.ini customization of this script via keys
      in the new (optional) [automsg] section:
      prompt (defaults to text.dat AutoMsg)
      sysop_prompt (defaults to hard-coded string)
      intro (defaults to hard-coded string)
      header_fmt (defaults to text.dat AutoMsgBy)
      user_fmt (defaults to hard-coded string)
      line_fmt (defaults to hard-coded string)
      max_line_len (defaults to 76)
    • Rob Swindell's avatar
      Timed event "month days" value of 1 means "any day" (same as 0) · 9d359582
      Rob Swindell authored
      This field should not normally have a value of '1' (no way to configure that, normally, since days are numbered starting at 1 and bit 1 is 2), but if it does, it's treated the same as 0 (any day of the month) - so fix that mismatch in getnexteventtime(). Just noticed this while comparing the logic with the new is_time_to_run() functions in main.cpp. That logic wasn't (should not have) changed, so this mismatch in the treatment of mdays == 1 existed before.
  4. 21 Feb, 2022 4 commits
    • Rob Swindell's avatar
      Refactor timed-event and QWKnet call-out scheduling · b269b65a
      Rob Swindell authored
      Reduced probably the biggest if() conditionals in sbbs to a single line by breaking the "time to run" logic into separate functions and sharing those functions between both QWKnet and timed-event scheduling. There was no actual problem with this code/logic, it was just very difficult to read and understand and step-through with a debugger and understand why or why not an event might run under different configurations and circumstances.
      Also removed the PostLink network call-out logic. pnet.dab is no longer read and written-to and if you happened to have any PostLink hubs configured (how?!?), they'll no longer be "polled". This is the only functional change unless I did something wrong in the process.
      One thing I noticed and contemplated, the current time is not queried between consecutive timed-event scheduling/execution. It's possible that an executed event can take a long time and impact the criteria for the next timed event. The events are checked for scheduling every few seconds, so I can't really think of a big down-side to the current design (apparently intended to reduce unnecessary querying of the current date/time), so I didn't do anything to change that. Just something I noticed.
    • Rob Swindell's avatar
      Rename "Allow Sysop Login" option to "Allow Sysop Access" · a8a6ca22
      Rob Swindell authored
      With this option set to "No", sysops can still login, they just can't perform most sysop functions.
      Updated System Password help text to clarify that the "Allow Sysop Access" option effectively disables the system password. Also mention the FTP Server use of the system password to enable sysop access.
    • Rob Swindell's avatar
      Change the semantics of the "Allow Sysop Logins" setting in SCFG->System · 3632b9c3
      Rob Swindell authored
      As Andre pointed out while documenting this setting on the wiki, the option seemed confusing: if a sysop could not login with "system operator access", how could they login at all? Answer: they could not.
      This setting used to be called "Allow Remote Sysop Logins", back when there was the concept of a "local login", so setting this option to "No" would mean that user accounts with sysop access could only be used for *local* login. But in Synchronet v3, there's really no such concept as a "local login", so it was changed to just "Allow Sysop Logins" (period) and not a lot of thought given to how/why a sysop would actually set to this "No" or what the implications would be (presumably, nobody ever sets this to "No").
      So rather than just get rid if the option altogether, I changed it to mean: an account with sysop access (i.e. level 90+) can still login, but any action that normally requires the system password will not be allowed. This includes the sysop-actions available in the FTP server when authenticating with <user-pass>:<system-pass> as the password. The sysop-user can still authenticate (and login), but none of those sysop-actions will be available to them.
    • Rob Swindell's avatar
      pthread_mutex_t is a CRITICAL_SECTION (not a pointer) on Win32 · b3c536e4
      Rob Swindell authored
      Partially revert Deuce's commit b4bc9c97
      This explains the EAccessViolation (stack corruption during sbbs startup) that sysops have reported when using the latest nightly builds.
  5. 20 Feb, 2022 3 commits
    • Deucе's avatar
      Add DISABLE_MKSTEMP_DEFINE support · cb76b146
      Deucе authored
      This macro as written won't compile on mingw32 due to the attributes
      on _mktemp().  This could be worked around, but it's easier to just
      disable it since I don't need it, and nobody else is building with
    • Deucе's avatar
      Fix socket_ioctl_ptr_t · 24a76496
      Deucе authored
      On Win32 it can't be defined until after winsock*.h is #included.
      On everything else, it needs to be a pointer.
    • Deucе's avatar
      Add socket_ioctl_ptr_t · 1d7b9805
      Deucе authored
      For Win32, this is actually the pointer type an ioctl() third
      argument needs to be.  For other OSs, this is basically what an
      FIONBIO third argument needs to be... there's really no restruction
      at all on what arguments after the second to ioctl() need to be.
  6. 19 Feb, 2022 2 commits
    • Deucе's avatar
      Make socket_send_buffer_t separate from socket_recv_buffer_t · edc4b075
      Deucе authored
      It seems we can't add a const to a typedef in a static_cast<>()
    • Deucе's avatar
      Use MinGW32 types for pthread_t and pthread_mutex_t · 3d0d525c
      Deucе authored
      uintptr_t should be the same as a DWORD on Win32,
      and CRITICAL_SECTION can be stored in an inptr_t as well.
      This should work fine, and allow more build environments to be happy.
      This is generally caused by new C++ standards having thread support
      in the standard library, so wrappers getting pushed deeper in.
      At some pointer, this should be redone with standard threads, but
      now is not the time.