Bram Matthys
ced8b0935d
Check for and refuse to run with <2048 bits RSA keys. I hope nobody is
...
using 1024 bit RSA keys in 2019, but always better to check and inform
the admin about such a big mistake.
2019-08-15 08:52:28 +02:00
Bram Matthys
4f4a867b58
Update prototype of HOOKTYPE_CHANMSG to include sendflags, prefix and target.
...
I needed the target for echo-message, and also in the history module we no
longer save to the history any @#channel messages, since otherwise they
could be played back to people we shouldn't see them ;)
2019-08-13 18:45:38 +02:00
Bram Matthys
4c8fe6e8d9
Add CAP echo-message.
2019-08-13 18:36:25 +02:00
Bram Matthys
7fa2b8be05
More ssl -> tls moves. Also recommend to use 'certfp' rather than
...
the longer 'sslcertfp' or 'tlscertfp', we already support this since
4.0 so... updated the documentation as well.
2019-08-12 14:53:29 +02:00
Bram Matthys
2b0afacdf0
Rename of "ssl" to "tls" part 2
2019-08-12 14:35:32 +02:00
Bram Matthys
09cf485d6c
Mass rename of "ssl" to "tls" everywhere. Including conf/ssl to
...
conf/tls. If you are upgrading then conf/ssl will be renamed to
conf/tls and a symlink will be added (so certbot etc won't fail).
This is part 1...
2019-08-12 14:26:31 +02:00
Bram Matthys
61cf5f16d3
Ok.. I get it.
...
[skip ci]
2019-08-11 18:02:13 +02:00
Bram Matthys
63cfdb4b68
src/windows/win.h -> include/windows/win.h
...
and update the include name
@skipci
2019-08-11 17:58:53 +02:00
Bram Matthys
1498f1e716
Rename directories from 'win32' to 'windows'
2019-08-11 17:40:08 +02:00
Bram Matthys
25687c2bed
New efuncs: tkl_ip_hash() and tkl_ip_hash_type(), for the rmtkl module.
2019-08-11 14:48:07 +02:00
Bram Matthys
c50f65c5bf
Update two small FIXME's (nothing worth mentioning)
2019-08-10 14:09:00 +02:00
i
8c11ebd0e7
Make allow {} block always continue when there were no password or wrong password was specified.
2019-07-18 18:47:05 +03:00
i
d22a2a20f0
Make usermode +T block channel CTCP's as well.
2019-07-14 19:01:31 +03:00
Bram Matthys
806256e9c2
Move generate_batch_id() to core. Use chathistory BATCH type, if supported.
2019-07-13 15:25:56 +02:00
Bram Matthys
0cda60301d
Add set::broadcast-channel-messages [auto|always|never]:
...
This determines when UnrealIRCd will use broadcast instead of multicast
for delivering channel messages to servers.
The default is 'auto' which uses multicast but switches to broadcast
when channel mode +H is set. This is what people should normally use.
If you set it to 'never' then +H will not work properly if there are
servers with 0 users on them.
2019-07-13 07:59:12 +02:00
i
ca094f0a75
New set::ping-warning option (how fast the server should reply to PING before sending a warning to opers).
2019-07-11 16:47:02 +03:00
i
60ebc1375e
Support channel status prefixes for SAJOIN.
2019-07-10 17:42:46 +03:00
Bram Matthys
d09b9d53a4
Make SSL/TLS mandatory for UnrealIRCd to run. Previously you could get
...
around this by simply having no certs etc. I doubt anyone used it and
that was not a recommended configuration.
(More to come)
2019-07-09 20:06:11 +02:00
Bram Matthys
79bd78c0f3
Make it so UnrealIRCd has full control over the SSL/TLS versions in use
...
and not just the operating system.
This makes us use SSL_CTX_set_min_proto_version(), which unfortunately is
a less fine-grained control for disabling specific SSL/TLS versions.
However, after that we use SSL_CTX_set_options with SSL_OP_NO_xxx.
The latter is deprecated though. Will revisit this change before U5 release..
2019-07-07 10:22:29 +02:00
Bram Matthys
3b3f63b990
Add HAVE_EXPLICIT_BZERO. Fix compile problems on Debian and other older
...
systems without explicit_bzero. Current usage is only in the PRNG which
is not very important anyway. We can re-visit later by attempting to
provide a fallback portable version, but from what I've seen this is
pretty ugly.
2019-07-07 09:18:34 +02:00
Bram Matthys
b605b7fd86
Use delayed module unloading not only for modules with moddata but also
...
for modules which have extended channelmodes with parameters,
since they have the same problem.
2019-06-29 09:10:18 +02:00
Bram Matthys
fbf4946777
Update tkldb to use new LoadPersistentInt/SavePersistentInt functions.
...
And before that, I fixed these functions so they actually work :D
2019-06-29 08:44:12 +02:00
Bram Matthys
5182c664d1
Easier API for just-commited persistent variables. Example:
...
LoadPersistentPointer(modinfo, removefld_list, floodprot_free_removefld_list);
SavePersistentPointer(modinfo, removefld_list);
The above example was for a pointer, there are also functions for int and long,
which are even more simple:
LoadPersistentInt(modinfo, somevar)
SavePersistentInt(modinfo, somevar)
and
LoadPersistentLong(modinfo, somevar)
SavePersistentLong(modinfo, somevar)
both are untested, but will be tested soon...
2019-06-28 22:08:45 +02:00
Bram Matthys
0920967cc4
New module_load_variable / module_save_variable functions
...
and made floodprot to use these functions.
TODO: 1) Different functions for pointer/int/long, 2) macro?
2019-06-28 21:02:29 +02:00
Bram Matthys
2a7fc8042d
Add new moddata types: MODDATA_LOCALVAR and MODDATA_GLOBALVAR. Untested.
...
Code using it will soon follow (and then it will be tested :D)
2019-06-28 18:35:37 +02:00
Bram Matthys
38e9c100d4
Get rid of include/threads.h (unused)
2019-06-26 17:27:45 +02:00
Bram Matthys
a2510a5dca
Delete sock.h, isn't even used anymore.
...
[skip ci]
2019-06-26 17:25:34 +02:00
Bram Matthys
70cca778cd
Test compile w/o sock.h
2019-06-26 17:19:10 +02:00
Bram Matthys
c673e5bbc6
Get rid of now meaningless include/hash.h
2019-06-26 17:17:20 +02:00
Bram Matthys
8e44d4d5ab
Get rid of weird NullChn, which is now just NULL :D
2019-06-26 17:13:45 +02:00
Bram Matthys
ded4a65a60
u_int16_t -> uint16_t and u_int32_t -> uint32_t, remove typedefs for
...
these types and others, that should no longer be needed thanks to
stdint.h.
2019-06-26 17:06:46 +02:00
Bram Matthys
709c84fff9
Remove stupid hash table layer for channels that only eats 256k+ extra
...
memory and causes unnecessary slowdown. Stupid ->hits and ->links.
And get rid of "return (xyz)", must be "return xyz" :D
2019-06-26 16:56:17 +02:00
Bram Matthys
f1b0b6b76e
Make throttling code (connect-flood) use SipHash and increase the
...
hash table size from 1019 to 8192 to have fewer collisions.
2019-06-26 16:46:28 +02:00
Bram Matthys
d5395848b7
Double the size of hash tables to reduce collisions.
2019-06-26 16:16:56 +02:00
Bram Matthys
f6eac29592
hash_nick_name -> hash_client_name, hash_find_nickserver -> hash_find_nickatserver
...
Both were confusing :)
2019-06-26 13:45:55 +02:00
Bram Matthys
d5b643ceee
Rewrite hash table code to use SipHash (more to follow)
2019-06-26 13:24:02 +02:00
Bram Matthys
c507db9005
Get rid of Windows compile warning regarding abort().
2019-06-23 08:57:39 +02:00
Bram Matthys
7875fc9d7d
Compile fixes for Windows due to cleanup from yesterday.
2019-06-23 08:03:33 +02:00
Bram Matthys
7161f33311
Code cleanup: make src/*.c use the generic #include "unrealircd.h" file
...
(with only a few exceptions)
Now, we'll find out later if Windows still compiles, I guess ;)
2019-06-22 21:18:08 +02:00
Bram Matthys
e8ff5d77c7
Remove weird option set::snomask-on-connect. Doubt anyone uses it.
2019-06-22 19:36:54 +02:00
Bram Matthys
f9b589d0c6
Remove almost 1000 lines, all functions that are (now) unused.
...
Also, drop support for snomasks to non-ircops (TODO: more)
2019-06-22 19:32:11 +02:00
Bram Matthys
e03c8135a9
CHFL_CHANPROT -> CHFL_CHANADMIN, is_chanprot -> is_chanadmin
...
These are just remnants of the past, when +a was called channel protection.
It is called channel admin since as long as I can remember, and in 90%
of the code and documentation it is called that way.
2019-06-22 17:32:57 +02:00
Bram Matthys
cf29aa8feb
Replace various 90% identical functions with some macro's instead.
2019-06-22 17:29:03 +02:00
Bram Matthys
05202dd2a4
Move can_send() function from core to m_message.
2019-06-22 16:03:06 +02:00
Bram Matthys
bf4d96e991
can_send() now returns 0 (false) or 1 (true), rather than magic values.
...
Also, the HOOKTYPE_CAN_SEND prototype changed so you can communicate
the error message in a flexible way, similar to what I just did
with extbans.
2019-06-22 15:57:32 +02:00
Bram Matthys
be49ef0bb8
More extban API changes... fun...
2019-06-22 15:11:16 +02:00
Bram Matthys
086d370704
Change extban API: pass 'msg' in BANCHK_MSG and (new) BANCHK_LEAVE_MSG.
2019-06-17 20:19:34 +02:00
Bram Matthys
1cfebcf05e
Add new set::part_instead_of_quit_on_comment_change to convert QUIT to PART
...
in case of a change in the quit comment, such as color stripping / blocking.
The default is 'no', but some users may like this to be 'yes' so things like
+S only affect the channel and not the quit for all channels.
This hereby also lays the groundwork for some next commits of 'i' :)
The configuration item name may still change if I think of a better one....
2019-06-17 08:20:42 +02:00
Bram Matthys
7b42c252ea
Some documentation updates, nothing important
...
[skip ci]
2019-06-16 10:08:50 +02:00
Bram Matthys
bd785a9309
Some initial work for the upcoming TKL 'e'/'E'/TKL_EXCEPT type.
2019-06-16 08:42:41 +02:00