Commit Graph

105 Commits

Author SHA1 Message Date
Evgeniy Khramtsov 3a5d2dbed8 Move mod_irc to ejabberd-contrib 2018-06-20 12:27:44 +03:00
Evgeniy Khramtsov fd8e07af47 Get rid of ejabberd.hrl header
The header consisted of too many unrelated stuff and macros misuse.
Some stuff is moved into scram.hrl and type_compat.hrl.
All macros have been replaced with the corresponding function calls.

TODO: probably type_compat.hrl is not even needed anymore since
we support only Erlang >= OTP 17.5
2018-06-14 14:00:47 +03:00
Evgeniy Khramtsov cdc7c1d1ed Update copyright dates 2018-01-05 23:18:58 +03:00
Evgeniy Khramtsov 4835537776 Move ejabberdctl ACME commands to other location 2017-11-17 12:50:27 +03:00
Konstantinos Kallas 80b44d8c15 Remove some unused variable warnings, replace lists:join with string join 2017-08-25 12:08:16 +03:00
Konstantinos Kallas f1ea67817c More whitespace changes 2017-08-22 14:58:12 +03:00
Konstantinos Kallas 30e729a150 Whitespace change 2017-08-22 14:54:23 +03:00
Konstantinos Kallas dd42d52ff9 Merge remove_account_option branch 2017-08-19 13:36:42 +03:00
Konstantinos Kallas a72a7f830a Add support to revoke a certificate by providing the pem
This is important so that a user can revoke a certificate that is not acquired or logged from our acme client
2017-08-12 17:14:23 +03:00
Konstantinos Kallas 73f0b6707a Move the ca_url to the config file 2017-08-12 15:59:54 +03:00
Konstantinos Kallas 1aadb797b3 Remove the new account option from get certificate. There is no reason for having this 2017-08-11 14:10:55 +03:00
Konstantinos Kallas 011b7ac3f2 Support getting certificates for domains not specified in the configuration file 2017-08-10 15:26:35 +03:00
Konstantinos Kallas 9756b452d6 Implement renew_certificate command
This command renews the certificates for all domains that already have a certificate that has expired or is close to expiring. It is meant to be run automatically more often than the renewal process because if the certificates are valid nothing happens
2017-08-08 16:38:19 +03:00
Konstantinos Kallas e6e8e64f84 Improve return format of get_certificates command 2017-08-02 21:10:49 +03:00
Konstantinos Kallas cc6f4b90fb Support certificate revocation 2017-07-27 18:25:44 +03:00
Konstantinos Kallas 9ce1f12b66 Pretty print list-certificates 2017-07-18 13:28:44 +03:00
Konstantinos Kallas 8fe551cc68 Add a stub for the list-certificates command 2017-07-17 11:39:27 +03:00
Konstantinos Kallas 09c3496ff1 Remove httpdir from some function arguments as we now use the built in ejabberd http server for authorizations 2017-07-17 10:48:57 +03:00
Konstantinos Kallas d3c477646f Add support for command get_certificates, very crude 2017-07-03 13:37:32 +03:00
Paweł Chmielowski 62806607bf Add missing , 2017-06-09 12:10:40 +02:00
Badlop b25b5c2f98 Improve export2sql explanation; remove obsolete and duplicated command 2017-06-09 12:02:49 +02:00
Paweł Chmielowski b013c29c7e Fix values put in args_examples 2017-05-19 16:56:37 +02:00
Evgeniy Khramtsov 633b68db11 Use cache for authentication backends
The commit introduces the following API incompatibilities:

In ejabberd_auth.erl:
* dirty_get_registered_users/0 is renamed to get_users/0
* get_vh_registered_users/1 is renamed to get_users/1
* get_vh_registered_users/2 is renamed to get_users/2
* get_vh_registered_users_number/1 is renamed to count_users/1
* get_vh_registered_users_number/2 is renamed to count_users/2

In ejabberd_auth callbacks
* plain_password_required/0 is replaced by plain_password_required/1
  where the argument is a virtual host
* store_type/0 is replaced by store_type/1 where the argument is
  a virtual host
* set_password/3 is now an optional callback
* remove_user/3 callback is no longer needed
* remove_user/2 now should return `ok | {error, atom()}`
* is_user_exists/2 now must only be implemented for backends
  with `external` store type
* check_password/6 is no longer needed
* check_password/4 now must only be implemented for backends
  with `external` store type
* try_register/3 is now an optional callback and should return
  `ok | {error, atom()}`
