Valentin Lorentz
eb1e27e20b
Add echo messages, either with the echo-message capability or simulated.
...
Plugin can opt in to getting echo messages by setting the class attribute
'echo_message = True' if they want to get echos.
This defaults to False in order not to break existing plugins, and because
they usually don't need it (there's outFilter for most cases).
2020-05-07 21:08:07 +02:00
Valentin Lorentz
572c609181
Add labels to outgoing messages when labeled-response is supported.
...
This is going to be useful for implementing echo-message; and to plugins
targetting only networks with labeled-response support.
2020-05-07 20:56:59 +02:00
Valentin Lorentz
307a2367f4
Don't add line breaks in the middle of capability names.
2020-05-07 18:38:18 +02:00
Valentin Lorentz
fc06aa72a6
Fix parsing ISUPPORT MODES with empty value.
2020-05-07 18:38:18 +02:00
Valentin Lorentz
2008f7b815
Exclude server_tags from truncation.
...
They have their own 8191 bytes.
2020-05-07 18:38:17 +02:00
Valentin Lorentz
da328b4985
Expire batches that never ended to avoid leaking memory.
2020-05-06 20:39:21 +02:00
Valentin Lorentz
cc0af4e790
Include start and end messages in a batch.
...
They may have useful server tags (especially when we start
supporting labeled-response).
2020-05-06 18:29:17 +02:00
Valentin Lorentz
a58c994954
Negotiate the 'setname' capability.
...
We don't store the name anywhere, but it can be useful to plugins.
2020-05-05 19:56:24 +02:00
Valentin Lorentz
309fc1233b
Add postTransition method to IrcCallback, called when irc.state.fsm changes.
2020-05-01 20:19:53 +02:00
Valentin Lorentz
f7130f2629
Add missing transition trigger on MOTD start.
2020-05-01 20:19:00 +02:00
Valentin Lorentz
22120ee862
Fix various issues with STS handling.
2020-05-01 19:46:19 +02:00
Valentin Lorentz
51ff013fcc
Apply STS policies when connecting to a server.
2020-05-01 19:46:19 +02:00
Valentin Lorentz
ecc2c32950
Add support for storing STS policies.
...
If on an insecure connection: reconnect.
If on a secure connect: store it and do nothing else.
For now, stored STS policies are not read when connecting to an
insecure server.
2020-05-01 19:46:19 +02:00
Valentin Lorentz
45ff70907f
[WIP] Start reworking Irc around a FSM.
...
To keep track of connection state instead of a complex implicit flow
between handling functions.
2020-05-01 19:43:27 +02:00
Valentin Lorentz
e7553dcca4
Add subcommand dispatching for CAP/FAIL/WARN/NOTE.
2020-01-23 14:25:10 +01:00
Valentin Lorentz
c4d073a9be
Rename doAuthenticate* functions to not conflict with callback names.
2020-01-23 14:24:41 +01:00
Valentin Lorentz
ac07b440dc
Rewrite ecdsa-nist256p-challenge using python-cryptography instead of python-ecdsa.
...
Which is more secure. Closes GH-1389.
It also fixes the protocol/format to use the same one as Atheme.
See also: 8a81224ba8
2020-01-01 12:07:59 +01:00
Valentin Lorentz
1ed47f802f
Request msgid capability.
2019-12-05 21:11:35 +01:00
Valentin Lorentz
2dddfefa98
Fix log on SASL failure.
...
Broken by 04b55805b8
.
2019-11-09 18:38:40 +01:00
Valentin Lorentz
6a9462be00
Fix reset of capabilities_ls.
...
Broken by 0014b206ad
.
2019-11-09 18:27:07 +01:00
Valentin Lorentz
04b55805b8
Log SASL mechanism on failure. Closes GH-1014.
2019-11-02 20:52:58 +01:00
Valentin Lorentz
9268356e97
Split 'CAP REQ' commands to not exceed 512 bytes.
2019-10-25 23:07:31 +02:00
Valentin Lorentz
0014b206ad
Reset capability set state on reconnection.
2019-10-25 22:40:51 +02:00
Valentin Lorentz
cfbbed3da9
Truncate incoming lines to 512-2, not 500.
2019-10-25 22:31:09 +02:00
Valentin Lorentz
84c1f1572d
Don't temporarily set msg.channel to invalid values.
...
This causes issue when multiple command threads deal with the same message.
2019-09-20 21:25:32 +02:00
Valentin Lorentz
c1ae3f5c81
all plugins: Use msg.channel instead of msg.args[0] + give network name to self.registryValue.
2019-08-24 23:35:01 +02:00
Valentin Lorentz
8bb31a54e7
Strip statusmsg chars in core to determine the actual channel.
...
Use msg.channel if relevant, otherwise strip them locally.
2019-08-24 14:52:59 +02:00
Valentin Lorentz
5b40b5136d
Limit statusmsg prefix stripping to PRIVMSG and NOTICE.
2019-08-18 10:09:11 +02:00
Valentin Lorentz
7a7cdb9f05
Add a 'channel' attribute to IrcMsg objects.
...
It's nicer to use 'irc.channel' instead of 'irc.args[0]', and .channel
provides the actual channel name (stripped of the statusmsg prefix),
so it can be used by plugins when they want to use the actual channel
name.
2019-08-17 22:23:51 +02:00
Valentin Lorentz
696254ff1b
Use irc.isChannel instead of ircutils.isChannel when possible.
...
It's aware of the network's 'chantypes'.
2019-08-04 21:52:40 +02:00
Valentin Lorentz
76699ec063
Add support for 'message-tags' capability, to receive TAGMSGs.
2019-05-08 21:19:53 +02:00
Valentin Lorentz
624553c069
irclib: Don't return the same nick twice when duplicates in supybot.nick.alternates + supybot.nick.
...
It migt crash on: 'assert newNick != self.nick'
2019-01-27 09:10:06 +01:00
Valentin Lorentz
c433f05190
Add a config var to require SASL auth when connecting.
2018-09-10 22:48:49 +02:00
Valentin Lorentz
7e98802809
Drop STARTTLS support, it complicates the connection initialization too much.
2018-01-24 09:27:39 +01:00
Nicolas Coevoet
2b030ac178
more arguments added for WHOX, to avoid external plugins recall same requests
2018-01-23 19:37:19 +01:00
Valentin Lorentz
40b9bbcb1b
Send 'AUTHENTICATE :+' at the end of a SCRAM auth.
...
https://github.com/ircv3/ircv3-specifications/pull/326
2018-01-14 22:53:40 +01:00
Valentin Lorentz
bdbc79bfc6
Fix for Slack.
2017-08-23 18:51:54 +02:00
Valentin Lorentz
b00081f6c9
Make REMOVE a high-priority message. Closes GH-1294.
2017-08-03 22:02:01 +02:00
Valentin Lorentz
8ce43110b6
Working support of scram-sha-256.
2017-01-11 00:10:46 +01:00
Valentin Lorentz
9be4db01f8
Fix ecdsa nameerror introduced in previous commit.
2017-01-10 23:27:50 +01:00
Valentin Lorentz
e87ad5b5a3
Untested implementation of SASL SCRAM auth.
2017-01-10 23:23:56 +01:00
James Lu
278a111f5f
irclib: expand standard substitutions in realname
2016-08-16 11:00:58 +02:00
Valentin Lorentz
b33dadea9e
Make INFO a bit less verbose when connecting.
2016-02-21 11:01:31 +01:00
Valentin Lorentz
fee97c0308
irclib: Tag AWAY messages with channel names.
2016-01-09 10:10:41 +00:00
Valentin Lorentz
4b1c766b42
Add support for STARTTLS (not tested).
2015-12-12 16:40:48 +01:00
Valentin Lorentz
30cb10e422
Add support for CAP NEW, including reauthentication.
2015-12-12 00:52:44 +01:00
Valentin Lorentz
834453eeff
Request capability.
...
We don't do anything with it, but plugins might use it.
2015-12-11 23:32:57 +01:00
Valentin Lorentz
8aff8170e4
Filter list of SASL mechanisms when provided (908 or IRCv3.2-style CAP LS).
2015-12-11 23:30:57 +01:00
Valentin Lorentz
45c23a8f54
Try all possible SASL mechanisms instead of just one.
2015-12-11 10:56:05 +01:00
Valentin Lorentz
15d59d1153
Handle AUTHENTICATE line splitting.
2015-12-10 20:08:53 +01:00