• chevron_right

      XMPP Server prosody auf einem Debian Buster

      Stefan · pubsub.movim.eu / xmpp-messenger · Sunday, 17 November, 2019 - 15:34 edit · 1 minute

    XMPP Server prosody auf einem Debian Buster

    Installation

    Die Installation erfolgt einfach über aptitude

    aptitude install prosody prosody-modules

    Dieser Befehl installiert den Server sowie die Module für den Server:

    Die Konfigurationsdateien liegen im Verzeichnis /etc/prosody/.

    Domain Name System (DNS)

    Subdomains

    Für die verschiedenen Dienste von XMPP werden in der Regel die folgenden Subdomains verwendet. Es folgt eine Übersicht von Subdomain, welche jedoch nicht zwingend so benannte werden müssen.

    • xmpp.domain.tld
    • conference.domain.tld
    • uploads.domain.tld

    domain.tld ist durch die eigene Domain zu ersetzen.

    SRV-Record

    _xmpp-server._tcp.domain.tld. 150 IN    SRV 5 0 5269 xmpp.domain.tld.
    _xmpp-client._tcp.domain.tld. 150 IN    SRV 5 0 5222 xmpp.domain.tld.
    _xmpps-client._tcp.domain.tld. 113 IN   SRV 0 5 5223 xmpp.domain.tld.
    

    Der SRV-Record lässt sich mit folgenden Befehlen prüfen.

    dig SRV _xmpp-server._tcp.domain.tld
    dig SRV _xmpp-client._tcp.domain.tld
    dig SRV _xmpps-client._tcp.domain.tld
    

    Konfiguration

    -- Eine Liste der Accounts für die Server Administratoren
    admins = { "admin@domain.tld" }
    
    -- Liste der aktiven Module
    modules_enabled = {
      "roster";
      "saslauth";
      "tls";
      "dialback";
      "disco";
      "private";
      "vcard";
      "version";
      "uptime";
      "time";
      "ping";
      "pep";
      "register";
      "mam";
      "carbons";
      "csi";
      "admin_adhoc";
      "posix";
      "watchregistrations";
      "vcard4";
      "smacks";
      "cloud_notify";
      "register_web";
      "http";
      "pep_vcard_avatar";
      "proxy65";
      "vcard_legacy";
      "blocklist";
      "server_contact_info";
    };
    
    contact_info = {
      abuse = { "mailto:webmaster@domain.tld" };
      admin = { "mailto:webmaster@domain.tld" };
    };
    
    -- Informationen wenn sich ein User auf dem Server registriert
    registration_watchers = { "admin@jabber.domain.tld" }
    registration_notification = "User $username just registered on $host"
    
    modules_disabled = {
    };
    
    allow_registration = true;
    daemonize = false;
    pidfile = "/var/run/prosody/prosody.pid";
    
    ssl = {
            key = "/etc/prosody/certs/localhost.key";
            certificate = "/etc/prosody/certs/localhost.crt";
    }
    
    c2s_require_encryption = true
    s2s_secure_auth = true
    authentication = "internal_hashed"
    
    -- Logging
    
    log = {
            error = "/var/log/prosody/prosody.err";
            { levels = { "error" }; to = "syslog";  };
    }
    
    legacy_ssl_ports = { 5223 }
    
    http_paths = {
      register_web = "/register";
    }
    
    VirtualHost "domain.tld"
            enabled = true
            ssl = {
                    key = "/etc/prosody/certs/localhost.key";
                    certificate = "/etc/prosody/certs/localhost.crt";
            }
    
    Component "conference.domain.tld" "muc"
    modules_enabled = { "muc_mam", "vcard_muc" }
    
    Component "uploads.domain.tld" "http_upload"
    
    • wifi_tethering open_in_new

      This post is public

      de.movim.eu