Skip to content

Commit 245358b

Browse files
committed
Add more invalid user email tests
1 parent d453cdb commit 245358b

1 file changed

Lines changed: 3 additions & 0 deletions

File tree

backend/api/validation.rs

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -246,11 +246,14 @@ mod tests {
246246
"\"\"@example.com",
247247
"\"user-with\nline-break\"@example.com",
248248
"\"user-with-unbalanced\"quotes\"@example.com",
249+
"user-with-\"balanced-quotes\"-in-middle@example.com",
249250
"user-with\\backslash@example.com",
250251
"user-with-unquoted-escaped\\ special-character@example.com",
251252
// While technically allowed by RFC 5322, the following forms aren't allowed by RFC 5321
252253
// and aren't required by any standards-compliant mail server, so there's no reason to
253254
// allow them. Users submitting these are most likely trying to break things.
255+
"\"user\".name@example.com",
256+
"user.\"name\"@example.com",
254257
"\"user\".\"name\"@example.com",
255258
" user.name@example.com",
256259
"user .name@example.com",

0 commit comments

Comments
 (0)