mirror of https://github.com/sipwise/prosody.git
* migrate from files to dirs as upstream * refresh debian/control list of modules * refresh mod_auth_sql.patch * update_plugins.sh for automate the process * keep the list of prosody modules at prosody-modules.list file * keep the upstream mercurial revision at prosody-modules.revision file Change-Id: Id4a0a2c4e88dae64641270ee79c6ee206f5bb695changes/90/10790/3
parent
0fbc57ef6e
commit
e191475653
@ -0,0 +1 @@
|
||||
debian/README_mod*
|
@ -0,0 +1,40 @@
|
||||
---
|
||||
labels:
|
||||
- 'Type-Auth'
|
||||
- 'Stage-Stable'
|
||||
summary: SQL Database authentication module
|
||||
...
|
||||
|
||||
Introduction
|
||||
============
|
||||
|
||||
Allow client authentication to be handled by an SQL database query.
|
||||
|
||||
Unlike mod\_storage\_sql (which is supplied with Prosody) this module
|
||||
allows for custom schemas (though currently it is required to edit the
|
||||
source).
|
||||
|
||||
Configuration
|
||||
=============
|
||||
|
||||
As with all auth modules, there is no need to add this to
|
||||
modules\_enabled. Simply add in the global section, or for the relevant
|
||||
hosts:
|
||||
|
||||
authentication = "sql"
|
||||
|
||||
This module reuses the database configuration of
|
||||
[mod\_storage\_sql](http://prosody.im/doc/modules/mod_storage_sql) (the
|
||||
'sql' option), which you can set even if you are not using SQL as
|
||||
Prosody's primary storage backend.
|
||||
|
||||
The query is currently hardcoded in the module, so you will need to edit
|
||||
the module to change it. The default query is compatible with jabberd2
|
||||
DB schema.
|
||||
|
||||
Compatibility
|
||||
=============
|
||||
|
||||
----- -------
|
||||
0.8 Works
|
||||
----- -------
|
@ -0,0 +1,54 @@
|
||||
---
|
||||
labels:
|
||||
- 'Stage-Alpha'
|
||||
summary: 'XEP-0191: Simple Communications Blocking support'
|
||||
...
|
||||
|
||||
Introduction
|
||||
============
|
||||
|
||||
Privacy lists are a widely implemented protocol for instructing your
|
||||
server on blocking communications with selected users and services.
|
||||
|
||||
However experience has shown that the power and flexibility of the
|
||||
rule-based system that privacy lists allow is very often much more
|
||||
complex than the user needs, and that in most cases a simple block on
|
||||
all communications to or from a list of specified JIDs would suffice.
|
||||
|
||||
Such a protocol would also allow much simpler user interface design than
|
||||
the current attempts at full privacy list interfaces.
|
||||
|
||||
Details
|
||||
=======
|
||||
|
||||
Simple Communications Blocking was developed to solve the above issues,
|
||||
and allows the client to manage a simple list of blocked JIDs. This
|
||||
plugin implements support for that protocol in Prosody, however the
|
||||
actual blocking is still managed by mod\_privacy, so it is **required**
|
||||
for that plugin to be loaded (this may change in future).
|
||||
|
||||
An XEP-0191 implementation without dependency on mod\_privacy is
|
||||
available in Prosody 0.10 as [mod\_blocklist][doc:modules:mod_blocklist].
|
||||
|
||||
Configuration
|
||||
=============
|
||||
|
||||
Simply ensure that mod\_privacy (or [mod\_privacy\_lists] in 0.10+) and
|
||||
mod\_blocking are loaded in your modules\_enabled list:
|
||||
|
||||
modules_enabled = {
|
||||
-- ...
|
||||
"privacy", -- or privacy_lists in Prosody 0.10+
|
||||
"blocking",
|
||||
-- ...
|
||||
|
||||
Compatibility
|
||||
=============
|
||||
|
||||
------ ---------------------------------------------
|
||||
0.10 Works but will conflict with mod\_blocklist
|
||||
0.9 Works
|
||||
0.8 Works
|
||||
0.7 Works
|
||||
0.6 Doesn't work
|
||||
------ ---------------------------------------------
|
@ -0,0 +1,49 @@
|
||||
---
|
||||
labels:
|
||||
- 'Stage-Beta'
|
||||
summary: Message Carbons
|
||||
...
|
||||
|
||||
Introduction
|
||||
============
|
||||
|
||||
This module implements [XEP-0280: Message
|
||||
Carbons](http://xmpp.org/extensions/xep-0280.html), allowing users to
|
||||
maintain a shared and synchronized view of all conversations across all
|
||||
their online clients and devices.
|
||||
|
||||
Configuration
|
||||
=============
|
||||
|
||||
As with all modules, you enable it by adding it to the modules\_enabled
|
||||
list.
|
||||
|
||||
modules_enabled = {
|
||||
...
|
||||
"carbons";
|
||||
...
|
||||
}
|
||||
|
||||
The module has no further configuration.
|
||||
|
||||
Clients
|
||||
=======
|
||||
|
||||
Clients that support XEP-0280:
|
||||
|
||||
- [Gajim](http://gajim.org/) (Desktop)
|
||||
- [Adium (1.6)](http://adium.im/) (Desktop - OS X)
|
||||
- [Yaxim](http://yaxim.org/) (Mobile - Android)
|
||||
- [Conversations](https://play.google.com/store/apps/details?id=eu.siacs.conversations)
|
||||
(Mobile - Android)
|
||||
- [poezio](http://poezio.eu/en/) (Console)
|
||||
|
||||
Compatibility
|
||||
=============
|
||||
|
||||
------- -----------------------
|
||||
0.8 Works
|
||||
0.9 Works
|
||||
0.10 Included with prosody
|
||||
trunk Included with prosody
|
||||
------- -----------------------
|
@ -0,0 +1,32 @@
|
||||
---
|
||||
summary: Client State Indication support
|
||||
...
|
||||
|
||||
Introduction
|
||||
============
|
||||
|
||||
This module implements [Client State
|
||||
Indication](http://xmpp.org/extensions/xep-0352.html), a way for mobile
|
||||
clients to tell the server that they are sitting in someones pocket and
|
||||
would rather not get some less urgent things pushed to it.
|
||||
|
||||
However this module does not do anything by itself. Deciding what things
|
||||
are considered "less urgent" is left to other modules.
|
||||
|
||||
- [mod\_throttle\_presence](/mod_throttle_presence.html) supresses
|
||||
presence updates
|
||||
- [mod\_filter\_chatstates](/mod_filter_chatstates.html) removes chat
|
||||
states (*Someone is typing...*)
|
||||
|
||||
Configuration
|
||||
=============
|
||||
|
||||
There is no configuration for this module, just add it to
|
||||
modules\_enabled as normal.
|
||||
|
||||
Compatibility
|
||||
=============
|
||||
|
||||
----- -------
|
||||
0.9 Works
|
||||
----- -------
|
@ -0,0 +1,26 @@
|
||||
---
|
||||
summary: Drop chat states from messages to inactive sessions
|
||||
...
|
||||
|
||||
Introduction
|
||||
============
|
||||
|
||||
Some mobile XMPP client developers consider [Chat State
|
||||
Notifications](http://xmpp.org/extensions/xep-0085.html) to be a waste
|
||||
of power and bandwidth, especially when the user is not actively looking
|
||||
at their device. This module will filter them out while the session is
|
||||
considered inactive. It depends on [mod\_csi](/mod_csi.html) for
|
||||
deciding when to begin and end filtering.
|
||||
|
||||
Configuration
|
||||
=============
|
||||
|
||||
There is no configuration for this module, just add it to
|
||||
modules\_enabled as normal.
|
||||
|
||||
Compatibility
|
||||
=============
|
||||
|
||||
----- -------
|
||||
0.9 Works
|
||||
----- -------
|
@ -0,0 +1,35 @@
|
||||
---
|
||||
summary: Throttle authentication attempts with optional tarpit
|
||||
...
|
||||
|
||||
Introduction
|
||||
============
|
||||
|
||||
This module lets you put a per-IP limit on the number of failed
|
||||
authentication attempts.
|
||||
|
||||
It features an optioanal
|
||||
[tarpit](https://en.wikipedia.org/wiki/Tarpit_%28networking%29), i.e.
|
||||
waiting some time before returning an "authentication failed" response.
|
||||
|
||||
Configuration
|
||||
=============
|
||||
|
||||
``` {.lua}
|
||||
modules_enabled = {
|
||||
-- your other modules
|
||||
"limit_auth";
|
||||
}
|
||||
|
||||
limit_auth_period = 30 -- over 30 seconds
|
||||
|
||||
limit_auth_max = 5 -- tolerate no more than 5 failed attempts
|
||||
|
||||
-- Will only work with Prosody trunk:
|
||||
limit_auth_tarpit_delay = 10 -- delay answer this long
|
||||
```
|
||||
|
||||
Compatibility
|
||||
=============
|
||||
|
||||
Requires 0.9 or later. The tarpit feature requires Prosody trunk.
|
@ -0,0 +1,49 @@
|
||||
---
|
||||
labels:
|
||||
- 'Stage-Stable'
|
||||
summary: Log failed authentication attempts with their IP address
|
||||
...
|
||||
|
||||
Introduction
|
||||
============
|
||||
|
||||
Prosody doesn't write IP addresses to its log file by default for
|
||||
privacy reasons (unless debug logging is enabled).
|
||||
|
||||
This module enables logging of the IP address in a failed authentication
|
||||
attempt so that those trying to break into accounts for example can be
|
||||
blocked.
|
||||
|
||||
fail2ban configuration
|
||||
======================
|
||||
|
||||
fail2ban is a utility for monitoring log files and automatically
|
||||
blocking "bad" IP addresses at the firewall level.
|
||||
|
||||
With this module enabled in Prosody you can use the following example
|
||||
configuration for fail2ban:
|
||||
|
||||
# /etc/fail2ban/filter.d/prosody-auth.conf
|
||||
# Fail2Ban configuration file for prosody authentication
|
||||
[Definition]
|
||||
failregex = Failed authentication attempt \(not-authorized\) for user .* from IP: <HOST>
|
||||
ignoreregex =
|
||||
|
||||
And at the appropriate place (usually the bottom) of
|
||||
/etc/fail2ban/jail.conf add these lines:
|
||||
|
||||
[prosody]
|
||||
enabled = true
|
||||
port = 5222
|
||||
filter = prosody-auth
|
||||
logpath = /var/log/prosody/prosody*.log
|
||||
maxretry = 6
|
||||
|
||||
Compatibility
|
||||
-------------
|
||||
|
||||
------- --------------
|
||||
trunk Works
|
||||
0.9 Works
|
||||
0.8 Doesn't work
|
||||
------- --------------
|
@ -0,0 +1,128 @@
|
||||
---
|
||||
labels:
|
||||
- 'Stage-Beta'
|
||||
summary: 'XEP-0313: Message Archive Management'
|
||||
...
|
||||
|
||||
Introduction
|
||||
============
|
||||
|
||||
Implementation of [XEP-0313: Message Archive Management].
|
||||
|
||||
Details
|
||||
=======
|
||||
|
||||
This module will archive all messages that match the simple rules setup
|
||||
by the user, and allow the user to access this archive.
|
||||
|
||||
Usage
|
||||
=====
|
||||
|
||||
First copy the module to the prosody plugins directory.
|
||||
|
||||
Then add "mam" to your modules\_enabled list:
|
||||
|
||||
``` {.lua}
|
||||
modules_enabled = {
|
||||
-- ...
|
||||
"mam",
|
||||
-- ...
|
||||
}
|
||||
```
|
||||
|
||||
Configuration
|
||||
=============
|
||||
|
||||
Option summary
|
||||
--------------
|
||||
|
||||
option type default
|
||||
------------------------------ ----------------------- -----------
|
||||
max\_archive\_query\_results number `50`
|
||||
default\_archive\_policy boolean or `"roster"` `true`
|
||||
archive\_expires\_after string `"1w"`
|
||||
archive\_cleanup\_interval number `4*60*60`
|
||||
|
||||
|
||||
Storage backend
|
||||
---------------
|
||||
|
||||
mod\_mam uses the store "archive2"[^1]. See [Prosodys data storage
|
||||
documentation][doc:storage] for information on how to configure storage.
|
||||
|
||||
For example, to use mod\_storage\_sql (requires Prosody 0.10 or later):
|
||||
|
||||
``` {.lua}
|
||||
storage = {
|
||||
archive2 = "sql";
|
||||
}
|
||||
```
|
||||
|
||||
If no archive-capable storage backend can be opened then an in-memory
|
||||
one will be used as fallback.
|
||||
|
||||
Query size limits
|
||||
-----------------
|
||||
|
||||
max_archive_query_results = 20;
|
||||
|
||||
This is the largest number of messages that are allowed to be retrieved
|
||||
in one request *page*. A query that does not fit in one page will
|
||||
include a reference to the next page, letting clients page through the
|
||||
result set. Setting large number is not recomended, as Prosody will be
|
||||
blocked while processing the request and will not be able to do anything
|
||||
else.
|
||||
|
||||
Archive expiry
|
||||
--------------
|
||||
|
||||
Messages in the archive will expire after some time, by default one
|
||||
week. This can be changed by setting `archive_expires_after`:
|
||||
|
||||
``` {.lua}
|
||||
archive_expires_after = "1d" -- one day
|
||||
|
||||
archive_expires_after = "1w" -- one week, the default
|
||||
|
||||
archive_expires_after = "2m" -- two months
|
||||
|
||||
archive_expires_after = "1y" -- one year
|
||||
|
||||
archive_expires_after = 60 * 60 -- one hour
|
||||
|
||||
archive_expires_after = "never" -- forever
|
||||
```
|
||||
|
||||
The format is an integer number of seconds or a multiple of a period
|
||||
given by a suffix that can be one of `d` (day), `w` (week), `m` (month)
|
||||
or `y` (year). No multiplier means seconds.
|
||||
|
||||
Message matching policy
|
||||
-----------------------
|
||||
|
||||
The MAM protocol includes a way for clients to control what messages
|
||||
should be stored. This allows users to enable or disable archiving by
|
||||
default or for specific contacts.
|
||||
|
||||
``` {.lua}
|
||||
default_archive_policy = true
|
||||
```
|
||||
|
||||
`default_archive_policy =` Meaning
|
||||
---------------------------- ------------------------------------------------------
|
||||
`false` Store no messages.
|
||||
`"roster"` Store messages to/from contacts in the users roster.
|
||||
`true` Store all messages. This is the default.
|
||||
|
||||
Compatibility
|
||||
=============
|
||||
|
||||
------- ---------------
|
||||
trunk Works
|
||||
0.10 Works
|
||||
0.9 Works
|
||||
0.8 Does not work
|
||||
------- ---------------
|
||||
|
||||
[^1]: Might be changed to "mam" at some point
|
||||
|
@ -0,0 +1,76 @@
|
||||
---
|
||||
labels:
|
||||
- 'Stage-Alpha'
|
||||
summary: 'XEP-0198: Reliability and fast reconnects for XMPP'
|
||||
...
|
||||
|
||||
Introduction
|
||||
============
|
||||
|
||||
By default XMPP is as reliable as your network is. Unfortunately in some
|
||||
cases that is not very reliable - in some network conditions disconnects
|
||||
can be frequent and message loss can occur.
|
||||
|
||||
To overcome this, XMPP has an optional extension (XEP-0198: Stream
|
||||
Management) which, when supported by both the client and server, can
|
||||
allow a client to resume a disconnected session, and prevent message
|
||||
loss.
|
||||
|
||||
Details
|
||||
=======
|
||||
|
||||
When using XEP-0198 both the client and the server keep a queue of the
|
||||
most recently sent stanzas - this is cleared when the other end
|
||||
acknowledges they have received the stanzas. If the client disconnects,
|
||||
instead of marking the user offline the server pretends the client is
|
||||
still online for a short (configurable) period of time. If the client
|
||||
reconnects within this period, any stanzas in the queue that the client
|
||||
did not receive are re-sent.
|
||||
|
||||
If the client fails to reconnect before the timeout then it is marked
|
||||
offline as normal, and any stanzas in the queue are returned to the
|
||||
sender as a "recipient-unavailable" error.
|
||||
|
||||
If you don't want this behaviour on timeout you can use [mod_smacks_offline]
|
||||
or [mod_smacks_noerror] to customize the behaviour further.
|
||||
|
||||
This module also provides some events used by [mod_cloud_notify].
|
||||
These events are: "smacks-ack-delayed", "smacks-hibernation-start" and
|
||||
"smacks-hibernation-end". See [mod_cloud_notify] for details on how this
|
||||
events are used there.
|
||||
|
||||
Configuration
|
||||
=============
|
||||
|
||||
Option Default Description
|
||||
------------------------------ ----------------- -----------------------------------------------------------------------------------------
|
||||
`smacks_hibernation_time` 300 (5 minutes) The number of seconds a disconnected session should stay alive for (to allow reconnect)
|
||||
`smacks_enabled_s2s` false Enable Stream Management on server connections? *Experimental*
|
||||
`smacks_max_unacked_stanzas` 0 How many stanzas to send before requesting acknowledgement
|
||||
`smacks_max_ack_delay` 60 (1 minute) The number of seconds an ack must be unanswered to trigger an "smacks-ack-delayed" event
|
||||
|
||||
Compatibility
|
||||
=============
|
||||
|
||||
----- -----------------------------------
|
||||
0.10 Works
|
||||
0.9 Works
|
||||
0.8 Works, use version [7693724881b3]
|
||||
----- -----------------------------------
|
||||
|
||||
|
||||
Clients
|
||||
=======
|
||||
|
||||
Clients that support XEP-0198:
|
||||
|
||||
- Gajim
|
||||
- Swift (but not resumption, as of version 2.0 and alphas of 3.0)
|
||||
- Psi (in an unreleased branch)
|
||||
- Conversations
|
||||
- Yaxim
|
||||
|
||||
[7693724881b3]: //hg.prosody.im/prosody-modules/raw-file/7693724881b3/mod_smacks/mod_smacks.lua
|
||||
[mod_smacks_offline]: //modules.prosody.im/mod_smacks_offline
|
||||
[mod_smacks_noerror]: //modules.prosody.im/mod_smacks_noerror
|
||||
[mod_cloud_notify]: //modules.prosody.im/mod_cloud_notify
|
@ -0,0 +1,31 @@
|
||||
---
|
||||
labels:
|
||||
- 'Stage-Beta'
|
||||
summary: Limit presence stanzas to save traffic
|
||||
...
|
||||
|
||||
Introduction
|
||||
============
|
||||
|
||||
For most people 'presence' (status changes) of contacts make up most of
|
||||
the traffic received by their client. However much of the time it is not
|
||||
essential to have highly accurate presence information.
|
||||
|
||||
This module automatically cuts down on presence traffic when clients
|
||||
indicate they are inactive (using the [CSI protocol](mod_csi.html)).
|
||||
|
||||
This is extremely valuable for mobile clients that wish to save battery
|
||||
power while in the background.
|
||||
|
||||
Configuration
|
||||
=============
|
||||
|
||||
Just load the module (e.g. in modules\_enabled). There are no
|
||||
configuration options.
|
||||
|
||||
Compatibility
|
||||
=============
|
||||
|
||||
----- -------
|
||||
0.9 Works
|
||||
----- -------
|
@ -0,0 +1,13 @@
|
||||
mod_auth_sql
|
||||
mod_blocking
|
||||
mod_carbons
|
||||
mod_carbons_adhoc
|
||||
mod_carbons_copies
|
||||
mod_csi
|
||||
mod_filter_chatstates
|
||||
mod_limit_auth
|
||||
mod_log_auth
|
||||
mod_mam
|
||||
mod_smacks
|
||||
mod_throttle_presence
|
||||
mod_websocket
|
@ -0,0 +1 @@
|
||||
51cf82d36a8a
|
@ -0,0 +1,44 @@
|
||||
#!/bin/bash
|
||||
#
|
||||
set -e
|
||||
|
||||
MOD_SRC=$1
|
||||
|
||||
usage() {
|
||||
echo "$0 modules_src_dir"
|
||||
printf "\tmodules_src_dir:\tpath to prosody-modules mercurial source\n"
|
||||
}
|
||||
|
||||
refresh_sources() {
|
||||
echo "refresh sources at $MOD_SRC"
|
||||
( cd "$MOD_SRC" && hg pull && hg update )
|
||||
}
|
||||
|
||||
copy_modules() {
|
||||
while read -r dir ; do
|
||||
if [ -d "$MOD_SRC/$dir" ] ; then
|
||||
cp -vr "$MOD_SRC/$dir" plugins
|
||||
else
|
||||
echo "$MOD_SRC/$dir no longer there"
|
||||
fi
|
||||
done < prosody-modules.list
|
||||
}
|
||||
|
||||
get_revision_id() {
|
||||
(cd "$MOD_SRC/$dir" && hg id -i) > 'prosody-modules.revision'
|
||||
}
|
||||
|
||||
if [ $# -ne 1 ] ; then
|
||||
echo "wrong number of parameters" >&2
|
||||
usage
|
||||
exit 1
|
||||
fi
|
||||
|
||||
if ! [ -d "$MOD_SRC" ] ; then
|
||||
printf "modules_src_dir[%s] not found\n" "$MOD_SRC"
|
||||
fi
|
||||
|
||||
refresh_sources
|
||||
copy_modules
|
||||
get_revision_id
|
||||
exit 0
|
Loading…
Reference in new issue