Missing anchors in regular expression. (#11717)

Co-authored-by: André Storfjord Kristiansen <33384479+dev-bio@users.noreply.github.com>
This commit is contained in:
Jintao Zhang 2024-08-02 06:56:56 +08:00 committed by GitHub
parent c6e86c86dc
commit 1a13bf5c0d
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -41,7 +41,7 @@ const (
)
var (
authVerifyClientRegex = regexp.MustCompile(`on|off|optional|optional_no_ca`)
authVerifyClientRegex = regexp.MustCompile(`^(on|off|optional|optional_no_ca)$`)
redirectRegex = regexp.MustCompile(`^((https?://)?[A-Za-z0-9\-.]*(:\d+)?/[A-Za-z0-9\-.]*)?$`)
)