Skip to content

[Sync] Update project files from source repository (e42f680) - #191

Merged
mrz1836 merged 1 commit into
masterfrom
chore/sync-files-go-whatsonchain-20260815-031030-e42f680
Aug 15, 2026
Merged

[Sync] Update project files from source repository (e42f680)#191
mrz1836 merged 1 commit into
masterfrom
chore/sync-files-go-whatsonchain-20260815-031030-e42f680

Conversation

@mrz1836

@mrz1836 mrz1836 commented Aug 15, 2026

Copy link
Copy Markdown
Owner

What Changed

  • Added new esc_html() bash function in .github/actions/validate-test-results/action.yml that escapes HTML metacharacters (&, <, >) in addition to stripping backticks and control characters
  • Updated TEST_LABEL, TEST, PKG, and FAIL_TYPE variables to use esc_html() instead of strip_bt() for values written into raw HTML portions of GitHub step summary
  • Retained strip_bt() for ERROR_MSG, OUTPUT, and STACK variables that are embedded in markdown code spans/fences where HTML is not interpreted
  • Modified version references in .github/env/10-security.env, .github/env/10-mage-x.env, .github/env/00-core.env, and .github/workflows/fortress.yml

Why It Was Necessary

  • Prevents crafted artifact-derived values (e.g., malicious subtest names) from breaking out of HTML tags and spoofing the rendered structure in GitHub step summaries
  • Addresses a security vulnerability where unescaped HTML metacharacters in test names or package names could close tags early and manipulate the CI output display
  • Applies defense-in-depth by using appropriate escaping based on context: HTML entity encoding for raw HTML sections, backtick stripping for markdown code blocks

Testing Performed

  • Validated that the new esc_html() function correctly escapes &, <, and > characters while preserving the existing strip_bt() behavior for backticks and control characters
  • Verified that test labels, test names, package names, and failure types are properly sanitized when rendered in GitHub step summaries
  • Confirmed that error messages, output, and stack traces remain correctly formatted within markdown code spans without double-encoding

Impact / Risk

  • Security Impact: Mitigates HTML injection risk in CI output rendering for artifact-derived content
  • Breaking Change: None - this is purely a security hardening measure that affects output formatting only
  • Risk: Low - changes are isolated to display formatting and do not affect test execution or result interpretation

@mrz1836 mrz1836 self-assigned this Aug 15, 2026
@mrz1836 mrz1836 added automated-sync Automated sync PR, e.g. from a fork or external repo automerge Label to automatically merge pull requests that meet all required conditions chore Simple dependency updates or version bumps labels Aug 15, 2026
@github-actions github-actions Bot added update General updates size/S Small change (11-50 lines) labels Aug 15, 2026
@mrz1836

mrz1836 commented Aug 15, 2026

Copy link
Copy Markdown
Owner Author

LGTM!

@mrz1836
mrz1836 merged commit eb10a74 into master Aug 15, 2026
23 checks passed
@github-actions
github-actions Bot deleted the chore/sync-files-go-whatsonchain-20260815-031030-e42f680 branch August 15, 2026 04:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

automated-sync Automated sync PR, e.g. from a fork or external repo automerge Label to automatically merge pull requests that meet all required conditions chore Simple dependency updates or version bumps size/S Small change (11-50 lines) update General updates

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant