Remove underscore from allowed email local part characters
Underscore is technically allowed by RFC 5321 but causes issues with many email systems in practice.
This commit is contained in:
parent
d562e41528
commit
da037e9a79
2 changed files with 1 additions and 2 deletions
|
|
@ -7,7 +7,6 @@ import (
|
|||
)
|
||||
|
||||
//go:embed all:embed
|
||||
//go:embed all:embed/_app
|
||||
var Files embed.FS
|
||||
|
||||
func FrontendFileSystem() http.FileSystem {
|
||||
|
|
|
|||
|
|
@ -286,7 +286,7 @@ func (h *UserHandler) ListAll(c *gin.Context) {
|
|||
Success(c, users)
|
||||
}
|
||||
|
||||
var emailLocalPartRegex = regexp.MustCompile("^[a-zA-Z0-9!#$%&'*+\\-/=?^_`{|}~-]+$")
|
||||
var emailLocalPartRegex = regexp.MustCompile("^[a-zA-Z0-9!#$%&'*+\\-/=?^`{|}~-]+$")
|
||||
|
||||
func validateEmailLocalPart(email string) error {
|
||||
parts := strings.Split(email, "@")
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue