Skip to content

docs: design, threat model, rules and CI - #2

Merged
groupsky merged 2 commits into
mainfrom
hq-job/pullgate-1-build/r-20261111-183015-607a
Nov 11, 2026
Merged

groupsky merged 2 commits into
mainfrom
hq-job/pullgate-1-build/r-20261111-183015-607a

Conversation

@groupsky

@groupsky groupsky commented Nov 11, 2026 •

Copy link
Copy Markdown
Contributor

The bones of pullgate (#1): the rules for work on the repo, the design, the threat model, and CI.

Progress

  • AGENTS.md and CLAUDE.md (fail closed, deny-path tests, security review, small dependencies, Conventional Commits, squash merges, no identifiers)
  • .claude/agents/security-reviewer.md, adapted to pullgate
  • DESIGN.md: rules 1-6, one run, the spool, approvals, the apply with on_failure, PULLGATE_OLD_TREE, modes, limits
  • THREAT-MODEL.md: every threat in the "Done when" list of v0.1: pull a repo, ask the owner on Telegram, apply one exact commit #1
  • go.mod (github.com/code6x/pullgate)
  • CI: gofmt, vet, test (race), static build, golangci-lint, govulncheck
  • security review and correctness review, findings fixed in the second commit

Review findings and what changed

  • Outbox symlink attack on root: spool dirs root-owned, root writes with os.OpenRoot and O_EXCL|O_NOFOLLOW.
  • Half-written or changed trees: export to a temp name, fresh trees per process.
  • A token thief edits text above real buttons: the listener counts a tap only on an unedited message with the text it sent.
  • Gate files, command programs and local repo URLs get the same owner and mode checks as the clone.
  • in_progress has a rollback phase; rollback environment defined (PULLGATE_ROLLBACK, PULLGATE_FAILED_SHA).
  • check_user processes are killed after each command.
  • Symlinks out of the tree are shown as warnings; refuse_symlinks option.
  • apply honours the pause file and off; expired questions are closed; auto mode goes through the apply unit.
  • Not changed: renaming on_failure = "pause" to hold. The owner chose pause in v0.1: pull a repo, ask the owner on Telegram, apply one exact commit #1.

🤖 Generated with Claude Code

groupsky and others added 2 commits November 11, 2026 18:36
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@groupsky
groupsky marked this pull request as ready for review November 11, 2026 16:43
@groupsky
groupsky merged commit 2bc846d into main Nov 11, 2026
4 checks passed
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