Skip to content

fix: validate authservice callback uri + redirect uri#2349

Merged
chance-coleman merged 8 commits into
mainfrom
validate-authservice-callback-uri
Feb 10, 2026
Merged

fix: validate authservice callback uri + redirect uri#2349
chance-coleman merged 8 commits into
mainfrom
validate-authservice-callback-uri

Conversation

@chance-coleman
Copy link
Copy Markdown
Contributor

Description

We cannot allow for root path URI's otherwise authservice will break. This PR add validation that doesn't allow authservice enabled apps to also have root path uri's defined in the redirect uri array field.

Related Issue

Fixes #2333

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Other (security config, docs update, etc)

Steps to Validate

  • If this PR introduces new functionality to UDS Core or addresses a bug, please document the steps to test the changes.

Checklist before merging

@chance-coleman chance-coleman self-assigned this Feb 6, 2026
@chance-coleman chance-coleman requested a review from a team as a code owner February 6, 2026 22:48
Comment thread docs/reference/configuration/single-sign-on/auth-service.md
Comment thread src/pepr/operator/crd/validators/package-validator.ts
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds admission-time validation to prevent Authservice-enabled SSO clients from configuring redirectUris that would produce an invalid Authservice callback_uri, avoiding Authservice crashes from misconfiguration.

Changes:

  • Add Package CR validation to deny Authservice-enabled clients that use root-path redirect URIs (/ or /*).
  • Add validator unit tests covering allowed/denied redirect URI cases for Authservice clients.
  • Document the new redirect URI validation behavior in the Authservice docs.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
src/pepr/operator/crd/validators/package-validator.ts Adds redirect URI validation logic for Authservice-enabled SSO clients.
src/pepr/operator/crd/validators/package-validator.spec.ts Adds test cases for the new Authservice redirect URI validation behavior.
docs/reference/configuration/single-sign-on/auth-service.md Documents the redirect URI validation rules and examples.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/pepr/operator/crd/validators/package-validator.ts Outdated
Comment thread src/pepr/operator/crd/validators/package-validator.ts Outdated
Comment thread src/pepr/operator/crd/validators/package-validator.spec.ts
joelmccoy
joelmccoy previously approved these changes Feb 9, 2026
Copy link
Copy Markdown
Contributor

@joelmccoy joelmccoy left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Generally lgtm with 1 nit suggestion

Comment thread src/pepr/operator/crd/validators/package-validator.ts Outdated
…ting, and refactor use of .some to a for loop
Comment thread src/pepr/operator/crd/validators/package-validator.ts Outdated
Copy link
Copy Markdown
Contributor

@mjnagel mjnagel left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Comment thread src/pepr/operator/crd/validators/package-validator.ts
@chance-coleman chance-coleman merged commit 0ae9121 into main Feb 10, 2026
37 checks passed
@chance-coleman chance-coleman deleted the validate-authservice-callback-uri branch February 10, 2026 15:43
chance-coleman added a commit that referenced this pull request Feb 10, 2026
🤖 I have created a release *beep* *boop*
---


##
[0.61.0](v0.60.0...v0.61.0)
(2026-02-10)


### Features

* add blackbox exporter to uds-core as optional component
([#2314](#2314))
([2f08ee5](2f08ee5))
* automount uds trust bundle to all applications
([#2337](#2337))
([ce66203](ce66203))
* cluster-less crd pipeline
([#2316](#2316))
([5128ffb](5128ffb))
* improve Keycloak availability
([#2334](#2334))
([a306465](a306465))


### Bug Fixes

* cleanup zarf --no-progress deprecation
([#2352](#2352))
([78d3b15](78d3b15))
* ensure ambient mode is the default in all operator code
([#2326](#2326))
([bda5384](bda5384))
* multiarch script output
([#2338](#2338))
([457d9b3](457d9b3))
* validate authservice callback uri + redirect uri
([#2349](#2349))
([0ae9121](0ae9121))


### Miscellaneous

* bump eks/aks k8s to 1.34
([#2339](#2339))
([4145337](4145337))
* crd versioning adr
([#2308](#2308))
([f1e5a86](f1e5a86))
* **deps:** bump @isaacs/brace-expansion from 5.0.0 to 5.0.1
([#2336](#2336))
([5db96c7](5db96c7))
* **deps:** bump lodash from 4.17.21 to 4.17.23
([#2319](#2319))
([ad29405](ad29405))
* **deps:** update grafana
([#2257](#2257))
([74ad882](74ad882))
* **deps:** update keycloak to v26.5.2
([#2297](#2297))
([e393a3d](e393a3d))
* **deps:** update loki
([#2265](#2265))
([e12859b](e12859b))
* **deps:** update metrics-server to v0.8.1
([#2324](#2324))
([a48c45a](a48c45a))
* **deps:** update pepr to v1.0.8
([#2320](#2320))
([b4b1b48](b4b1b48))
* **deps:** update vector
([#2315](#2315))
([872f083](872f083))
* remove deprecated devDep for root-ca script
([#2342](#2342))
([616fbdb](616fbdb))
* update uds package icon to new doug logo
([#2353](#2353))
([77150aa](77150aa))


### Documentation

* add clarity on label placement for reload
([#2330](#2330))
([1a2515f](1a2515f))
* fix broken link and adjust markdown annotation
([#2331](#2331))
([5d542a3](5d542a3))

---
This PR was generated with [Release
Please](https://github.com/googleapis/release-please). See
[documentation](https://github.com/googleapis/release-please#release-please).

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
Co-authored-by: Chance Coleman <139784371+chance-coleman@users.noreply.github.com>
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.

Pepr does not reject redirectUris for the root / URL path, but this crashes Authservice

4 participants