@bobfrankston/rmfmail 1.2.309 → 1.2.312
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/.commitmsg +39 -11
- package/.llm/trusted-lists.md +46 -0
- package/TODO.md +2 -2
- package/client/android-bootstrap.bundle.js +80 -15
- package/client/android-bootstrap.bundle.js.map +2 -2
- package/client/app.bundle.js +57 -2
- package/client/app.bundle.js.map +2 -2
- package/client/components/message-viewer.js +82 -1
- package/client/components/message-viewer.js.map +1 -1
- package/client/components/message-viewer.ts +79 -2
- package/client/compose/compose.bundle.js +1 -1
- package/client/compose/compose.bundle.js.map +2 -2
- package/client/lib/api-client.js +1 -1
- package/client/lib/api-client.js.map +1 -1
- package/client/lib/api-client.ts +3 -3
- package/docs/allowlist.md +25 -2
- package/docs/spam-false-positives.md +23 -0
- package/npmchanges.md +30 -0
- package/package.json +5 -5
- package/packages/mailx-imap/package-lock.json +2 -2
- package/packages/mailx-imap/package.json +1 -1
- package/packages/mailx-service/index.d.ts +3 -1
- package/packages/mailx-service/index.d.ts.map +1 -1
- package/packages/mailx-service/index.js +4 -2
- package/packages/mailx-service/index.js.map +1 -1
- package/packages/mailx-service/index.ts +6 -4
- package/packages/mailx-service/package.json +1 -1
- package/packages/mailx-settings/docs/allowlist.md +25 -2
- package/packages/mailx-settings/docs/spam-false-positives.md +23 -0
- package/packages/mailx-settings/index.d.ts +1 -0
- package/packages/mailx-settings/index.d.ts.map +1 -1
- package/packages/mailx-settings/index.js +7 -0
- package/packages/mailx-settings/index.js.map +1 -1
- package/packages/mailx-settings/index.ts +7 -0
- package/packages/mailx-settings/package.json +1 -1
- package/packages/mailx-store/package.json +1 -1
- package/packages/mailx-store/store.d.ts.map +1 -1
- package/packages/mailx-store/store.js +3 -0
- package/packages/mailx-store/store.js.map +1 -1
- package/packages/mailx-store/store.ts +3 -0
- package/packages/mailx-store-web/package.json +1 -1
- package/packages/mailx-store-web/web-service.d.ts +3 -2
- package/packages/mailx-store-web/web-service.d.ts.map +1 -1
- package/packages/mailx-store-web/web-service.js +4 -2
- package/packages/mailx-store-web/web-service.js.map +1 -1
- package/packages/mailx-store-web/web-service.ts +6 -4
- package/packages/mailx-store-web/web-settings.d.ts +1 -0
- package/packages/mailx-store-web/web-settings.d.ts.map +1 -1
- package/packages/mailx-store-web/web-settings.js +2 -0
- package/packages/mailx-store-web/web-settings.js.map +1 -1
- package/packages/mailx-store-web/web-settings.ts +2 -0
- package/packages/mailx-types/index.d.ts +2 -2
- package/packages/mailx-types/index.d.ts.map +1 -1
- package/packages/mailx-types/index.js +1 -1
- package/packages/mailx-types/index.js.map +1 -1
- package/packages/mailx-types/index.ts +2 -2
- package/packages/mailx-types/package.json +1 -1
- package/packages/mailx-types/trust.d.ts +35 -0
- package/packages/mailx-types/trust.d.ts.map +1 -1
- package/packages/mailx-types/trust.js +129 -8
- package/packages/mailx-types/trust.js.map +1 -1
- package/packages/mailx-types/trust.ts +152 -8
package/client/app.bundle.js
CHANGED
|
@@ -356,7 +356,7 @@ function trustSenderOrDomain(type, value) {
|
|
|
356
356
|
return ipc().trustSenderOrDomain?.(type, value) ?? Promise.resolve({ trusted: false });
|
|
357
357
|
}
|
|
358
358
|
function getAllowlist() {
|
|
359
|
-
return ipc().getAllowlist?.() ?? Promise.resolve({ senders: [], domains: [], recipients: [], flaggedSenders: [], flaggedDomains: [], trustedSenders: [], trustedDomains: [], trustedIntermediaries: [] });
|
|
359
|
+
return ipc().getAllowlist?.() ?? Promise.resolve({ senders: [], domains: [], recipients: [], flaggedSenders: [], flaggedDomains: [], trustedSenders: [], trustedDomains: [], trustedIntermediaries: [], trustedLists: [] });
|
|
360
360
|
}
|
|
361
361
|
function flagSenderOrDomain(type, value) {
|
|
362
362
|
return ipc().flagSenderOrDomain?.(type, value) ?? Promise.resolve({ flagged: false });
|
|
@@ -2930,6 +2930,34 @@ async function showMessage(accountId, uid, folderId, specialUse, isRetry = false
|
|
|
2930
2930
|
items.push({ label: "", action: () => {
|
|
2931
2931
|
}, separator: true });
|
|
2932
2932
|
}
|
|
2933
|
+
const listSpam = msg.spamScore;
|
|
2934
|
+
if (listSpam?.listProved && listSpam.listId && !listSpam.listTrusted) {
|
|
2935
|
+
const listId = listSpam.listId;
|
|
2936
|
+
items.push({
|
|
2937
|
+
label: `\u2713 Trust the ${listId} mailing list`,
|
|
2938
|
+
action: async () => {
|
|
2939
|
+
const st = document.getElementById("status-sync");
|
|
2940
|
+
try {
|
|
2941
|
+
const res = await trustSenderOrDomain("list", listId);
|
|
2942
|
+
if (!res?.trusted)
|
|
2943
|
+
throw new Error("the list did not save");
|
|
2944
|
+
listSpam.listTrusted = true;
|
|
2945
|
+
document.querySelector(".mv-spamscore")?.remove();
|
|
2946
|
+
document.querySelector(".mv-trust")?.remove();
|
|
2947
|
+
if (st)
|
|
2948
|
+
st.textContent = `Trusting the ${listId} mailing list`;
|
|
2949
|
+
} catch (e2) {
|
|
2950
|
+
if (st) {
|
|
2951
|
+
st.textContent = `Couldn't trust the ${listId} list \u2014 ${e2?.message || e2}`;
|
|
2952
|
+
st.style.color = "oklch(0.65 0.2 25)";
|
|
2953
|
+
}
|
|
2954
|
+
console.error("[allowlist] trust list failed:", e2);
|
|
2955
|
+
}
|
|
2956
|
+
}
|
|
2957
|
+
});
|
|
2958
|
+
items.push({ label: "", action: () => {
|
|
2959
|
+
}, separator: true });
|
|
2960
|
+
}
|
|
2933
2961
|
}
|
|
2934
2962
|
if (omitted > 0) {
|
|
2935
2963
|
items.push({
|
|
@@ -3159,7 +3187,9 @@ async function showMessage(accountId, uid, folderId, specialUse, isRetry = false
|
|
|
3159
3187
|
chip.className = `mv-spamscore mv-spamscore-${level}`;
|
|
3160
3188
|
const why = (spam.reasons || []).length ? "\n\n" + spam.reasons.join("\n") : "";
|
|
3161
3189
|
const provedNote = spam.provedBy === "dkim" ? "the sending domain signed it and the signature verified" : spam.provedBy === "trusted" ? "it never passed through an untrusted host" : "the sending domain passed DMARC";
|
|
3162
|
-
chip.title = (level === "bulk" ? spam.proved ? spam.bulkOnly ? `Scored by bulk-mail or blocklist rules; ${provedNote}, so the sender is proved.` : `${provedNote[0].toUpperCase()}${provedNote.slice(1)}, so the sender is proved. Not every rule that scored is a bulk-mail test \u2014 they are listed below.` : spam.bulkOnly ? "Every rule that scored is a bulk-mail test \u2014 none of them test who sent this." : "No forgery rule scored. The rules that did are listed below." : level === "high" ? "Your mail server scored this at or above its spam threshold and flagged it." : "Below your server's spam threshold, but more than halfway to it.") + why
|
|
3190
|
+
chip.title = (level === "bulk" ? spam.proved ? spam.bulkOnly ? `Scored by bulk-mail or blocklist rules; ${provedNote}, so the sender is proved.` : `${provedNote[0].toUpperCase()}${provedNote.slice(1)}, so the sender is proved. Not every rule that scored is a bulk-mail test \u2014 they are listed below.` : spam.bulkOnly ? "Every rule that scored is a bulk-mail test \u2014 none of them test who sent this." : "No forgery rule scored. The rules that did are listed below." : level === "high" ? "Your mail server scored this at or above its spam threshold and flagged it." : "Below your server's spam threshold, but more than halfway to it.") + why + (spam.listProved && spam.listId && !spam.listTrusted ? `
|
|
3191
|
+
|
|
3192
|
+
Delivered by the ${spam.listId} mailing list, which your server proved sent it. Right-click the From address to trust the list.` : "");
|
|
3163
3193
|
chip.textContent = `spam score ${spam.score} of ${spam.threshold}`;
|
|
3164
3194
|
bodyEl.appendChild(chip);
|
|
3165
3195
|
}
|
|
@@ -3202,6 +3232,31 @@ async function showMessage(accountId, uid, folderId, specialUse, isRetry = false
|
|
|
3202
3232
|
}
|
|
3203
3233
|
warn.appendChild(actions);
|
|
3204
3234
|
}
|
|
3235
|
+
const lists = worst === "danger" ? [] : Array.from(new Set(trust.map((f) => f.list).filter(Boolean)));
|
|
3236
|
+
if (lists.length) {
|
|
3237
|
+
const actions = document.createElement("div");
|
|
3238
|
+
actions.className = "mv-trust-actions";
|
|
3239
|
+
for (const listId of lists) {
|
|
3240
|
+
const b = document.createElement("button");
|
|
3241
|
+
b.className = "mv-trust-action";
|
|
3242
|
+
b.textContent = `Trust the ${listId} list`;
|
|
3243
|
+
b.addEventListener("click", async () => {
|
|
3244
|
+
b.disabled = true;
|
|
3245
|
+
try {
|
|
3246
|
+
const res = await trustSenderOrDomain("list", listId);
|
|
3247
|
+
if (!res?.trusted)
|
|
3248
|
+
throw new Error("the list did not save");
|
|
3249
|
+
warn.remove();
|
|
3250
|
+
document.querySelector(".mv-spamscore")?.remove();
|
|
3251
|
+
} catch (e) {
|
|
3252
|
+
b.disabled = false;
|
|
3253
|
+
b.textContent = `Could not save: ${e?.message || e}`;
|
|
3254
|
+
}
|
|
3255
|
+
});
|
|
3256
|
+
actions.appendChild(b);
|
|
3257
|
+
}
|
|
3258
|
+
warn.appendChild(actions);
|
|
3259
|
+
}
|
|
3205
3260
|
const vias = worst === "danger" ? [] : Array.from(new Set(trust.map((f) => f.via).filter(Boolean)));
|
|
3206
3261
|
if (vias.length) {
|
|
3207
3262
|
const actions = document.createElement("div");
|