Skip to content

docs(adr): propose rendering security and selective Symfony adoption - #8436

Open
somethingwithproof wants to merge 3 commits into
Cacti:developfrom
somethingwithproof:docs/rendering-security-components
Open

somethingwithproof wants to merge 3 commits into
Cacti:developfrom
somethingwithproof:docs/rendering-security-components

Conversation

@somethingwithproof

@somethingwithproof somethingwithproof commented Oct 20, 2026 •

Copy link
Copy Markdown
Member

This change proposes a common approach to safely rendering text, attributes, URLs, script data and formatted HTML in Cacti. The architecture document describes how existing helpers and selected Symfony components could support that work, with compatibility and testing requirements. It gives maintainers a reviewable implementation plan; it does not implement the migration or resolve security findings.

Summary

Cacti's renderers mix plain text, attributes, URLs, script data, and intentional HTML. Add proposed ADR 0003 with an implementation plan and an assessment of the Symfony components already available.

Reuse CactiValidator::validate() or isValid() for established option contracts where needed, keeping session-writing validation out of renderers. Continue using Cacti's context-specific output helpers. HttpFoundation has a limited role at dedicated JSON response boundaries; OptionsResolver is currently development-only. HTML Sanitizer, Twig, and Symfony Form require separate dependency decisions.

The plan starts with a caller inventory and hidden-field pilot, followed by shared text/attribute helpers and filter script data. Optional formatted-HTML and Twig pilots follow separately. It defines caller compatibility, maintenance-branch propagation, dependency requirements, and regression/rescan acceptance criteria.

Scope

Targets develop and updates the ADR index. This is a documentation proposal for maintainer review; it changes no runtime behavior or dependencies and claims no security finding resolved. Necessary 1.2.x fixes remain independent of framework migration. Finding-specific evidence stays in the private security-reporting process.

Validation

  • Reviewed the final diff against the current helper APIs, representative callers, Composer manifest/lock, existing test suites, and official Symfony/Twig guidance. A complete core/plugin caller audit remains an implementation prerequisite.
  • Clean locked Composer install under PHP 8.5.11 selected through mise.
  • Repository PHP CS Fixer: 437 files checked, zero changes.
  • Repository PHPStan: 465 files, no errors.
  • Markdown lint, eight relative documentation links, changelog validation, and git diff --check passed.
  • Runtime regression tests are deferred to implementation PRs; this PR changes Markdown only.

At head 65aaf8e, locked integration failed before checkout because ECR rejected the MariaDB image download with toomanyrequests: Data limit exceeded. Other checks were still running when inspected. This is an infrastructure failure, not a passing integration result: https://github.com/Cacti/cacti/actions/runs/39393378436/job/118530036126

No release-note fragment is added because this records a proposed approach rather than a shipped behavior change.

Revision and checks

Description scope: target develop, 2 changed files, head fd10e7b4a. Checked 2026-10-23 03:06:04 UTC.

GitHub check snapshot: 2 passed. Local test figures and earlier CI runs above are recorded evidence for their stated revisions and environments; they do not assert that every check passes at this head.

@somethingwithproof
somethingwithproof requested a review from a team as a code owner October 20, 2026 08:15
@somethingwithproof somethingwithproof added documentation Documentation issue type:security Namespaced Cacti workflow label area:ui Namespaced Cacti workflow label release:1.3 Namespaced Cacti workflow label labels Oct 20, 2026
@github-actions
github-actions Bot force-pushed the docs/rendering-security-components branch 3 times, most recently from e962503 to fd10e7b Compare October 22, 2026 20:46
@github-actions
github-actions Bot force-pushed the docs/rendering-security-components branch 2 times, most recently from 51404d1 to 95dfb7c Compare October 26, 2026 20:51
Signed-off-by: Thomas Vincent <thomasvincent@gmail.com>
Signed-off-by: Thomas Vincent <thomasvincent@gmail.com>
Signed-off-by: Thomas Vincent <thomasvincent@gmail.com>
@github-actions
github-actions Bot force-pushed the docs/rendering-security-components branch from 95dfb7c to 5f548f5 Compare October 28, 2026 20:46
@sonarqubecloud

Copy link
Copy Markdown

This branch has not been deployed

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

Labels

area:ui Namespaced Cacti workflow label documentation Documentation issue release:1.3 Namespaced Cacti workflow label type:security Namespaced Cacti workflow label

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant