[v17] fix: Prevent an App from setting a public address that conflicts with a Teleport Proxy public address 👮#58767
Merged
cthach merged 2 commits intobranch/v17from Sep 5, 2025
Conversation
… a Teleport Proxy public address 👮🏾 (#58475) * fix: apps should not be able to set public_addr to the web proxy address Signed-off-by: Chris Thach <chris.thach@goteleport.com> * feat: add API validation Signed-off-by: Chris Thach <chris.thach@goteleport.com> * test: add coverage for UpsertApplicationServer Signed-off-by: Chris Thach <chris.thach@goteleport.com> * refactor: polish Signed-off-by: Chris Thach <chris.thach@goteleport.com> * refactor: make consistent Signed-off-by: Chris Thach <chris.thach@goteleport.com> * refactor: use ValidateApp func everywhere. Revert changes to Check* method. Signed-off-by: Chris Thach <chris.thach@goteleport.com> * refactor: dedupe Signed-off-by: Chris Thach <chris.thach@goteleport.com> * refactor: improve error messages for application address conflicts and add validation check in connections handler Signed-off-by: Chris Thach <chris.thach@goteleport.com> * ux: bubble up friendly error to UI Signed-off-by: Chris Thach <chris.thach@goteleport.com> * refactor: revert unnecessary change * fix: app public address in redirect Signed-off-by: Chris Thach <chris.thach@goteleport.com> * fix: streamline proxy address validation in ValidateApp function Signed-off-by: Chris Thach <chris.thach@goteleport.com> * refactor: remove contact cluster admin in favor of self-service. Add logging. Signed-off-by: Chris Thach <chris.thach@goteleport.com> * Apply suggestions from code review Co-authored-by: rosstimothy <39066650+rosstimothy@users.noreply.github.com> * fix: skip proxy servers with unset public addresses in ValidateApp function Signed-off-by: Chris Thach <chris.thach@goteleport.com> * refactor: simplify error messages for application public address conflicts with proxy Signed-off-by: Chris Thach <chris.thach@goteleport.com> * fix: logging in the wrong spot Signed-off-by: Chris Thach <chris.thach@goteleport.com> * fix: handle when a server has multiple public addrs Signed-off-by: Chris Thach <chris.thach@goteleport.com> --------- Signed-off-by: Chris Thach <chris.thach@goteleport.com> Co-authored-by: rosstimothy <39066650+rosstimothy@users.noreply.github.com> Signed-off-by: Chris Thach <chris.thach@goteleport.com>
Contributor
|
Amplify deployment status
|
rosstimothy
approved these changes
Sep 5, 2025
avatus
approved these changes
Sep 5, 2025
Merged
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Backport #58475 to branch/v17
Fixes https://github.com/gravitational/teleport-private/issues/2104
changelog: Prevented an application from being registered if its public address matches a Teleport cluster address.