summaryrefslogtreecommitdiff
path: root/src/modules/m_spanningtree/treesocket1.cpp
AgeCommit message (Collapse)Author
2017-12-03Rename the spanningtree module header to server.Peter Powell
In the future we will have server linking modules that are not the spanningtree module.
2017-11-17Fix a ton of -Wsign-conversion warnings.Peter Powell
2016-08-24Check for errors after calling IOHookProvider::OnAccept()Attila Molnar
2016-08-22m_spanningtree Change type of Link::Name to std::stringAttila Molnar
Switch to stdalgo::string::equalsci()
2016-08-08Keep multiple IOHookProvider references in class ListenSocketAttila Molnar
This adds the <bind:hook> config option which works together with <bind:ssl>
2015-05-13m_spanningtree Clean up commentsAttila Molnar
2015-01-20m_spanningtree Get rid of some boilerplateAttila Molnar
Make methods const while at it
2015-01-10Reduce std::string::substr() usageAttila Molnar
substr() returns a new string while erase() and assign() modify the existing one
2014-07-28m_spanningtree Throw a ProtocolException if a server SQUITs a server it ↵Attila Molnar
shouldn't
2014-07-28m_spanningtree Squit dead servers immediately when they die, not at the next ↵Attila Molnar
timer tick
2014-07-28m_spanningtree Add the TreeServer that split to the cull list and destroy ↵Attila Molnar
everything under it recursively at cull time instead of at squit processing time
2014-07-28m_spanningtree Move squit logic into TreeServer from TreeSocketAttila Molnar
2014-07-28m_spanningtree Remove now needless TreeSocket::ConnectionFailureShownAttila Molnar
2014-07-27m_spanningtree Keep track of whether we've sent our burst, to be used for ↵Attila Molnar
translation
2014-04-16m_spanningtree Throw an exception on protocol violations instead of ↵Attila Molnar
returning CMD_INVALID Catch CoreExceptions, log and close the link in OnDataReady()
2014-04-07Merge insp20Attila Molnar
2014-03-02m_spanningtree Do pointer comparison before deleting one of the pointers in ↵Attila Molnar
TreeSocket::Squit() While the previous code worked fine in practice, it was incorrect in theory
2014-03-02m_spanningtree Don't send snotices to servers about remote servers splittingAttila Molnar
The snotice is sent to opers when the SQUIT is processed by their server
2014-01-22Split IOHook into IOHook and IOHookProviderAttila Molnar
Create one IOHook instance for each hooked socket which contains all the hook specific data and read/write/close functions, removing the need for the "issl_session" array in SSL modules. Register instances of the IOHookProvider class in the core and use them to create specialized IOHook instances (OnConnect/OnAccept). Remove the OnHookIO hook, add a dynamic reference to ListenSocket that points to the hook provider (if any) to use for incoming connections on that socket. For outgoing connections modules still have to find the IOHookProvider they want to use themselves but instead of calling AddIOHook(hookprov), now they have to call IOHookProvider::OnConnect() after the connection has been established.
2014-01-05Improve UserManager::QuitUser() and related codeAttila Molnar
- Make operreason optional; NULL means same as quitreason - Remove User::quietquit, it is now handled internally in spanningtree - Send snotice about quitting remote users from spanningtree
2013-09-10m_spanningtree Minor fixesattilamolnar
- Handle the case when servers SQUIT themselves - Fix extra space in channel messages
2013-08-27m_spanningtree Introduce command buildersattilamolnar
2013-08-25m_spanningtree Allow server-to-server command handlers to specify whether ↵attilamolnar
they accept servers, remote users or both as the command source To make life easier for handlers accepting servers only as source, pass them a TreeServer* so they don't have to call FindServer()
2013-08-22m_spanningtree Add TreeServer::GetChildren() that replaces ChildCount() and ↵attilamolnar
GetChild()
2013-08-22m_spanningtree Change TreeServer::GetSocket() to always return the socket ↵attilamolnar
that can be used to talk to the server The only exception is the tree root (us) which has no associated socket (NULL) Add TreeServer::IsRoot() and IsLocal() helpers
2013-08-18m_spanningtree Move all server-to-server command handlers into handler classesattilamolnar
These commands are not registered in or called by the core. When looking for the handler of a command a new command table is searched first which contains all server-to-server commands. If a handler cannot be found in there, the core command table is consulted.
2013-08-17m_spanningtree Remove SpanningTreeUtilities* fields and parametersattilamolnar
2013-08-04Change the syntax of FOREACH macros to be less dumb.Adam
2013-08-04Change modules to use the MODNAME constant when logging.Peter Powell
The majority of modules were logging with their module name as the log type. There was a few places which were logging to a non-name type but, with the exception of CONFIG, those messages are so uncommon that it doesn't make sense to use a seperate type for them.
2013-07-26Use server ids when propagating squitsAdam
2013-07-24m_spanningtree Change the type of TreeServer::ServerName to std::stringattilamolnar
2013-07-24m_spanningtree Cleanup TreeServer and TreeSocket construction/destructionattilamolnar
2013-06-07Create IOHook interface (extracted from Module)attilamolnar
2013-05-19Fix spacing in calls to LogManager::Log.Peter Powell
2013-04-12m_spanningtree Remove unneeded #includesattilamolnar
2013-04-12m_spanningtree Change both prefix and first parameter of SQUIT to be a SIDattilamolnar
2013-04-12Tidy up source files:Peter Powell
- Use #pragma once instead of include guards. - Move header files in src/modules to include/modules. - Fixed various spacing issues.
2013-04-12Add LOG_ prefix to the log level enum values.Peter Powell
2012-09-30Fix more undefined behavior caused by referencing the returned buffer by ↵attilamolnar
std::string::c_str() when the object is temporary See 83c7cc45daf6fb1f8c36f15297a4657e45a34e88
2012-08-10m_spanningtree Add missing aposthrope to connection failed server noticeattilamolnar
2012-08-10m_spanningtree: Resolve issue #250ChrisTX
2012-07-08m_spanningtree Add function to easily determine whether a server was ↵attilamolnar
introduced to the network, use it to determine when to send SQUIT
2012-06-12m_spanningtree Burst to a new server before introducing it to the rest of ↵attilamolnar
the network Fixes issue #103 reported by @nenolod
2012-04-19Replace copyright headers with headers granting specific authors copyrightRobby-
2010-02-21Add HMAC implementation to HashProviderdanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12508 e03df62e-2008-0410-955e-edbf42e46eb7
2010-02-13Clean up treesocket naming confusion by adding a link block reference during ↵danieldg
negotiation git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12452 e03df62e-2008-0410-955e-edbf42e46eb7
2010-02-13Fix double-invocation of Squit that can cause a crash on delinkdanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12451 e03df62e-2008-0410-955e-edbf42e46eb7
2010-02-11Restart server_hash iteration after quitting dead and pinged out serversdanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12435 e03df62e-2008-0410-955e-edbf42e46eb7
2010-02-04Add DYING link state, push error messages on link, and only limit recvq on ↵danieldg
unauthenticated servers git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12370 e03df62e-2008-0410-955e-edbf42e46eb7
2010-02-03Split servers if they try to send infinite garbage without a newlinedanieldg
git-svn-id: http://svn.inspircd.org/repository/trunk/inspircd@12369 e03df62e-2008-0410-955e-edbf42e46eb7