forked from boostorg/regex
151 lines
7.8 KiB
Plaintext
151 lines
7.8 KiB
Plaintext
'è (?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* # optional leading comment
|
|
(?: (?:
|
|
[^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters...
|
|
(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom
|
|
|
|
|
" (?: # opening quote...
|
|
[^\\\x80-\xff\n\015"] # Anything except backslash and quote
|
|
| # or
|
|
\\ [^\x80-\xff] # Escaped something (something != CR)
|
|
)* " # closing quote
|
|
) # initial word
|
|
(?: (?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* \. (?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* (?:
|
|
[^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters...
|
|
(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom
|
|
|
|
|
" (?: # opening quote...
|
|
[^\\\x80-\xff\n\015"] # Anything except backslash and quote
|
|
| # or
|
|
\\ [^\x80-\xff] # Escaped something (something != CR)
|
|
)* " # closing quote
|
|
) )* # further okay, if led by a period
|
|
(?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | ) \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* @ (?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* (?:
|
|
[^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters...
|
|
(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom
|
|
| \[ # [
|
|
(?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff
|
|
\] # ]
|
|
) # initial subdomain
|
|
(?: #
|
|
(?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* \. # if led by a period...
|
|
(?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* (?:
|
|
[^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters...
|
|
(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom
|
|
| \[ # [
|
|
(?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff
|
|
\] # ]
|
|
) # ...further okay
|
|
)*
|
|
# address
|
|
| # or
|
|
(?:
|
|
[^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters...
|
|
(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom
|
|
|
|
|
" (?: # opening quote...
|
|
[^\\\x80-\xff\n\015"] # Anything except backslash and quote
|
|
| # or
|
|
\\ [^\x80-\xff] # Escaped something (something != CR)
|
|
)* " # closing quote
|
|
) # one word, optionally followed by....
|
|
(?:
|
|
[^()<>@,;:".\\\[\]\x80-\xff\000-\010\012-\037] | # atom and space parts, or...
|
|
\(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) | # comments, or...
|
|
" (?: # opening quote...
|
|
[^\\\x80-\xff\n\015"] # Anything except backslash and quote
|
|
| # or
|
|
\\ [^\x80-\xff] # Escaped something (something != CR)
|
|
)* " # closing quote
|
|
# quoted strings
|
|
)*
|
|
< (?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* # leading <
|
|
(?: @ (?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* (?:
|
|
[^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters...
|
|
(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom
|
|
| \[ # [
|
|
(?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff
|
|
\] # ]
|
|
) # initial subdomain
|
|
(?: #
|
|
(?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* \. # if led by a period...
|
|
(?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* (?:
|
|
[^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters...
|
|
(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom
|
|
| \[ # [
|
|
(?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff
|
|
\] # ]
|
|
) # ...further okay
|
|
)*
|
|
(?: (?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* , (?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* @ (?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* (?:
|
|
[^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters...
|
|
(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom
|
|
| \[ # [
|
|
(?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff
|
|
\] # ]
|
|
) # initial subdomain
|
|
(?: #
|
|
(?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* \. # if led by a period...
|
|
(?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* (?:
|
|
[^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters...
|
|
(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom
|
|
| \[ # [
|
|
(?: [^\\\x80-\xff\n\015\[\]] | \\ [^\x80-\xff] )* # stuff
|
|
\] # ]
|
|
) # ...further okay
|
|
)*
|
|
)* # further okay, if led by comma
|
|
: # closing colon
|
|
(?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* )? # optional route
|
|
(?:
|
|
[^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]+ # some number of atom characters...
|
|
(?![^(\040)<>@,;:".\\\[\]\000-\037\x80-\xff]) # ..not followed by something that could be part of an atom
|
|
|
|
|
" (?: # opening quote...
|
|
[^\\\x80-\xff\n\015"] # Anything except backslash and quote
|
|
| # or
|
|
\\ [^\x80-\xff] # Escaped something (something != CR)
|
|
)* " # closing quote
|
|
) # initial word
|
|
(?: (?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* \. (?: [\040\t] | \(
|
|
(?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] | \( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-( (?: [^\\\x80-\xff\n\015()] | \\ [^\x80-\xff] )* \) )*
|
|
\) )* # optional trailing comment
|
|
|
|
<user@dom.ain> |