Skip to content

feat(api): enforce durable request budgets and refusal stops #15 - #18

Merged
yashiels merged 2 commits into
mainfrom
agent/request-policy
Oct 14, 2026
Merged

yashiels merged 2 commits into
mainfrom
agent/request-policy

Conversation

@yashiels

@yashiels yashiels commented Oct 14, 2026 •

Copy link
Copy Markdown
Owner

Summary

  • Route authenticated API traffic through durable, host-user-wide request admissions: minimum 5-second spacing, at most 100 admissions per rolling 24 hours, and one in-flight exchange.
  • Preserve spacing independently of quota-history pruning, including configured delays longer than 24 hours and fresh-process restarts.
  • Persist cooldowns and manual-review refusal stops before response-body decoding; do not automatically retry application requests.
  • Add local safety status/resume commands and allowlisted diagnostics that preserve safe numeric HTTP status without exposing raw response/error content.
  • Fail closed on unsafe state, ownership, modes and native ACLs. Native Linux access/default ACL tests include unchanged denied state and a successful control after removing only the injected fixture ACL.

Depends on merged #17. Documentation/release follow separately under #16.

Verification

  • Reviewed head: 054b6ef4590a94672a8f471ef0f67394a9c290fa.
  • Both signed commits verified; the published parent was preserved and the review fix added without force-push. Squash merge yields one landed M2 commit.
  • Independent macOS make ci, make lint, scratch build and offline CLI smoke passed using isolated fixture state and no account credentials.
  • Actual unchanged Linux workflow executed with act: vet, race tests and gofmt all passed. All 10 packages were present, including the command package; both native ACL cases passed.
  • Pinned tracked-source export verified before and after execution: all 86 paths, Git blob identities and executable modes matched the reviewed tree.
  • Separate state and API/CLI reviews signed off; subsequent deltas, including the final production fixes, also signed off on this exact head.
  • Late inline findings fixed and regression-tested: ordinary profile failures stop immediately, only the deprecated REST endpoint can fall back on HTTP 410, and valid auth redirects with literal-percent suffixes persist the manual-review stop across fresh clients/policies.
  • No live LinkedIn/employer traffic, saved credential replacement or real refusal reset performed.

Limits

  • This budget counts application admissions, not exact physical packets. Restricted standard-transport connection recovery and trusted custom-transport internals remain outside exact wire-attempt accounting.
  • These thresholds are operational safeguards, not LinkedIn-approved limits or protection against account restrictions.
  • Host-local state does not coordinate other hosts, older binaries or unrelated applications.
  • The full-source archive CI invocation disables act Git-ignore filtering so an ignored binary basename cannot omit the tracked command source directory. No workflow checks were weakened.

Closes #15

@sentinel-skyner sentinel-skyner Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛡️ Sentinel review

Two policy gaps allow unintended follow-up admissions.

2 inline comments below.

Automated review via cursorbridge:gpt-5.6-sol. Findings only — not an approval. Push new commits to re-review.

Comment thread internal/cmd/profile.go Outdated
Comment thread internal/api/request.go
Comment thread internal/cmd/profile.go Outdated
Comment thread internal/api/request.go
@yashiels
yashiels merged commit 3460d84 into main Oct 14, 2026
1 check passed
@yashiels
yashiels deleted the agent/request-policy branch October 14, 2026 22:18

@sentinel-skyner sentinel-skyner Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🛡️ Sentinel review

No material issues found in the reviewed diff.

Automated review via cursorbridge:gpt-5.6-sol. Findings only — not an approval. Push new commits to re-review.

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.

Add durable pacing, budgets and refusal controls

1 participant