aboutsummaryrefslogtreecommitdiffstats
path: root/core/s2smanager.lua
Commit message (Collapse)AuthorAgeFilesLines
* core: Prefix module imports with prosody namespaceKim Alvefur2023-03-171-2/+2
|
* core.s2smanager: Don't remove unrelated session on close of bidi sessionKim Alvefur2022-06-271-1/+1
| | | | | | | | | | | | | | Normally with bidi, any outgoing connection should be the same as the incoming, hence when closing a bidi connection it should be removed as a route to the remote server. However it is not guaranteed, a remote bidi-capable server might have decided to open a new connection for some reason. This can lead to a situation where there are two bidi connections, and the s2sout route is a locally initiated s2sout connection. In this case, such a s2sout connection should be kept. Noticed in a rare case where bidi has just been enabled on a running server, and something establishes new connections immediately when a connection is closed.
* s2smanager: Fire s2s-destroyed event to mirror s2s-createdMatthew Wild2021-11-121-0/+1
| | | | | | | | | | | | The existing events do not fire for unauthed sessions, for example (because the type does not match). I deemed changing their behaviour too risky, and the current behaviour may even be more desirable for some uses. This means we now have roughly paired events: - s2s-created -> s2s-destroyed (global only) - s2sin-established -> s2sin-destroyed (global + host) - s2sout-established -> s2sout-destroyed (global + host)
* core.s2smanager: Set "direction" on destroyed sessions (fixes #1641)Kim Alvefur2021-03-031-0/+1
| | | | | | | | Should prevent errors in certain places where it logs session.direction captialized using gsub. Might cause bugs tho, but then the session is destroyed so maybe it doesn't matter?
* s2s: Allow passing a custom error for bouncing queued stanzas (#770)Kim Alvefur2019-11-231-2/+2
| | | | Since stream errors and stanza errors are different
* core.s2smanager: Fix traceback due to mixup with to/fromKim Alvefur2019-10-051-1/+1
| | | | Forgot to swap to and from in 3123a13cf577
* core.s2smanager: Remove bidi-enabled s2sin from outgoing routing tableKim Alvefur2019-10-051-0/+3
| | | | Caused creation of new s2sout instead of proper bidi-enabled s2sin.
* core.s2smanager: Add map of names authenticate for remote on s2sout for ↵Kim Alvefur2019-09-071-0/+1
| | | | | | parity with s2sin Making s2sin and -out look more alike in preparation for bidi support
* core.s2smanager: Add [direction] boolean flags to s2s connectionsKim Alvefur2019-09-071-0/+2
| | | | This will allow representing connections that go both directions
* core.s2smanager: Rewrite log line to use formatting instead of concatenationKim Alvefur2019-07-301-5/+3
| | | | | Makes it more in line with logging elsewhere. Potentially avoids or at least delays creation of new string.
* core.s2smanager: Remove use of tostring in loggingKim Alvefur2019-07-291-2/+2
| | | | This is now performed by loggingmanager
* core.s2smanager: Fix previous commit (Thanks Martin)Kim Alvefur2019-03-301-1/+1
|
* core.s2smanager: Use util.session to create sessionsKim Alvefur2019-03-291-17/+15
|
* core.s2smanager: Spread out session tables over multiple linesKim Alvefur2019-03-291-3/+14
| | | | Improves readability
* core.s2smanager: Rename variable to be same in two functionsKim Alvefur2019-03-291-4/+4
|
* core.s2smanager: Add stub reset_stream method to destroyed sessionsKim Alvefur2019-01-161-0/+3
| | | | Fixes traceback if connection is closed from the 's2s-authenticated' event
* s2smanager: Explicitly export the incoming_s2s table [luacheck]Kim Alvefur2018-03-231-2/+2
|
* vairious: Add annotation when an empty environment is set [luacheck]Kim Alvefur2018-02-281-0/+1
|
* Merge 0.10->trunkKim Alvefur2017-03-061-1/+3
|\
| * core: Split some very long lines [luacheck]Kim Alvefur2017-03-041-1/+3
| |
* | s2smanager: Include a stub thread on destroyed sessions (thanks Link Mauve)Kim Alvefur2016-06-091-0/+1
|/
* core.*: Remove use of module() functionKim Alvefur2015-02-211-6/+12
|
* Merge 0.9->0.10Kim Alvefur2015-05-141-0/+1
|\
| * s2smanager: Make sure destroyed sessions have a sends2s methodKim Alvefur2015-05-141-0/+1
| |
* | portmanager, s2smanager, sessionmanager, stanza_router, storagemanager, ↵Matthew Wild2015-05-061-2/+2
| | | | | | | | usermanager, util.xml: Add luacheck annotations
* | Remove all trailing whitespaceFlorian Zeitz2013-08-091-4/+4
|/
* sessionmanager, s2smanager: Remove unused importsMatthew Wild2013-04-111-2/+2
|
* sessionmanager, s2smanager: Remove open_session tracingMatthew Wild2013-04-081-8/+1
|
* s2smanager: Remove unused function parameterMatthew Wild2013-03-221-1/+1
|
* s2smanager: Access prosody.hosts instead of hosts global directlyMatthew Wild2013-03-221-1/+1
|
* s2smanager, mod_s2s, mod_dialback, mod_saslauth: Move ↵Matthew Wild2013-03-221-73/+2
| | | | s2smanager.make_authenticated() to mod_s2s, and plugins now signal authentication via the s2s-authenticated event
* s2smanager: Use unused local, reduce table indexingKim Alvefur2013-03-131-5/+5
|
* s2smanager: Generate session names used for logging the same way everywhereKim Alvefur2013-01-241-1/+1
|
* s2smanager: missing return on session.send function.Marco Cirillo2012-08-261-1/+1
|
* s2smanager: Remove logging of (unknown) in a case where from_host and ↵Matthew Wild2012-07-231-1/+1
| | | | to_host should always be set
* Hopefully inert commit to clean up logging across a number of modules, ↵Matthew Wild2012-07-231-2/+2
| | | | removing all cases of concatenation when building log messages
* s2smanager: Fix a traceback when we close a s2s connection ourselves (thanks ↵Waqas Hussain2012-06-131-1/+1
| | | | for the testing Zash).
* Merge with ZashMatthew Wild2012-05-101-27/+2
|\
| * s2smanager, mod_s2s: Move checking DNS timeout option to mod_s2sKim Alvefur2012-05-101-5/+0
| |
| * s2smanager: Clean up unused imports.Kim Alvefur2012-05-101-22/+2
| |
* | mod_s2s, s2smanager, mod_dialback: Move addition of session.send() on s2sin ↵Matthew Wild2012-05-101-2/+7
|/ | | | to after they are authenticated (thus from mod_s2s to s2smanager). Update mod_dialback to fire route/remote directly, as session.send() is no longer available for s2sin_unauthed. Fixes #291.
* Merge timber->trunk - thanks everyone!Matthew Wild2012-04-241-580/+13
|\
| * s2smanager, mod_s2s: Move import of dns_max_depth to mod_s2sKim Alvefur2012-03-111-1/+0
| |
| * s2smanager, mod_s2s: clear up ip_hosts after s2s is marked as established, ↵Marco Cirillo2012-02-241-0/+1
| | | | | | | | remove useless space from mod_s2s code
| * s2smanager: remove send_to_host.Florian Zeitz2012-02-241-4/+1
| |
| * s2smanager, mod_s2s, mod_s2s/s2sout: Split connection handling out of ↵Matthew Wild2012-01-231-570/+11
| | | | | | | | s2smanager into mod_s2s, and further split connection logic for s2sout to a module lib, s2sout.lib.lua
* | Merge 0.9->trunkMatthew Wild2012-03-091-1/+1
|\ \
| * | core.s2smanager: Log the entire stream header.Kim Alvefur2012-03-041-1/+1
| | |
* | | Merge with 0.9Matthew Wild2012-02-251-1/+6
|\| |
| * | core.s2smanager: Fix check_cert_status() for when the stream has no from attrKim Alvefur2012-02-211-1/+6
| | |