aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAgeFilesLines
* prosodyctl: Report OpenSSL versionKim Alvefur2021-05-121-0/+4
|
* util.hashes: Expose OpenSSL versionKim Alvefur2021-05-121-0/+4
|
* util.jwt: Use constant-time comparison with expected signatureMatthew Wild2021-05-131-1/+2
|
* Merge 0.11->trunkMatthew Wild2021-05-1319-54/+111
|\
| * Added tag 0.11.9 for changeset d0e9ffccdef9Matthew Wild2021-05-120-0/+0
| |
| * mod_dialback: Remove d-w-d feature0.11.9Kim Alvefur2021-05-122-23/+1
| | | | | | | | | | | | | | Backs out 1d0862814bfc and 2fdd71b08126 Largely unused, undocumented and did not have enough tests to provide confidence in its correct operation.
| * mod_dialback: Use correct host for certificate check (fixes #1381)Kim Alvefur2019-06-231-2/+1
| |
| * mod_dialback: Use constant-time comparison with hmacMatthew Wild2021-05-121-1/+2
| |
| * mod_proxy65: Restrict access to local c2s connections by defaultMatthew Wild2021-05-121-4/+12
| | | | | | | | | | Previously no 'proxy65_acl' option would allow unrestricted access by local or remote JIDs.
| * mod_limits: Use default limits if none configuredMatthew Wild2021-05-111-1/+10
| |
| * prosody.cfg.lua.dist: Enable rate limits by defaultMatthew Wild2021-05-111-1/+12
| |
| * prosodyctl about: Report libexpat version if knownMatthew Wild2021-05-111-1/+5
| |
| * certmanager: Disable renegotiation by defaultMatthew Wild2021-05-111-0/+2
| | | | | | | | This requires LuaSec 0.7+ and OpenSSL 1.1.1+
| * mod_limits: Don't emit error when no burst period is configuredMatthew Wild2021-05-111-1/+1
| |
| * core.certmanager: Test for SSL options in absence of LuaSec configKim Alvefur2021-04-261-5/+9
| |
| * core.certmanager: Attempt to directly access LuaSec config tableKim Alvefur2021-04-261-1/+1
| | | | | | | | | | Due to a bug this field was not properly exported before See https://github.com/brunoos/luasec/issues/149
| * util.xmppstream: Allow dynamically configuring the stanza size limit for a ↵Matthew Wild2021-05-101-0/+3
| | | | | | | | | | | | | | stream This may be useful for any plugins that want to experiment with different policies for stanza size limits (e.g. unauthenticated vs authenticated streams).
| * util.xmppstream: Mark bytes for stream closure as handledMatthew Wild2021-05-101-0/+3
| |
| * MUC: Add support for advertising muc#roomconfig_allowinvites in room disco#infoMatthew Wild2021-05-101-2/+10
| | | | | | | | | | | | | | | | | | | | | | | | The de-facto interpretation of this (undocumented) option is to indicate to the client whether it is allowed to invite other users to the MUC. This is differs from the existing option in our config form, which only controls the behaviour of sending of invites in a members-only MUC (we always allow invites in open rooms). Conversations is one client known to use this disco#info item to determine whether it may send invites.
| * mod_auth_internal_{plain,hashed}: Use constant-time string comparison for ↵Matthew Wild2021-05-102-3/+5
| | | | | | | | secrets
| * util.xmppstream: Reduce default xmppstream limit to 1MBMatthew Wild2021-05-101-1/+1
| |
| * util.set: Add is_set() to test if an object is a setMatthew Wild2021-05-101-2/+8
| |
| * util.hashes: Add constant-time string comparison (binding to CRYPTO_memcmp)Matthew Wild2021-05-101-0/+14
| |
| * mod_c2s, mod_s2s, mod_component, mod_bosh, mod_websockets: Set default ↵Matthew Wild2021-05-075-5/+7
| | | | | | | | | | | | | | | | | | | | | | | | stanza size limits c2s/bosh/ws streams will default to 256KB, s2s and components to 512KB. These values are aligned with ejabberd's default settings, which should reduce issues related to inconsistent size limits between servers on the XMPP network. The previous default (10MB) is excessive for any production server, and allows significant memory usage by even unauthenticated sessions.
| * util.startup: Set more aggressive defaults for GCMatthew Wild2021-05-071-1/+7
| | | | | | | | | | | | | | | | | | Testing has demonstrated that the default GC parameters are not sufficient to prevent runaway memory growth when running under Lua 5.2 and Lua 5.3. Setting the GC speed to 500 was tested on Lua versions 5.1->5.4 and did not display unbounded memory growth.
| * prosodyctl: check config: Add 'gc' to list of global optionsMatthew Wild2021-04-301-1/+1
| |
* | core.certmanager: Catch error from lfsKim Alvefur2021-05-071-1/+11
| | | | | | | | | | | | | | lfs.dir() throws a hard error if there's a problem, e.g. no such directory or permission issues. This also gets called early enough that the main loop error protection hasn't been brought up yet, causing a proper crash.
* | core.certmanager: Resolve certs path relative to config dirKim Alvefur2021-05-071-3/+3
| | | | | | | | | | | | | | | | | | Otherwise the default "certs" would be relative to $PWD, which works when testing from a source checkout, but not on installed systems where it usually points to the data directory. Also, the LuaFileSystem dir() iterator throws a hard error, which may cause a crash or other problems.
* | core.portmanager: Use existing http_host for https SNI mappingKim Alvefur2021-05-051-0/+4
| |
* | core.portmanager: Allow overriding expected SNI name per serviceKim Alvefur2021-05-051-2/+3
| | | | | | | | | | | | | | E.g. VirtualHost"example.com" https_name = "xmpp.example.com"
* | core.certmanager: Skip directly to guessing of key from cert filenameKim Alvefur2021-05-051-2/+17
| | | | | | | | Cuts down on a ton of debug logs
* | core.certmanager: Join paths with OS-aware util.paths functionKim Alvefur2021-05-051-2/+3
| | | | | | | | Right thing to do, rather than hardcoding '/'
* | core.certmanager: Build an index over certificatesKim Alvefur2021-04-101-0/+79
| |
* | core.certmanager: Check for complete filenameKim Alvefur2021-04-101-1/+1
| | | | | | | | Prevents a false positive match on files with fullchain.pem as suffix
* | mod_tls: Fix order of debug messages and tls context creationKim Alvefur2021-05-051-2/+2
| | | | | | | | | | Originally added in 5b048ccd106f Merged wrong in ca01c449357f
* | configure: Make ICU the default library for IDNA and JID normalizationKim Alvefur2020-07-121-3/+3
| | | | | | | | See #533
* | net.http.server: Split out method for sending only the headerKim Alvefur2021-04-241-2/+7
| | | | | | | | | | Makes it easier to reuse, e.g. for SSE or websockets or other custom responses.
* | s2s et al.: Add counters for connection state transitionsJonas Schäfer2021-04-213-11/+50
| |
* | mod_s2s: Port to new OpenMetrics APIJonas Schäfer2021-04-181-10/+26
| |
* | mod_c2s: Port to new OpenMetrics APIJonas Schäfer2021-04-181-10/+16
| |
* | Statistics: Rewrite statistics backends to use OpenMetricsJonas Schäfer2021-04-187-494/+1110
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The metric subsystem of Prosody has had some shortcomings from the perspective of the current state-of-the-art in metric observability. The OpenMetrics standard [0] is a formalization of the data model (and serialization format) of the well-known and widely-used Prometheus [1] software stack. The previous stats subsystem of Prosody did not map well to that format (see e.g. [2] and [3]); the key reason is that it was trying to do too much math on its own ([2]) while lacking first-class support for "families" of metrics ([3]) and structured metric metadata (despite the `extra` argument to metrics, there was no standard way of representing common things like "tags" or "labels"). Even though OpenMetrics has grown from the Prometheus world of monitoring, it maps well to other popular monitoring stacks such as: - InfluxDB (labels can be mapped to tags and fields as necessary) - Carbon/Graphite (labels can be attached to the metric name with dot-separation) - StatsD (see graphite when assuming that graphite is used as backend, which is the default) The util.statsd module has been ported to use the OpenMetrics model as a proof of concept. An implementation which exposes the util.statistics backend data as Prometheus metrics is ready for publishing in prosody-modules (most likely as mod_openmetrics_prometheus to avoid breaking existing 0.11 deployments). At the same time, the previous measure()-based API had one major advantage: It is really simple and easy to use without requiring lots of knowledge about OpenMetrics or similar concepts. For that reason as well as compatibility with existing code, it is preserved and may even be extended in the future. However, code relying on the `stats-updated` event as well as `get_stats` from `statsmanager` will break because the data model has changed completely; in case of `stats-updated`, the code will simply not run (as the event was renamed in order to avoid conflicts); the `get_stats` function has been removed completely (so it will cause a traceback when it is attempted to be used). Note that the measure_*_event methods have been removed from the module API. I was unable to find any uses or documentation and thus deemed they should not be ported. Re-implementation is possible when necessary. [0]: https://openmetrics.io/ [1]: https://prometheus.io/ [2]: #959 [3]: #960
* | util.prosodyctl.shell: Fix for different location of unpack in Lua 5.1Kim Alvefur2021-04-251-1/+2
| |
* | util.prosodyctl.shell: Fix for missing 'sep' arg to string.rep in Lua 5.1Kim Alvefur2021-04-251-1/+2
| |
* | util.prosodyctl.shell: Allow calling console commands with fewer shell quotesKim Alvefur2021-04-251-3/+2
| | | | | | | | | | | | | | | | E.g. `prosodyctl shell module reload disco example.com` becomes equivalent to `prosodyctl shell 'module:reload("disco", "example.com")`. Won't work for every possible command, but reduces the amount of shell quoting problems for most common commands.
* | mod_tls: Bail out if session got destroyed while sending <proceed/>Kim Alvefur2021-04-151-0/+1
| | | | | | | | | | | | | | Can happen in case opportunistic_writes is enabled and the session got destroyed while writing that tag. Thanks Ge0rG
* | core.sessionmanager: Add a dummy rawsend() method to resting sessionsKim Alvefur2021-04-151-0/+1
| | | | | | | | | | | | | | Should fix a traceback on attempted use after destruction, in case where opportunistic_writes was in use. Thanks Ge0rG
* | mod_c2s: Fix traceback if session was destroyed while opening stream (thanks ↵Kim Alvefur2021-04-141-0/+3
| | | | | | | | | | | | | | | | | | | | | | Ge0rG) Could happen with the 'opportunistic_writes' setting, since then the stream opening is written directly to the socket, which can in turn trigger session destruction if the socket somehow got closed just after the other sent their stream header. Error happens later when it tries to `hosts[session.host == nil].events`
* | util.xmppstream: Send <?xml?> declaration in same call as stream openKim Alvefur2021-04-141-2/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | If network_settings.opportunistic_writes is enabled then this would previously have resulted in two socket writes, and possibly two packets being sent. This caused some issues in older versions of Gajim, which apparently expected the stream opening in the first packet, and thus it could not connect. With this change and opportunistic_writes enabled, the first packet should contain both the xml declaration and the stream open tag. Without opportunistic_writes, there should be no observable change. Tested with Gajim 1.1.2 (on same machine). Unsure if loopback behaves differently than the network here.
* | core.statsmanager: Allow special "manual" value for statistics_intervalKim Alvefur2021-04-062-6/+19
| | | | | | | | | | | | | | | | | | | | | | | | | | When set, no periodic statistics collection is done by core.statsmanager, instead some module is expected to call collect() when it suits. Obviously only one such module should be enabled. Quoth jonas’ > correct way is to scrape the internal sources on each call to /metrics > in the context of Prometheus "manual" as opposed to "automatic", from the point of view of statsmanager.
* | Merge 0.11->trunkKim Alvefur2021-04-102-4/+15
|\|