99 Commits

Author SHA1 Message Date
Sadie Powell
bfa5fb407e Merge branch 'insp3' into master. 2019-02-05 00:47:30 +00:00
B00mX0r
e844a2cef9 Fix a minor typo in ssl.h 2019-02-01 09:43:32 +00:00
Sadie Powell
0fab643858 Convert repetitive functions to use C++11 variadic templates. 2019-01-25 15:17:37 +00:00
Sadie Powell
c78ecdf579 Replace the override macro with the override keyword. 2019-01-25 02:52:11 +00:00
Peter Powell
961109ae4f Remove trailing whitespace from various source files. 2019-01-24 22:18:22 +00:00
Peter Powell
dba2cddc46 Fix overriding <options:exemptchanops> with the exemptchanops mode.
Closes #1558.
2019-01-24 18:03:12 +00:00
Peter Powell
ee7db9bbfb Store durations as unsigned long not long in XLine and m_filter. 2018-12-13 14:20:43 +00:00
Peter Powell
9dab477dad Allow modules to check if a user is on a callerid accept list. 2018-12-09 04:28:20 +00:00
Peter Powell
9574997540 Only check if a SSL cert is usable if we're getting the fp. 2018-11-26 14:33:44 +00:00
Peter Powell
6adca3e099 Fix the OnSendWhoLine event being completely broken with WHOX. 2018-11-15 19:24:47 +00:00
Peter Powell
79892a727e Implement support for WEBIRC attributes. 2018-11-04 15:29:06 +00:00
Peter Powell
ae0ae8ea61 Allow HAProxy to specify that a client is connecting with SSL. 2018-10-25 13:50:43 +01:00
Peter Powell
75e144b55e Fix the chanhistory module being inconsistent across servers.
Closes #331.
2018-10-01 12:34:47 +01:00
Peter Powell
584d456903 Add support for the IRCv3 batch specification.
Co-authored-by: Attila Molnar <attilamolnar@hush.com>
2018-08-13 22:01:42 +01:00
Peter Powell
2249524355 Add support for the IRCv3 server-time specification.
Co-authored-by: Attila Molnar <attilamolnar@hush.com>
2018-08-13 22:01:21 +01:00
Peter Powell
58a0a7e014 Implement IRCv3 message tag support.
Co-authored-by: Attila Molnar <attilamolnar@hush.com>
2018-08-13 21:51:11 +01:00
Peter Powell
ba23c2b115 Convert AWAY to use cross-module events and clean up slightly.
OnSetAway has been replaced with four events. OnUserPreAway and
OnUserPreBack can be used to deny an away state change and/or
change the away message of a local user. OnUserAway and OnUserBack
allow modules to be notified that a user's away state has changed.
2018-08-12 15:01:45 +01:00
Peter Powell
abbf70b2a3 Rename User::fullname to realname and make it private. 2018-07-30 18:50:34 +01:00
Peter Powell
8cb20e3545 Replace most usages of "GECOS" with "real" or "real name". 2018-07-30 18:30:11 +01:00
Peter Powell
384ef31bc0 Use CommandBase::Params instead of std::vector<std::string>.
This is presently a typedef but will soon be replaced with a class
that encapsulates both tags and parameters.
2018-07-26 20:12:14 +01:00
Peter Powell
454c8d3749 Move OnStats from the core to a cross-module event.
Some core code still exists in the XLine system but this will be
replaced when the XLine system is replaced later.
2018-04-08 16:54:27 +01:00
Daniel Vassdal
d38f2ad213 SQL: Add HasColumn() to check if a result contains a named column. 2018-04-07 11:50:08 +01:00
Dylan Frank
3fb20b61b6 Ignore expired or invalid client certificates (#1468).
Fixes #1345.
2018-03-29 19:11:55 +01:00
Peter Powell
d2efdbf6bb Fix building on Windows (mostly). 2018-02-17 17:12:26 +00:00
Peter Powell
372bb6ec31 Make InspIRCd::Format return std::string instead of const char*.
Using the latter is problematic as if you don't copy the return
value before calling Format again your formatted message will be
overwritten by something else. This bug was observed in m_callerid
where InspIRCd::Format was being used for formatting two arguments
the latter of which was being overwritten with the former.

We could have preserved the return type and just copied the string
but then callers would have had to deallocate the string once they
have finished with it which is an undesirabable burden to put on
callers.
2018-01-03 12:38:40 +00:00
Peter Powell
b6f57c0f06 Improve and modernize the SQL system API.
- Move everything into the SQL namespace and drop the SQL prefix.
- Move SQLProvider::PopulateUserInfo to SQL::PopulateUserInfo.
- Rename SQLEntry to SQL::Field and clean up.
- Rename SQLEntries to SQL::Row.
- Rename SQLerror to SQL::Error and clean up.
- Rename SQLerrorNum to SQL::ErrorCode and drop the SQL_ prefix.
- Rename ParamL to SQL::ParamList.
- Rename ParamM to SQL::ParamMap;
- Make implementing SQLQuery::OnError mandatory.
- Redo most of the documentation in the sql header.
2017-12-22 16:49:01 +00:00
B00mX0r
197c3445b0
Add SHUN as a /filter action
This resolves #483
2017-12-21 09:21:53 -08:00
Peter Powell
70be9c79d2 Move OnSync{Channel,Network,User} to ServerEventListener. 2017-12-03 13:58:10 +00:00
Peter Powell
4aa27e75af Rename the spanningtree module header to server.
In the future we will have server linking modules that are not the
spanningtree module.
2017-12-03 13:54:11 +00:00
Peter Powell
91e0af0fc4 Add the override keyword in places that it is missing.
GCCs warnings for this are much better than Clangs.
2017-11-21 15:51:45 +00:00
Peter Powell
b047c903da Add support to IOHook for retrieving the hostname sent via SNI. 2017-10-29 11:15:47 +00:00
Peter Powell
d865b43486 Hide User#host and User#dhost and use accessors to modify them.
This removes the need to invalidate the cache after changing a
user's hostname.
2017-10-28 16:16:10 +01:00
Peter Powell
dcd3438011 Add a helper function for calling the OnCheckExemption event. 2017-10-21 16:34:48 +01:00
Peter Powell
74dd288542 Move <dns:timeout> out of the core. 2017-09-03 19:28:50 +01:00
Peter Powell
ff3b706b25 Merge pull request #1271 from SaberUK/master+exemption
Move the OnCheckExemption hook out of the core.
2017-07-27 13:13:16 +01:00
Adam
f2e3762ff4
core_dns: add support for txt records
This might be used later by m_dnsbl to get reasons for listings
2017-04-23 16:35:21 -04:00
Peter Powell
81027f3a08 Move the OnCheckExemption hook out of the core. 2017-03-20 11:47:59 +00:00
Attila Molnar
65667e7cc2 Fix Windows build and most MSVC warnings 2016-09-02 19:58:44 +02:00
Adam
14556541bb core_dns Make question a member of request, move common FindAnswerOfType to be a member of query 2016-08-25 17:12:48 +02:00
Attila Molnar
f91da925b5 Export the GetCiphersuite() method from the SSL modules 2016-04-28 17:06:16 +02:00
Attila Molnar
b96329dc3b Add SSLIOHook::IsSSL() to determine whether a socket is using SSL or not
Use it in a few places
2016-04-28 17:04:33 +02:00
Attila Molnar
1b8f7ef94a Fix oversight in the last Stats::Context:AddRow() method 2016-02-25 19:19:04 +01:00
Attila Molnar
304b6dbbf5 Introduce Stats::Context, pass it to the OnStats hook and switch all code to it 2016-02-25 17:02:03 +01:00
Attila Molnar
0c42bcde16 Convert WhoisContext::SendLine() calls to pass the parameters of the numeric as method parameters 2016-02-25 16:27:30 +01:00
Attila Molnar
18d5754871 m_ircv3 Make WriteNeighborsWithCap() available for use in other modules 2015-12-05 16:47:41 +01:00
Attila Molnar
c933f32408 m_cap Make Capability objects compatible with dynamic_references, add Cap::Reference 2015-12-05 16:42:17 +01:00
Attila Molnar
425d54073a m_cap Specialize extension item 2015-12-05 16:16:49 +01:00
Attila Molnar
302053cf8f m_cap Provide the OnCapValueChange event and add Cap::Manager::NotifyValueChange() 2015-12-05 15:58:48 +01:00
Attila Molnar
912fd7a922 m_cap Provide the OnCapAddDel() event 2015-12-05 15:57:00 +01:00
Attila Molnar
b9c6792cd6 m_cap Add Capability::GetCapValue(), list capabilities with values 2015-12-05 15:50:07 +01:00