* dirty_get_registered_users/0 is no longer needed
* get_vh_registered_users/1 is no longer needed
* get_vh_registered_users/2 is renamed to get_users/2
* get_vh_registered_users_number/1 is no longer needed
* get_vh_registered_users_number/2 is renamed to count_users/2
* get_password_s/2 is no longer needed
* get_password/2 now must only be implemented for backends with
  `plain` or `scram` store type

Additionally, the commit introduces two new callbacks:
* use_cache/1 where the argument is a virtual host
* cache_nodes/1 where the argument is a virtual host

New options are also introduced: `auth_use_cache`, `auth_cache_missed`,
`auth_cache_life_time` and `auth_cache_size`.
2017-05-11 14:37:21 +03:00
Evgeniy Khramtsov 0b93cb7ece Store options using p1_options module 2017-04-27 19:44:58 +03:00
Evgeniy Khramtsov 18433e289f Add clear_cache admin command 2017-04-22 11:33:39 +03:00
Evgeniy Khramtsov d523357ba8 Invalidate access permissions on configuration reload 2017-02-27 09:55:54 +03:00
Evgeniy Khramtsov fadcc85553 Put more stuff under supervision 2017-02-26 15:10:59 +03:00
Evgeniy Khramtsov a3ea6e7723 Improve reload_config admin command 2017-02-23 11:14:49 +03:00
Evgeniy Khramtsov d5d906184f Merge branch 'new_stream'
Conflicts:
	src/cyrsasl.erl
	src/ejabberd_c2s.erl
	src/ejabberd_cluster.erl
	src/ejabberd_frontend_socket.erl
	src/ejabberd_node_groups.erl
	src/ejabberd_router.erl
	src/mod_bosh.erl
	src/mod_ip_blacklist.erl
	src/mod_muc_mnesia.erl
	src/mod_offline.erl
	src/mod_proxy65_sm.erl
2017-01-20 19:35:46 +03:00
Evgeniy Khramtsov 0baaad30b1 Implement database backend interface for MUC, BOSH and auth_anonyous 2017-01-13 12:03:39 +03:00
Badlop 5fdd1c39fe Update copyright date automatically (#1442) 2017-01-02 21:42:06 +01:00
Badlop cc14e223c6 Describe command arguments and results in ejabberd_admin 2016-12-12 13:19:17 +01:00
Christophe Romain 23f7075313 Fix reload_config 2016-12-02 16:29:46 +01:00
Mickael Remond 309fd56fb4
Merge branch 'master' of github.com:processone/ejabberd 2016-12-01 15:05:09 +01:00
Evgeniy Khramtsov 49f1275e20 Get rid of excessive (io)list_to_binary/1 calls 2016-11-24 15:06:06 +03:00
Mickael Remond 42bede77a1
Merge branch 'master' of github.com:processone/ejabberd 2016-11-09 09:04:58 +01:00
Mickael Remond 35506f5470
Expose unregister API command 2016-11-09 09:04:52 +01:00
Paweł Chmielowski 98e0123ca4 New api permissions framework 2016-10-05 13:21:11 +02:00
Mickael Remond efc744092b
We do not force yet access rules check on register command 2016-08-07 18:27:16 +02:00
Mickael Remond 6ea7153e31
Improve error handling 2016-07-31 22:48:24 +02:00
Mickael Remond 39640b67c7
Add support for rich error reporting for API 2016-07-30 13:08:30 +02:00
Mickael Remond fb2603d3cd
Return 409 conflict error code on register if user already exists 2016-07-30 11:50:04 +02:00
Mickael Remond d7ad99f147
Initial attempt on access on commands
May change and will require more work / test / refactor
2016-07-25 11:43:49 +02:00
Mickael Remond 68555ff466
Add support for checking access rules conformance for commands 2016-07-23 18:21:45 +02:00
Badlop ba2680df61 Delete duplicated command export_sql, use export2sql instead (#1118) 2016-05-16 17:57:57 +02:00
Evgeniy Khramtsov 1aae8a9fda Rename odbc to sql everywhere 2016-04-20 13:25:42 +03:00
Badlop 107569a17d New command delete_mnesia deletes all tables that can be exported 2016-03-21 16:19:06 +01:00
Evgeniy Khramtsov d3ee2a9c18 Add 'import_prosody' command 2016-01-29 14:30:50 +03: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
Badlop f448ff608a Update copyright to 2016 (#901) 2016-01-13 12:29:14 +01:00