Skip to content

fix(security): remediate community dependencies and request handlers - #7296

Merged
jmgasper merged 4 commits into
developfrom
fix/security-findings-2026-11
Nov 2, 2026
Merged

jmgasper merged 4 commits into
developfrom
fix/security-findings-2026-11

Conversation

@jmgasper

@jmgasper jmgasper commented Nov 2, 2026 •

Copy link
Copy Markdown
Collaborator

The ECS image and legacy dependency tree contain critical, high, and medium vulnerabilities. This moves Community App to Node 24 and patched dependencies, replaces the vulnerable build toolchain, and fixes the reported request-handling and browser injection issues.

  • Refresh application and smoke-test lockfiles; pin Topcoder Git dependencies; preserve legacy Auth0, M2M and minimatch interfaces through adapters backed by patched implementations.
  • Restrict avatar/recruiting destinations and redirects, bound image/XML/form inputs, add route rate limits and an origin CORS allowlist, encode search parameters, and remove password/stack logging.
  • Migrate to Webpack 5, Babel 7, PostCSS 8 and Dart Sass while retaining React 16, SSR, CSS module names and service-worker behavior. Handle rejected SSR and background currency-feed promises under Node 24.
  • Run the container as UID 10001 and remove build tools/package managers. Supply credentials at runtime from the existing SSM buildvar and appvar paths; deduplicate names with appvar taking precedence and exclude generated credential files from the image.
  • Update the optional JMeter suite to Java 21/JMeter 5.6.3 with explicit patched runtime libraries and only the protocols used by its HTTP plan. Keep a non-load validation helper.
  • Gate critical/high/medium vulnerabilities, secrets and misconfigurations in Trivy. Preserve license classifications as a separate downloadable inventory; Sharp's LGPL libvips classification is not a vulnerability finding.

Validation:

  • All 324 original critical/high/medium Dependabot alerts map to patched or removed packages. Main and smoke audits have zero findings at those severities (12 and 1 low respectively).
  • Clean container install, JS/SCSS lint, 527 unit tests and 153 snapshots pass; 16 existing tests remain skipped. All 15 security tests and the production build pass, including syntax checks for 69 browser bundles.
  • Final application image, repository scan (including Maven dependencies), and assembled JMeter runtime: zero critical/high/medium findings. GitHub CodeQL, Trivy, Actions analysis and commit lint pass at 764d796da.
  • Final isolated container runs as UID 10001, remains healthy with external networking disabled, and serves assets, the Auth0 callback and challenge SSR with 200. Missing/invalid JWTs return 401 and a valid fixture JWT returns 200. No CI-generated credential files are present. Earlier checks also cover expired/wrong-signature JWTs, origin restrictions, rate limits and recovery after CMS errors.
  • Chromium challenge SSR/hydration and Past Challenges navigation pass with local API fixtures: zero page errors or failed local assets. External Auth0, navigation and analytics are blocked in that check.
  • Two deployment-script tests pass; read-only IAM simulation confirms the execution role can read the existing buildvar parameters. JMeter configures successfully, parses the existing plan without running its samplers, and executes one HTTP request against a loopback fixture. No load tests ran against Topcoder.

Deployment configuration: register /community-app-assets/auth0-popup on each community origin as an Auth0 callback, use RS256 for social linking, and configure Allowed Web Origins. The JWT secret must be at least 32 bytes. Confirm proxy CIDRs, additional avatar/CORS origins, and SSM/KMS access for both runtime parameter paths as documented in the README. Authenticated linking and submission checks against the configured tenant remain staging validation. No merge or deployment has been performed.

Comment thread src/server/services/avatar.js Fixed
@jmgasper
jmgasper marked this pull request as ready for review November 2, 2026 06:48
@jmgasper
jmgasper requested a review from kkartunov as a code owner November 2, 2026 06:48
@jmgasper
jmgasper merged commit b531e63 into develop Nov 2, 2026
6 of 7 checks passed
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