Commit graph

  • 8846506292 Might be a good idea to also skip local Q:Lines (ban nick {} blocks) :D GottemHams 2019-06-05 19:19:03 +0200
  • e423f69082
    [tkldb] Add some extra check for trailing DB data. If everything goes correctly then after reading all TKL entries we should be at the end of file. If there is still data after that, something went wrong... quite wrong.. :D Bram Matthys 2019-06-05 09:39:59 +0200
  • 673779eab9
    Write string lengths as 16-bit rather than 64-bit: saves about 34% space of the database file, with possible some small speed improvement as well. Bram Matthys 2019-06-05 09:33:04 +0200
  • ec5811dc3b
    [tkldb] Save every 5 minutes now that writing is fast enough :) And mention the benchmark figures in the .c file. Bram Matthys 2019-06-05 09:01:04 +0200
  • eaa1b213b9
    [tkldb] Use buffered I/O. Writing the DB is now 29 times faster. Saving 100k zlines now takes 72ms instead of 2100ms Loading 100k zlines now takes 510ms instead of 1300ms Bram Matthys 2019-06-05 08:53:30 +0200
  • 1f6bb6d3cc
    Some benchmarking Bram Matthys 2019-06-05 08:45:48 +0200
  • 498f728cbb
    [tkldb] If DB is corrupt then rename to .corrupt and start a new one. This, rather than having the module not loaded at all, which could mean, especially if missed the warning on boot, that you run for weeks or months without having your TKL's stored, which would be a shame ;) Also a failure to rename() is not fatal, as it likely means that we don't have permissions, in such a case you will see a repeated error every X minutes due to the write, which is good. Bram Matthys 2019-06-05 08:22:22 +0200
  • 21f24cc596
    Fix for NICK+USER order. Should be correct? Should check identd.. Bram Matthys 2019-06-04 20:05:27 +0200
  • 5f8dd67051
    if( -> if ( :D [skip ci] Bram Matthys 2019-06-04 20:04:22 +0200
  • e9da2eb3cb
    [tkldb] "skipped".. why? "expired" :D And don't bother users too much about this, unless in DEBUGMODE. Bram Matthys 2019-06-04 20:00:15 +0200
  • 6b1af917fc
    Do it the other way around than previous commit. Force 32 bit type. So it's compatible with machines where int is 64bit (ILP64), mostly for the future I guess. Bram Matthys 2019-06-04 19:52:59 +0200
  • 628f367849
    tkldb: version field should also be forced 64 bit or you'll have the same problem with porting 32 to 64 again... Bram Matthys 2019-06-04 19:34:37 +0200
  • 52b39acf78 Fixed return values/checks for helper functions/macros, return empty string instead of NULL when reading zero length strings, discard tkl->subtype and store spamf as a char instead of unsigned int, remove rewriting after DB read, also renamed TKLines/TKLs/etc to *-Lines for uniformity with other code GottemHams 2019-06-03 20:45:56 +0200
  • bb91ac1c56
    Update this a bit. Will take a look again later. [skip ci] Bram Matthys 2019-06-03 18:48:18 +0200
  • 9f64711113
    Remove FreeBSD 12 workaround Bram Matthys 2019-06-03 15:17:02 +0200
  • 597186d9c3
    BuildBot: Fix run-tests on FreeBSD 12 Bram Matthys 2019-06-03 14:44:35 +0200
  • 253df2c8db
    BuildBot: -j3 -> -j4 [skip ci] Bram Matthys 2019-06-03 13:31:45 +0200
  • 55757a5605
    Remove references to old test framework. [skip ci] Bram Matthys 2019-06-03 13:30:15 +0200
  • 73cea64c9f
    Updates for IRC test framework: changed port to 5901 of irc1 Bram Matthys 2019-06-03 13:03:43 +0200
  • bc8e4a5c47
    Updates for new IRC test framework Bram Matthys 2019-06-03 12:59:22 +0200
  • 321cf75fb7
    Resolve resolve merge conflict :D [skip ci] Bram Matthys 2019-06-01 08:57:19 +0200
  • 13f96b0a57
    Small adjustments to tkldb: convert some to safefree(), get rid of sizeof(char) - which is guaranteed to be 1 by C99 and on any decent compiler and always use MyMallocEx even when it's not necessary :D. Bram Matthys 2019-06-01 08:53:17 +0200
  • e78e303314
    Re-indent tkldb, sorry could not resist :D Bram Matthys 2019-06-01 08:46:22 +0200
  • 2556ae9d70
    [tkldb] Allow boot without existing database. Change return values to 1/0 (true/false). Bram Matthys 2019-06-01 08:39:32 +0200
  • b8e65a2f7f
    Buildbot: *NIX build test: add -DNOREMOVETMP to make valgrind do a better job at printing module information (I hope). Bram Matthys 2019-06-01 08:24:31 +0200
  • 7c32e4d63f
    Windows build: fix makefile.win32 Bram Matthys 2019-06-01 08:23:33 +0200
  • 4dbe8a8238 Resolve merge conflict :D GottemHams 2019-05-31 22:39:27 +0200
  • c697e2ea99 Renamed m_storetkl to just tkldb GottemHams 2019-05-31 22:25:18 +0200
  • bf6f885b98 Storetkl now also supports the hashed *@IP Z:Line thingy, also added errno calls to all error output GottemHams 2019-05-31 22:06:59 +0200
  • c43a1b15af Store TS types in a uint64_t before DB writing to prepare the module for a Year 2038 fix, also upgraded num/rewrite ints to 64 bit since they *might* be as big as tklcount GottemHams 2019-05-31 21:23:19 +0200
  • c6389270f9
    Remove a few useless #define's (And final test of buildbot today :D) Bram Matthys 2019-05-30 21:02:27 +0200
  • c3add3b41c
    Windows build: Randomly remove some slashes, for no reason. [skip ci] Bram Matthys 2019-05-30 20:12:25 +0200
  • 7d7d736df3
    More windows build fixes [skip ci] Bram Matthys 2019-05-30 20:03:50 +0200
  • 858b63e1d5
    Windows: remove .CHANGES.NEW [skip ci] Bram Matthys 2019-05-30 19:56:54 +0200
  • 9af24a56f9
    Buildbot: makefile.win32 updates [skip ci] Bram Matthys 2019-05-30 19:42:17 +0200
  • 57e06a7070
    Windows: add api-mtag to makefile.win32 Bram Matthys 2019-05-30 19:36:15 +0200
  • f0a773ee59
    Windows: Add conf_preprocessor to makefile.win32 Bram Matthys 2019-05-30 19:33:21 +0200
  • a2a7acc4bd
    Buildbot: more windows updates Bram Matthys 2019-05-30 19:30:20 +0200
  • e8e113a8c0
    Buildbot: ............................. Bram Matthys 2019-05-30 19:23:15 +0200
  • 120ec5cea3
    ............. Bram Matthys 2019-05-30 19:22:14 +0200
  • d02b4de5d3
    Buildbot: updates for windows Bram Matthys 2019-05-30 19:20:15 +0200
  • 2682d7bc6d
    Buildbot: Updates for windows Bram Matthys 2019-05-30 19:08:33 +0200
  • 9530006e70
    BB: Terminate unrealircd at end of test (otherwise it may hang buildbot) Bram Matthys 2019-05-30 16:48:05 +0200
  • 03fbc35fb7
    Buildbot: Run cipherscan not on FreeBSD for now, so we can test the rest. Bram Matthys 2019-05-30 16:14:06 +0200
  • 3f723323d0
    BuildBot: Use gmake on FreeBSD and temporarily disable select-config. Bram Matthys 2019-05-30 16:08:54 +0200
  • ecac3f9d4a
    Mention U5 in ./Config -quick restriction Bram Matthys 2019-05-30 08:52:08 +0200
  • 1b0a7cb9b8
    Fix build tests due to previous change. Bram Matthys 2019-05-30 08:51:05 +0200
  • 195cd17d02
    Rename LIBDIR to PRIVATELIBDIR in config.settings to avoid confusion. Bram Matthys 2019-05-30 08:46:13 +0200
  • 4004152a7a Updated m_storetkl's descriptions for added clarity GottemHams 2019-05-28 21:44:27 +0200
  • 0f97c03487 Probably a good idea to add storetkl stuff to Windows makefile too huh GottemHams 2019-05-28 21:38:38 +0200
  • d8ff67d088 Added m_storetkl to modules.default.conf GottemHams 2019-05-28 21:35:37 +0200
  • 35600fdfa0 Updated storetkl: write DB on a timer instead of hooking TKL_ADD/DEL, better DB format for improved compatibility with future Unreal versions, configurable .db path, support for softbans, write DB to a tempfile first to prevent corruption of existing DB, also applied some misc optimisations/portability improvements GottemHams 2019-05-28 21:34:11 +0200
  • 6cf386ee87
    ... Bram Matthys 2019-05-27 19:22:04 +0200
  • 9e87f92c64
    Fix small memory leak in SJOIN. Bram Matthys 2019-05-27 19:20:25 +0200
  • f046482761
    Freeing memory is usually a good idea (duh) Bram Matthys 2019-05-27 07:43:44 +0200
  • 55a183bde4
    Add "PROTOCTL MTAGS" to indicate message-tags & big buffer support. This so we can link to UnrealIRCd 4.x.... Bram Matthys 2019-05-26 13:56:09 +0200
  • 57fd5f4f2b
    Add HOOKTYPE_IS_HANDSHAKE_FINISHED: if a module returns 0 then register_user() will not be called. This is used, for example, by m_cap when the CAP LS handshake is still in progress. Modules can add their own requirements as they see fit. Note that, as for (CAP) functionality, this adds nothing new, it just implements it in a cleaner way, rather than all over the place, like in UnrealIRCd 4.x. Bram Matthys 2019-05-26 12:07:44 +0200
  • dde1cf3194
    Fix some mtag FIXME's. Bram Matthys 2019-05-26 11:45:58 +0200
  • 622cb43a48
    Manual audit of exit_client() done, for mtags. Bram Matthys 2019-05-26 11:36:40 +0200
  • 61b15d9f4d
    Mass update (automatic) of exit_client(). Next step is manual audit... Bram Matthys 2019-05-26 10:45:54 +0200
  • be4ef2e7e3
    Add message tags support in exit_client(). Yay.. another API change! Bram Matthys 2019-05-26 10:36:39 +0200
  • 9f54a19801
    New unified function for common: sendto_local_common_channels() and make this support mtags so it now works for NICK, ACCOUNT, AWAY. Still to do: exit client for QUIT. Bram Matthys 2019-05-26 10:08:02 +0200
  • 39cd11f504
    Fix OOB read due to message tag with trailing backslash. Bram Matthys 2019-05-25 15:48:33 +0200
  • b63a67dea0
    More parse/parse2 fixes like 6e219cd834. This fixes an OOB write (NUL byte write) due to trusting 'length'. It is now removed and renamed to bytes, it's only for adding lag. Bram Matthys 2019-05-25 15:40:18 +0200
  • 39af766ced
    Add a FIXME Bram Matthys 2019-05-25 15:40:10 +0200
  • a74bae0447
    Some cleaning in m_sajoin. Whitespace and if() order. Bram Matthys 2019-05-25 12:32:18 +0200
  • f320e32b7e
    Clean up compiler flag checker. (Since we don't need the C++ check, we use C only) Bram Matthys 2019-05-25 11:36:13 +0200
  • e0c2ccd99b
    Remove unused configure checks: HAVE_C99_VARLEN_ARRAY, HAVE_RAND_EGD, and an AC_SUBST for MKPASSWDLIBS. Bram Matthys 2019-05-25 11:27:53 +0200
  • 05e3ed63a0
    Default to --with-system-pcre2. Now all shipped libs default to system libs. Bram Matthys 2019-05-25 11:01:11 +0200
  • 5513b21936
    Remove old extras/regex Bram Matthys 2019-05-25 10:50:01 +0200
  • 1108b58951
    Remove old TRE regex engine. Hasn't been maintained since 2010 and has various outstanding crash and 100% CPU issues. We have been encouraging the PCRE2 engine since the start of UnrealIRCd 4 already. TRE is being phased out of U4 by the end of the year, so we can safely remove it in U5 already. Bram Matthys 2019-05-25 10:42:46 +0200
  • 185b4e05c0
    Whoops, this #comment in 'make install' showed up to end-users. Bram Matthys 2019-05-25 10:19:33 +0200
  • 4b45555edd
    Fix issue if compiling without TRE but with shipped argon2 (or other combinations). Need to create libdir in ./Config ;) Bram Matthys 2019-05-25 10:17:33 +0200
  • 6e219cd834
    Remove confusing 'bufend' variable from parse and parse2 functions. Such a variable suggests that we will never read past that, but that is not the case, since we (correctly) assume that the buffer is NUL terminated, which is ensured by dbuf_getmsg(). The 'length' is still available for informational purposes, to avoid strlen()'s at various places. Hm, I guess length can cause the same confusion as bufend, but still.. I like it better :D Bram Matthys 2019-05-25 09:50:36 +0200
  • a2f37722ae
    Fix unitialized variable issues in message-tags handling. Bram Matthys 2019-05-25 09:08:43 +0200
  • 8b1cd80700
    Make labeled-response work again after API change. TODO: handle both draft/ and without draft/, maybe upstream? Bram Matthys 2019-05-25 09:08:26 +0200
  • 427885681d
    Make account-tag not inherit. I don't think there's a bug right now, but it's not logical and makes it too easy to make a mistake. Bram Matthys 2019-05-25 08:05:26 +0200
  • daab5abc92
    Manual audit of sendto_one(): add mtags support where necessary. Bram Matthys 2019-05-24 21:09:55 +0200
  • 6e5df1a4c0
    Add mtags argument to sendto_one(). Phase 1 (automated), next is manual audit of all sendto_one's. Also it doesn't work yet... Bram Matthys 2019-05-24 17:38:48 +0200
  • c307d6c61b
    Make WHOX the default. Warn if you try to load both modules. Now uses CommandAdd() instead of an override, which was just an interim solution earlier. Bram Matthys 2019-05-23 19:08:49 +0200
  • c528b22cdd CIDR support for /WHOX ip matching. i 2019-05-22 23:01:55 +0300
  • 418b42e5bf
    More sendnumeric() and sendnumericfmt() conversions. Bram Matthys 2019-05-22 17:09:12 +0200
  • 4a11309344
    Transform sendto_one's to sendnumericfmt() - stage 1 Bram Matthys 2019-05-22 16:39:06 +0200
  • f8bee4941a
    Some fixes due to the sendnumeric() migration (see previous commits). Bram Matthys 2019-05-22 12:58:38 +0200
  • 39029555cb
    A few more sendnumeric() conversions, putting numerics in main file. Bram Matthys 2019-05-22 12:39:01 +0200
  • 7e4bfbc7c3
    Move more to sendtxtnumeric()... and some sendnumeric() leftovers. Bram Matthys 2019-05-22 12:10:57 +0200
  • 1a4cbb7023
    sendnumeric() - phase 2 Bram Matthys 2019-05-22 11:41:46 +0200
  • c27bb26abc
    sendnumeric() - stage 1 Bram Matthys 2019-05-22 10:43:07 +0200
  • 5fb9b12d5e
    Mass-replace sending of notices with sendnotice(), which exists for quite a while now ;) Bram Matthys 2019-05-22 09:34:34 +0200
  • a320bec089
    More message tags support in the API. sendto_server() now has mtags and sendto_match_butone as well. Still about 15 FIXME's that need to be resolved, but committing early. Bram Matthys 2019-05-21 19:00:35 +0200
  • 6d1d3de620
    Move .CHANGES.NEW -> doc/Config.header Bram Matthys 2019-05-19 16:30:27 +0200
  • f08e662878
    Update and document modules.default.conf wrt IRCv3 features (CAPs etc). Bram Matthys 2019-05-19 16:06:06 +0200
  • c3a929646c
    Move src/modules/cap/* to src/modules/ as the meaning got blurred. For example, msgid / message-ids is not a CAP, while server-time is. There mere fact of something being in CAP or not shouldn't cause something to be in different directories ;). Bram Matthys 2019-05-19 15:58:34 +0200
  • da31011b30
    Move most of the message-tags stuff to the message-tags module. Bram Matthys 2019-05-19 15:41:24 +0200
  • 13c59febbf
    Support for optional efunctions, with a default handler. Bram Matthys 2019-05-19 09:49:53 +0200
  • 4e17f85fe6
    1) New function new_message() which should be called when a new message is sent, or at least for channel events. 2) Move adding of msgid/time/account tags to modules, which is their proper place. Bram Matthys 2019-05-19 09:24:38 +0200
  • 10dcacdb0a
    @define, @if, @endif are all working. You can do something like: @define $SERVERIP "1.2.3.4" listen { ip $SERVERIP; port 6667; } Bram Matthys 2019-05-18 16:06:28 +0200
  • 35fa6cedac
    Convert some alloc+strlcpy to safestrldup in config code. -curce->ce_vardata = MyMallocEx(ptr-start+1); - strlcpy(curce->ce_vardata, start, ptr-start+1); +safestrldup(curce->ce_vardata, start, ptr-start+1); Bram Matthys 2019-05-18 14:32:36 +0200
  • 1adb02b56b
    Move new preprocessor from yesterday to it's own file (src/conf_preprocessor.c) Bram Matthys 2019-05-18 13:58:27 +0200
  • fad8c35847
    Initial support for dynamic configuration, $define, $if, $endif. Early commit, still cleaning up to do. But what works is: Bram Matthys 2019-05-17 20:43:36 +0200