8000 AssertEmail with strict mode does not check for DNS. · Issue #34681 · symfony/symfony · GitHub
[go: up one dir, main page]

Skip to content
AssertEmail with strict mode does not check for DNS. #34681
Closed
@VincentLanglet

Description

@VincentLanglet

Symfony version(s) affected: 4.3

Description
When using

@Assert\Email(mode="strict")

There is no error for a fooBar@gmailcom email value

Possible Solution
The EmailValidator use

$strictValidator->isValid($email, new NoRFCWarningsValidation())

A better check could be

$strictValidator->isValid($email, new MultipleValidationWithAnd([new NoRFCWarningsValidation(), new DNSCheckValidation()]))

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0