@bobfrankston/rmfmail 1.2.290 → 1.2.291

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 CHANGED
@@ -1,39 +1,31 @@
1
- Spam banner: an unknown rule must be able to condemn on its own
1
+ An approved sender, proved, says nothing at all
2
2
 
3
- Bob 2026-08-28: "we have a problem since, of course, things like conference
4
- announcements use bulk mailers." An IEEE/ICECER call for papers, DMARC-proved,
5
- BAYES_00, scored exactly 4.5 of 4.5DCC_CHECK 3.0 + KAM_MARKETINGBL 1.0 +
6
- **1.5 GB_AWSTRACK_REDIR, Amazon SES's click-tracker** and the one rule this
7
- file had never heard of pushed a proved announcement into "Check this message
8
- before acting on it / Links and attachments here should not be opened".
3
+ Bob 2026-08-28, having just clicked "Always: *@icecer.com" on a conference call
4
+ for papers that still showed a bulk-mail note: "I accepted the server so
5
+ shouldn't this be considered safe?" Yesand this is the half of C165 that was
6
+ still open. `allowlist.jsonc` has been the approved-sender store all along, and
7
+ nothing consulted it when computing trust.
9
8
 
10
- The "unknown means caution" policy was right; testing it by PRESENCE was not.
11
- An unknown rule now keeps a proved sender at caution only when it could have
12
- flagged the message BY ITSELF its own scores summed against the server's own
13
- threshold. That adds no constant to tune: "enough to condemn" already has a
14
- number and it is the one the server used. KAM_BENEFICIARY, the case the policy
15
- exists for, is worth 10.0 alone and still cautions; a 1.5 click-tracker cannot.
16
- Unscored rules (no X-Spam-Report) leave the sum unknown, and unknown stays
17
- cautious.
9
+ `assessMessageTrust` and `spamScoreOf` now take `senderTrusted`, and store.ts
10
+ fills it from the sender and domain lists the reader maintains. When the sender
11
+ is approved AND proved AND nothing accuses it of forgery, the server-spam
12
+ finding is not rendered at all and the score chip goes with it: the score
13
+ answers "is this bulk", the reader has already answered "is it wanted", and
14
+ repeating the first after the second is how a banner becomes furniture.
18
15
 
19
- Two classification fixes found by sampling what still cautioned a PROVED
20
- sender across the store:
16
+ Three boundaries, deliberate:
21
17
 
22
- - Branded ESP click-trackers (GB_AWSTRACK*, SendGrid, Mailchimp) are bulk-mail
23
- machinery. Open redirectors (URI_PHP_REDIR and friends) stay unclassified
24
- a tracking domain the sending platform owns is not an abused redirect.
25
- - KAM_*URIBL_* ("Body contains URI listed in PCCC WILD RBL", 9.0) and
26
- SH_HBL_EMAILS ("Email address listed in email blocklist", 8.0) are the same
27
- evidence as URIBL_SBL somebody else's list about a host the message
28
- mentions and were the bulk of the remaining noise: a Business Insider
29
- newsletter, an MIT cancer-center invitation, a campaign mailing.
30
- KAM_INFOUSMEBIZ judges the TLD a domain lives in, which is guilt by
31
- neighbourhood.
18
+ - **Trust never silences forgery evidence.** SPF_FAIL, a DMARC failure, a
19
+ FORGED_* rule, self-spoof, relay-auth mismatch all still render, at full
20
+ severity, on a trusted sender.
21
+ - **Trust counts only where the sender is PROVED** (DMARC, DKIM_VALID_AU, or
22
+ ALL_TRUSTED). Otherwise the approved-sender list would be a switch a forger
23
+ flips by typing a trusted address into From. A trusted address that cannot be
24
+ proved now gets a SHARPER warning than an untrusted one: "This claims to be a
25
+ sender you trust, but nothing proves it is."
26
+ - **senderTrusted is narrower than allowRemote.** The recipient-alias list says
27
+ mail reached an address of the reader's, which permits images; it is not a
28
+ statement about who sent it, and the trust banner asks about the sender.
32
29
 
33
- Over the same 20,308 messages, of 1,131 flagged: 294 danger (unchanged — proof
34
- never overrides forgery), 278 caution, 559 quiet. What still cautions a proved
35
- sender is now almost entirely content-scam rules: ADVANCE_FEE, DEAR_BENEFICIARY,
36
- KAM_CRIM, UNDISC_MONEY, BITCOIN_DIRECT. The two false positives left in that
37
- set — a Substack news digest about displacement tripping KAM_CRIM, a Qatar
38
- Airways statement tripping BITCOIN_DIRECT — are exactly what sender trust is
39
- for, and are deliberately NOT being fixed by inventing more rule exceptions.
30
+ The measurement is unchanged spamScoreOf still reports the score, kind and
31
+ reasons, with `trusted: true` alongside. Only the display goes.
@@ -2350,6 +2350,9 @@ function serverSpamVerdict(input) {
2350
2350
  const a = analyzeServerSpam(input);
2351
2351
  if (!a || !a.flagged)
2352
2352
  return null;
2353
+ const trustedAndProved = input.senderTrusted && a.proved;
2354
+ if (trustedAndProved && a.kind !== "forgery" && !a.authFailures.length)
2355
+ return null;
2353
2356
  const numbers = Number.isFinite(a.score) && Number.isFinite(a.threshold) ? `SpamAssassin score ${a.score} of ${a.threshold}` : "flagged by SpamAssassin";
2354
2357
  const why = a.reasons.length ? ` \u2014 ${a.reasons.join("; ")}` : "";
2355
2358
  const bayes = a.bayesHam ? "; your own trained filter puts it at 0-1% spam (BAYES_00)" : "";
@@ -2375,6 +2378,13 @@ function serverSpamVerdict(input) {
2375
2378
  detail: `${numbers}${why}${bayes}`
2376
2379
  };
2377
2380
  const proof = a.proved ? `${provedNote(a)} ` : "";
2381
+ if (input.senderTrusted && !a.proved)
2382
+ return {
2383
+ id: "server-spam-verdict",
2384
+ severity: "caution",
2385
+ text: "This claims to be a sender you trust, but nothing proves it is.",
2386
+ detail: `No DMARC pass, no valid signature from the sending domain, and it passed through hosts your server does not trust. ${numbers}${why}`
2387
+ };
2378
2388
  return {
2379
2389
  id: "server-spam-verdict",
2380
2390
  severity: "caution",
@@ -2534,6 +2544,7 @@ function spamScoreOf(input) {
2534
2544
  kind: a.kind,
2535
2545
  proved: a.proved,
2536
2546
  provedBy: a.provedBy,
2547
+ trusted: !!input.senderTrusted && a.proved && a.kind !== "forgery" && !a.authFailures.length,
2537
2548
  reasons: a.reasons
2538
2549
  };
2539
2550
  }