Skip to content

Commit

Permalink
Fix backwards domain check. (#998)
Browse files Browse the repository at this point in the history
  • Loading branch information
joel-rieke committed Mar 8, 2024
1 parent 398c8eb commit 0a7690d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/capauth/agentconfig.go
Original file line number Diff line number Diff line change
Expand Up @@ -49,8 +49,8 @@ func ValidateVhost(host string, protocol string) error {
}

func ValidateVhostDomain(host string) error {
for _, endpoint := range coreopts.BuildOptions.GetSupportedDomains(prod.IsProd()) {
if strings.HasSuffix(endpoint, host) {
for _, domain := range coreopts.BuildOptions.GetSupportedDomains(prod.IsProd()) {
if strings.HasSuffix(host, domain) {
return nil
}
}
Expand Down

0 comments on commit 0a7690d

Please sign in to comment.