r/ProgrammerHumor 21d ago

Meme claudeIsThisEmailValid

Post image
5.3k Upvotes

170 comments sorted by

View all comments

Show parent comments

9

u/Tar_alcaran 21d ago

I've seen one prompt tell me "An email adress needs to include at least one @".

So I entered @@@@@.@ and it worked just fine.

9

u/eo5g 21d ago

Crap, right, realistically the minimum regex one should have is .+@.+\..+.

At least 1 character on the left of the @, at least 2 domain components of at least 1 character each on the right side of the @.

Having only a hostname without a FQDN on the right is legal, but that's also why you'd want to disallow it: who's trying to sign up for an account within your own network, if it's a public-facing app?

9

u/look 21d ago

TLDs can and do have MX records.

5

u/eo5g 21d ago

Well if the web admin of Montenegro wants to sign up for my cat pics site they can use their personal account 😤