Bug 1964334

Summary: alertmanager/prometheus/thanos-querier /metrics endpoints are not secured
Product: OpenShift Container Platform Reporter: Junqi Zhao <juzhao>
Component: MonitoringAssignee: Arunprasad Rajkumar <arajkuma>
Status: CLOSED ERRATA QA Contact: Junqi Zhao <juzhao>
Severity: low Docs Contact:
Priority: low    
Version: 4.8CC: alegrand, anpicker, aos-bugs, dbaker, erooth, hongyli, kakkoyun, pkrupa
Target Milestone: ---   
Target Release: 4.8.0   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: No Doc Update
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2021-07-27 23:10:08 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
The /metrics endpoint is accessible to anyone without any authentication none

Description Junqi Zhao 2021-05-25 08:54:05 UTC
Created attachment 1786772 [details]
The /metrics endpoint is accessible to anyone without any authentication

Description of problem:
this bug is from bug 1960767, only grafana metrics endpoint is secured now, but alertmanager/prometheus/thanos-querier are not secured
see the attached picture


Version-Release number of selected component (if applicable):
4.8.0-0.nightly-2021-05-25-041803

How reproducible:
always 

Steps to Reproduce:
1. login in grafana/alertmanager/prometheus/thanos-querier routes metrics endpoint one by one
# oc get route -n openshift-monitoring
Append the route UI URL with /metrics
2.
3.

Actual results:
The /metrics endpoint is accessible to anyone without any authentication.

Expected results:
The /metrics endpoint should not be accessible without authentication.

Additional info:

Comment 1 Simon Pasquier 2021-05-25 15:42:22 UTC
*** Bug 1897630 has been marked as a duplicate of this bug. ***

Comment 3 hongyan li 2021-05-31 03:26:00 UTC
same issue exists for thanos-ruler when enabled user-workload monitoring

Comment 4 Arunprasad Rajkumar 2021-05-31 06:25:50 UTC
@hongyli Thanks, I've updated the PR to include thanos-ruler as well.

Comment 6 Junqi Zhao 2021-06-02 01:37:10 UTC
checked with 4.8.0-0.nightly-2021-06-01-190440,alertmanager/prometheus/thanos-querier/thanos-ruler metrics endpoints are secured now

Comment 9 errata-xmlrpc 2021-07-27 23:10:08 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory (Moderate: OpenShift Container Platform 4.8.2 bug fix and security update), and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://access.redhat.com/errata/RHSA-2021:2438