view mod_offline_email/README.markdown @ 4651:8231774f5bfd

mod_cloud_notify_encrypted: Ensure body substring remains valid UTF-8 The `body:sub()` call risks splitting the string in the middle of a multi-byte UTF-8 sequence. This should have been caught by util.stanza validation, but that would have caused some havoc, at the very least causing the notification to not be sent. There have been no reports of this happening. Likely because this module isn't widely deployed among users with languages that use many longer UTF-8 sequences. The util.encodings.utf8.valid() function is O(n) where only the last sequence really needs to be checked, but it's in C and expected to be fast.
author Kim Alvefur <zash@zash.se>
date Sun, 22 Aug 2021 13:22:59 +0200
parents ea6b5321db50
children
line wrap: on
line source

---
labels:
- 'Stage-Beta'
summary: Forward offline messages via email
...

Introduction
============

Quite often when I am out and about, I'm not able to connect to Jabber.
It is usually much more likely I can access my email though (whether via
the web, or a mobile client).

For this reason I decided it would be extremely useful to have Jabber
messages sent to me while I was offline forwarded to my email inbox.

Usage
=====

Simply add "offline\_email" to your modules\_enabled list. When any user
receives a message while they are offline, it will automatically be
forwarded via mail to the **same** address as their Jabber ID. e.g.
user1@example.com's offline messages will be forwarded to
user1@example.com's email inbox.

Configuration
=============

  Option                   Description
  ------------------------ ----------------------------------------------------------------------------------------------------------------------------------------------------
  queue\_offline\_emails   The number of seconds to buffer messages for, before they are sent as an email. The default is to send each message as it arrives.
  smtp\_server             Address of the SMTP server to send through. Default 'localhost' (recommended, see caveats below)
  smtp\_username           If set, Prosody will authenticate with the SMTP server before sending (default is no authentication)
  smtp\_password           The password for the above user (default is none)
  smtp\_from               Address from which it will appear the emails came. Default is smtp\_username@smtp\_server, where smtp\_username is replaced with 'xmpp' if not set

Compatibility
=============

  ----- -------
  0.9   Works
  ----- -------

Caveats/Todos/Bugs
==================

-   Currently SMTP sending blocks the whole server. This should not be
    noticeable if your mail server is on the same machine as Prosody.
-   There is not (yet) any way to configure forwarding to an email
    address other than your JID (idea... use email address in vcard?)
-   Enable/disable this feature per user?