25
1
mirror of https://github.com/processone/ejabberd.git synced 2024-11-22 16:20:52 +01:00
Commit Graph

3436 Commits

Author SHA1 Message Date
Alexey Shchepin
2d042f078e New parse transform for ?SQL_UPSERT and ?SQL_UPSERT_T 2016-03-02 00:12:49 +03:00
Alexey Shchepin
3d8219d8f9 Update mod_roster and ejabberd_auth_odbc SQL queries to the new API 2016-03-02 00:12:49 +03:00
Alexey Shchepin
7f3bffe821 Allow balanced expressions inside @(...) in ejabberd_sql_pt 2016-03-02 00:12:49 +03:00
Alexey Shchepin
99255631dd Updated some mod_offline SQL queries to the new API 2016-03-02 00:12:11 +03:00
Alexey Shchepin
ba35c1ed9d Use 'any' to match any DBMS in sql_query 2016-03-01 22:50:20 +03:00
Alexey Shchepin
437e768e4a Better error handling in ejabberd_sql_pt 2016-03-01 22:50:07 +03:00
Alexey Shchepin
c58a4be6ee Support for run-time SQL queries selection depending on DBMS version 2016-03-01 22:49:56 +03:00
Alexey Shchepin
6374ef4866 New parse transform for SQL queries, use prepare/execute calls with Postgres 2016-03-01 22:48:30 +03:00
Evgeniy Khramtsov
382c7c21ad Do not call to deprected/undefined functions from mod_shared_roster_ldap 2016-02-29 16:35:45 +03:00
Holger Weiss
6d8c7232d8 mod_register_web: Choose the right error messages 2016-02-29 00:39:57 +01:00
Evgeniy Khramtsov
6b126171da Improve LDAP shared roster support (EJAB-1480) 2016-02-26 17:27:12 +03:00
Christophe Romain
56523784e1 Implementation of pubsub#itemreply (EJAB-1347)(#928) 2016-02-26 10:32:03 +01:00
Christophe Romain
1c6d20924b Fix host/serverhost usage (#902) 2016-02-26 09:33:07 +01:00
Marek Foss
ebaf750a9b Fix for #935 2016-02-25 18:56:43 +01:00
Paweł Chmielowski
a9de13c5d9 Don't include empty line after java example 2016-02-25 12:14:17 +01:00
Christophe Romain
576c10ee3a Make caps warning less confusing (#955) 2016-02-23 14:14:24 +01:00
Holger Weiss
44f581c3b5 mod_http_upload: Also expand @HOST@ in 'docroot'
In some environments, it might be desirable to use separate document
roots for each virtual host.
2016-02-20 20:13:30 +01:00
Holger Weiss
b971449f12 mod_http_upload: Expand 'docroot' before using it
Expand the @HOME@ keyword within the 'docroot' value before setting the
permissions of the document root directory.
2016-02-20 18:21:38 +01:00
Holger Weiss
5b4aefbacd Accept stream compression request after SASL
This is an updated version of the patch submitted to EJAB-1382 by
Alexey (thanks!).
2016-02-19 18:53:28 +01:00
Evgeniy Khramtsov
4b0860e7de Make it possible to define 'sm_db_type' per virtual host 2016-02-19 16:38:43 +03:00
Badlop
eece6e69cb Fix format_result so get_room_options command works again after aa5caa3 2016-02-17 20:43:35 +01:00
badlop
c9c59f00ad Merge pull request #953 from cdroege/fix_css
Fix the color of links in tables in web admin
2016-02-15 12:52:54 +01:00
Paweł Chmielowski
47a67c7320 Allow to pass \n in argument to ejabberdctl 2016-02-12 23:38:39 +01:00
Christian Dröge
c579313821 Fix the color of links in tables in web admin 2016-02-12 18:45:45 +01:00
Holger Weiss
eaaab45c14 mod_muc_room: Let members see admin/owner JIDs
Let members retrieve all affiliation lists in non-anonymous rooms, not
just the list of members.
2016-02-11 22:52:27 +01:00
Holger Weiss
041e886b87 mod_muc_room: Don't expose JIDs in anonymous rooms
Don't let room members retrieve the member list unless the room is
non-anonymous.
2016-02-11 22:24:14 +01:00
Holger Weiss
17be70339c mod_mam: Send new preferences when they are set
If a client updates the archiving preferences, include the new
preferences with the IQ result (as mandated by XEP-0313).
2016-02-10 23:06:31 +01:00
Badlop
02a519a11e Mention new XEP support 2016-02-08 21:35:46 +01:00
Badlop
1de085ec23 Prepare room JID in create_room command 2016-02-08 21:35:26 +01:00
Paweł Chmielowski
217b6da5fd Fix example value for rescode return type 2016-02-09 16:44:57 +01:00
Paweł Chmielowski
d5b3e6af00 More documentation of arguments in mod_admin_extra 2016-02-09 16:33:32 +01:00
Evgeniy Khramtsov
4839ba5ae4 XEP-0013: Flexible Offline Message Retrieval support 2016-02-09 17:59:54 +03:00
Paweł Chmielowski
2bca8d5121 Remove remanants of pre-binary strings 2016-02-09 15:50:35 +01:00
Christophe Romain
583476380a Use muc_online_room record for pattern matching 2016-02-09 15:33:00 +01:00
Paweł Chmielowski
c0da9b43ce Better presentation of result description in docs 2016-02-09 13:18:01 +01:00
Paweł Chmielowski
30d171e79e Start documenting arguments in mod_admin_extra commands 2016-02-09 13:03:40 +01:00
Paweł Chmielowski
d36c351fc7 Typo in markdown generator 2016-02-09 13:03:40 +01:00
Holger Weiss
10ed4a1c85 Add most status codes only to initial MUC presence 2016-02-08 20:10:20 +01:00
Badlop
04a315eb52 Fix section links to the Guide in the WebAdmin 2016-02-08 16:16:53 +01:00
badlop
cf2f80bd09 Merge pull request #944 from cdroege/configureable_host-mod_register_web
Allow to modify host when deleting account or changing password over web
2016-02-08 13:48:11 +01:00
Evgeny Khramtsov
2bfb619d19 Merge pull request #914 from weiss/mam-expose-jid
Expose occupant JID in MUC MAM messages whenever possible
2016-02-08 14:23:19 +03:00
Mickael Remond
0b1620a45c Remove compile warnings 2016-02-08 10:50:28 +01:00
Holger Weiss
bf49c292f8 Omit redundant check for overcrowded MUC room
The send_update_presence/4 function already checked whether the room is
overcrowded before calling send_update_presence1/4, so there's no need
to have send_new_presence/4 perform the same check.
2016-02-08 00:46:33 +01:00
Holger Weiss
8098f7d9a8 mod_mam: Don't let outcasts access MUC archive
XEP-0313 says: "A MUC archive MUST check that the user requesting the
archive has the right to enter it at the time of the query [...].  In
the case of open MUC rooms, the MUC archives can generally be accessed
by any users [...] who do not have an affiliation of 'outcast'".
2016-02-08 00:16:02 +01:00
Holger Weiss
a31f59ea31 XEP-0198: Fix session timeout corner case
If the "resend_on_timeout" option is set to 'if_offline' and a pending
stream management session is terminated because a new session is opened
by the same resource (while no other resource is online), resend
unacknowledged messages rather than bouncing error messages.
2016-02-06 22:28:55 +01:00
Badlop
7435ee464f Rename option to regexp_room_id for consistency with other options (#905) 2016-02-05 12:09:27 +01:00
HAMANO Tsukasa
268f0b30ec add room_id_regexp option 2016-02-05 12:09:18 +01:00
Christian Dröge
30388fa2bf Allow to modify host when deleting account or changing password over web 2016-02-04 21:31:16 +01:00
Pablo Polvorin
942072cf9d Make hibernate timeouts configurable
Two *global* options added:
c2s_hibernate and receiver_hibernate.

Default if not specified is 90000, the previous hardcoded value.
2016-02-04 15:45:29 -03:00
Mickael Remond
dfc29ea03c Switch to Fast XML module 2016-02-03 19:03:17 +01:00
Mickael Remond
71ee0d56fa Switch to fast_tls and update app names 2016-02-03 16:13:16 +01:00
Mickael Remond
9ae1371c6e Convert more dependencies to new repository / packages 2016-02-03 12:30:12 +01:00
Mickael Remond
0de222d998 Convert code to use Fast YAML 2016-02-03 11:30:48 +01:00
Mickael Remond
b137ee3beb Move to new dependencies for SIP and STUN 2016-02-03 11:26:14 +01:00
Mickael Remond
99b5c5712c Move to new iconv package 2016-02-03 11:17:24 +01:00
Mickael Remond
e8ba7bce24 Use stringprep app name 2016-02-03 10:12:25 +01:00
Nathan Bruning
80fc34fb0c Fix presence-based delivery 2016-02-02 14:06:07 +01:00
Paweł Chmielowski
fa55ac5c8f More strict checking for MUC initial presence 2016-02-01 12:09:58 +01:00
Paweł Chmielowski
dc52ec904c Send presence with code 170 only in initial presence from MUC 2016-02-01 11:30:49 +01:00
Evgeniy Khramtsov
d3ee2a9c18 Add 'import_prosody' command 2016-01-29 14:30:50 +03:00
Evgeniy Khramtsov
54dc2f56c6 Import privacy lists from Prosody 2016-01-29 14:14:08 +03:00
Evgeniy Khramtsov
b20db3b736 Initial version of migration script from Prosody to ejabberd 2016-01-28 14:23:51 +03:00
Paweł Chmielowski
aaa84dc118 Need extra line before ## in markdown 2016-01-27 11:42:13 +01:00
Paweł Chmielowski
239b1c6f74 Always use lagger 2016-01-26 14:34:58 +01:00
Christophe Romain
b2c6e397fc Set set utf8mb4 charset on mysql connection 2016-01-26 13:47:24 +01:00
Paweł Chmielowski
621dff7307 Add header to generated markdown file 2016-01-26 10:46:38 +01:00
Paweł Chmielowski
bdeb4a7e32 Add a way to get all ejabberd_commands, not only those that was registered
This is part of (TECH-1828).
2016-01-26 10:00:28 +01:00
Paweł Chmielowski
22696e8388 Geenarte markdown that is acceptable by docs.ejabberd.org processor 2016-01-25 16:51:54 +01:00
Paweł Chmielowski
a2a692d081 Merge pull request #919 from hamano/rename_timestamp_function
rename timestamp function #917
2016-01-24 07:51:25 +01:00
Mickael Remond
a3931e6b73 lager is the default logger, we need to reverse the define flag 2016-01-23 18:43:06 +01:00
HAMANO Tsukasa
5a85b0fb52 rename timestamp function #917 2016-01-23 17:58:10 +09:00
Holger Weiss
b62607037a mod_mam: Expose MUC occupant JID in more cases
Include the occupant JID with MUC MAM messages if the room is not
anonymous, and also when the MAM user sent the MUC message himself (not
just in the case where he is a room moderator).
2016-01-20 00:02:40 +01:00
Christophe Romain
2ddbd032ee Add error handling to send_stanza 2016-01-19 16:16:04 +01:00
Holger Weiss
5e4ed4266d mod_mam: Strip existing JID tags from MUC messages
Strip any pre-existing <x/> tags which have an <item/> child with a
'jid' attribute from MUC MAM messages.  This way, if such a tag exists,
clients can be sure it was added by mod_mam.
2016-01-19 00:39:10 +01:00
Alexey Shchepin
a150bf8fdc Make C2S session establishment optional (ECS-11) 2016-01-18 16:33:57 +03:00
Holger Weiss
bd383fb8c1 mod_mam: Remove unused code
This mod_mam version doesn't store groupchat messages in user archives,
and it also doesn't support the "store_body_only" option.
2016-01-18 13:27:29 +01:00
Holger Weiss
63777f830d Use maps instead of dicts in HTTP upload modules
ejabberd currently depends on Erlang/OTP 17.1 or higher, so we can now
use maps.
2016-01-16 01:30:22 +01:00
badlop
6ac839dd76 Merge pull request #906 from hamano/stats_processes
add stats processes command
2016-01-15 19:26:23 +01:00
Evgeniy Khramtsov
a83c5a8f3a Do not redefine records 2016-01-15 15:44:50 +03:00
Evgeniy Khramtsov
1d452c98c1 Describe option type of 'domain_balancing' 2016-01-15 14:32:10 +03:00
Holger Weiss
ddaa409ee2 XEP-0198: Let MAM take care of pending messages
If a stream management session times out for a user who appears to be
using MAM, drop any unacknowledged messages rather than resending or
bouncing them.  This avoids duplicates or bogus error messages.

However, this is only done if the new mod_mam option "assume_mam_usage"
is set to 'if_enabled' or 'on_request'.  In the former case, a user is
assumed to be using MAM if archiving is enabled for his account.  In the
latter case, MAM usage is assumed only if archiving was explicitly
requested by the client, or if archiving was enabled by means of
mod_mam's "request_activates_archiving" option.
2016-01-15 01:08:22 +01:00
HAMANO Tsukasa
6cb1905f7c add stats processes command 2016-01-15 00:27:15 +09:00
Holger Weiss
db04cdf2ca mod_mam: Sort messages returned by Mnesia
Sort the messages retrieved from an Mnesia archive before selecting the
subset limited by the <max/> value.  This makes sure the desired subset
of messages is sent to the client.
2016-01-14 02:27:02 +01:00
Holger Weiss
58c8fc5770 mod_mam: Limit result set page size
If the client doesn't specify a maximum number of messages to retrieve
per page, set a limit of 50 messages.  If the client specifies a limit
larger than 250, cap the number to 250 messages.

These limits aren't enforced for MAM v0.2 requests though, as that
version of the XEP doesn't require clients to support RSM.  The newer
revisions say that "a server MAY place a reasonable limit on how many
stanzas may be pushed to a client in one request.  Whether or not the
client query included a <set/> element, the server MAY simply return its
limited results, modifying the <set/> element it returns appropriately."
2016-01-14 02:12:28 +01:00
Holger Weiss
35ec0d58a4 mod_mam: Reject <index/>-based paging
If an <index/> is specified in the MAM request, reject the request
rather than ignoring the desired index and returning wrong results.
XEP-0059 says that the server "MAY return a <feature-not-implemented/>
error."
2016-01-14 01:39:19 +01:00
Holger Weiss
11afa45646 mod_mam: Remove unused variable 2016-01-14 01:15:11 +01:00
Holger Weiss
89f63a4fdf mod_mam: Check whether MUC message is desired 2016-01-14 01:13:16 +01:00
Holger Weiss
85f4f90b45 mod_mam: Support XEP-0313 v0.2 MUC archive queries 2016-01-14 00:58:48 +01:00
Holger Weiss
8117092e6a mod_mam: Respond to form requests
If the client requests a data form with the supported filters, return it
as per XEP-0313 v0.3 and newer.
2016-01-13 23:56:05 +01:00
Holger Weiss
89b1700279 mod_mam: Add 'from' attribute to <delay/> tag 2016-01-13 23:17:23 +01:00
Holger Weiss
9cd048c442 mod_mam: Improve binary comparison of message UIDs
Make sure the binary comparison performed when clients use message UIDs
to page through Mnesia archives yields correct results even if the
specified UIDs don't have the same number of digits as the UIDs of the
stored messages.  This way, MAM will continue to work as expected after
migrating from mod_mam_mnesia to mod_mam.
2016-01-13 23:01:51 +01:00
Holger Weiss
3dccc20d8b mod_mam: Add "delete_old_mam_messages" command
The new "delete_old_mam_messages" command allows for purging all MAM
messages of the specified type older than the specified number of days.
(Currently only implemented for Mnesia archives.)
2016-01-13 22:46:30 +01:00
Holger Weiss
a61b0c303d mod_mam: Add "request_activates_archiving" option
Enabling "request_activates_archiving" tells mod_mam not to store any
messages for a user until his client issued a MAM request, regardless of
mod_mam's "default" option.  Once a MAM request is issued, messages are
archived as usual.
2016-01-13 21:38:08 +01:00
Holger Weiss
0183b2487e Advertise MUC MAM v0.4.1 in room JID's disco#info 2016-01-13 20:30:44 +01:00
Badlop
f448ff608a Update copyright to 2016 (#901) 2016-01-13 12:29:14 +01:00
Evgeniy Khramtsov
fd3e3a99c5 Log failed SQL requests 2016-01-13 14:13:32 +03:00
Evgeniy Khramtsov
776fe8b32a Fix MAM MUC for v0.4.1 2016-01-13 11:45:08 +03:00
Holger Wei
64d96778b4 Don't return error for blocked MUC messages
If a message stanza is blocked as per XEP-0016 or XEP-0191, return an
error only if the type of the blocked message is "normal" or "chat".
This makes sure users won't be kicked from MUC rooms when blocking other
participants.

Closes #897.
2016-01-12 10:20:35 +01:00
Holger Weiss
3e1425b905 Merge remote-tracking branch 'processone/pr/899'
* processone/pr/899:
  mod_http_upload: Use application/octet-stream instead of text/html for security reasons
2016-01-11 12:38:51 +01:00
Evgeniy Khramtsov
65e6dfb9dd Do not fail on incorrect data coming from SQL (898) 2016-01-11 14:35:11 +03:00