emailengine-app 2.88.0 → 2.90.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 +36 -45
- package/.release-please-manifest.json +1 -1
- package/CHANGELOG.md +58 -0
- package/Dockerfile +5 -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.js +158 -453
- package/lib/api-routes/account-routes.js +42 -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 +83 -234
- package/lib/consts.js +1 -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/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/license-subscription.js +77 -11
- package/lib/load-env.js +48 -0
- package/lib/logger.js +1 -4
- package/lib/mcp/tools.js +244 -207
- package/lib/metric-values.js +76 -0
- package/lib/metrics.js +320 -0
- package/lib/node-version.js +99 -12
- package/lib/oauth/gmail.js +39 -120
- package/lib/oauth/http-request.js +195 -0
- package/lib/oauth/mail-ru.js +24 -58
- 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 +1 -1
- 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/settings.js +4 -1
- package/lib/sso-routes.js +249 -0
- package/lib/sso.js +29 -6
- package/lib/tools.js +5 -4
- 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 +12 -318
- package/lib/ui-routes/auth-routes.js +10 -10
- package/lib/ui-routes/dashboard-routes.js +4 -0
- package/lib/ui-view-context.js +328 -0
- package/lib/utils/public-suffix.js +22 -101
- package/lib/web-safe-html.js +70 -13
- package/lib/worker-metrics.js +82 -0
- package/list-generate.js +57 -23
- package/package.json +34 -33
- package/sbom.json +380 -1612
- package/scripts/refresh-test-tokens.js +1 -1
- package/server.js +351 -707
- package/static/css/flyonui.css +1 -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 +1055 -969
- package/translations/messages.pot +71 -60
- package/views/accounts/browse.hbs +19 -1
- package/views/dashboard.hbs +9 -0
- package/views/upgrade.hbs +25 -0
- package/workers/api.js +20 -451
- package/data/public_suffix_list.dat +0 -16597
- package/lib/net-tos-guard.js +0 -42
package/lib/net-tos-guard.js
DELETED
|
@@ -1,42 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
// Keeps a failed type-of-service marking from ending the process.
|
|
4
|
-
//
|
|
5
|
-
// undici 7 (held there by the Node 20 floor, see .ncurc.js) calls socket.setTypeOfService() for
|
|
6
|
-
// every request on a Node that has it (24.x), unguarded, as it writes the request (client-h1.js). On macOS
|
|
7
|
-
// the underlying setsockopt() answers EINVAL once the peer has reset the connection, so a peer that
|
|
8
|
-
// went away right after accepting (a server shutting down or restarting) threw an uncaughtException
|
|
9
|
-
// in whichever thread made the request. undici 8 wraps the call itself; marking is best effort
|
|
10
|
-
// there too. EmailEngine never sets a type of service, so nothing is lost by ignoring the failure.
|
|
11
|
-
// Remove this together with the undici 8 upgrade.
|
|
12
|
-
|
|
13
|
-
const net = require('net');
|
|
14
|
-
|
|
15
|
-
/**
|
|
16
|
-
* Wraps setTypeOfService() of a socket prototype so a failure of the call itself is ignored
|
|
17
|
-
* @param {Object} proto - net.Socket.prototype, or a stand-in in tests
|
|
18
|
-
* @returns {boolean} Whether the prototype was wrapped (false without the method, or done before)
|
|
19
|
-
*/
|
|
20
|
-
function guardTypeOfService(proto) {
|
|
21
|
-
const original = proto.setTypeOfService;
|
|
22
|
-
if (typeof original !== 'function' || original.tosGuarded) {
|
|
23
|
-
return false;
|
|
24
|
-
}
|
|
25
|
-
const guarded = function setTypeOfService(...args) {
|
|
26
|
-
try {
|
|
27
|
-
return original.apply(this, args);
|
|
28
|
-
} catch (err) {
|
|
29
|
-
if (err && err.syscall === 'setTypeOfService') {
|
|
30
|
-
return this;
|
|
31
|
-
}
|
|
32
|
-
throw err;
|
|
33
|
-
}
|
|
34
|
-
};
|
|
35
|
-
guarded.tosGuarded = true;
|
|
36
|
-
proto.setTypeOfService = guarded;
|
|
37
|
-
return true;
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
guardTypeOfService(net.Socket.prototype);
|
|
41
|
-
|
|
42
|
-
module.exports = { guardTypeOfService };
|