T09 · Insecure Skill Coding Practices
- Location
references/graph-schema.md:143- Finding
Fail-Open API Authentication Exposes Journal-Derived Metadata and Rebuild Operations
- Content
View full analysis
- Remediation
View remediation
Security audit
Security checks for vulnerabilities and agentic risk
The skill is mostly a coherent local brain-map visualizer, but its provided API examples can expose journal-derived private data and rebuild actions if deployed as documented.
Review and harden the API route examples before installing on anything reachable beyond localhost. Use one server-only secret name consistently, fail closed when auth is missing, do not place access keys in NEXT_PUBLIC variables, restrict rebuilds to trusted users, and review the generated graph JSON because it can contain sensitive journal summaries and file-path metadata.
references/graph-schema.md:143Fail-Open API Authentication Exposes Journal-Derived Metadata and Rebuild Operations
Referenced artifact was not completely inspected
Copy `references/journal-parser.md` into a Node.js script at `scripts/build-brain-map-projects.js` in your Mission Control or host app. Adjust `WORKSPACE_DIR` a
Referenced artifact was not completely inspected
Copy `references/journal-parser.md` into a Node.js script at `scripts/build-brain-map-projects.js` in your Mission Control or host app. Adjust `WORKSPACE_DIR` a
Code accesses credential files (SSH keys, AWS credentials, etc.). This could indicate credential theft attempts.
keywords: [
'github', 'git push', 'git commit', 'pull request', 'pr #', 'merge',
'feature branch', 'main branch', 'hno-skills', 'ghost-theme',
'pr open', 'pr merged', 'pat', 'personal access token',
],
},
{
The documentation at L176-L179 says a single click opens a node's file in project view, which directly conflicts with the earlier behavior description at L104-L116 that first click reorbits and second click opens. This is an active contradiction in the skill's own intent documentation about a user-visible interaction model.
The installation instructions tell users to run npx serve without pinning a specific version. That causes execution of whatever package version the registry resolves at runtime, creating a supply-chain risk if a malicious or compromised release is published or if behavior changes unexpectedly. In this skill's context, the command is presented as a routine way to host the app, which increases the chance users will execute it directly.
L321 states promotion is a local configuration write within the parser's existing output scope, while L140-L145 and L305 describe promotion and category customization as affecting named Attention Pocket configuration or PROJECT_DEFS. Those are different write targets: output JSON scope versus parser/config definition scope.
The file description says the component has a left panel showing attention projects ranked by recency-weighted density and a right panel graph for the selected project. However, the implemented BrainMapGraph only fetches one graph dataset and renders an SVG visualization with stats, legend, focus label, and tooltips; there is no project list UI or project-selection behavior matching that description.
The document does not prominently warn that the script ingests journal contents and persists derived summaries and file-access metadata into an output JSON file. Because journals may contain sensitive operational details, users may run it without understanding the privacy and data-handling implications, increasing risk of unintended local exposure or downstream publication.
Skill enumerates or reads other installed skills. Access to other skills' SKILL.md files or the skills directory reveals prompt instructions, capabilities, and secrets that should be invisible to peer skills.
**Pass 2 — transcript regex fallback**
The script performs filesystem checks, reads journal files, and later writes output at module top level before the exported API is intended to be used. If another component imports this module expecting a pure library, it can trigger unexpected local data processing, process termination via process.exit(1), and file writes as an import side effect.
This markdown file includes a quoted agent prompt that begins with broad imperative language: 'Read my session history from [source] and generate a journal entry for each session...'. Because the prompt is presented as a reusable invocation without scope limits or negative examples, it could overlap with general summarization requests and trigger use of this skill in contexts beyond the intended journal-bootstrap workflow.
This markdown file documents that a brain-map:open-file event is emitted so the host page can read and display a file, but it does not include a user-facing warning that interacting with the graph may trigger local file access. For markdown files, SQP-2 applies when descriptions omit warnings about behaviors that could affect user data or privacy.
The note says the component is 'fully self-contained — no external state, no context dependencies,' but the same file documents and the code demonstrates dependencies on /api/brain-map/graph and a host listener for brain-map:open-file. Those external runtime dependencies mean the component is not actually self-contained in the ordinary sense.
The manifest frames the skill as visualizing attention movement, which suggests presentation-oriented behavior. This file actually performs data extraction from memory/journal/*.md, project classification, graph construction, and writes a JSON artifact to disk, which is a broader analytics/build step than visualization itself.
No suspicious patterns detected.