dotCMS / dotCMS/core

Enforce HTTPS-only in RequestCostPublisher (refuse, don't warn)

Open Beginner friendly
#36,928 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Team : Enablement
Dominant language
Java
Stars
970
Forks
486
Avg merge
3d 33m
Merged PRs (30d)
170

Description

Parent

Part of #36927.

Problem

RequestCostPublisher.java:124-139 only warns if REQUEST_COST_PUSH_URL isn't https:// — it doesn't refuse to send. TLS holds today only because config happens to be correct, not because the code enforces it. This matters more once the collector accepts traffic that could originate outside OVH's own network (see #36927).

Change

Reject (fail validation at startup / no-op the publisher, matching the existing "both push vars set ⇒ activate" pattern) if REQUEST_COST_PUSH_URL's scheme isn't https, instead of logging a warning and sending anyway.

No env var changes — production config is already https://, so this is a pure guardrail, not a behavior change for anyone configured correctly.

Design reference

ADR-0022 (dotCMS/platform-adrs#73) and docs/plan-request-cost-provider-attribution.md §3.1 in dotCMS/ovh-k8s-cluster.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at RequestCostPublisher.java:124-139 and inspect the existing “both push vars set ⇒ activate” validation path. Ensure a non-https REQUEST_COST_PUSH_URL refuses activation or sending, while an https URL remains unchanged; verify the startup validation or no-op behavior using the relevant existing tests if present.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
backend, security
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
72/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.