emailengine-app 2.89.0 → 2.91.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.ncurc.js +19 -8
- package/.release-please-manifest.json +1 -1
- package/CHANGELOG.md +73 -0
- package/Dockerfile +7 -3
- package/ENVIRONMENT.md +24 -23
- package/README.md +1 -1
- package/bin/healthcheck.js +1 -1
- package/copy-static-files.sh +0 -8
- package/data/google-crawlers.json +1 -1
- package/encrypt.js +1 -4
- package/lib/account/field-codec.js +396 -0
- package/lib/account-assignment.js +26 -9
- package/lib/account.js +196 -462
- package/lib/api-routes/account-routes.js +49 -6
- package/lib/api-routes/route-metadata.js +5 -2
- package/lib/api-routes/submit-routes.js +15 -2
- package/lib/api-token-auth.js +342 -274
- package/lib/arf-detect.js +174 -149
- package/lib/attachment-size.js +29 -0
- package/lib/autodetect-imap-settings.js +482 -296
- package/lib/consts.js +5 -5
- package/lib/db.js +1 -4
- package/lib/email-client/base-client.js +907 -780
- package/lib/email-client/gmail-client.js +557 -450
- package/lib/email-client/imap/cid-parts.js +61 -0
- package/lib/email-client/imap/mailbox.js +376 -422
- package/lib/email-client/imap/sync-operations.js +239 -178
- package/lib/email-client/imap-client.js +5 -5
- package/lib/email-client/message-builder.js +4 -5
- package/lib/email-client/new-message-steps.js +168 -2
- package/lib/email-client/outlook/graph-message.js +266 -0
- package/lib/email-client/outlook/subscription-expiry.js +30 -0
- package/lib/email-client/outlook-client.js +652 -808
- package/lib/get-raw-email.js +338 -232
- package/lib/get-secret.js +1 -4
- package/lib/imapproxy/imap-server.js +5 -5
- package/lib/license-subscription.js +60 -0
- package/lib/load-env.js +48 -0
- package/lib/logger-consts.js +37 -1
- package/lib/logger.js +1 -4
- package/lib/mail-probe.js +157 -0
- package/lib/mcp/tools.js +244 -207
- package/lib/metric-values.js +76 -0
- package/lib/metrics.js +320 -0
- package/lib/oauth/gmail.js +39 -120
- package/lib/oauth/http-request.js +195 -0
- package/lib/oauth/mail-ru.js +33 -60
- package/lib/oauth/outlook.js +37 -137
- package/lib/oauth/pubsub/google.js +176 -117
- package/lib/oauth2-apps.js +440 -463
- package/lib/openapi/build-document.js +10 -10
- package/lib/read-env-value.js +31 -7
- package/lib/redis-backend-warnings.js +70 -0
- package/lib/route-descriptors.js +78 -0
- package/lib/schemas.js +10 -1
- package/lib/sentry-integrations.js +299 -0
- package/lib/sentry.js +75 -27
- package/lib/sso-routes.js +249 -0
- package/lib/sso.js +29 -6
- package/lib/tools.js +17 -28
- package/lib/ui-routes/account-edit-form.js +198 -0
- package/lib/ui-routes/account-page.js +241 -0
- package/lib/ui-routes/account-routes.js +46 -349
- package/lib/ui-routes/account-setup.js +1 -1
- package/lib/ui-routes/auth-routes.js +10 -10
- package/lib/ui-routes/provider-signin.js +187 -0
- package/lib/ui-routes/route-helpers.js +1 -1
- package/lib/ui-routes/unsubscribe-routes.js +2 -2
- package/lib/ui-view-context.js +328 -0
- package/lib/utils/public-suffix.js +22 -101
- package/lib/web-safe-html.js +20 -7
- package/lib/worker-metrics.js +82 -0
- package/list-generate.js +2 -5
- package/package.json +28 -24
- package/sbom.json +360 -1030
- package/scripts/refresh-test-tokens.js +1 -1
- package/server.js +400 -677
- package/static/css/flyonui.css +1 -1
- package/static/css/public.css +55 -1
- package/static/css/src/app.tailwind.css +18 -0
- package/static/js/ee-client.js +2619 -645
- package/static/js/ui.js +12 -2
- package/static/licenses.html +224 -764
- package/translations/de.mo +0 -0
- package/translations/de.po +429 -390
- package/translations/en.mo +0 -0
- package/translations/en.po +342 -257
- package/translations/es.mo +0 -0
- package/translations/es.po +440 -395
- package/translations/et.mo +0 -0
- package/translations/et.po +425 -375
- package/translations/fr.mo +0 -0
- package/translations/fr.po +425 -383
- package/translations/it.mo +0 -0
- package/translations/it.po +441 -394
- package/translations/ja.mo +0 -0
- package/translations/ja.po +408 -335
- package/translations/messages.pot +188 -130
- package/translations/nl.mo +0 -0
- package/translations/nl.po +419 -382
- package/translations/pl.mo +0 -0
- package/translations/pl.po +425 -379
- package/translations/sv.mo +0 -0
- package/translations/sv.po +440 -388
- package/translations/tr.mo +0 -0
- package/translations/tr.po +441 -387
- package/views/account-identity-error.hbs +1 -1
- package/views/account-workspace-error.hbs +2 -2
- package/views/accounts/browse.hbs +19 -1
- package/views/accounts/register/imap-server.hbs +22 -7
- package/views/accounts/register/imap.hbs +3 -0
- package/views/accounts/register/index.hbs +1 -27
- package/views/accounts/register/provider-signin.hbs +58 -0
- package/views/oauth-scope-error.hbs +1 -1
- package/views/partials/provider_signin_button.hbs +30 -0
- package/views/queues/index.hbs +1 -1
- package/views/redirect.hbs +1 -1
- package/views/unsubscribe.hbs +6 -6
- package/workers/api.js +20 -451
- package/data/public_suffix_list.dat +0 -16698
package/.ncurc.js
CHANGED
|
@@ -23,7 +23,7 @@ module.exports = {
|
|
|
23
23
|
target: name =>
|
|
24
24
|
['pino', '@playwright/test'].includes(name)
|
|
25
25
|
? 'patch'
|
|
26
|
-
: ['gettext-parser', 'marked', '
|
|
26
|
+
: ['gettext-parser', 'marked', 'he', 'iconv-lite', '@hapi/boom'].includes(name)
|
|
27
27
|
? 'minor'
|
|
28
28
|
: 'latest'
|
|
29
29
|
// pino - held on 10.3.x. 10.4.0 took PR #2294, which makes lib/caller.js prefer
|
|
@@ -44,22 +44,33 @@ module.exports = {
|
|
|
44
44
|
// times out with "Received: undefined" while the page snapshot shows the button).
|
|
45
45
|
// Same spec passes in 3.8 s on 1.63.0; nothing in the 1.64 release notes covers
|
|
46
46
|
// it. Lift once a 1.64.x or later passes that spec unchanged.
|
|
47
|
-
// gettext-parser - 8.x
|
|
47
|
+
// gettext-parser - 8.x and later are ESM-only (10.0.0 is type:module with no require condition). It is a
|
|
48
|
+
// devDependency only (gettext-extract.js and test/gettext-pot-order-test.js), so pkg is not
|
|
49
|
+
// the constraint: the unit tier runs under `npm run test:cjs` (require(esm) disabled), where
|
|
50
|
+
// an ESM-only gettext-parser fails to load.
|
|
48
51
|
// marked - 16.x dropped the CommonJS build (ESM-only, needs require(esm)); 15.x is the last
|
|
49
52
|
// require()-compatible line, verified in a yao/pkg node24 build.
|
|
50
53
|
// Permanent: an ESM-only release cannot be bundled by pkg, whatever the Node floor.
|
|
51
54
|
// iconv-lite - 1.0 (alpha since 2026-10) moves to ES modules, relying on require(esm). Held on 0.x;
|
|
52
55
|
// libmime, imapflow and mailparser carry the same cap. The ES module move keeps it out of
|
|
53
56
|
// the pkg bundle.
|
|
57
|
+
// @hapi/boom - 11.0.0-rc.0 (dist-tag next, 2026-08) is type:module with only an ESM export (boom PR #309,
|
|
58
|
+
// "convert module to ESM") and engines node>=22. Without this cap `npm run update` would move
|
|
59
|
+
// to it the day 11.0.0 reaches latest, and the pkg binary would fail while dev and tests pass on
|
|
60
|
+
// require(esm). The hapi org did the same to bourne, formula, pinpoint and tlds in 2026 and has
|
|
61
|
+
// ESM-only rcs of hoek 12 and topo 7, so a hapi 22 will likely follow: add every direct
|
|
62
|
+
// @hapi/* dependency here the day it publishes an ESM-only major. hapi 21 itself still depends
|
|
63
|
+
// on boom ^10, hoek ^11 and topo ^6.
|
|
54
64
|
// he - 2.x is ESM-only (exports only src/he.mjs). 1.2.0 is the last CommonJS release. mailparser,
|
|
55
65
|
// which reaches EmailEngine through the same require, rejects 2.x for the same reason.
|
|
56
66
|
// Permanent for the same pkg reason as marked.
|
|
57
|
-
//
|
|
58
|
-
//
|
|
59
|
-
//
|
|
60
|
-
//
|
|
61
|
-
//
|
|
62
|
-
//
|
|
67
|
+
//
|
|
68
|
+
// Sentry: EmailEngine builds its client from @sentry/core (lib/sentry.js, with its own context-lines, context and
|
|
69
|
+
// modules integrations in lib/sentry-integrations.js) and must not depend on @sentry/node or @sentry/node-core.
|
|
70
|
+
// @sentry/node 11.x depends on @sentry/bundler-plugins, which pulls the 16 MB Sentry CLI (package `sentry`,
|
|
71
|
+
// licensed FSL-1.1-Apache-2.0, not an OSI license) and the native oxc-parser into the runtime tree and the pkg
|
|
72
|
+
// bundle, and @sentry/node-core, the light SDK used until 2026-11, ended at 10.x. @sentry/core depends only on
|
|
73
|
+
// @sentry/conventions; check that it still does on every major.
|
|
63
74
|
//
|
|
64
75
|
// ical.js was capped at 1.x here as "2.x is ESM-only", which was never true: every 2.x ships a CommonJS
|
|
65
76
|
// build behind exports.require. Moved to 2.x on 2026-09-28; it is also what resolves a DTSTART against
|
package/CHANGELOG.md
CHANGED
|
@@ -1,5 +1,78 @@
|
|
|
1
1
|
# Changelog
|
|
2
2
|
|
|
3
|
+
## [2.91.0](https://github.com/postalsys/emailengine/compare/v2.90.0...v2.91.0) (2026-11-26)
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
### Features
|
|
7
|
+
|
|
8
|
+
* name the OAuth2 provider in autodiscovery results ([a3c2151](https://github.com/postalsys/emailengine/commit/a3c21513217218a10dad8b7194e19d6cb49145bb))
|
|
9
|
+
* offer OAuth2 sign-in when autodiscovery recognizes Gmail or Microsoft 365 ([ff3189c](https://github.com/postalsys/emailengine/commit/ff3189c5de184cbf420085c9e6de6dfac7d6710f))
|
|
10
|
+
* offer OAuth2 sign-in when the hosted form detects Gmail or Microsoft 365 ([bba7313](https://github.com/postalsys/emailengine/commit/bba731370e9f083f62df6bf0f5eb19269a9723a8))
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
### Bug Fixes
|
|
14
|
+
|
|
15
|
+
* balance line breaks in the hosted form's headings and sign-in copy ([878bf4c](https://github.com/postalsys/emailengine/commit/878bf4c469ba3b0de6f128b5224186c6424d43b4))
|
|
16
|
+
* balance line breaks in the hosted form's headings and sign-in copy ([2e829fb](https://github.com/postalsys/emailengine/commit/2e829fb61e30ebdae89e28983a20f0b4e5014b70))
|
|
17
|
+
* bump node from `8a32c8c` to `116b800` ([517616b](https://github.com/postalsys/emailengine/commit/517616b6127095c763851ce1abe6155a5c5dead1))
|
|
18
|
+
* bump node from `8a32c8c` to `116b800` ([fd78f06](https://github.com/postalsys/emailengine/commit/fd78f062fa86b1a6e1299f41e30e3cabae5c92da))
|
|
19
|
+
* flag a rejected Mail.ru OAuth client on the app ([7490e6b](https://github.com/postalsys/emailengine/commit/7490e6b3ecc98b468df0b72468d9334eb5ccd7fc))
|
|
20
|
+
* honor a file-backed log level in the main process, add EENGINE_LOG_REDACT_HEADERS ([d2fea14](https://github.com/postalsys/emailengine/commit/d2fea14670afa53617c3da7e8ce7d959a198f55a))
|
|
21
|
+
* polish public UI copy and translations ([96a1f01](https://github.com/postalsys/emailengine/commit/96a1f01f36e6fb061f3768888c9270a577d1c43c))
|
|
22
|
+
* recognize smtp.google.com as a Google Workspace MX ([c4bb501](https://github.com/postalsys/emailengine/commit/c4bb5010a7deb48a33582ea5f562525493a02ed8))
|
|
23
|
+
* recover accounts whose assignment or worker dispatch was lost ([92cfab9](https://github.com/postalsys/emailengine/commit/92cfab95de7e985d4fee67d1074c34c0df339314))
|
|
24
|
+
* resolve mail settings for domains that publish none ([90ed041](https://github.com/postalsys/emailengine/commit/90ed0412e9193575e958b4a36467faa0eb7f538e))
|
|
25
|
+
* resolve mail settings for domains that publish none ([5cb4bd4](https://github.com/postalsys/emailengine/commit/5cb4bd4c047424e293dd4cf4d896aa8000542666))
|
|
26
|
+
* update dependencies ([740e988](https://github.com/postalsys/emailengine/commit/740e9886ffdb37b11d2161632dab55a03adb62bd))
|
|
27
|
+
* update dependencies ([d066d88](https://github.com/postalsys/emailengine/commit/d066d8822490772e0c24c606d01ed0f13bbfafd3))
|
|
28
|
+
* update dependencies ([e6f506b](https://github.com/postalsys/emailengine/commit/e6f506b82757d66a871da857d3fa6071b4288829))
|
|
29
|
+
* update dependencies ([9c73807](https://github.com/postalsys/emailengine/commit/9c73807861a97018fcdbd444fab0789a170ab28c))
|
|
30
|
+
* warn about Amazon ElastiCache only when the primary has no replica ([2a97862](https://github.com/postalsys/emailengine/commit/2a97862e8398627c6f1147978ac51caa4e4628c4))
|
|
31
|
+
|
|
32
|
+
## [2.90.0](https://github.com/postalsys/emailengine/compare/v2.89.0...v2.90.0) (2026-11-20)
|
|
33
|
+
|
|
34
|
+
|
|
35
|
+
### Features
|
|
36
|
+
|
|
37
|
+
* write inline reply and forward headers in the language of the locale ([454a6dd](https://github.com/postalsys/emailengine/commit/454a6ddc23f9de95f326e8ba55e3e8e0cb67b9a0))
|
|
38
|
+
|
|
39
|
+
|
|
40
|
+
### Bug Fixes
|
|
41
|
+
|
|
42
|
+
* anchor the AWS WorkMail MX pattern ([1cc357e](https://github.com/postalsys/emailengine/commit/1cc357e58f8678a60a4aeff5a9b5c773126646df))
|
|
43
|
+
* connect a Gmail account whose profile carries no history ID ([c7cb645](https://github.com/postalsys/emailengine/commit/c7cb64595c8f868a9c2ea4c6196a501a13f5803b))
|
|
44
|
+
* fetch listed Gmail messages ten at a time, not eleven ([ac2e0d3](https://github.com/postalsys/emailengine/commit/ac2e0d31447bf73b1c7a7ed0425bb7b9706b1f9c))
|
|
45
|
+
* give a reply or forward a text part when it has no text of its own ([86522b7](https://github.com/postalsys/emailengine/commit/86522b7a3c4547ad72fc8accc5f6266f6353e9d3))
|
|
46
|
+
* keep account counter names off Object.prototype ([35d62b0](https://github.com/postalsys/emailengine/commit/35d62b0ee10a3206ee128d941cb0b719f68cf8d0))
|
|
47
|
+
* keep an unsaved message in the message browser when its save question is dismissed ([aace267](https://github.com/postalsys/emailengine/commit/aace267ddd763b7647ce92b72b48b4a8bd7e285a))
|
|
48
|
+
* keep complaint recipients collected before the feedback report ([09b5e84](https://github.com/postalsys/emailengine/commit/09b5e848b51a8ebb24f2ca584f0466ddcfa0110c))
|
|
49
|
+
* leave an account field holding undefined out of the stored hash ([9e96857](https://github.com/postalsys/emailengine/commit/9e968579b165c7462f0c3fb547ed1fd0e011f03f))
|
|
50
|
+
* leave optional packages out of the Docker image ([6d00ea1](https://github.com/postalsys/emailengine/commit/6d00ea121364872da597bf07bda2f064ca83c1e1))
|
|
51
|
+
* link straight to a message in the admin message browser ([9d881a6](https://github.com/postalsys/emailengine/commit/9d881a6706aae3bc002eeb6295bfa932cd20f7ea))
|
|
52
|
+
* load .env with Node's own parser instead of dotenv ([23fd4ad](https://github.com/postalsys/emailengine/commit/23fd4adf0396690557de837b8a2e609f0285de1e))
|
|
53
|
+
* load the passkey library on the first passkey request ([2f4280b](https://github.com/postalsys/emailengine/commit/2f4280b4f09eb084ca1d81f6e6519b55a1a543a3))
|
|
54
|
+
* look up registrable domains through tldts ([942bd43](https://github.com/postalsys/emailengine/commit/942bd4368dc5c59ea99d8a880f518403df014e05))
|
|
55
|
+
* mark a forwarded message $Forwarded only, and even when it was answered ([c52084a](https://github.com/postalsys/emailengine/commit/c52084a86966661bca74f48a5c9cf447d8b7ca99))
|
|
56
|
+
* move the Prometheus metrics to @prometheus-io/client ([a2c6f63](https://github.com/postalsys/emailengine/commit/a2c6f63c75c2c3a12bcca62e29fbe932990b74d1))
|
|
57
|
+
* plain-text quotes, web-safe font and attachment file size ([779082e](https://github.com/postalsys/emailengine/commit/779082ee6735b475f26fdfcacc52af7a5028ef2a))
|
|
58
|
+
* quote a plain-text original in the HTML part of a reply or forward ([2f6a02a](https://github.com/postalsys/emailengine/commit/2f6a02a9f8074ac2070025f03cd2715da48bcd7f))
|
|
59
|
+
* raise the Outlook client secret flag when no secret is configured ([6667e8d](https://github.com/postalsys/emailengine/commit/6667e8dea9b42a836b32929606f1e5da29f4479a))
|
|
60
|
+
* refuse a missing API token with a 401 instead of a TypeError ([140d88d](https://github.com/postalsys/emailengine/commit/140d88de63c5e7243a46c535c9035072f4561088))
|
|
61
|
+
* register the OIDC sign-in route at boot, before discovery succeeds ([a81ee0b](https://github.com/postalsys/emailengine/commit/a81ee0bed1419941ae824718fd316104f5dcc637))
|
|
62
|
+
* report the file size of attachments ([79386b3](https://github.com/postalsys/emailengine/commit/79386b39355f3cb023dc5f591460fabb97e68f89))
|
|
63
|
+
* resolve @hapi/bell to the root joi 18 ([0b77d15](https://github.com/postalsys/emailengine/commit/0b77d154ee8471f8d665f917b9eec65634a861db))
|
|
64
|
+
* return the usual shape from the IMAP attachment list without a body structure ([caaaba9](https://github.com/postalsys/emailengine/commit/caaaba9f7d8c4f588239bc76a5e84f71b6175611))
|
|
65
|
+
* send error reports through @sentry/core 11 ([b6531e5](https://github.com/postalsys/emailengine/commit/b6531e52445a059a6f70b44b83887b28015f960d))
|
|
66
|
+
* stop an untouched account edit save from reconnecting IMAP ([65ee163](https://github.com/postalsys/emailengine/commit/65ee1639a91ed4ad7a4e57059b0227ddba4f70fa))
|
|
67
|
+
* stop re-downloading an API message that came back without content ([ba5e272](https://github.com/postalsys/emailengine/commit/ba5e2721db068abe5345ce3a49b7d67d3f3b99e7))
|
|
68
|
+
* stop storing account objects as '[object Object]' ([324c803](https://github.com/postalsys/emailengine/commit/324c8035c1343c0cf904b8feb40efd7dbd451643))
|
|
69
|
+
* treat an uppercase GET as a GET when placing an Outlook request payload ([7a55420](https://github.com/postalsys/emailengine/commit/7a55420c93c075048b061b8a98550fce8a32a4ac))
|
|
70
|
+
* update dependencies ([d116dbc](https://github.com/postalsys/emailengine/commit/d116dbc09112f170133c22608fd8b880eb78247d))
|
|
71
|
+
* update dependencies ([aa47701](https://github.com/postalsys/emailengine/commit/aa47701d5cd9dbe3a0b78effaf4499cab93d0548))
|
|
72
|
+
* update dependencies ([2bf0f1b](https://github.com/postalsys/emailengine/commit/2bf0f1b6542dac24e291db973de6f663159de52d))
|
|
73
|
+
* update dependencies ([a61a043](https://github.com/postalsys/emailengine/commit/a61a043b8d6b36c21abeebe3cc304b188fba6cd4))
|
|
74
|
+
* web-safe HTML of plain-text mail no longer fixes the font ([484c601](https://github.com/postalsys/emailengine/commit/484c6016c6ac10094dde44af3989fef4a4a8ef22))
|
|
75
|
+
|
|
3
76
|
## [2.89.0](https://github.com/postalsys/emailengine/compare/v2.88.0...v2.89.0) (2026-11-15)
|
|
4
77
|
|
|
5
78
|
|
package/Dockerfile
CHANGED
|
@@ -11,7 +11,7 @@
|
|
|
11
11
|
# here; the runtime stage below copies out only the finished tree, so npm and its dependencies never
|
|
12
12
|
# reach the published image. npm accounted for 38 of the 59 HIGH/CRITICAL findings in the old image
|
|
13
13
|
# (a vendored tar, pacote, sigstore, minimatch) and nothing at runtime ever invokes it.
|
|
14
|
-
FROM node:24-alpine@sha256:
|
|
14
|
+
FROM node:24-alpine@sha256:116b800c3754b440ee0aa3ed2f20f5bf3d99a554bfd9adeea09ea8017f6e85f5 AS builder
|
|
15
15
|
|
|
16
16
|
ARG BUILDPLATFORM
|
|
17
17
|
ARG TARGETPLATFORM
|
|
@@ -33,7 +33,11 @@ WORKDIR /emailengine
|
|
|
33
33
|
# the lockfile actually changes.
|
|
34
34
|
COPY package.json package.json
|
|
35
35
|
COPY package-lock.json package-lock.json
|
|
36
|
-
|
|
36
|
+
# --omit=optional, as the binary build does: the only optional runtime packages are msgpackr-extract
|
|
37
|
+
# (a native addon with an install script that MSGPACKR_NATIVE_ACCELERATION_DISABLED below keeps
|
|
38
|
+
# unused anyway, plus its six platform prebuilds), handlebars' precompiler (uglify-js) and a
|
|
39
|
+
# types package. None of them is loaded at runtime.
|
|
40
|
+
RUN npm ci --omit=dev --omit=optional
|
|
37
41
|
|
|
38
42
|
# Copy app folders
|
|
39
43
|
COPY bin bin
|
|
@@ -74,7 +78,7 @@ RUN : "${EE_COMMIT_HASH:?EE_COMMIT_HASH build arg is required, e.g. --build-arg
|
|
|
74
78
|
&& rm -f update-info.sh
|
|
75
79
|
|
|
76
80
|
# Runtime stage.
|
|
77
|
-
FROM node:24-alpine@sha256:
|
|
81
|
+
FROM node:24-alpine@sha256:116b800c3754b440ee0aa3ed2f20f5bf3d99a554bfd9adeea09ea8017f6e85f5
|
|
78
82
|
|
|
79
83
|
# `apk upgrade` patches the Alpine packages that the base image itself lags on - at the time of
|
|
80
84
|
# writing node:24-alpine still carries an openssl below 3.5.8-r0. dumb-init reaps zombies as PID 1.
|
package/ENVIRONMENT.md
CHANGED
|
@@ -16,29 +16,30 @@ entry says otherwise. Sizes take a number with a unit (`5MB`, `1GB`) or plain by
|
|
|
16
16
|
|
|
17
17
|
## Core
|
|
18
18
|
|
|
19
|
-
| Variable | Default | Description
|
|
20
|
-
| --------------------------------------- | -------------------------- |
|
|
21
|
-
| `EENGINE_REDIS` | `redis://127.0.0.1:6379/8` | Redis connection URI. `REDIS_URL` is read when this is unset.
|
|
22
|
-
| `EENGINE_REDIS_TLS_REJECT_UNAUTHORIZED` | `true` | Set to `false` to accept a Redis server certificate no CA signed, for managed services such as the Heroku Redis add-on. Applies to a `rediss://` connection only; every other connection is still verified.
|
|
23
|
-
| `EENGINE_REDIS_PREFIX` | none | Prefix for every Redis key, so several instances can share one database.
|
|
24
|
-
| `EENGINE_SECRET` | none | Encryption secret for stored credentials. Changing it makes stored credentials unreadable; use `emailengine encrypt` to rotate.
|
|
25
|
-
| `EENGINE_PORT` | `3000` | API and admin UI port. `PORT` is read when this is unset.
|
|
26
|
-
| `EENGINE_HOST` | `127.0.0.1` | API and admin UI bind address.
|
|
27
|
-
| `EENGINE_TIMEOUT` | `10s` | How long an API request waits for a worker to answer (duration).
|
|
28
|
-
| `EENGINE_LOG_LEVEL` | `trace` | Logging level.
|
|
29
|
-
| `EENGINE_LOG_RAW` | `false` | Log raw IMAP and SMTP protocol traffic. Credentials are masked either way.
|
|
30
|
-
| `
|
|
31
|
-
| `
|
|
32
|
-
| `
|
|
33
|
-
| `
|
|
34
|
-
| `
|
|
35
|
-
| `
|
|
36
|
-
| `
|
|
37
|
-
| `
|
|
38
|
-
| `
|
|
39
|
-
| `
|
|
40
|
-
| `
|
|
41
|
-
| `
|
|
19
|
+
| Variable | Default | Description |
|
|
20
|
+
| --------------------------------------- | -------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
21
|
+
| `EENGINE_REDIS` | `redis://127.0.0.1:6379/8` | Redis connection URI. `REDIS_URL` is read when this is unset. |
|
|
22
|
+
| `EENGINE_REDIS_TLS_REJECT_UNAUTHORIZED` | `true` | Set to `false` to accept a Redis server certificate no CA signed, for managed services such as the Heroku Redis add-on. Applies to a `rediss://` connection only; every other connection is still verified. |
|
|
23
|
+
| `EENGINE_REDIS_PREFIX` | none | Prefix for every Redis key, so several instances can share one database. |
|
|
24
|
+
| `EENGINE_SECRET` | none | Encryption secret for stored credentials. Changing it makes stored credentials unreadable; use `emailengine encrypt` to rotate. |
|
|
25
|
+
| `EENGINE_PORT` | `3000` | API and admin UI port. `PORT` is read when this is unset. |
|
|
26
|
+
| `EENGINE_HOST` | `127.0.0.1` | API and admin UI bind address. |
|
|
27
|
+
| `EENGINE_TIMEOUT` | `10s` | How long an API request waits for a worker to answer (duration). |
|
|
28
|
+
| `EENGINE_LOG_LEVEL` | `trace` | Logging level. |
|
|
29
|
+
| `EENGINE_LOG_RAW` | `false` | Log raw IMAP and SMTP protocol traffic. Credentials are masked either way. |
|
|
30
|
+
| `EENGINE_LOG_REDACT_HEADERS` | none | Comma-separated request header names whose values are replaced with `[Redacted]` in the logs, in addition to `Authorization` and `Cookie`. For example a shared-secret header that a WAF or proxy in front of EmailEngine requires. |
|
|
31
|
+
| `EENGINE_SETTINGS` | none | JSON object of settings, re-applied on every start. A value saved in the admin UI for one of its keys reverts at the next restart. |
|
|
32
|
+
| `EENGINE_PREPARED_TOKEN` | none | A base64url msgpack-encoded API token to provision at start. |
|
|
33
|
+
| `EENGINE_PREPARED_PASSWORD` | none | A base64url PBKDF2 admin password hash to apply at start. Writing a different hash ends every admin session. |
|
|
34
|
+
| `EENGINE_PREPARED_LICENSE` | none | A license key to apply at start. |
|
|
35
|
+
| `EENGINE_REQUIRE_API_AUTH` | none | Initial value for whether API requests need an access token (`true`/`false`), used when the setting has never been saved. |
|
|
36
|
+
| `EENGINE_ENABLE_OAUTH_TOKENS_API` | none | Initial value for the setting that allows the OAuth2 access token API, used when it has never been saved. |
|
|
37
|
+
| `EENGINE_CONNECTION_SETUP_DELAY` | `0` | Pause between two account assignments while accounts are handed to workers, to spread the connection load at start (duration). |
|
|
38
|
+
| `EENGINE_UPDATE_CHECK_DISABLED` | `false` | Stop checking for new EmailEngine releases. |
|
|
39
|
+
| `EENGINE_BEACON_DISABLED` | `false` | Opt out of the anonymized feature-usage diagnostics sent with license validation. License validation itself is unaffected. |
|
|
40
|
+
| `EENGINE_DISABLE_SETUP_WARNINGS` | `false` | Hide the setup warning banners in the admin UI. |
|
|
41
|
+
| `EENGINE_DOCEAN` | none | Set by the DigitalOcean one-click image; adjusts the dashboard and diagnostics. Not for manual use. |
|
|
42
|
+
| `EENGINE_INSTALL_SCRIPT` | none | Set by the install script; adjusts the dashboard and diagnostics. Not for manual use. |
|
|
42
43
|
|
|
43
44
|
## Workers and queues
|
|
44
45
|
|
package/README.md
CHANGED
|
@@ -46,7 +46,7 @@ A headless email client application that provides access to IMAP, SMTP, Gmail AP
|
|
|
46
46
|
> [!IMPORTANT]
|
|
47
47
|
> EmailEngine uses Redis as its primary database, not as a cache. Set `maxmemory-policy` to `noeviction` and give Redis enough memory for your workload - with any other policy Redis can drop sync state, which makes already-synced messages look new and generates duplicate webhooks.
|
|
48
48
|
>
|
|
49
|
-
> Redis Cluster and Amazon ElastiCache
|
|
49
|
+
> Redis Cluster is **not** supported, and neither is anything that always runs as one: Amazon MemoryDB, and Amazon ElastiCache with cluster mode or the durability option enabled. Use a standard Redis primary instance. Amazon ElastiCache with cluster mode disabled works only with at least one replica and Multi-AZ automatic failover: a single ElastiCache node starts empty when AWS replaces it, and does not reload its snapshot. EmailEngine warns about all of the above on the dashboard when it detects them.
|
|
50
50
|
|
|
51
51
|
> [!NOTE]
|
|
52
52
|
> While Redis does not officially support Windows, alternatives like [Memurai](https://www.memurai.com/) are available.
|
package/bin/healthcheck.js
CHANGED
|
@@ -6,7 +6,7 @@
|
|
|
6
6
|
|
|
7
7
|
// Resolve `.env` and `config/` against the application root, in the same order as server.js
|
|
8
8
|
process.chdir(require('path').join(__dirname, '..'));
|
|
9
|
-
require('
|
|
9
|
+
require('../lib/load-env').loadEnvFile();
|
|
10
10
|
|
|
11
11
|
const config = require('@zone-eu/wild-config');
|
|
12
12
|
const { probeTarget, probe } = require('../lib/health-probe');
|
package/copy-static-files.sh
CHANGED
|
@@ -93,14 +93,6 @@ fetch_json() {
|
|
|
93
93
|
fetch_json data/google-crawlers.json wget -q -O - https://developers.google.com/static/crawling/ipranges/special-crawlers.json
|
|
94
94
|
node -e 'console.log("Google crawlers updated: "+require("./data/google-crawlers.json").creationTime);'
|
|
95
95
|
|
|
96
|
-
# The Public Suffix List, read by lib/utils/public-suffix.js. Kept verbatim (it is MPL-2.0 and carries
|
|
97
|
-
# its own licence header), and only accepted when both sections arrived whole: a truncated list would
|
|
98
|
-
# not fail to parse, it would just quietly know fewer suffixes. Nor is a list older than the one
|
|
99
|
-
# already here: the site's CDN has served a copy two days behind the one committed the same morning,
|
|
100
|
-
# and the refresh replaced the newer list with it. Exit code 3 keeps the current copy without a warning
|
|
101
|
-
fetch_checked data/public_suffix_list.dat 'const fs=require("fs");const t=fs.readFileSync(process.argv[1],"utf8");for(const m of ["===BEGIN ICANN DOMAINS===","===END ICANN DOMAINS===","===BEGIN PRIVATE DOMAINS===","===END PRIVATE DOMAINS==="])if(!t.includes(m))throw new Error("missing "+m);const v=x=>((x.match(/^\/\/ VERSION: (\S+)/m)||[])[1]||"");let old="";try{old=v(fs.readFileSync(process.argv[2],"utf8"))}catch(e){}if(old&&v(t)<old){console.error("Public Suffix List: the download ("+(v(t)||"no version")+") is older than the copy here ("+old+"), keeping it");process.exit(3)}' wget -q -O - https://publicsuffix.org/list/public_suffix_list.dat
|
|
102
|
-
grep -m1 '^// VERSION:' data/public_suffix_list.dat || true
|
|
103
|
-
|
|
104
96
|
# The SBOM shipped in the binary and served at /sbom.json, generated from the installed tree by npm
|
|
105
97
|
# (SPDX 2.3). Runtime dependencies only: dev tooling never reaches an instance. It used to come
|
|
106
98
|
# from GitHub's dependency graph (gh sbom), which only knows a lockfile once it has been pushed, so
|