As we know that Internet communication is widely spread over
the world. For this communication email address has play vital role to identify
the mail box in which mails are delivered. So there are so many format which
are valid and invalid as per standard RFC 5321, RFC 5322 and RFC 6531.
The general format of mail address is adarsh@example.com. This contain two part –
First Part-
Before at sign @ (i.e adarsh) is known as username or local part. This part is
unique in any domain and having some restrictions.
Second Part-
After at sign @(i.e. example .com) is generally known as domain part.
For any valid mail id is the result of combination of both
part with some restriction. So there are some valid and invalid mail id format
are given-
Some Example of Valid mail id Format:
abc@sample.co.in
abc+efg@sample.com (+ sign in username is also valid)
abc@[valid IP address] (IP address in place of domain name is valid)
abc-efg@sample.com (Dash in username is valid)
“abc
(qw) &* efg”@sample.com (Allow
with the double quotes in username)
abc@com (Com is the top level domain)
Some Example of Invalid mail id Format:
Abc.sample.com (Missing @)
abc@efg@sample.com (double @)
abc efg@sample.com (Space is not allowed in username)
abc”efg”hi@sample.com (Partially double quotes are not allowed in username)
abc.efg.@sample.com (Either leading or trailing dot ( .) in username or
domain name is not
allowed)
abc@sample (Not allowed until sample is top domain)
abc@ and @sample.com
(Either username or domain name missing is
not allowed)
These are basic format on which we write the test cases for
verifying the mail id field.
Node post , kepp it up
ReplyDelete