diff --git a/doc/guide.html b/doc/guide.html index 9ee4604e7..cd2723de7 100644 --- a/doc/guide.html +++ b/doc/guide.html @@ -1,29 +1,46 @@ -Ejabberd 1.1.0 Installation and Operation Guide - - + + +Ejabberd 1.1.1 Installation and Operation Guide + + + + + - + +

- -

Ejabberd 1.1.0 Installation and Operation Guide

- -

Alexey Shchepin
+ + +
+

Ejabberd 1.1.1 Installation and Operation Guide

+

Alexey Shchepin
mailto:alexey@sevcom.net
-xmpp:aleksey@jabber.ru

+xmpp:aleksey@jabber.ru


-
+
@@ -32,114 +49,115 @@
-
I can thoroughly recommend ejabberd for ease of setup -- +
I can thoroughly recommend ejabberd for ease of setup – Kevin Smith, Current maintainer of the Psi project
- + -

Table of Contents

+

Contents

-
  • +
    • 1  Introduction -
      • + -
      • 2  Installation from Source -
        • +
        • 2  Installation from Source +
          • 2.1  Installation Requirements -
            • -2.1.1  ``Unix-like'' operating systems -
            • 2.1.2  Windows + -
            • 2.2  Obtaining ejabberd -
            • 2.3  Compilation - -
            • 3  Configuration -
              • +
              • 3  Configuration +
                • 3.1  Initial Configuration -
                  • + -
                  • 3.2  Relational Database Support -
                    • +
                    • 3.2  Relational Database Support + -
                    • 3.3  Creating an Initial Administrator -
                    • 3.4  Online Configuration and Monitoring - -
                    • 4  Firewall Settings -
                    • 5  SRV Records -
                    • 6  Clustering -
                      • +
                      • 4  Firewall Settings +
                      • 5  SRV Records +
                      • 6  Clustering +
                        • 6.1  How it Works - -
                        • A  Built-in Modules -
                          • +
                          • A  Built-in Modules +
                            • A.1  Overview -
                            • A.2  Common Options - -
                            • B  Internationalization and Localization -
                            • C  Release Notes - -

                              1  Introduction

                              +

                              1  Introduction

                              @@ -151,134 +169,134 @@
                              -

                              1.1  Key Features

                              +

                              1.1  Key Features

                              ejabberd is: -
                              • +
                                • Multiplatform: ejabberd runs under Microsoft Windows and Unix derived systems such as Linux, FreeBSD and NetBSD.

                                  -
                                • Distributed: You can run ejabberd on a cluster of machines and all of them will serve the same Jabber domain(s). When you need more capacity you can simply add a new cheap node to your cluster. Accordingly, you do not need to buy an expensive high-end machine to support tens of thousands concurrent users.
                                  +
                                • Distributed: You can run ejabberd on a cluster of machines and all of them will serve the same Jabber domain(s). When you need more capacity you can simply add a new cheap node to your cluster. Accordingly, you do not need to buy an expensive high-end machine to support tens of thousands concurrent users.

                                  -
                                • Fault-tolerant: You can deploy an ejabberd cluster so that all the information required for a properly working service will be replicated permanently on all nodes. This means that if one of the nodes crashes, the others will continue working without disruption. In addition, nodes also can be added or replaced ``on the fly''.
                                  +
                                • Fault-tolerant: You can deploy an ejabberd cluster so that all the information required for a properly working service will be replicated permanently on all nodes. This means that if one of the nodes crashes, the others will continue working without disruption. In addition, nodes also can be added or replaced “on the fly”.

                                  -
                                • Administrator Friendly: ejabberd is built on top of the Open Source Erlang. As a result you do not need to install an external database, an external web server, amongst others because everything is already included, and ready to run out of the box. Other administrator benefits include: -
                                  • +
                                  • Administrator Friendly: ejabberd is built on top of the Open Source Erlang. As a result you do not need to install an external database, an external web server, amongst others because everything is already included, and ready to run out of the box. Other administrator benefits include: +
                                    • Comprehensive documentation. -
                                    • Straightforward installers for Linux, Mac OS X, and Windows. -
                                    • Web interface for administration tasks. -
                                    • Shared Roster Groups. -
                                    • Command line administration tool. -
                                    • Can integrate with existing authentication mechanisms. -
                                    • Capability to send announce messages. +
                                    • Straightforward installers for Linux, Mac OS X, and Windows. +
                                    • Web interface for administration tasks. +
                                    • Shared Roster Groups. +
                                    • Command line administration tool. +
                                    • Can integrate with existing authentication mechanisms. +
                                    • Capability to send announce messages.


                                    -
                                  • Internationalized: ejabberd leads in internationalization. Hence it is very well suited in a globalized world. Related features are: -
                                    • +
                                    • Internationalized: ejabberd leads in internationalization. Hence it is very well suited in a globalized world. Related features are: +
                                      • Translated in 11 languages. -
                                      • Support for IDNA. +
                                      • Support for IDNA.


                                      -
                                    • Open Standards: ejabberd is the first Open Source Jabber server claiming to fully comply to the XMPP standard. -
                                      • +
                                      • Open Standards: ejabberd is the first Open Source Jabber server claiming to fully comply to the XMPP standard. +
                                      -

                                      1.2  Additional Features

                                      +

                                      1.2  Additional Features

                                      Besides common Jabber server features, ejabberd comes with a wide range of other features: -
                                      • +
                                        • Modular -
                                          • +
                                            • Load only the modules you want. -
                                            • Extend ejabberd with your own custom modules. +
                                            • Extend ejabberd with your own custom modules.
                                            -
                                          • Security -
                                            • +
                                            • Security +
                                              • SASL and STARTTLS for c2s and s2s connections. -
                                              • STARTTLS and Dialback s2s connections. -
                                              • Web interface accessible via HTTPS secure access. +
                                              • STARTTLS and Dialback s2s connections. +
                                              • Web interface accessible via HTTPS secure access.
                                              -
                                            • Databases -
                                              • +
                                              • Databases +
                                                • Native MySQL support. -
                                                • Native PostgreSQL support. -
                                                • Mnesia. -
                                                • ODBC data storage support. +
                                                • Native PostgreSQL support. +
                                                • Mnesia. +
                                                • ODBC data storage support.
                                                -
                                              • Authentication -
                                                • +
                                                • Authentication +
                                                  • LDAP and ODBC. -
                                                  • External Authentication script. -
                                                  • Internal Authentication. +
                                                  • External Authentication script. +
                                                  • Internal Authentication.
                                                  -
                                                • Others -
                                                  • +
                                                  • Others +
                                                    • Compressing XML streams with Stream Compression (JEP-0138). -
                                                    • Interface with networks such as AIM, ICQ and MSN. -
                                                    • Statistics via Statistics Gathering (JEP-0039). -
                                                    • IPv6 support both for c2s and s2s connections. -
                                                    • Multi-User Chat module with logging. -
                                                    • Users Directory based on users vCards. -
                                                    • Publish-Subscribe component. -
                                                    • Support for virtual hosting. -
                                                    • HTTP Polling service. -
                                                    • IRC transport. +
                                                    • Interface with networks such as AIM, ICQ and MSN. +
                                                    • Statistics via Statistics Gathering (JEP-0039). +
                                                    • IPv6 support both for c2s and s2s connections. +
                                                    • Multi-User Chat module with logging. +
                                                    • Users Directory based on users vCards. +
                                                    • Publish-Subscribe component. +
                                                    • Support for virtual hosting. +
                                                    • HTTP Polling service. +
                                                    • IRC transport.
                                                  -

                                                  2  Installation from Source

                                                  +

                                                  2  Installation from Source

                                                  -

                                                  2.1  Installation Requirements

                                                  +

                                                  2.1  Installation Requirements

                                                  - + -

                                                  2.1.1  ``Unix-like'' operating systems

                                                  +

                                                  2.1.1  “Unix-like” operating systems

                                                  -To compile ejabberd on a ``Unix-like'' operating system, you need: -
                                                  • +To compile ejabberd on a “Unix-like” operating system, you need: +
                                                    • GNU Make; -
                                                    • GCC; -
                                                    • libexpat 1.95 or higher; -
                                                    • Erlang/OTP R9C-2 or higher; -
                                                    • OpenSSL 0.9.6 or higher (optional). -
                                                    • Zlib 1.2.3 or higher (optional). -
                                                    • GNU Iconv 1.8 or higher (optional, not needed at all on systems with GNU libc). +
                                                    • GCC; +
                                                    • libexpat 1.95 or higher; +
                                                    • Erlang/OTP R9C-2 or higher; +
                                                    • OpenSSL 0.9.6 or higher (optional). +
                                                    • Zlib 1.2.3 or higher (optional). +
                                                    • GNU Iconv 1.8 or higher (optional, not needed at all on systems with GNU libc).
                                                    -

                                                    2.1.2  Windows

                                                    +

                                                    2.1.2  Windows

                                                    To compile ejabberd on a Windows flavour, you need: -
                                                    • + -

                                                      2.2  Obtaining ejabberd

                                                      +

                                                      2.2  Obtaining ejabberd

                                                      @@ -287,49 +305,49 @@ Released versions of ejabberd can be obtained from

                                                      The latest development version can be retrieved from the Subversion repository. -
                                                      +
                                                         svn co http://svn.process-one.net/ejabberd/trunk ejabberd
                                                       
                                                      -

                                                      2.3  Compilation

                                                      +

                                                      2.3  Compilation

                                                      - + -

                                                      2.3.1  ``Unix-like'' operating systems

                                                      +

                                                      2.3.1  “Unix-like” operating systems

                                                      -Compile ejabberd on a ``Unix-like'' operating system by executing: -
                                                      +Compile ejabberd on a “Unix-like” operating system by executing:
                                                      +
                                                         ./configure
                                                         make
                                                         su
                                                         make install
                                                       
                                                      These commands will: -
                                                      • +
                                                        • install ejabberd into the directory /var/lib/ejabberd, -
                                                        • install the configuration file into /etc/ejabberd, -
                                                        • create a directory called /var/log/ejabberd to store log files. +
                                                        • install the configuration file into /etc/ejabberd, +
                                                        • create a directory called /var/log/ejabberd to store log files.
                                                        -

                                                        2.3.2  Windows

                                                        +

                                                        2.3.2  Windows

                                                        -
                                                        • +
                                                          • Install Erlang emulator (for example, into C:\Program Files\erl5.3). -
                                                          • Install Expat library into C:\Program Files\Expat-1.95.7 +
                                                          • Install Expat library into C:\Program Files\Expat-1.95.7 directory.

                                                            Copy file C:\Program Files\Expat-1.95.7\Libs\libexpat.dll to your Windows system directory (for example, C:\WINNT or C:\WINNT\System32) -
                                                          • Build and install the Iconv library into the directory +
                                                          • Build and install the Iconv library into the directory C:\Program Files\iconv-1.9.1.

                                                            Copy file C:\Program Files\iconv-1.9.1\bin\iconv.dll to your @@ -341,25 +359,25 @@ Note: instead of copying libexpat.dll and iconv.dll to the Windows C:\Program Files\Expat-1.95.7\Libs and C:\Program Files\iconv-1.9.1\bin to the PATH environment variable. -
                                                          • While in the directory ejabberd\src run: -
                                                            +
                                                          • While in the directory ejabberd\src run: +
                                                             configure.bat
                                                             nmake -f Makefile.win32
                                                            -
                                                          • Edit the file ejabberd\src\ejabberd.cfg and run -
                                                            +
                                                          • Edit the file ejabberd\src\ejabberd.cfg and run +
                                                             werl -s ejabberd -name ejabberd
                                                             
                                                          -

                                                          2.4  Starting

                                                          +

                                                          2.4  Starting

                                                          Execute the following command to start ejabberd: -
                                                          +
                                                             erl -pa /var/lib/ejabberd/ebin -name ejabberd -s ejabberd
                                                           
                                                          or -
                                                          +
                                                             erl -pa /var/lib/ejabberd/ebin -sname ejabberd -s ejabberd
                                                           
                                                          In the latter case the Erlang node will be identified using only the first part of the host name, i. e. other Erlang nodes outside this domain can't contact @@ -371,7 +389,7 @@ for storing its user database and for logging.

                                                          To specify the path to the configuration file, the log files and the Mnesia database directory, you may use the following command: -
                                                          +
                                                             erl -pa /var/lib/ejabberd/ebin \
                                                                 -sname ejabberd \
                                                                 -s ejabberd \
                                                          @@ -385,25 +403,25 @@ You can find other useful options in the Erlang manual page
                                                           
                                                          To use more than 1024 connections, you should set the environment variable ERL_MAX_PORTS: -
                                                          +
                                                             export ERL_MAX_PORTS=32000
                                                           
                                                          Note that with this value, ejabberd will use more memory (approximately 6 MB more).

                                                          To reduce memory usage, you may set the environment variable ERL_FULLSWEEP_AFTER: -
                                                          +
                                                             export ERL_FULLSWEEP_AFTER=0
                                                           
                                                          But in this case ejabberd can start to work slower.

                                                          -

                                                          3  Configuration

                                                          +

                                                          3  Configuration

                                                          -

                                                          3.1  Initial Configuration

                                                          +

                                                          3.1  Initial Configuration

                                                          @@ -414,12 +432,12 @@ configuration file are appended to the entries in the database. The configuration file contains a sequence of Erlang terms. Lines beginning with a `%' sign are ignored. Each term is a tuple of which the first element is the name of an option, and any further elements are that option's values. If the -configuration file do not contain for instance the ``hosts'' option, the old +configuration file do not contain for instance the “hosts” option, the old host name(s) stored in the database will be used.

                                                          You can override the old values stored in the database by adding next lines to the configuration file: -
                                                          +
                                                             override_global.
                                                             override_local.
                                                             override_acls.
                                                          @@ -428,7 +446,7 @@ before new ones are added.

                                                          -

                                                          3.1.1  Host Names

                                                          +

                                                          3.1.1  Host Names

                                                          @@ -436,23 +454,23 @@ The option hosts defines a list containing one or more domains that ejabberd will serve.

                                                          Examples: -
                                                          • +
                                                            • Serving one domain: -
                                                              • -
                                                                +
                                                                • +
                                                                     {hosts, ["example.org"]}.
                                                                  -
                                                                • Backwards compatibility with older ejabberd versions can be retained +
                                                              • Backwards compatibility with older ejabberd versions can be retained with: -
                                                                + 
                                                                   {host, "example.org"}.
                                                                 
                                                              -
                                                            • Serving two domains: -
                                                              +
                                                            • Serving two domains: +
                                                                 {hosts, ["example.net", "example.com"]}.
                                                               
                                                            -

                                                            3.1.2  Default Language

                                                            +

                                                            3.1.2  Default Language

                                                            @@ -463,82 +481,82 @@ option language is "en". In order to take effect there must be translation file <language>.msg in ejabberd's msgs directory.

                                                            Examples: -
                                                            • +
                                                              • To set Russian as default language: -
                                                                +
                                                                   {language, "ru"}.
                                                                -
                                                              • To set Spanish as default language: -
                                                                +
                                                              • To set Spanish as default language: +
                                                                   {language, "es"}.
                                                                 
                                                              -

                                                              3.1.3  Access Rules

                                                              +

                                                              3.1.3  Access Rules

                                                              Access control in ejabberd is performed via Access Control Lists (ACLs). The declarations of ACLs in the configuration file have the following syntax: -
                                                              +
                                                                 {acl, <aclname>, {<acltype>, ...}}.
                                                               
                                                              <acltype> can be one of the following: -
                                                              -all
                                                              Matches all JIDs. Example: -
                                                              +
                                                              +all
                                                              Matches all JIDs. Example: +
                                                               {acl, all, all}.
                                                              -
                                                              {user, <username>}
                                                              Matches the user with the name +
                                                              {user, <username>}
                                                              Matches the user with the name <username> at the first virtual host. Example: -
                                                              +
                                                               {acl, admin, {user, "yozhik"}}.
                                                              -
                                                              {user, <username>, <server>}
                                                              Matches the user with the JID +
                                                              {user, <username>, <server>}
                                                              Matches the user with the JID <username>@<server> and any resource. Example: -
                                                              +
                                                               {acl, admin, {user, "yozhik", "example.org"}}.
                                                              -
                                                              {server, <server>}
                                                              Matches any JID from server +
                                                              {server, <server>}
                                                              Matches any JID from server <server>. Example: -
                                                              +
                                                               {acl, exampleorg, {server, "example.org"}}.
                                                              -
                                                              {user_regexp, <regexp>}
                                                              Matches any local user with a name that +
                                                              {user_regexp, <regexp>}
                                                              Matches any local user with a name that matches <regexp> at the first virtual host. Example: -
                                                              +
                                                               {acl, tests, {user, "^test[0-9]*$"}}.
                                                              -
                                                              {user_regexp, <regexp>, <server>}
                                                              Matches any user with a name +
                                                              {user_regexp, <regexp>, <server>}
                                                              Matches any user with a name that matches <regexp> at server <server>. Example: -
                                                              +
                                                               {acl, tests, {user, "^test", "example.org"}}.
                                                              -
                                                              {server_regexp, <regexp>}
                                                              Matches any JID from the server that +
                                                              {server_regexp, <regexp>}
                                                              Matches any JID from the server that matches <regexp>. Example: -
                                                              +
                                                               {acl, icq, {server, "^icq\\."}}.
                                                              -
                                                              {node_regexp, <user_regexp>, <server_regexp>}
                                                              Matches any user +
                                                              {node_regexp, <user_regexp>, <server_regexp>}
                                                              Matches any user with a name that matches <user_regexp> at any server that matches <server_regexp>. Example: -
                                                              +
                                                               {acl, yohzik, {node_regexp, "^yohzik$", "^example.(com|org)$"}}.
                                                              -
                                                              {user_glob, <glob>}
                                                              -
                                                              {user_glob, <glob>, <server>}
                                                              -
                                                              {server_glob, <glob>}
                                                              -
                                                              {node_glob, <user_glob>, <server_glob>}
                                                              This is the same as +
                                                              {user_glob, <glob>}
                                                              +
                                                              {user_glob, <glob>, <server>}
                                                              +
                                                              {server_glob, <glob>}
                                                              +
                                                              {node_glob, <user_glob>, <server_glob>}
                                                              This is the same as above. However, it uses shell glob patterns instead of regexp. These patterns can have the following special characters: -
                                                              - *
                                                              matches any string including the null string. -
                                                              ?
                                                              matches any single character. -
                                                              [...]
                                                              matches any of the enclosed characters. Character +
                                                              + *
                                                              matches any string including the null string. +
                                                              ?
                                                              matches any single character. +
                                                              [...]
                                                              matches any of the enclosed characters. Character ranges are specified by a pair of characters separated by a `-'. If the first character after `[' is a `!', any character not enclosed is matched.
                                                              The following ACLs are pre-defined: -
                                                              -all
                                                              Matches any JID. -
                                                              none
                                                              Matches no JID. +
                                                              +all
                                                              Matches any JID. +
                                                              none
                                                              Matches no JID.
                                                              An entry allowing or denying access to different services looks similar to this: -
                                                              +
                                                                 {access, <accessname>, [{allow, <aclname>},
                                                                                         {deny, <aclname>},
                                                                                         ...
                                                              @@ -546,64 +564,64 @@ this:
                                                               
                                                              When a JID is checked to have access to <accessname>, the server sequentially checks if that JID mathes any of the ACLs that are named in the second elements of the tuples in the list. If it matches, the first element of -the first matched tuple is returned, otherwise ``deny'' is returned.
                                                              +the first matched tuple is returned, otherwise “deny” is returned.

                                                              Example: -
                                                              +
                                                                 {access, configure, [{allow, admin}]}.
                                                                 {access, something, [{deny, badmans},
                                                                                      {allow, all}]}.
                                                               
                                                              The following access rules are pre-defined: -
                                                              -all
                                                              Always returns ``allow'' -
                                                              none
                                                              Always returns ``deny'' +
                                                              +all
                                                              Always returns “allow” +
                                                              none
                                                              Always returns “deny
                                                              -

                                                              3.1.4  Shapers

                                                              +

                                                              3.1.4  Shapers

                                                              Shapers enable you to limit connection traffic. The syntax of shapers is like this: -
                                                              +
                                                                 {shaper, <shapername>, <kind>}.
                                                               
                                                              Currently only one kind of shaper called maxrate is available. It has the following syntax: -
                                                              +
                                                                 {maxrate, <rate>}
                                                               
                                                              where <rate> stands for the maximum allowed incomig rate in bytes per second.

                                                              Examples: -
                                                              • -To define a shaper named ``normal'' with traffic speed limited to +
                                                                • +To define a shaper named “normal” with traffic speed limited to 1,000 bytes/second: -
                                                                  +
                                                                     {shaper, normal, {maxrate, 1000}}.
                                                                  -
                                                                • To define a shaper named ``fast'' with traffic speed limited to +
                                                                • To define a shaper named “fast” with traffic speed limited to 50,000 bytes/second: -
                                                                  +
                                                                     {shaper, fast, {maxrate, 50000}}.
                                                                   
                                                                -

                                                                3.1.5  Listened Sockets

                                                                +

                                                                3.1.5  Listened Sockets

                                                                The option listen defines for which addresses and ports ejabberd will listen and what services will be run on them. Each element of the list is a tuple with the following elements: -
                                                                • +
                                                                  • Port number. -
                                                                  • Module that serves this port. -
                                                                  • Options to this module. +
                                                                  • Module that serves this port. +
                                                                  • Options to this module.
                                                                  Currently next modules are implemented: -

                                                                  +

                                                                  @@ -647,18 +665,18 @@ Currently next modules are implemented:
                                                                  ejabberd_c2scertfile, http_poll, inet6, ip, tls, web_admin
                                                                  -

                                                                  +

                                                                  (*) The mechanism for external components is defined in Jabber Component Protocol (JEP-0114).

                                                                  The following options are available: -
                                                                  - {access, <access rule>}
                                                                  This option defines - access to the port. The default value is ``all''. -
                                                                  {certfile, Path}
                                                                  Path to a file containing the SSL certificate. -
                                                                  {hosts, [Hostnames], [HostOptions]}
                                                                  This option +
                                                                  + {access, <access rule>}
                                                                  This option defines + access to the port. The default value is “all”. +
                                                                  {certfile, Path}
                                                                  Path to a file containing the SSL certificate. +
                                                                  {hosts, [Hostnames], [HostOptions]}
                                                                  This option defines one or more hostnames of connected services and enables you to specify additional options including {password, Secret}. -
                                                                  http_poll
                                                                  +
                                                                  http_poll
                                                                  This option enables HTTP Polling (JEP-0025) support. HTTP Polling enables access via HTTP requests to ejabberd from behind firewalls which do not allow outgoing sockets on port 5222.
                                                                  @@ -670,85 +688,85 @@ If HTTP Polling is enabled, it will be available at JWChat (there is a tutorial to install JWChat with instructions for ejabberd). -
                                                                  inet6
                                                                  Set up the socket for IPv6. -
                                                                  {ip, IPAddress}
                                                                  This option specifies which network +
                                                                  inet6
                                                                  Set up the socket for IPv6. +
                                                                  {ip, IPAddress}
                                                                  This option specifies which network interface to listen for. For example {ip, {192, 168, 1, 1}}. -
                                                                  {max_stanza_size, Size}
                                                                  This +
                                                                  {max_stanza_size, Size}
                                                                  This option specifies an approximate maximal size in bytes of XML stanzas. For example {max\_stanza\_size, 65536}. The default value - is ``infinity''. -
                                                                  {shaper, <access rule>}
                                                                  This option defines a + is “infinity”. +
                                                                  {shaper, <access rule>}
                                                                  This option defines a shaper for the port (see section 3.1.4). The default value - is ``none''. -
                                                                  ssl
                                                                  This option specifies that traffic on + is “none”. +
                                                                  ssl
                                                                  This option specifies that traffic on the port will be encrypted using SSL. You should also set the certfile option. It is recommended to use the tls option instead. -
                                                                  starttls
                                                                  This option +
                                                                  starttls
                                                                  This option specifies that STARTTLS encryption is available on connections to the port. You should also set the certfile option. -
                                                                  starttls_required
                                                                  This option +
                                                                  starttls_required
                                                                  This option specifies that STARTTLS encryption is required on connections to the port. No unencrypted connections will be allowed. You should also set the certfile option. -
                                                                  tls
                                                                  This option specifies that traffic on +
                                                                  tls
                                                                  This option specifies that traffic on the port will be encrypted using SSL immediately after connecting. You should also set the certfile option. -
                                                                  zlib
                                                                  This +
                                                                  zlib
                                                                  This option specifies that Zlib stream compression (as defined in JEP-0138) is available on connections to the port. Client cannot use stream compression and stream encryption simultaneously, so if you specify both tls (or ssl) and zlib the latter option will not affect connection at all. -
                                                                  web_admin
                                                                  This option +
                                                                  web_admin
                                                                  This option enables the web interface for ejabberd administration which is available at http://server:port/admin/. Login and password are the username and password of one of the registered users who are granted access by the - ``configure'' access rule. + “configure” access rule.
                                                                  Also the following global options are available for s2s connections: -
                                                                  - {s2s_use_starttls, true|false}
                                                                  +
                                                                  + {s2s_use_starttls, true|false}
                                                                  This option defines whether to use STARTTLS for s2s connections. -
                                                                  {s2s_certfile, Path}
                                                                  Path to the +
                                                                  {s2s_certfile, Path}
                                                                  Path to the file containing the SSL certificate. -
                                                                  {domain_certfile, Domain, Path}
                                                                  Path +
                                                                  {domain_certfile, Domain, Path}
                                                                  Path to the file containing the SSL certificate for the specified domain.
                                                                  For instance, the following configuration defines that: -
                                                                  • +
                                                                    • c2s connections are listened for on port 5222 and 5223 (SSL) and denied - for the user ``bad'' -
                                                                    • s2s connections are listened for on port 5269 with STARTTLS for secured + for the user “bad” +
                                                                    • s2s connections are listened for on port 5269 with STARTTLS for secured traffic enabled. -
                                                                    • Port 5280 is serving the web interface and the HTTP Polling service. Note +
                                                                    • Port 5280 is serving the web interface and the HTTP Polling service. Note that it is also possible to serve them on different ports. The second example in section 3.4.1 shows how exactly this can be done. -
                                                                    • All users except for the administrators have a traffic of limit +
                                                                    • All users except for the administrators have a traffic of limit 1,000 Bytes/second -
                                                                    • The +
                                                                    • The AIM transport aim.example.org is connected to port 5233 with password - ``aimsecret'' -
                                                                    • The ICQ transport JIT (icq.example.org and + “aimsecret” +
                                                                    • The ICQ transport JIT (icq.example.org and sms.example.org) is connected to port 5234 with password - ``jitsecret'' -
                                                                    • The + “jitsecret” +
                                                                    • The MSN transport msn.example.org is connected to port 5235 with password - ``msnsecret'' -
                                                                    • The + “msnsecret” +
                                                                    • The Yahoo! transport yahoo.example.org is connected to port 5236 with password - ``yahoosecret'' -
                                                                    • The Gadu-Gadu transport gg.example.org is - connected to port 5237 with password ``ggsecret'' -
                                                                    • The + “yahoosecret” +
                                                                    • The Gadu-Gadu transport gg.example.org is + connected to port 5237 with password “ggsecret” +
                                                                    • The Jabber Mail Component jmc.example.org is connected to port 5238 with password - ``jmcsecret'' + “jmcsecret
                                                                    -
                                                                    +
                                                                       {acl, blocked, {user, "bad"}}.
                                                                       {access, c2s, [{deny, blocked},
                                                                                      {allow, all}]}.
                                                                    @@ -779,7 +797,7 @@ c2s connections are listened for on port 5222 and 5223 (SSL) and denied
                                                                       {s2s_certfile, "/path/to/ssl.pem"}.
                                                                     
                                                                    Note, that for jabberd 1.4- or WPJabber-based services you have to make the transports log and do XDB by themselves: -
                                                                    +
                                                                       <!--
                                                                          You have to add elogger and rlogger entries here when using ejabberd.
                                                                          In this case the transport will do the logging.
                                                                    @@ -811,7 +829,7 @@ services you have to make the transports log and do XDB by themselves:
                                                                     
                                                                    -

                                                                    3.1.6  Modules

                                                                    +

                                                                    3.1.6  Modules

                                                                    @@ -821,17 +839,17 @@ element is the name of a module and the second is a list of options for that module. Read section A for detailed information about modules.

                                                                    Examples: -
                                                                    • +
                                                                      • In this simple example, only the module mod_echo is loaded and no options are specified between square brackets: -
                                                                        + 
                                                                           {modules,
                                                                            [{mod_echo,      []}
                                                                            ]}.
                                                                        -
                                                                      • The second example is also simple: the modules mod_echo, mod_time, and +
                                                                      • The second example is also simple: the modules mod_echo, mod_time, and mod_version are loaded without options. Remark that, besides the last entry, all entries end with a comma: -
                                                                        + 
                                                                           {modules,
                                                                            [{mod_echo,      []},
                                                                             {mod_time,      []},
                                                                        @@ -840,22 +858,22 @@ In this simple example, only the module mod_echo is loaded and no
                                                                         
                                                                      -

                                                                      3.1.7  Virtual Hosting

                                                                      +

                                                                      3.1.7  Virtual Hosting

                                                                      Options can be defined separately for every virtual host using the host_config option. It has the following syntax: -
                                                                      +
                                                                         {host_config, <hostname>, [<option>, <option>, ...]}.
                                                                       
                                                                      Examples: -
                                                                      • +
                                                                        • Domain example.net is using the internal authentication method while domain example.com is using the LDAP server running on the domain localhost to perform authentication: -
                                                                          +
                                                                           {host_config, "example.net", [{auth_method, internal}]}.
                                                                           
                                                                           {host_config, "example.com", [{auth_method, ldap},
                                                                          @@ -864,10 +882,10 @@ Domain example.net is using the internal authentication method while
                                                                                                         {ldap_rootdn, "dc=localdomain"},
                                                                                                         {ldap_rootdn, "dc=example,dc=com"},
                                                                                                         {ldap_password, ""}]}.
                                                                          -
                                                                        • Domain example.net is using ODBC to perform authentication +
                                                                        • Domain example.net is using ODBC to perform authentication while domain example.com is using the LDAP servers running on the domains localhost and otherhost: -
                                                                          +
                                                                           {host_config, "example.net", [{auth_method, odbc},
                                                                                                         {odbc_server, "DSN=ejabberd;UID=ejabberd;PWD=ejabberd"}]}.
                                                                           
                                                                          @@ -880,24 +898,24 @@ Domain example.net is using the internal authentication method while
                                                                           
                                                                        -

                                                                        3.1.8  SASL anonymous and anonymous login

                                                                        +

                                                                        3.1.8  SASL anonymous and anonymous login

                                                                        The configuration of the anonymous mode can be done with three host_config parameters: -
                                                                        • +
                                                                          • auth_method: This value is used for defining the authentication method: internal, odbc, ldap, external). You now have a special extra option to enable anonymous mode: anonymous.

                                                                            -
                                                                          • allow_multiple_connections: This option can be either true or false and +
                                                                          • allow_multiple_connections: This option can be either true or false and is only used when the anonymous mode is enabled. Setting it to true means that the same username will be able to be taken several time in anonymous login mode if different resource are used to connect. This option is only useful in very special cases. It defaults to false.

                                                                            -
                                                                          • anonymous_protocol: This option can take three values: +
                                                                          • anonymous_protocol: This option can take three values: sasl_anon, login_anon or both. sasl_anon means that SASL anonymous mode is enabled. login_anon means that anonymous login mode is enabled. both means that SASL anonymous and login anonymous are @@ -907,26 +925,26 @@ Those options are defined for each virtual host with the host_config parameter (see section 3.1.7).

                                                                            Examples: -
                                                                            • +
                                                                              • To enable anonymous login on a virtual host: -
                                                                                +
                                                                                 {host_config, "public.example.org", [{auth_method, anonymous},
                                                                                                                      {anonymous_protocol, login_anon}]}.
                                                                                -
                                                                              • To enable anonymous login and internal authentication on a virtual host: -
                                                                                +
                                                                              • To enable anonymous login and internal authentication on a virtual host: +
                                                                                 {host_config, "public.example.org", [{auth_method, [anonymous,internal]},
                                                                                                                      {anonymous_protocol, login_anon}]}.
                                                                                -
                                                                              • To enable SASL anonymous on a virtual host: -
                                                                                +
                                                                              • To enable SASL anonymous on a virtual host: +
                                                                                 {host_config, "public.example.org", [{auth_method, [anonymous]},
                                                                                                                      {anonymous_protocol, sasl_anon}]}.
                                                                                -
                                                                              • To enable SASL anonymous and anonymous login on a virtual host: -
                                                                                +
                                                                              • To enable SASL anonymous and anonymous login on a virtual host: +
                                                                                 {host_config, "public.example.org", [{auth_method, [anonymous]},
                                                                                                                      {anonymous_protocol, both}]}.
                                                                                -
                                                                              • To enable SASL anonymous, anonymous login and internal authentication on +
                                                                              • To enable SASL anonymous, anonymous login and internal authentication on a virtual host: -
                                                                                +
                                                                                 {host_config, "public.example.org", [{auth_method, [anonymous,internal]},
                                                                                                                      {anonymous_protocol, both}]}.
                                                                                 
                                                                              @@ -936,12 +954,12 @@ available from:
                                                                              -

                                                                              3.2  Relational Database Support

                                                                              +

                                                                              3.2  Relational Database Support

                                                                              -

                                                                              3.2.1  Authentication against a relational database

                                                                              +

                                                                              3.2.1  Authentication against a relational database

                                                                              ejabberd use its internal Mnesia database as a default. It is however possible @@ -954,7 +972,7 @@ system.
                                                                              The option value name be misleading, as the method name is use both for access to relational database through ODBC or through the native interface. In any case, the first step is to define the odbc auth_method. For example: -
                                                                              +
                                                                               {host_config, "public.example.org", [{auth_method, [odbc]}]}.
                                                                               
                                                                              The actual database access is defined in the option odbc_server. Its @@ -963,16 +981,16 @@ interface available, PostgreSQL or MySQL.

                                                                              To use a relational database through ODBC, you can pass the ODBC connection string as odbc_server parameter. For example: -
                                                                              +
                                                                               {odbc_server, "DSN=database;UID=ejabberd;PWD=password"}.
                                                                               
                                                                              To use the native PostgreSQL interface, you can pass a tuple of the following form as parameter: -
                                                                              +
                                                                               {pgsql, "Server", "Database", "Username", "Password"}
                                                                               
                                                                              pgsql is a keyword that should be kept as is. For example: -
                                                                              +
                                                                               {odbc_server, {pgsql, "localhost", "database", "ejabberd", "password"}}.
                                                                               
                                                                              Note that you need to install the Erlang PgSQL library first. This library is @@ -981,11 +999,11 @@ available from Sourceforge: {mysql, "Server", "Database", "Username", "Password"}
                                                                              mysql is a keyword that should be kept as is. For example: -
                                                                              +
                                                                               {odbc_server, {mysql, "localhost", "test", "root", "password"}}.
                                                                               
                                                                              Note that you need to install the Erlang MySQL library first. This library is @@ -996,61 +1014,61 @@ available from:
                                                                              3.2.2  Relational database for other modules

+

3.2.2  Relational database for other modules

It is possible to use a relational database to store pieces of information. You can do this by changing the module name to a name with an _odbc suffix in ejabberd config file. You can use a relational database for the following data: -