summaryrefslogtreecommitdiff
path: root/modules
diff options
context:
space:
mode:
authorSadie Powell <sadie@witchery.services>2024-09-24 18:57:55 +0100
committerSadie Powell <sadie@witchery.services>2024-09-24 19:56:13 +0100
commitade8db023eca7575ad16096ecf5bb2ba38483a95 (patch)
treefd5fea54534e14e115d0618ae138db01b4d585b3 /modules
parent2ae733bcd15e841fc348b3d78a368f6c684fafb1 (diff)
Bump minimum UnrealIRCd version to 6.0.
Diffstat (limited to 'modules')
-rw-r--r--modules/protocol/unrealircd.cpp36
1 files changed, 13 insertions, 23 deletions
diff --git a/modules/protocol/unrealircd.cpp b/modules/protocol/unrealircd.cpp
index f6f2e0a5a..1a3b7145a 100644
--- a/modules/protocol/unrealircd.cpp
+++ b/modules/protocol/unrealircd.cpp
@@ -23,7 +23,10 @@ public:
PrimitiveExtensibleItem<ModData> ClientModData;
PrimitiveExtensibleItem<ModData> ChannelModData;
- UnrealIRCdProto(Module *creator) : IRCDProto(creator, "UnrealIRCd 4+"), ClientModData(creator, "ClientModData"), ChannelModData(creator, "ChannelModData")
+ UnrealIRCdProto(Module *creator)
+ : IRCDProto(creator, "UnrealIRCd 6+")
+ , ClientModData(creator, "ClientModData")
+ , ChannelModData(creator, "ChannelModData")
{
DefaultPseudoclientModes = "+BioqS";
CanSVSNick = true;
@@ -216,21 +219,15 @@ private:
void SendConnect() override
{
- /*
- NICKv2 = Nick Version 2
- VHP = Sends hidden host
- UMODE2 = sends UMODE2 on user modes
- NICKIP = Sends IP on NICK
- SJ3 = Supports SJOIN
- NOQUIT = No Quit
- TKLEXT = Extended TKL we don't use it but best to have it
- MLOCK = Supports the MLOCK server command
- VL = Version Info
- SID = SID/UID mode
- */
Uplink::Send("PASS", Config->Uplinks[Anope::CurrentUplink].password);
- Uplink::Send("PROTOCTL", "NICKv2", "VHP", "UMODE2", "NICKIP", "SJOIN", "SJOIN2", "SJ3", "NOQUIT", "TKLEXT", "MLOCK", "SID", "MTAGS", "BIGLINES");
+ // BIGLINES: enable sending lines up to 16384 characters in length.
+ // EAUTH: communicates information about the local server.
+ // MLOCK: enable receiving the MLOCK message when a mode lock changes.
+ // MTAGS: enable receiving IRCv3 message tags.
+ // SID: communicates the unique identifier of the local server.
+ // VHP: enable receiving the vhost in UID.
+ Uplink::Send("PROTOCTL", "BIGLINES", "MLOCK", "MTAGS", "VHP");
Uplink::Send("PROTOCTL", "EAUTH=" + Me->GetName() + ",,,Anope-" + Anope::VersionShort());
Uplink::Send("PROTOCTL", "SID=" + Me->GetSID());
@@ -353,11 +350,8 @@ private:
void SendLogin(User *u, NickAlias *na) override
{
- /* 3.2.10.4+ treats users logged in with accounts as fully registered, even if -r, so we can not set this here. Just use the timestamp. */
- if (Servers::Capab.count("ESVID") > 0 && !na->nc->HasExt("UNCONFIRMED"))
+ if (!na->nc->HasExt("UNCONFIRMED"))
IRCD->SendMode(Config->GetClient("NickServ"), u, "+d", na->nc->display);
- else
- IRCD->SendMode(Config->GetClient("NickServ"), u, "+d", u->signon);
}
void SendLogout(User *u) override
@@ -448,9 +442,7 @@ private:
bool IsTagValid(const Anope::string &tname, const Anope::string &tvalue) override
{
- if (Servers::Capab.count("MTAGS"))
- return true;
- return false;
+ return !!Servers::Capab.count("MTAGS");
}
};
@@ -1753,8 +1745,6 @@ public:
void OnUserNickChange(User *u, const Anope::string &) override
{
u->RemoveModeInternal(Me, ModeManager::FindUserModeByName("REGISTERED"));
- if (Servers::Capab.count("ESVID") == 0)
- IRCD->SendLogout(u);
}
void OnChannelSync(Channel *c) override