Advertisement
Guest User

Untitled

a guest
Aug 31st, 2018
98
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 10.44 KB | None | 0 0
  1. -- Prosody XMPP Configuration File
  2. --
  3. -- Information on configuring Prosody can be found on our
  4. -- website at https://prosody.im/doc/configure
  5. --
  6. -- Tip: You can check that the syntax of this file is correct
  7. -- when you have finished by running this command:
  8. -- prosodyctl check config
  9. -- If there are any errors, it will let you know what and where
  10. -- they are, otherwise it will keep quiet.
  11. --
  12. -- Good luck, and happy Jabbering!
  13.  
  14.  
  15. ---------- Server-wide settings ----------
  16. -- Settings in this section apply to the whole server and are the default settings
  17. -- for any virtual hosts
  18.  
  19. -- This is a (by default, empty) list of accounts that are admins
  20. -- for the server. Note that you must create the accounts separately
  21. -- (see https://prosody.im/doc/creating_accounts for info)
  22. -- Example: admins = { "user1@example.com", "user2@example.net" }
  23. admins = { "ramesh@chat.bleepyin.com" }
  24.  
  25. -- Enable use of libevent for better performance under high load
  26. -- For more information see: https://prosody.im/doc/libevent
  27. --use_libevent = true
  28.  
  29. -- Prosody will always look in its source directory for modules, but
  30. -- this option allows you to specify additional locations where Prosody
  31. -- will look for modules first. For community modules, see https://modules.prosody.im/
  32. plugin_paths = { "/var/www/vhosts/bleepyin.com/chat.bleepyin.com/modules/prosody-modules" }
  33. -- This is the list of modules Prosody will load on startup.
  34. -- It looks for mod_modulename.lua in the plugins folder, so make sure that exists too.
  35. -- Documentation for bundled modules can be found at: https://prosody.im/doc/modules
  36.  
  37.  
  38.  
  39. --Component "chat.bleepyin.com" "http"
  40. -- modules_enabled = { "bosh" }
  41.  
  42. modules_enabled = {
  43.  
  44. -- Generally required
  45. "roster"; -- Allow users to have a roster. Recommended ;)
  46. "saslauth"; -- Authentication for clients and servers. Recommended if you want to log in.
  47. "tls"; -- Add support for secure TLS on c2s/s2s connections
  48. "dialback"; -- s2s dialback support
  49. "disco"; -- Service discovery
  50.  
  51. -- Not essential, but recommended
  52. "carbons"; -- Keep multiple clients in sync
  53. "pep"; -- Enables users to publish their mood, activity, playing music and more
  54. "private"; -- Private XML storage (for room bookmarks, etc.)
  55. "blocklist"; -- Allow users to block communications with other users
  56. "vcard"; -- Allow users to set vCards
  57.  
  58. -- Nice to have
  59. "version"; -- Replies to server version requests
  60. "uptime"; -- Report how long server has been running
  61. "time"; -- Let others know the time here on this server
  62. "ping"; -- Replies to XMPP pings with pongs
  63. "register"; -- Allow users to register on this server using a client and change passwords
  64. "mam"; -- Store messages in an archive and allow users to access it
  65. "carbons";
  66. -- Admin interfaces
  67. "admin_adhoc"; -- Allows administration via an XMPP client that supports ad-hoc commands
  68. --"admin_telnet"; -- Opens telnet console interface on localhost port 5582
  69.  
  70. -- HTTP modules
  71. "bosh"; -- Enable BOSH clients, aka "Jabber over HTTP"
  72. "websocket"; -- XMPP over WebSockets
  73. "http_files"; -- Serve static files from a directory over HTTP
  74. "http_upload";
  75. "conversejs";
  76. "http";
  77. "csi"; -- client state indication
  78. "throttle_presence"; -- presence throttling in CSI
  79. "filter_chatstates"; -- disable "X is typing" type messages
  80. "s2s";
  81. -- Other specific functionality
  82. --"limits"; -- Enable bandwidth limiting for XMPP connections
  83. --"groups"; -- Shared roster support
  84. --"server_contact_info"; -- Publish contact information for this service
  85. --"announce"; -- Send announcement to all online users
  86. --"welcome"; -- Welcome users who register accounts
  87. --"watchregistrations"; -- Alert admins of registrations
  88. --"motd"; -- Send a message to users when they log in
  89. --"legacyauth"; -- Legacy authentication. Only used by some old clients and bots.
  90. --"proxy65"; -- Enables a file transfer proxy service which clients behind NAT can use
  91. }
  92.  
  93. -- These modules are auto-loaded, but should you want
  94. -- to disable them then uncomment them here:
  95. modules_disabled = {
  96. -- "offline"; -- Store offline messages
  97. -- "c2s"; -- Handle client connections
  98. -- "posix"; -- POSIX functionality, sends server to background, enables syslog, etc.
  99. }
  100.  
  101.  
  102.  
  103.  
  104.  
  105. -- Disable account creation by default, for security
  106. -- For more information see https://prosody.im/doc/creating_accounts
  107. cross_domain_websocket = true
  108. consider_websocket_secure = true;
  109. allow_registration = true;
  110. --min_seconds_between_registrations = 21600
  111. -- Force clients to use encrypted connections? This option will
  112. -- prevent clients from authenticating unless they are using encryption.
  113.  
  114. c2s_require_encryption = true
  115.  
  116. -- Force servers to use encrypted connections? This option will
  117. -- prevent servers from authenticating unless they are using encryption.
  118. -- Note that this is different from authentication
  119.  
  120. s2s_require_encryption = true
  121.  
  122.  
  123. cors_origin_allow_all = true
  124. -- Force certificate authentication for server-to-server connections?
  125. -- This provides ideal security, but requires servers you communicate
  126. -- with to support encryption AND present valid, trusted certificates.
  127. -- NOTE: Your version of LuaSec must support certificate verification!
  128. -- For more information see https://prosody.im/doc/s2s#security
  129.  
  130. --s2s_secure_auth = true
  131.  
  132. -- Some servers have invalid or self-signed certificates. You can list
  133. -- remote domains here that will not be required to authenticate using
  134. -- certificates. They will be authenticated using DNS instead, even
  135. -- when s2s_secure_auth is enabled.
  136.  
  137. --s2s_secure_domains = { "chat.bleepyin.com" }
  138.  
  139. -- Even if you leave s2s_secure_auth disabled, you can still require valid
  140. -- certificates for some domains by specifying a list here.
  141.  
  142. --s2s_secure_domains = { "bleepyin.com" }
  143.  
  144. -- Select the authentication backend to use. The 'internal' providers
  145. -- use Prosody's configured data storage to store the authentication data.
  146. -- To allow Prosody to offer secure authentication mechanisms to clients, the
  147. -- default provider stores passwords in plaintext. If you do not trust your
  148. -- server please see https://prosody.im/doc/modules/mod_auth_internal_hashed
  149. -- for information about using the hashed backend.
  150.  
  151. authentication = "internal_hashed"
  152. allow_anonymous_s2s = true
  153.  
  154. -- Select the storage backend to use. By default Prosody uses flat files
  155. -- in its configured data directory, but it also supports more backends
  156. -- through modules. An "sql" backend is included by default, but requires
  157. -- additional dependencies. See https://prosody.im/doc/storage for more info.
  158.  
  159. storage = "sql" -- Default is "internal" (Note: "sql" requires installed
  160. -- lua-dbi RPM package)
  161.  
  162. -- For the "sql" backend, you can uncomment *one* of the below to configure:
  163. --sql = { driver = "SQLite3", database = "prosody.sqlite" } -- Default. 'database' is the filename.
  164. sql = { driver = "MySQL", database = "admin_prosody", username = "admin_prosody", password = "admin@123", host = "localhost" }
  165. --sql = { driver = "PostgreSQL", database = "prosody", username = "prosody", password = "secret", host = "localhost" }
  166.  
  167.  
  168. -- Archiving configuration
  169. -- If mod_mam is enabled, Prosody will store a copy of every message. This
  170. -- is used to synchronize conversations between multiple clients, even if
  171. -- they are offline. This setting controls how long Prosody will keep
  172. -- messages in the archive before removing them.
  173.  
  174. archive_expires_after = "1w" -- Remove archived messages after 1 week
  175.  
  176. -- You can also configure messages to be stored in-memory only. For more
  177. -- archiving options, see https://prosody.im/doc/modules/mod_mam
  178.  
  179. -- Logging configuration
  180. -- For advanced logging see https://prosody.im/doc/logging
  181. log = {
  182. -- Log everything of level "info" and higher (that is, all except "debug" messages)
  183. -- to /var/log/prosody/prosody.log and errors also to /var/log/prosody/prosody.err
  184. info = "/var/log/prosody/prosody.log"; -- Change 'info' to 'debug' for verbose logging
  185. error = "/var/log/prosody/prosody.err"; -- Log errors also to file
  186. -- error = "*syslog"; -- Log errors also to syslog
  187. -- "*console"; -- Log to the console, useful for debugging with daemonize=false
  188. }
  189.  
  190. -- Uncomment to enable statistics
  191. -- For more info see https://prosody.im/doc/statistics
  192. -- statistics = "internal"
  193.  
  194. -- Certificates
  195. -- Every virtual host and component needs a certificate so that clients and
  196. -- servers can securely verify its identity. Prosody will automatically load
  197. -- certificates/keys from the directory specified here.
  198. -- For more information, including how to use 'prosodyctl' to auto-import certificates
  199. -- (from e.g. Let's Encrypt) see https://prosody.im/doc/certificates
  200.  
  201. -- Location of directory to find certificates in (relative to main config file):
  202. --certificates = "/etc/pki/prosody/"
  203.  
  204. -- POSIX configuration
  205. -- For more info see https://prosody.im/doc/modules/mod_posix
  206. pidfile = "/run/prosody/prosody.pid";
  207. --daemonize = false -- Default is "true"
  208.  
  209.  
  210. ----------- Virtual hosts -----------
  211. -- You need to add a VirtualHost entry for each domain you wish Prosody to serve.
  212. -- Settings under each VirtualHost entry apply *only* to that host.
  213.  
  214. key = "/etc/prosody/bleepyin.key";
  215. certificate = "/etc/prosody/bleepyin.crt";
  216.  
  217. VirtualHost "chat.bleepyin.com"
  218. enabled = true
  219. ssl = {
  220. key = "/etc/prosody/bleepyin.key";
  221. certificate = "/etc/prosody/bleepyin.crt";
  222. }
  223.  
  224.  
  225.  
  226. ------ Components ------
  227. -- You can specify components to add hosts that provide special services,
  228. -- like multi-user conferences, and transports.
  229. -- For more information on components, see https://prosody.im/doc/components
  230.  
  231. ---Set up a MUC (multi-user chat) room server on conference.example.com:
  232. Component "conference.chat.bleepyin.com" "muc"
  233. -- restrict_room_creation = "admin"
  234. --modules_enabled ={}
  235.  
  236. ---Set up an external component (default component port is 5347)
  237. --
  238. -- External components allow adding various services, such as gateways/
  239. -- transports to other networks like ICQ, MSN and Yahoo. For more info
  240. -- see: https://prosody.im/doc/components#adding_an_external_component
  241. --
  242. --Component "gateway.example.com"
  243. -- component_secret = "password"
  244.  
  245. ------ Additional config files ------
  246. -- For organizational purposes you may prefer to add VirtualHost and
  247. -- Component definitions in their own config files. This line includes
  248. -- all config files in /etc/prosody/conf.d/
  249. consider_bosh_secure = true;
  250. cross_domain_bosh = true;
  251. Include "conf.d/*.cfg.lua"
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement