Skip to content

patch: Prevent template injection#346

Merged
carlcsaposs-canonical merged 3 commits intomainfrom
env-variables
Mar 31, 2026
Merged

patch: Prevent template injection#346
carlcsaposs-canonical merged 3 commits intomainfrom
env-variables

Conversation

@carlcsaposs-canonical
Copy link
Copy Markdown
Contributor

There is a negligible security benefit, since these inputs are trusted (we already use environment variables for untrusted input), but this can help prevent mistakes.

Furthermore, it is simpler to use environment variables in all cases than to distinguish between trusted and untrusted input. (However it is still important to identify untrusted input, handle it as such, and threat model it appropriately.)

@carlcsaposs-canonical
Copy link
Copy Markdown
Contributor Author

Merge after #345 and rebase (base branch is currently #345)

Copy link
Copy Markdown

@taurus-forever taurus-forever left a comment

Choose a reason for hiding this comment

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

Tnx!

Copy link
Copy Markdown
Contributor

@reneradoi reneradoi left a comment

Choose a reason for hiding this comment

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

Thank you Carl!

Base automatically changed from checkout-persist to main March 31, 2026 08:49
There is a negligible security benefit, since these inputs are trusted (we already use environment variables for untrusted input), but this can help prevent mistakes.

Furthermore, it is simpler to use environment variables in all cases than to distinguish between trusted and untrusted input. (However it is still important to identify untrusted input, handle it as such, and threat model it appropriately.)
To reduce ambiguity

(Prefix used to avoid accidental conflicts with other programs' environment variables)
@carlcsaposs-canonical carlcsaposs-canonical merged commit 96ac793 into main Mar 31, 2026
1 check passed
@carlcsaposs-canonical carlcsaposs-canonical deleted the env-variables branch March 31, 2026 08:51
carlcsaposs-canonical added a commit that referenced this pull request Mar 31, 2026
carlcsaposs-canonical added a commit that referenced this pull request Mar 31, 2026
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.

3 participants