Commit f51c06ad authored by Heiko Reese's avatar Heiko Reese
Browse files

Public search: fixed string comparision, now using Unicode case folding to compare case-insensitive

parent 780c8049
......@@ -191,7 +191,7 @@ func main() {
HandlerFunc(downloadHandler)
// add emailtocert handler
r.Path("/emailtocert/v1/{email:.*@.*}").
r.Path("/emailtocert/v1/{email:.+@.+}").
Methods("GET").
HandlerFunc(emailtocertHandler)
......
......@@ -269,7 +269,7 @@ func MakePublicSearchFilter(query string, visibilityWatcher *AttributeState) SCF
var numMatches int
for _, token := range queryTokens {
for _, certToken := range append(c.pubsearchToken, c.EmailAddresses...) {
if token == certToken {
if strings.EqualFold(token, certToken) {
numMatches++
continue
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment