Commit graph

447 commits

Author SHA1 Message Date
JD Horelick f26e8b67e2 Remove all the DEFINE's and the random places they were used for the .conf-based ban stuff. 2010-12-04 17:26:14 -05:00
Jilles Tjoelker 01b7a527a3 Show the services login name in WHOWAS.
The numeric is the same (330) as used in WHOIS.

This takes at most half a megabyte of memory (large network, 30 char nicks).
2010-08-29 22:30:54 +02:00
Jilles Tjoelker 717238d2a2 Add target change for channels.
This has a separate enabling option channel::channel_target_change.

It applies to PRIVMSG, NOTICE and TOPIC by unvoiced unopped non-opers.

The same slots are used for channels and users.
2010-08-29 01:26:00 +02:00
Jilles Tjoelker 2fb6379693 Change ERR_MLOCKRESTRICTED to 742 as 735-739 seem for MONITOR extensions. 2010-08-24 22:51:20 +02:00
Stephen Bennett 51269a8737 Merge backout of 8939a7e03d15 2010-08-24 21:31:55 +01:00
Stephen Bennett 0f1ab797e4 Backed out changeset 8939a7e03d15
The code behind this capability was never implemented, and subsequent
discussions have agreed to approach the problem differently. There seems no
reason to continue advertising a capability that does nothing.
2010-08-24 21:30:56 +01:00
William Pitcock 6fb6bd15ae Enforce TS rules on MLOCKs. 2010-08-23 20:22:59 -05:00
William Pitcock 32de9f4e67 Add ERR_MLOCKRESTRICTED (735) to reflect bounces caused by MLOCK. 2010-08-23 18:59:32 -05:00
Jilles Tjoelker f5455d2cd5 Tweak auto-accept:
* does not apply to NOTICE (as those may well be automated)
* mirrors +g behaviour so that no useless accept entries are added for services
* respects max_accept, if it would be exceeded the message is dropped with numeric 494
* check moved up so this is checked before floodcount/tgchange
2010-07-04 17:14:56 +02:00
William Pitcock 545f0a0f07 strip_colour(): strip ASCII 29 (mIRC 7 italics). 2010-06-19 16:53:56 -05:00
Stephen Bennett c71a6e3bed Branch merge 2010-05-02 21:36:32 +01:00
Stephen Bennett 3b8a6350f8 Backed out changeset c57955c5225e
Now that MLOCK is no longer stored as a struct Mode, this is unnecessary.
2010-05-02 21:29:22 +01:00
Stephen Bennett 6b8db2daf2 Allow the final parameter of MLOCK to be empty, to remove an existing mlock 2010-05-02 20:42:46 +01:00
Stephen Bennett 78e6b731e4 Rework ircd-side MLOCK enforcement: instead of trying to track modes locked on or off, instead keep a simple list of mode letters that are locked, and reject any change to those modes. 2010-04-30 22:01:21 +01:00
William Pitcock bd44fc7b09 Automated merge with ssh://hg.atheme.org//hg/charybdis 2010-04-06 17:14:51 -05:00
William Pitcock c239b97f68 Hook up source-account-hostmask client protocol extension. 2010-04-06 17:14:44 -05:00
JD Horelick 944b0584ea Change config option for ident_timeout to default_ident_timeout as jilles
recommended.
2010-04-05 16:29:11 -04:00
JD Horelick 0ffb810660 Add a configuration option for ident_timeout. 2010-04-05 15:28:44 -04:00
Jilles Tjoelker 19716b9fd6 New custom channel mode API allowing reloading such modules.
Additionally, attempting to use too many modes or two times
the same letter is now detected and prevented.

Modules now request that a channel mode be added/orphaned,
instead of ugly manipulation from which that request had
to be guessed.

Slight changes are needed to modules that provide channel modes.
From the old API, one important function has been made static,
the other important function has been renamed, so loading old
modules should fail safely.
2010-04-01 01:16:16 +02:00
Jilles Tjoelker dca9e55257 Add propagated resvs, like klines and xlines. 2010-03-27 16:13:57 +01:00
Jilles Tjoelker 3cbbfb2556 Add propagated xlines, like klines. 2010-03-16 23:05:50 +01:00
Jilles Tjoelker 1702b69419 Add option general::use_propagated_bans to allow disabling new KLINE.
If this option is yes (default), KLINE by itself sets global (propagated) bans.
If this option is no, KLINE by itself sets a local kline following cluster{},
compatible with 3.2 and older versions.
2010-03-14 17:21:20 +01:00
William Pitcock 8727cbe88a Add propagation of MLOCK state for simple modes.
Special modes like +j can be tracked easily just by adding the necessary
code to parse them to set_channel_mlock().  This will cover propagation
as well.
2010-03-07 23:13:39 -06:00
William Pitcock 82eac99fc0 Fix typo. 2010-03-07 22:30:30 -06:00
William Pitcock ec55bec527 Add MLOCK capability token. 2010-03-07 22:25:41 -06:00
William Pitcock a51c452643 Rename channel_modes() to channel_modes_real(), and use macros to build both the mode list, and the mlock list. 2010-03-07 22:22:14 -06:00
William Pitcock bafd5ea61c struct Channel: add mode_lock structure to the channel object. 2010-03-07 21:41:06 -06:00
William Pitcock a51b50c366 struct Mode: add off_mode bitfield to describe disabled channel modes. 2010-03-07 21:40:34 -06:00
William Pitcock dd0f1f5b88 Add RPL_CHANNELMLOCKIS for ircd-side MLOCK enforcement. 2010-03-07 21:35:54 -06:00
Jilles Tjoelker 5c2b9eaf48 BAN: Reject bans with insufficient non-wildcard characters.
Such bans are not applied locally, but are propagated normally.
They can only be removed on a server that applies them.

