Skip to content

Logs: a test fails when typed content reaches a log line #1846

Done

Description

@vmillet-dev

Context — D18 and CLAUDE.md forbid note content, passphrases and keys in a log. Today the rule is held by tests on two paths (AppError::for_log, the panic hook). The logs of this milestone (#1843, #1844, #1845) log every action and every call, and the ring puts them in the file: a payload printed by mistake would leave on the disk.

Change — One test walks a session through each area with sentinel content everywhere a person types, at the most talkative level, and fails if a sentinel is found in anything logged.

To do

  1. In crates/app (it sees the logger, and ui as a dev-dependency gives it egui_kittest): a session on the real core, a temporary library, every target at trace, the terminal and the file captured.
  2. Sentinels in the passphrase, a space's and a folder's name, a snippet's title, body and {{field}} value, a Note, a checklist item, a Calcul line, a tag, an attachment's file name, a request's URL, header, body and variable, an environment value, a script's console.log, a tool's input.
  3. The session does what a person does with them: create, edit, search, tag, move, delete and undo, send a request (local server), run a tool, lock and unlock, switch library, then a warning and a panic of the process run apart (the ring is written).
  4. A sentinel found fails with the line that held it. Fix what it finds in this pull request.
  5. Name the test in the wiki's logs page as the rule's guard, and in devnotes-security-review's checklist.
  6. One pull request into dev/1.3.3, last of the milestone.

Tests

  • The test is green, and red on a line deliberately logging an action with {:?} (shown once in the pull request, not kept).

Generated by Claude Code

Activity

  1. added
    test
    on Dec 3, 2026
  2. vmillet-dev commented on Dec 6, 2026

    @vmillet-dev
    OwnerAuthor

    Fixed by #1918, merged into dev/1.3.3.


    Generated by Claude Code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    test

    Type

    No type

    Projects

    No projects

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions