CVE-2026-18382: Project-koku/koku-metrics-operator: koku-metrics-operator: service-account client credentials sent to user-controlled token_url

Published Jul 30, 2026
·
Updated

Summary

The koku-metrics-operator CostManagementMetricsConfig CRD exposes spec.authentication.tokenurl as a writable field with no host validation. When spec.authentication.type == service-account, the operator POSTs clientid and clientsecret (read from a user-referenced Secret) as form data to this user-supplied URL. The default is the Red Hat SSO endpoint, but a CR editor can override it to any URL.

Impact

A principal with create/update permission on costmanagementmetricsconfigs can redirect the tenant's Red Hat SSO clientid/clientsecret pair to an attacker endpoint. These credentials grant api.console scope on console.redhat.com for the customer organization.

Affected Code

- api/v1beta1/metricsconfigtypes.go:117 — tokenurl field definition (no validation) - internal/controller/costmanagementmetricsconfigcontroller.go:450 — GetAccessToken(ctx, cr.Spec.Authentication.TokenURL) call - internal/crhchttp/config.go:75-93 — POST to user-supplied tokenURL

Remediation

Hard-code the Red Hat SSO token endpoint or enforce a suffix allow-list (.redhat.com) in GetAccessToken. Reject non-HTTPS schemes:

go if !strings.HasSuffix(tokenURL, ".redhat.com") { return "", fmt.Errorf("tokenurl must be a .redhat.com endpoint") }

Other sources

A flaw was found in koku-metrics-operator. The operator's CostManagementMetricsConfig custom resource allows a user able to edit the CR to specify an arbitrary OAuth token endpoint. When authentication.type is set to service-account, the operator sends the tenant's Red Hat SSO clientid and clientsecret to this user-controlled URL, allowing the attacker to obtain the credentials.

MITRE

Affected Software

2 affected components
Project-koku/koku-metrics-operator
redhat Cost Management Metrics Operator Openshift

Remediation

Recommended actions to resolve this vulnerability, in priority order.

  1. Configuration

    In CostManagementMetricsConfig handling (GetAccessToken / POST to token_url), enforce that spec.authentication.token_url is a *.redhat.com endpoint (e.g., require HasSuffix(tokenURL, ".redhat.com")) and reject non-HTTPS schemes, so user-controlled token_url cannot redirect the tenant Red Hat SSO client_id/client_secret to an attacker endpoint.

    koku-metrics-operator (CostManagementMetricsConfig CRD) spec.authentication.token_url = Enforce allow-list for token_url suffix (*.redhat.com) and reject non-HTTPS schemes

Event History

Jul 30, 2026
Data Sourced
via Red Hat·11:46 AM
DescriptionSeverityAffected Software
CVE Published
via MITRE·12:00 PM
Data Sourced
via MITRE·12:00 PM
DescriptionSeverityWeakness
Data Sourced
via NVD·12:17 PM
DescriptionSeverityWeaknessAffected Software
Free Weekly Intel

Don't miss critical vulnerabilities

Join thousands of security professionals who receive our weekly digest of trending CVEs, zero-days, and exploited vulnerabilities.

No spam. Unsubscribe anytime.

Frequently Asked Questions

1

What is the severity of CVE-2026-18382?

The severity of CVE-2026-18382 is medium with a score of 6.8.

2

How do I fix CVE-2026-18382?

To fix CVE-2026-18382, ensure that the token_url in the CostManagementMetricsConfig CRD is properly validated and restrict access to trusted hosts only.

3

What type of vulnerability is CVE-2026-18382?

CVE-2026-18382 is classified as a Server-Side Request Forgery (SSRF) vulnerability.

4

What can be exposed due to CVE-2026-18382?

CVE-2026-18382 can expose sensitive client credentials, such as client_id and client_secret, to unauthorized users.

5

What software is affected by CVE-2026-18382?

CVE-2026-18382 affects the Project-koku/koku-metrics-operator software.

Contact

SecAlerts Pty Ltd.
132 Wickham Terrace
Fortitude Valley,
QLD 4006, Australia
info@secalerts.co
By using SecAlerts services, you agree to our services end-user license agreement. This website is safeguarded by reCAPTCHA and governed by the Google Privacy Policy and Terms of Service. All names, logos, and brands of products are owned by their respective owners, and any usage of these names, logos, and brands for identification purposes only does not imply endorsement. If you possess any content that requires removal, please get in touch with us.
© 2026 SecAlerts Pty Ltd.
ABN: 70 645 966 203, ACN: 645 966 203