Note that normally KLINE will not accept such bans.
This is mainly for services, differing min_wildcard and
ircd changes.
2010-03-06 01:45:41 +01:00
Jilles Tjoelker 431a1a2784 Add propagated klines.
A KLINE command without the ON clause now sets a propagated
("global") ban. KLINE commands with the ON clause work as
before.

Propagated klines can only be removed with an UNKLINE command
without the ON clause, and this removes them everywhere.
In fact, they remain in a deactivated state until the latest
expiry ever used for the mask has passed.

Propagated klines are part of the netburst using a new BAN
message and capab. If such a burst has an effect, both the
server name and the original oper are shown in the server
notice.

No checks whatsoever are done on bursted klines at this time.

The system should be extended to XLINE and RESV later.

There is currently no way to list propagated klines,
but TESTLINE works normally.
2010-03-05 18:36:44 +01:00
Jilles Tjoelker 9197bc355e Add code to expire "propagated" bans.
The data structure is very simple: a dlink list of all propagated bans.
2010-03-04 00:21:22 +01:00
Jilles Tjoelker c2e7ab8c1e ConfItem.next is not used, remove it. 2010-03-03 23:36:28 +01:00
Jilles Tjoelker f9545a9b54 Make struct operhash_entry private. 2010-03-01 01:24:00 +01:00
Jilles Tjoelker 27f616ddf5 Track who set a dline/kline/xline/resv as in ratbox3.
Like in ratbox3, there is no way to query this information
(other than bandb's tables, but they worked before this
commit).
2010-03-01 01:23:22 +01:00
Jilles Tjoelker a12ad04472 Generate the "Temporary K-line %d min" part from aconf->hold - aconf->created. 2010-02-28 16:27:06 +01:00
Jilles Tjoelker b52c294986 Store the creation time of klines and dlines as a time_t instead of as text.
The value 0 indicates the creation time is unknown (currently the case
for bandb).
Also store a creation time for xlines and resvs, but do not use it yet.
2010-02-28 00:46:56 +01:00
Alexander F?r?y 51027be825 Use RPL_QUIETLIST and RPL_ENDOFQUIETLIST instead of RPL_BANLIST and
RPL_ENDOFBANLIST for channel mode +q.
2010-02-27 01:08:41 +01:00
Jilles Tjoelker 666de5311f Remove some obsolete paths from config.h. 2010-02-22 23:53:45 +01:00
Jilles Tjoelker 1815320d3b Remove more old kline.conf stuff.
Make sure to recompile modules, stuff has been removed
close to the start of ConfigFileEntry.
2010-02-22 19:31:05 +01:00
Jilles Tjoelker 22342cd11f Remove code to write bans to csv files. 2010-02-22 19:09:46 +01:00
William Pitcock ff31db8473 Add support for client certificate fingerprints in o:lines. 2010-02-17 06:41:41 -06:00
Jilles Tjoelker 4f2685f3e1 Move target change code to src/tgchange.c,
so we can use it for /invite as well.
2010-02-15 21:58:34 +01:00
Jilles Tjoelker c9f01c4f2f target change: Allow free replies.
When a user receives a private message, notice or RPL_UMODEGMSG,
add the source to a special set of 5 target slots.
These slots are checked in the normal way when sending messages,
allowing a reply without using up a free target.

This feature will not be very useful if a user is being messaged
by many different users; to help this, messages blocked entirely
by +g or +R do not affect the targets. CTCP replies also remain
free in terms of targets.
2010-02-15 01:07:07 +01:00
Jilles Tjoelker 179becdf5f target change: Overwrite the least recently used target with a new one. 2010-02-15 00:31:17 +01:00
Jilles Tjoelker ad1d39a76f Make the number of targets tracked for target change a #define. 2010-02-13 15:18:17 +01:00
Jilles Tjoelker 8eda114a78 Pass certfp to other servers and show it in whois. Do not show it on connect.
The server protocol for this is
:<uid> ENCAP * CERTFP :<40 hex chars>
both in new user introductions and in burst.

As in oftc-hybrid, only the user themselves and opers can see the certfp.

Displaying the certfp on connect seems unnecessary to me,
the user can whois themselves if needed.
2010-02-06 00:18:27 +01:00
Jilles Tjoelker 8f10356217 Remove remnants of <foo>_t typedefs. 2010-01-30 15:57:10 +01:00
William Pitcock 2e918bf515 Merge +C (no CTCP to channels) from ircd-seven. 2010-01-19 02:11:04 -06:00
William Pitcock 83595e6016 Add bandb IRCd APIs. 2010-01-07 17:10:16 -06:00