Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
eterfund-api-email
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
eterfund
eterfund-api-email
Commits
a968dec4
Commit
a968dec4
authored
Oct 01, 2018
by
Дмитрий Никулин
Committed by
Vitaly Lipatov
Oct 01, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Add more specific domains
parent
091ecdca
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
index.php
index.php
+1
-1
svcCheckEmail.php
svcCheckEmail.php
+2
-2
No files found.
index.php
View file @
a968dec4
...
@@ -15,7 +15,7 @@
...
@@ -15,7 +15,7 @@
</html>
</html>
<body>
<body>
<form
action=
""
method=
"post"
>
<form
action=
""
method=
"post"
>
E-mail:
<input
type=
"text"
name=
"email"
value=
"
<?php
echo
$_POST
[
'email'
];
?>
"
class=
"svcCheckEmail"
/>
E-mail:
<input
type=
"text"
name=
"email"
value=
"
<?php
if
(
isset
(
$_POST
[
'email'
]))
echo
$_POST
[
'email'
];
?>
"
class=
"svcCheckEmail"
/>
<input
type=
"submit"
value=
"Отправить"
/>
<input
type=
"submit"
value=
"Отправить"
/>
</form>
</form>
</body>
</body>
svcCheckEmail.php
View file @
a968dec4
...
@@ -14,7 +14,7 @@ function typeddomain($domain) {
...
@@ -14,7 +14,7 @@ function typeddomain($domain) {
// I know, yadex.ru and mail.com are exists, but we will ban it
// I know, yadex.ru and mail.com are exists, but we will ban it
// TODO: тут мы вполне можем предложить автоисправление
// TODO: тут мы вполне можем предложить автоисправление
$blacklist
=
array
(
"lnbox.ru"
,
"indox.ru"
,
"meil.ru"
,
"maile.ru"
,
"meil.ru"
,
"mali.ru"
,
"wail.ru"
,
"maiil.ru"
,
"maij.ru"
,
"mfil.ru"
,
"mai.ru"
,
"qmail.com"
,
"mal.ru"
,
"vail.ru"
,
$blacklist
=
array
(
"lnbox.ru"
,
"indox.ru"
,
"meil.ru"
,
"maile.ru"
,
"meil.ru"
,
"mali.ru"
,
"wail.ru"
,
"maiil.ru"
,
"maij.ru"
,
"mfil.ru"
,
"mai.ru"
,
"qmail.com"
,
"mal.ru"
,
"vail.ru"
,
"yandeks.ru"
,
"yandexs.ru"
,
"jandex.ru"
,
"yahdex.ru"
,
"yanbex.ru"
,
"ayndex.ru"
,
"yndex.ru"
,
"yanddex.ru"
,
"yamdex.ru"
,
"yundex.ru"
,
"eandex.ru"
,
"yadex.ru"
,
"yandeks.ru"
,
"yandexs.ru"
,
"jandex.ru"
,
"yahdex.ru"
,
"yanbex.ru"
,
"ayndex.ru"
,
"yndex.ru"
,
"yanddex.ru"
,
"yamdex.ru"
,
"yundex.ru"
,
"eandex.ru"
,
"yadex.ru"
,
"yandes.ru"
,
"gmal.com"
,
"gmal.ru"
,
"gmeil.com"
,
"gmauil.com"
,
"gmail.ru"
,
"gmal.com"
,
"dmail.com"
,
"mail.com"
,
"gmal.com"
,
"gmal.ru"
,
"gmeil.com"
,
"gmauil.com"
,
"gmail.ru"
,
"gmal.com"
,
"dmail.com"
,
"mail.com"
,
"rabler.ru"
,
"ramdler.ru"
,
"ranbler.ru"
);
"rabler.ru"
,
"ramdler.ru"
,
"ranbler.ru"
);
return
in_array
(
$domain
,
$blacklist
);
return
in_array
(
$domain
,
$blacklist
);
...
@@ -77,7 +77,7 @@ $ip_from = get_client_ip();
...
@@ -77,7 +77,7 @@ $ip_from = get_client_ip();
// TODO: improve domain list? drop it?
// TODO: improve domain list? drop it?
if
(
if
(
mb_strlen
(
$email
,
'utf8'
)
>
5
&&
mb_strlen
(
$email
,
'utf8'
)
>
5
&&
preg_match
(
'/^([^@\s]+)@(([a-zA-Z0-9\_\-]+\.)+([a-zA-Z]{2}|aero|arpa|asia|biz|cat|com|coop|edu|gov|info|int|jobs|mil|mobi|museum|name|net|org|post|pro|tel|travel))$/'
,
$email
,
$matches
)
preg_match
(
'/^([^@\s]+)@(([a-zA-Z0-9\_\-]+\.)+([a-zA-Z]{2}|aero|arpa|asia|biz|cat|com|coop|edu|gov|info|int|jobs|mil|mobi|museum|name|net|org|post|pro|tel|travel
|events
))$/'
,
$email
,
$matches
)
)
{
)
{
$response
=
array
(
$response
=
array
(
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment