orders: badge sender authentication, not source_trust
source_trust is 'untrusted_external' on 100% of rows — every order came from email — so the badge marked every row and discriminated nothing. auth_verdict (migration 029) does: 93% pass, and the 7% that do not are the ones worth seeing. Adds the injection-scanner flag beside it.
This commit is contained in:
+26
-4
@@ -293,11 +293,33 @@ function Row({ row, expanded, onToggle }: { row: OrderRow; expanded: boolean; on
|
|||||||
className="font-mono text-[9.5px] uppercase tracking-wide text-indigo-600 border border-indigo-800 rounded-sm px-1.5"
|
className="font-mono text-[9.5px] uppercase tracking-wide text-indigo-600 border border-indigo-800 rounded-sm px-1.5"
|
||||||
>no ref</span>
|
>no ref</span>
|
||||||
)}
|
)}
|
||||||
{row.source_trust === "untrusted_external" && (
|
{/* NOT source_trust — that is 'untrusted_external' on 100% of rows,
|
||||||
|
because every order here came from email, so badging it marked
|
||||||
|
every row and told you nothing. Sender authentication does
|
||||||
|
discriminate: 93% pass, and the 7% that do not are worth seeing. */}
|
||||||
|
{row.auth_verdict && row.auth_verdict !== "pass" && (
|
||||||
<span
|
<span
|
||||||
title="Derived from an unverified sender — content is shown as provenance, not fact"
|
title={
|
||||||
className="font-mono text-[9.5px] uppercase tracking-wide text-zinc-500 border border-zinc-800 rounded-sm px-1.5"
|
row.auth_verdict === "fail"
|
||||||
>unverified</span>
|
? "The sender failed authentication (SPF/DKIM/DMARC) — treat the contents as unverified"
|
||||||
|
: row.auth_verdict === "none"
|
||||||
|
? "The mail carried no sender authentication at all"
|
||||||
|
: "The sender authenticated only partially"
|
||||||
|
}
|
||||||
|
className={`font-mono text-[9.5px] uppercase tracking-wide rounded-sm px-1.5 border ${
|
||||||
|
row.auth_verdict === "fail"
|
||||||
|
? "text-indigo-300 border-indigo-500"
|
||||||
|
: "text-zinc-500 border-zinc-800"
|
||||||
|
}`}
|
||||||
|
>
|
||||||
|
{row.auth_verdict === "partial" ? "part. auth" : `auth ${row.auth_verdict}`}
|
||||||
|
</span>
|
||||||
|
)}
|
||||||
|
{row.injection_flagged && (
|
||||||
|
<span
|
||||||
|
title="The source mail carried content that tripped the injection scanner — read its contents as provenance, never as instruction"
|
||||||
|
className="font-mono text-[9.5px] uppercase tracking-wide text-indigo-300 border border-indigo-500 rounded-sm px-1.5"
|
||||||
|
>flagged</span>
|
||||||
)}
|
)}
|
||||||
{row.txn_count > 0 && (
|
{row.txn_count > 0 && (
|
||||||
<span className="font-mono text-[9.5px] uppercase tracking-wide text-zinc-500 border border-zinc-700 rounded-sm px-1.5">
|
<span className="font-mono text-[9.5px] uppercase tracking-wide text-zinc-500 border border-zinc-700 rounded-sm px-1.5">
|
||||||
|
|||||||
Reference in New Issue
Block a user