Skip to content

Bump vulnerable dependencies and add security scanning - #8

Merged
dandydarshan merged 2 commits into
mainfrom
security/deps-and-scanning
Nov 6, 2026
Merged

dandydarshan merged 2 commits into
mainfrom
security/deps-and-scanning

Conversation

@dandydarshan

@dandydarshan dandydarshan commented Nov 6, 2026 •

Copy link
Copy Markdown
Owner

Summary

Clears every known CVE from the pinned dependencies, closes an eval on LLM output, and adds security scanning so new issues show up in CI.

 cluster_modules: parse <GROUPED_COMPONENTS> reply
-  module_tree = eval(response_content)          # prompt-injected repo => code execution
+  module_tree = ast.literal_eval(response_content.strip())
 .github/
+├── dependabot.yml          # pip + actions, weekly, 7-day cooldown, mcp<2 kept
 └── workflows/
+    ├── security.yml        # pip-audit, ruff S (Bandit), zizmor; PR/push/weekly
     ├── ci.yml              # actions on Node 24 majors, pinned to SHAs,
     │                       #   persist-credentials: false
     └── build-wheels.yml    # same
 requirements.txt           # re-resolved: 23 vulnerable pkgs bumped, ~30 unused
                            #   leftovers dropped (Jupyter stack -> tornado CVEs)

Notable bumps: pydantic-ai 1.0.6 → 1.107.10 (kept <2), litellm 1.77 → 1.103, starlette 0.47 → 1.10, mcp → 1.30 (kept <2). mermaid-py stays commented out.

Actions move to their first Node 24 majors (Node 20 is EOL): checkout v5, setup-python v6, upload-artifact v6, download-artifact v7. Covers what upstream FSoft-AI4Code#89 does for ci.yml, plus the artifact actions in build-wheels.yml.

Evidence

  • Before: pip-audit -r requirements.txt → 272 advisories across 23 packages; zizmor → 19 high, 7 medium; runners warned "Node.js 20 is deprecated".
    After: pip-audit → No known vulnerabilities found; zizmor (medium+) → clean; ruff --select S → clean; no Node 20 warnings.
  • Tests on a clean 3.12 install from requirements.txt: 453 passed, 3 skipped; pip check clean.
  • Wheels (run 42193145810): Linux manylinux, Windows 3.12–3.14, macOS universal2 3.12–3.14 and macOS x86_64 tests all green.
  • Mock codewiki generate (real CLI against a scripted OpenAI-compatible server): clustering parsed a Python-literal <GROUPED_COMPONENTS> via literal_eval → 2 modules, agents wrote api.md/core.md via tool calls, overview written, exit 0.

Merge Danger

Door: two-way

Revert the commit to restore the old pins and workflows.

Blast Radius: runtime

Big jumps in pydantic-ai, litellm and starlette are only covered by mocked LLM tests; run one real-model generate before release. Dependabot will start opening PRs once merged. To make the Security job block merges, add "Security scan" as a required check.

🤖 Generated with Claude Code

Darshan M U and others added 2 commits November 6, 2026 14:41
- requirements.txt: re-resolved so pip-audit reports no known CVEs
  (23 packages were affected); unused Jupyter/openai-agents leftovers
  that pulled in tornado are dropped.
- cluster_modules: parse the LLM's module tree with ast.literal_eval
  instead of eval, so a prompt-injected reply cannot run code.
- New Security workflow (pip-audit, ruff Bandit rules, zizmor) on PRs,
  pushes to main and weekly; Dependabot for pip and Actions with a
  7-day cooldown.
- Workflows: actions pinned to commit hashes, checkouts drop persisted
  credentials. sha1 cache keys marked usedforsecurity=False.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Node 20 is end of life and runners were already forcing these actions
onto Node 24 with a deprecation warning. Each action moves to its first
Node 24 major, still pinned by commit hash: checkout v5, setup-python
v6, upload-artifact v6, download-artifact v7. Artifacts are downloaded
by name/pattern, which these majors leave unchanged.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@dandydarshan
dandydarshan merged commit f3718c7 into main Nov 6, 2026
14 checks passed
@dandydarshan
dandydarshan deleted the security/deps-and-scanning branch November 6, 2026 10:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant