Repository navigation
deploy: bound journald log retention to three months - #111
Merged
Merged
Conversation
Everything the deployment logs lands in journald, whose default retention is size-based with no time cap, so logs could be kept indefinitely. Install a drop-in (MaxFileSec=1week + MaxRetentionSec=12week) from deploy.sh: files rotate at most weekly and are deleted 12 weeks after their newest entry, bounding the worst case at ~91 days. This backs the 'technical logs are retained for up to three months' statement in the upcoming ICP MCP privacy policy (drafted in #109); size-based vacuuming may still delete entries sooner, which that wording allows. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw
aterga
pushed a commit
that referenced
this pull request
Jul 31, 2026
Keeps this PR docs-only and shrinks the policy draft's ops note to a pointer at the PR that enforces the bound. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw
Merged
8 of 10 tasks
aterga
marked this pull request as ready for review
July 31, 2026 13:56
There was a problem hiding this comment.
🟢 Ready to approve
The configuration is valid, idempotent, and appropriately enforces the stated retention policy.
This review doesn't count toward merge requirements. Sign up for the private preview to control whether Copilot approvals count.
Pull request overview
Adds a journald retention policy to align deployment logs with the planned three-month privacy-policy limit.
Changes:
- Configures weekly journal rotation and 12-week retention.
- Restarts journald to apply the drop-in immediately.
File summaries
| File | Description |
|---|---|
deploy/native/deploy.sh |
Installs and activates the journald retention configuration. |
Review details
- Files reviewed: 1/1 changed files
- Comments generated: 0
- Review effort level: Balanced
We're testing this review assessment. Please use 👍 or 👎 to tell us if it's correct.
sea-snake
approved these changes
Jul 31, 2026
7 of 8 tasks
aterga
pushed a commit
that referenced
this pull request
Jul 31, 2026
…nd (#111) Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw
aterga
added a commit
that referenced
this pull request
Jul 31, 2026
…t, landing-page link (#109) * docs: add the Anthropic Connectors Directory submission package Everything needed to publish the production deployment to Anthropic's connectors directory: the verified submission process (portal, access prerequisites, governing policy/terms), a requirements-met table checked against the live server, the five pre-submission blockers (privacy-policy URL, the financial-transactions policy question, reviewer test identity, production lagging main, icon asset), and paste-ready drafts for every portal field including example prompts and reviewer test instructions. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * docs: align Hackenproof spelling with SECURITY.md; drop the Terms placeholder Copilot review on #109: SECURITY.md spells it Hackenproof, and "(Terms §)" read as an unresolved section reference. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * docs: the II privacy policy cannot cover the MCP server; spell out the needed policy The Internet Identity Privacy Policy (2026-04-07) scopes itself solely to Google-account linking and expressly disclaims all other processing, so it cannot serve as the connector's privacy-policy URL. Replace blocker 1's 'have legal check dfinity.org/privacy' with the concrete requirement: a dedicated ICP MCP policy, with the contents mapped from what the server actually processes (delegations, account labels, OAuth state, tool arguments, in-memory-only retention, host logs, public on-chain effects, DFINITY-only third parties). Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * docs: draft the ICP MCP privacy policy for legal review Modeled on the Internet Identity Privacy Policy (2026-04-07) structure, with the technical claims drawn from the server's actual behavior: in-memory-only session/OAuth state capped at the II grant (<=30 days), transient tool-call processing, the single security-purpose sid cookie, no analytics, DFINITY-operated infrastructure as the only recipients, and the public-permanent nature of on-chain effects. Bracketed placeholders mark the decisions legal/ops must supply (retention window, venue, contact, effective date). Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * docs: rework the privacy-policy draft per DFINITY review feedback - Use II consent-screen terminology ("Questions only" / "Actions & questions") instead of read-only-by-default, which was inaccurate: the access level is an explicit user choice, and the same correction propagates to the submission doc's description, blockers, and reviewer instructions. - Document revocation at id.ai/manage/access (effective within at most five minutes), repeated under User Rights for users who no longer remember which AI sessions are active. - Describe the Internet Computer as a public network running applications via a consensus protocol; no blockchain branding, no permanent-state claim: what applications record is governed by them. - Clarify the sid cookie is server-set and inaccessible to page scripts; leave room for aggregated, anonymized usage metrics; drop the II-principal mention (the server only ever sees its own-domain pseudonym); state per-application principals may be considered private when account tools request them. - Set log retention to three months and flag the ops prerequisite: journald's default retention is size-based, so the bound needs a MaxRetentionSec=90day drop-in installed by deploy.sh. - No em-dashes in the policy text. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * deploy: bound journald retention to the privacy policy's three months Everything the deployment logs lands in journald, whose default retention is size-based with no time cap, so nothing enforced the policy's 'retained for up to three months'. Install a drop-in (MaxFileSec=1week + MaxRetentionSec=12week) from deploy.sh: files rotate at most weekly and are deleted 12 weeks after their newest entry, bounding the worst case at ~91 days. The policy draft's ops note now points at the drop-in and the required rollout to both hosts. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * docs: factor the journald retention change out to #111 Keeps this PR docs-only and shrinks the policy draft's ops note to a pointer at the PR that enforces the bound. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * docs: correct the privacy drafts against the implementation (Copilot review) Every claim in the review verified against the code and stands: - The sign-in cookie is named mcp_connect (CONNECT_COOKIE, src/auth.rs), not sid. - OAuth client registrations are NOT in-memory: they persist to OAUTH_CLIENTS_FILE in the unit's StateDirectory, survive restarts, and expire only by LRU eviction (10,000 cap); stored fields are the generated client id, redirect URIs, and last-used timestamp, while client_name is echoed but never stored. - The request log records method/path/status/latency (never query strings or bodies) and auth events log session ids and the Service-scoped principal; client IPs and user agents are not systematically recorded (Caddy runs without access logs). The policy previously over-disclosed absent fields and omitted real ones. - Data sharing now names the user-directed recipients: applications receive the request arguments and per-app identity, and app discovery fetches user-supplied origins; DFINITY infrastructure is not the only recipient. - The submission doc no longer pre-fills dfinity.org/privacy (blocker 1 says it is insufficient; an incomplete policy is immediate rejection), no longer claims first-party APIs only, and flags the first-party-API acknowledgment as unresolved alongside financial transactions. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * docs: distinguish disconnect from revocation; fix annotation and skills claims Second Copilot round, each claim verified against the code: - Disconnecting the connector only stops the assistant using its token; the server has no revocation endpoint, so the authorization stands until it expires or is revoked at id.ai/manage/access. The policy's User Rights section now says exactly that instead of presenting the two as equivalent. - Four tools (icp_create_canister, icp_top_up_canister, icp_start_canister, icp_stop_canister) are annotated neither read-only nor destructive (additive/reversible writes), so the listing text no longer claims every tool is one or the other. - icp_get_skill returns full SKILL.md instructions fetched live from skills.internetcomputer.org, so the prompt-injection acknowledgment is now flagged for open disclosure instead of being called straightforwardly true. - The directory-safe profile option now says a ledger blocklist cannot satisfy the financial-transfer prohibition (intermediary canisters and custom ledgers bypass it): the generic update tool has to go, or actions must be allow-listed. - Contact address settled as [email protected] (placeholder removed). Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * docs: pin the privacy-policy venue to mcp.internetcomputer.org/privacy-policy The venue decision is made: the MCP server will serve the policy itself. Record the URL in the portal field draft, the blocker, and the checklist; the only remaining placeholder is the effective date. Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * docs: the /privacy-policy page is implemented in #112 Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * docs: effective date decided (August 3, 2026); no open decisions remain Co-Authored-By: Claude Fable 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * Link the privacy policy from the landing page footer The landing page is a bundler shell whose document lives as a JS string literal in assets/index.html; adding a footer link is a surgical edit to that string (matching the sibling 'Hosted by DFINITY' anchor's styling, spaced by the flex row's existing gap) rather than a bundle regeneration. The route comment and the submission doc's blocker 1 no longer describe the link as outstanding. Verified by rendering the unpacked page in Chromium: the footer shows the link, clicking it lands on /privacy-policy (title 'ICP MCP Privacy Policy', effective date August 3, 2026). Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * Correct two inaccuracies in the privacy policy (Copilot review) Both verified against the code: - Sharing was described as 'two ways' while omitting the recipient intrinsic to the Service: results go back to the connected AI assistant, whose provider processes them under its own policy. Now stated first, since it is the point of the Service. - 'No data about you remains after a session ends' was inaccurate for the revocation path: map_delegation_error returns RECONNECT_MSG on Unauthorized without removing the Session, and prune_stale retains entries until the ORIGINAL grant_expiration_ns, so a revoked session's key stays in memory until the duration first chosen (up to 30 days) or a restart. The policy now says so, and notes the record cannot be used to act once the authorization is gone. Revocation timing is now attributed to Internet Identity rather than implied to be the Service's own guarantee. Applied to both the served page and its source text. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * Attribute revocation timing to Internet Identity in the intro too The summary paragraph still stated the five-minute figure as the Service's own; section 4 already attributes it. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * Internet Identity and the API boundary nodes are DAO-governed, not DFINITY-operated The sharing section labelled the whole dependency list 'operated by DFINITY Foundation', which is wrong for the two that matter most: Internet Identity (id.ai) and the public API boundary nodes the server submits through (IC_URL = https://icp-api.io) are part of the Internet Computer and governed by the NNS DAO. Only dashboard.internetcomputer.org and skills.internetcomputer.org are DFINITY-operated. Misidentifying who receives data is a substantive error in a privacy policy, so this is corrected in the served page and its source text, and in the submission package's data-handling and first-party-API notes — where it also strengthens the case that 'first-party APIs only' cannot be acknowledged as a clean yes. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * Add the official ICP mark and its square icon exports The connectors-directory listing needs an icon. Commit the official ICP mark as SVG plus square transparent PNGs (1024 and 512) for the portal's icon field, and mark blocker 5 done. The mark is ~2.05:1, so the exports centre it at 84% of the canvas width on a square transparent field rather than cropping. Rendered with Chromium: the mark's linearGradients (one carrying a rotate transform) are mis-rendered by lighter rasterisers. Listing icon only — the served pages keep the DFINITY wordmark for their 'Hosted by' footer. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * Record that mcp-review has been asked (2026-07-31) Blocker 2 is now waiting on a reply rather than on someone sending the email. Reframe its options as 'once the answer arrives', and note that the first-party-API acknowledgment needs a follow-up if the reply does not cover it. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw * Reviewer access is self-serve; record what the mcp-review email asked Blocker 3: no shared test identity. Reviewers create their own Internet Identity and follow the setup instructions on the landing page, which is the right shape for a passkey-based, device-bound authenticator that nobody can pre-provision into. Reviewer instructions rewritten to match, with an offer to provision a canister-controlling, cycles-funded identity on request — that is the one thing a fresh identity cannot exercise, and the likeliest reason a reviewer pushes back on the 'fully populated account' criterion. Blocker 2: the 2026-07-31 email asked two questions (cycles funding and canister_update_call). Two gaps recorded: the first-party-API acknowledgment was not among them and needs its own follow-up, and the mitigation the email offers for canister_update_call — blocking the well-known ledger transfer/approve methods — is bypassable via custom ledgers and forwarding canisters, so it must not be shipped as-is if the reply takes it up. Co-Authored-By: Claude Opus 5 <[email protected]> Claude-Session: https://claude.ai/code/session_01TGhwpdTbUqQbR5AiiN8Ljw --------- Co-authored-by: Claude <[email protected]>
This was referenced Jul 31, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Everything the deployment logs (imcp2 tracing, Caddy, the status dashboard) lands in journald, whose default retention is size-based with no time cap — logs could be kept indefinitely. This installs a journald drop-in from
deploy/native/deploy.shso retention is bounded at three months, backing the "technical logs are retained for up to three months" statement in the ICP MCP privacy policy being drafted in #109.Why
MaxRetentionSec=12weekpaired withMaxFileSec=1weekinstead of a plain90day: journald deletes whole archived files, keyed on each file's newest entry, so a file's oldest entries overshoot the cap by up to one rotation period. With weekly rotation the worst case is 13 weeks (~91 days); with the default monthly rotation a90daycap could keep entries ~120 days. Size-based vacuuming may still delete entries sooner, which the policy's "up to" wording allows.The bound takes effect on each host at its next deploy (staging on the next
mainpush, production on the nextrelease-*tag). Both hosts need it live before the privacy policy is published.Related issues
Factored out of #109 to keep that PR docs-only.
Changes
deploy/native/deploy.sh: install/etc/systemd/journald.conf.d/90-imcp2-retention.conf(MaxFileSec=1week,MaxRetentionSec=12week) and restartsystemd-journald, inside the existing remote sudo block. Idempotent, owned by the deploy (a drop-in, not an edit tojournald.conf).Testing
bash -n deploy/native/deploy.sh(the drop-in heredoc contains no shell expansions, so local expansion of the outer unquoted heredoc is unaffected)cargo build --locked --all-targets— n/a, no Rust changescargo test --locked --all-targets— n/a, no Rust changescargo fmt --all/cargo clippy --all-targets— n/a, no Rust changesnpm test --prefix monitoring/mcp-status— n/a, dashboard unchangedChecklist
Generated by Claude Code