Skip to content

fix(ns-api): write /tmp/TZ without a shell - #1865

Merged
gsanchietti merged 1 commit into
mainfrom
fix_tz
Aug 6, 2026
Merged

fix(ns-api): write /tmp/TZ without a shell#1865
gsanchietti merged 1 commit into
mainfrom
fix_tz

Conversation

@gsanchietti

Copy link
Copy Markdown
Member

The timezone post-commit hook passed the UCI timezone value through "sh -c echo '' > /tmp/TZ", so a value containing a single quote broke out of the quoting and the rest was executed as a command. Write the file directly with Python instead: no shell is involved, and the resulting content is unchanged.

Assisted-by: Claude Code:claude-opus-5[1m]

The timezone post-commit hook passed the UCI timezone value through
"sh -c echo '<value>' > /tmp/TZ", so a value containing a single quote
broke out of the quoting and the rest was executed as a command. Write
the file directly with Python instead: no shell is involved, and the
resulting content is unchanged.

Assisted-by: Claude Code:claude-opus-5[1m]
@gsanchietti
gsanchietti requested a review from m-dilorenzi August 6, 2026 07:31
@m-dilorenzi

Copy link
Copy Markdown
Collaborator

LGTM

image image

@gsanchietti
gsanchietti merged commit 4d8b6f5 into main Aug 6, 2026
3 checks passed
@gsanchietti
gsanchietti deleted the fix_tz branch August 6, 2026 09:52
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.

2 participants