mirror of
https://github.com/morluto/rea.git
synced 2026-11-15 11:13:21 +00:00
feat(electron): report custom URL protocol registrations
Expose static Electron protocol call facts through the shared application graph and existing CLI/MCP Evidence views. Preserve canonical case-insensitive scheme identity, original spellings, exact source provenance and explicit unknowns; keep registration success and runtime routing unproven. Integration fixes also enforce module-only privileged API ownership, reuse the shared finding-key owner, and align the owning type documentation with the Evidence semantics. Validation and bounded real Obsidian CLI/MCP measurements are recorded in the PR. Co-authored-by: UnknownHacker1 <35694178+UnknownHacker1@users.noreply.github.com> Co-authored-by: gensokyo-dev <342580529+gensokyo-dev@users.noreply.github.com>
This commit is contained in:
1 parent
69bf61f7c7
commit
47fa6ab379
24 files changed
+1134
-11
No files matched your search
@@ -251,6 +251,11 @@ const semanticKey = (node: ApplicationNode): string | null => {
|
||||
return value === null ? null : `semantic\0${node.kind}\0${value}`;
|
||||
};
|
||||
|
||||
/** Kinds keyed by one literal name, unless that name is a dynamic expression. */
|
||||
const LITERAL_NAME_PROPERTIES: Partial<
|
||||
Record<ApplicationNode["kind"], string>
|
||||
> = { "ipc-channel": "channel", "url-scheme": "scheme" };
|
||||
|
||||
const semanticValue = (
|
||||
node: ApplicationNode,
|
||||
properties: Readonly<Record<string, JsonValue>>,
|
||||
@@ -262,10 +267,13 @@ const semanticValue = (
|
||||
properties.storage_kind,
|
||||
properties.name ?? properties.mechanism,
|
||||
);
|
||||
if (node.kind === "ipc-channel")
|
||||
return properties.resolution === "dynamic"
|
||||
const literalKey = LITERAL_NAME_PROPERTIES[node.kind];
|
||||
if (literalKey !== undefined)
|
||||
return ["dynamic", "invalid-literal"].includes(
|
||||
String(properties.resolution),
|
||||
)
|
||||
? null
|
||||
: (exactString(properties.channel) ?? firstLabel(node));
|
||||
: (exactString(properties[literalKey]) ?? firstLabel(node));
|
||||
if (node.kind === "context-bridge-api")
|
||||
return (
|
||||
firstLabel(node) ??
|
||||
|
||||
Reference in new issue
Block a user