Stop implicit argv logging#194
Merged
Merged
Conversation
7 tasks
codeforester
marked this pull request as ready for review
July 25, 2026 23:03
10 tasks
codeforester
added a commit
that referenced
this pull request
Jul 25, 2026
## Summary - make persistent-sink eligibility reflect the configured filesystem path - keep `log_is_enabled` non-mutating while rejecting missing-parent, non-regular, symlink, non-owned, and unwritable targets - create new primary logs privately and normalize new or existing files to mode `0600` before appending - suppress best-effort setup and redirection failures, then disable a failed path for the remainder of the process - apply the same sink contract to structured and file-content logging ## Issue Closes #192 ## Validation - `bats lib/bash/std/tests/lib_std.bats` — 159 tests passed locally, with one environment-specific process-listing skip - `./tests/validate.sh` — 321 tests passed - `shellcheck --severity=warning lib/bash/std/lib_std.sh` - `git diff --check` ## Notes - This PR is stacked on #194; its base branch is `security/191-20260725-safe-argv-logging`. - Successful terminal behavior and rendered log records are unchanged. - `log_is_enabled` does not create or chmod a path; the final setup and append remain best-effort across filesystem races and I/O failures. - Parent-directory creation, ACL removal, rotation, and new public sink APIs are out of scope. - #193 will add an actual Bash 4.2 logging smoke test over the completed path. - `VERSION` remains unchanged; this work is targeted to the `v1.4.0` milestone. ## Checklist - [x] Branch name follows `<category>/<issue>-<YYYYMMDD>-<slug>`. - [x] Pull request is scoped to one issue, unless a documented multi-issue exception applies. - [x] Pull request body explains what changed and how it was validated. - [x] Relevant project checks pass. - [x] Documentation is updated when behavior or user-facing commands change. - [x] CHANGELOG is updated for notable user-visible or release-worthy changes. - [x] Pull request includes `Fixes #<issue>` or `Closes #<issue>` when merge should close the issue.
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
logging invocation details
safe diagnostic, not option, positional, or URL-embedded secret values
Issue
Closes #191
Validation
bats lib/bash/std/tests/lib_std.bats— 153 tests passed locally, with oneenvironment-specific process-listing skip
./tests/validate.sh— 315 tests passedgit diff --checkNotes
unchanged.
__SCRIPT_ARGS__,--debug-wrapper, and deprecated--verbose-wrappercompatibility are unchanged.
will add an actual Bash 4.2 logging smoke test.
VERSIONremains unchanged; this work is targeted to thev1.4.0milestone.
Checklist
<category>/<issue>-<YYYYMMDD>-<slug>.Fixes #<issue>orCloses #<issue>when merge should close the issue.