3
0
mirror of https://github.com/jlu5/PyLink.git synced 2024-12-27 05:03:07 +01:00
Commit Graph

1041 Commits

Author SHA1 Message Date
James Lu
722881bc33 inspircd: fix incorrect lstrip() usage when mangling mode names 2019-05-31 18:13:21 -07:00
James Lu
917543dd12 inspircd: burst shorter version strings on insp3
These get shown in /map, for example.
2019-05-31 18:13:15 -07:00
James Lu
b260a28c8f inspircd: handle insp3 SERVER command 2019-05-31 18:12:06 -07:00
James Lu
12784a4b5b inspircd: handle insp3 IJOIN with TS & flags 2019-05-31 17:46:36 -07:00
James Lu
ea753774fd inspircd: check for local protocol version instead of the remote's
We should be speaking the insp20 protocol even to insp3 servers if configured to do so, not some broken hybrid of the two.
OPERTYPE handling remains an exception.
2019-05-31 17:35:49 -07:00
James Lu
c43d13ef61 inspircd: FTOPIC handling for InspIRCd 3 2019-05-02 18:05:54 -07:00
James Lu
66485ec6a2 inspircd: send SINFO instead of VERSION on 1205 2019-05-02 17:42:45 -07:00
James Lu
3d69b7f4e8 ircs2s_common: fix sending the wrong target in PING 2019-05-02 17:36:42 -07:00
James Lu
ad4cb9561c inspircd: add FJOIN, IJOIN, KICK handling for InspIRCd 3
IJOIN is new. Strip membership IDs from incoming FJOIN and KICK for now.
2019-05-02 17:36:42 -07:00
James Lu
08386a8ef7 inspircd: get rid of MIN_PROTO_VER
We should always check that our remote has a protocol version >= our own.

i.e. support links using PyLink 1202 <-> InspIRCd 1205, PyLink 1205 <-> InspIRCd 1205, but NOT PyLink 1205 <-> InspIRCd 1202
2019-05-02 17:36:42 -07:00
James Lu
db6d5d6d05 inspircd: actually read our DEFAULT_IRCD setting 2019-05-02 17:36:38 -07:00
James Lu
42e1eda51a inspircd: use NUM to send numerics on insp3 2019-05-02 17:06:04 -07:00
James Lu
4276607ee4 inspircd: rework modelist negotiation to support InspIRCd 3.0 2019-05-02 16:52:29 -07:00
James Lu
0fe8a8d51a inspircd: move protocol version check into CAPAB START handler
InspIRCd 3.0 stopped sending the protocol version in CAPAB CAPABILITIES, but it's always available in CAPAB START.
2019-05-02 16:11:53 -07:00
James Lu
6f617cb068 inspircd: allow choosing the target IRCd via "target_version" option 2019-05-02 16:11:21 -07:00
James Lu
44a364df98 Move message tags code from clientbot to ircs2s_common 2019-05-02 15:54:34 -07:00
James Lu
e3d72c43a4 inspircd: move proto_ver constants into the class definition 2019-05-02 15:47:03 -07:00
James Lu
f90b0c8577 clientbot: avoid adding empty nicks to the state
It looks like names replies may end with an extra space, which should not be considered as part of the nick list..
2019-04-29 12:04:11 -07:00
James Lu
a8bb5f66e5 clientbot: log the entire args list when splitting /names reply fails 2019-04-29 11:58:18 -07:00
James Lu
9056799633 clientbot: only split /names replies by spaces
This fixes issues with colored hostnames because \x1f is treated as a whitespace char by str.split().

Closes #641.
2019-04-08 22:35:37 -07:00
James Lu
1780271dd0 unreal: work around a potential race when sending kills on join 2019-03-01 23:34:41 -08:00
James Lu
ba17821af4 Declare visible-state-only by default in ClientbotBaseProtocol 2019-02-16 16:43:05 -08:00
James Lu
ac8b7babf1 inspircd: don't allow _ in hosts
CHGHOST on InspIRCd 2.0 does not see this as valid.
2019-02-12 15:55:10 -08:00
James Lu
cfbadb4539 Move _squit, _get_SID, _get_UID wrappers into PyLinkNCWUtils
ClientbotBaseProtocol requires these for the squit wrapper to work.
2019-02-12 00:38:37 -08:00
James Lu
873283e61e clientbot: properly bounce kicks on networks not implementing them 2019-02-10 13:01:31 -08:00
James Lu
d089b8d40e clientbot: split wrapper stuff into a ClientbotBaseProtocol class
Closes #632.
2019-02-10 12:40:02 -08:00
James Lu
52f588c920 Track affected servers in SQUIT hooks 2018-12-27 12:09:40 -08:00
James Lu
4d39ad1c84 unreal: bump protocol version to 4200
Corresponding to UnrealIRCd 4.2.0.
2018-10-05 23:57:20 -07:00
James Lu
2f4476eb0c unreal: remove invalid comparison
(Regression from commit fac6fe506f)
2018-09-21 21:40:56 -07:00
James Lu
667fa610ec unreal: remove duplicate conversion 2018-09-16 11:29:25 -07:00
James Lu
e929fda293 unreal: Bump protocol version to 4019 (4.0.19-rc1) 2018-09-12 17:35:30 -07:00
James Lu
d5fd7b03f5 unreal: enable slash-in-hosts, it seems to work fine 2018-09-12 17:35:25 -07:00
James Lu
fac6fe506f unreal: use SJOIN in join() to work around weird TS corrupting bugs
This seems to be what Unreal itself does anyways.
2018-08-25 18:50:51 -04:00
James Lu
298913200c clientbot: properly handle cases when the bot is told to kick itself
- Treat kicks to the PyLink client as a real user kick instead of a virtual one
- Forward on kick hooks if the PyLink client is kick target - this allows things like autorejoin to work

Closes #377.
2018-08-25 01:14:26 -04:00
James Lu
5838d88404 networks: reload shared modules used by protocol modules too 2018-08-23 02:57:03 -04:00
James Lu
9cf507183d clientbot: filter PART hooks for only parts we didn't initialize
This fixes Relay being confused by its own "Relay plugin unloaded" /part's, and makes Clientbot's behaviour in this regard consistent with other protocols.
2018-07-18 19:14:47 -07:00
James Lu
bba235bba2 Update GitHub repository address 2018-07-08 12:54:10 -07:00
James Lu
76c0db15c4 core: merge TLS validation code into IRCNetwork (#592)
Certificate verification is now enabled for all Clientbot networks, but not yet for S2S links (self-signed certs are common here and direct IP links even more so)
2018-06-15 15:29:15 -07:00
James Lu
4524aebbac clientbot: initial pass of TLS cert validation (#592)
This works OK, but we should make the validation options built-in instead of clientbot-specific.
2018-06-15 02:47:12 -07:00
James Lu
040b009fcb clientbot: ignore RPL_ENDOFBANLIST (368) responses for removed channels 2018-06-15 02:19:56 -07:00
James Lu
1b68bfadc6 coremods, plugins, protocols: drop now redundant allowAuthed=False in is_oper() calls 2018-06-11 23:56:44 -07:00
James Lu
1a97a32ef5 ircs2s_common: return just the kill reason as text in kill parsing (#520) 2018-06-11 19:26:42 -07:00
James Lu
31a0d36990 clientbot: ignore missing args in 324 / RPL_CHANNELMODEIS
Fixes #537.
2018-06-08 18:45:20 -07:00
James Lu
1ab5d614c0 protocols: convert user TS to an int when receiving new users (#594) 2018-05-26 16:26:14 -07:00
James Lu
f20fa5e995 Add User.get_fields(), and rework plugins to fix $nick broken expansions
User.nick is no longer a writable attribute since a085aed924, so it won't show up in __dict__ now.

get_fields() replaces the User.__dict__ hack various plugins used and also provides some new expansion variables:
- $sid and $server expand to the server ID and name respectively
- $modes and $channels are now preformatted strings
- $netname expands to the network name

$manipulatable and $_irc were removed since their values aren't quite meaningful as strings
2018-05-26 02:12:38 -07:00
James Lu
b9f782868c inspircd: remove users from the state immediately when sending a kill
This matches Anope and Atheme's behaviours.

Closes #607.
2018-05-21 00:33:13 -07:00
James Lu
3120fa5396 clientbot: stop sending duplicate JOIN hooks
Also set _clientbot_initial_who_received on 315/ENDOFWHO, instead of on the first /who response we get.

Really fixes #551.
2018-05-09 22:31:19 -07:00
James Lu
451db74f0c clientbot: don't send duplicate away statuses 2018-05-09 22:23:14 -07:00
James Lu
f54382534c kick and kill should raise NotImplementedError when not supported by a protocol
Closes #605.
2018-05-09 22:19:03 -07:00
James Lu
8eba402a33 clientbot: drop pre-WHO join bursting with userhost-in-names, it's too unreliable
Closes #602.
Closes #551.
2018-04-24 12:39:29 -07:00