This commit is contained in:
quoije
2023-05-10 21:03:22 -04:00
parent ef1b411c12
commit bd732815c7
1304 changed files with 192970 additions and 5407 deletions
+66
View File
@@ -0,0 +1,66 @@
# disposable-email-domains
A list of [disposable email domains](http://en.wikipedia.org/wiki/Disposable_email_address) like `mailinator.com`. You can use it to detect or block disposable accounts in your signup process. Exact domain matches are found in [index.json](https://github.com/ivolo/disposable-email-domains/blob/master/index.json) and wildcard domains (ex: `*.33mail.com`) are in [wildcard.json](https://github.com/ivolo/disposable-email-domains/blob/master/wildcard.json).
# Examples
## Node.JS
```js
var domains = require('disposable-email-domains');
var wildcards = require('disposable-email-domains/wildcard.json');
// ... your code here
```
## API
An always-up-to-date version of this repo is provided as an API by [Kickbox](https://kickbox.com/). Issuing a `GET` request to https://open.kickbox.com/v1/disposable/{DomainOrEmailAddress} will return `{"disposable":true}` or `{"disposable":false}` as a JSON response.
```
https://open.kickbox.com/v1/disposable/mailinator.com
{"disposable":true}
```
# Installation
```
$ npm install disposable-email-domains
```
```
$ component install ivolo/disposable-email-domains
```
# Contributing
Add new disposable domains to [index.json](https://github.com/ivolo/disposable-email-domains/blob/master/index.json) and wildcard disposable domains to [wildcard.json](https://github.com/ivolo/disposable-email-domains/blob/master/wildcard.json).
To easily add new domains, insert them into [index.txt](https://github.com/ivolo/disposable-email-domains/blob/master/contributions/index.txt) and/or [wildcard.txt](https://github.com/ivolo/disposable-email-domains/blob/master/contributions/wildcard.txt) and run `npm run add`.
The domains will be added to the respective files and some validation will be made to ensure they pass the tests.
Please run `npm run test` before creating a Pull Request to ensure all tests are passing.
You can also run `npm run prod` to add new domains and run the tests at the same time.
# License
```
WWWWWW||WWWWWW
W W W||W W W
||
( OO )__________
/ | \
/o o| MIT \
\___/||_||__||_|| *
|| || || ||
_||_|| _||_||
(__|__|(__|__|
```
THE SOFTWARE IS PROVIDED "AS IS" AND "AS AND WHEN AVAILABLE", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
THE SOFTWARE.
+44
View File
@@ -0,0 +1,44 @@
const { writeFileSync, readFileSync } = require('fs')
const _ = require('lodash')
var index = require('./index')
var wildcard = require('./wildcard')
// Add new domains
const newDomains = readFileSync('./contributions/index.txt').toString().split("\n").filter(d => d)
index = _.concat(index, newDomains)
const newWildcardDomains = readFileSync('./contributions/wildcard.txt').toString().split("\n").filter(d => d)
wildcard = _.concat(wildcard, newWildcardDomains)
// Remove empty strings
index = index.filter(d => d)
wildcard = wildcard.filter(d => d)
// Lowercase
index = index.map(domain => { return _.toLower(domain) })
wildcard = wildcard.map(domain => { return _.toLower(domain) })
// Sort
index.sort()
wildcard.sort()
// Dedupe
index = _.uniq(index)
wildcard = _.uniq(wildcard)
// Remove wildcards
var regexp = new RegExp(/(.+(?:\.[\w-]+\.[\w-]+)+)$/)
index = index
.filter(domain => {
if (regexp.test(domain)) {
return ! wildcard.filter(wildcard => {
return _.endsWith(domain, wildcard)
}).length
}
return true
})
writeFileSync('index.json', JSON.stringify(index, null, 2))
writeFileSync('wildcard.json', JSON.stringify(wildcard, null, 2))
+10
View File
@@ -0,0 +1,10 @@
{
"name": "disposable-email-domains",
"repo": "ivolo/disposable-email-domains",
"description": "Get a list of disposable email domains.",
"version": "1.0.59",
"keywords": ["validate", "email", "disposable", "domains"],
"license": "MIT",
"files": ["index.json"],
"scripts": ["index.js"]
}
+13
View File
@@ -0,0 +1,13 @@
{
"name": "ivolo/disposable-email-domains",
"description": "disposable domains list",
"keywords": ["disposable", "domains"],
"license": "MIT",
"authors": [
{
"name": "Ilya Volodarsky",
"email": "[email protected]",
"role": "Maintainer"
}
]
}
+6
View File
@@ -0,0 +1,6 @@
/**
* Expose the disposable domains.
*/
module.exports = require('./index.json');
+121572
View File
File diff suppressed because it is too large Load Diff
+19
View File
@@ -0,0 +1,19 @@
{
"name": "disposable-email-domains",
"version": "1.0.62",
"repository": "https://github.com/ivolo/disposable-email-domains.git",
"license": "MIT",
"main": "./index.json",
"scripts": {
"test": "mocha || true",
"add": "node add.js",
"prod": "node add.js && mocha || true"
},
"devDependencies": {
"chai": "^3.5.0",
"chai-sorted": "^0.1.0",
"lodash": "^4.17.21",
"mocha": "^6.2.1",
"validator": "^13.7.0"
}
}
+17
View File
@@ -0,0 +1,17 @@
const isFQDN = require('validator').isFQDN;
/*
Check if all the elements are valid domains
*/
module.exports = function (chai) {
chai.Assertion.addProperty('isFQDN', function () {
var obj = this._obj, _this = this;
obj.forEach(function(o){
_this.assert(
isFQDN(o)
, 'expected "' + o + '" to be a valid domain'
, 'expected "' + o + '" to not be all lowecase'
);
});
});
};
+15
View File
@@ -0,0 +1,15 @@
/*
Check if all the elements are in lowercase
*/
module.exports = function (chai) {
chai.Assertion.addProperty('lowercase', function () {
var obj = this._obj, _this = this;
obj.forEach(function(o){
_this.assert(
o === o.toLowerCase()
, 'expected "' + o + '" to be all lowercase'
, 'expected "' + o + '" to not be all lowercase'
);
});
});
};
+20
View File
@@ -0,0 +1,20 @@
var wildcard = require('../../wildcard');
const _ = require('lodash');
/*
Check if all the elements are in lowercase
*/
module.exports = function (chai) {
chai.Assertion.addProperty('notInWildcard', function () {
this._obj.forEach(domain => {
if (new RegExp(/(.+(?:\.[\w-]+\.[\w-]+)+)$/).test(domain)) {
wildcard.forEach(wildcard => {
this.assert(
! _.endsWith(domain, wildcard)
, '"' + domain + '" is already in the wildcard list'
);
})
}
});
});
};
+33
View File
@@ -0,0 +1,33 @@
const _ = require('lodash');
const domains = require('../index');
const chai = require('chai');
const expect = chai.expect;
chai.use(require("chai-sorted"));
chai.use(require('./helpers/lowercase'));
chai.use(require('./helpers/isFQDN'));
chai.use(require('./helpers/notInWildcard'));
describe('Domains', function(){
it('should be an array', function(){
expect(domains).to.be.a('array');
});
it('should have at least one domain', function(){
expect(domains).to.have.length.above(0);
});
it('should be in alphabetical order', function(){
expect(domains).to.be.sorted();
});
it('should not have duplicates', function(){
expect(domains).to.deep.equal(_.uniq(domains));
});
it('should be lowercase', function(){
expect(domains).to.be.all.lowercase;
});
it('should be a valid domain', function(){
expect(domains).to.be.all.isFQDN;
});
it('should not be a wildcard domain', function(){
expect(domains).to.be.all.notInWildcard;
});
});
+29
View File
@@ -0,0 +1,29 @@
const _ = require('lodash');
const domains = require('../wildcard');
const chai = require('chai');
const expect = chai.expect;
chai.use(require("chai-sorted"));
chai.use(require('./helpers/lowercase'));
chai.use(require('./helpers/isFQDN'));
describe('Wildcard domains', function(){
it('should be an array', function(){
expect(domains).to.be.a('array');
});
it('should have at least one domain', function(){
expect(domains).to.have.length.above(0);
});
it('should be in alphabetical order', function(){
expect(domains).to.be.sorted();
});
it('should not have duplicates', function(){
expect(domains).to.deep.equal(_.uniq(domains));
});
it('should be lowercase', function(){
expect(domains).to.be.all.lowercase;
});
it('should be a valid domain', function(){
expect(domains).to.be.all.isFQDN;
});
});
+6
View File
@@ -0,0 +1,6 @@
/**
* Expose the wildcard disposable domains.
*/
module.exports = require('./wildcard.json');
+401
View File
@@ -0,0 +1,401 @@
[
"0x01.gq",
"0x01.tk",
"10mail.org",
"10mail.tk",
"33m.co",
"33mail.com",
"3dxtras.com",
"3utilities.com",
"567map.xyz",
"8191.at",
"aa.am",
"accountsite.me",
"acmetoy.com",
"acusupply.com",
"adultvidlite.com",
"aji.kr",
"anonaddy.com",
"anonaddy.me",
"anonbox.net",
"anyalias.com",
"asanatest1.us",
"azzawajalla.store",
"bajetesik.store",
"band-freier.de",
"bandband1.com",
"bangmadid.store",
"batikbantul.com",
"bccto.me",
"bebekpenyet.buzz",
"bei.kr",
"bel.kr",
"beo.kr",
"bfo.kr",
"bgsaddrmwn.me",
"bho.kr",
"biasaelho.space",
"biz.st",
"biz.tm",
"bko.kr",
"blacksong.pw",
"blueauramassage.com",
"bounceme.net",
"bum.net",
"buwosok.tech",
"buzzndaraiangop2wae.buzz",
"byui.me",
"caboodle.buzz",
"cad.edu.gr",
"cempue.online",
"chickenkiller.com",
"choirul.host",
"cid.kr",
"ciran.xyz",
"cko.kr",
"cloudns.asia",
"cloudns.cc",
"cloudns.cx",
"cloudns.nz",
"com.com",
"coms.hk",
"comx.cf",
"craigslist.org",
"creo.site",
"creo.tips",
"creou.dev",
"crowdpress.it",
"cu.cc",
"cua77.xyz",
"d3vs.net",
"dadosa.xyz",
"danuarte.online",
"darrels.site",
"daseus.online",
"dayatan.host",
"dbo.kr",
"ddns.net",
"ddnsfree.com",
"deail.com",
"dedyn.io",
"defaultdomain.ml",
"discard-email.cf",
"dko.kr",
"dlink.cf",
"dlink.gq",
"dlyemail.com",
"dmtc.dev",
"dmtc.edu.pl",
"dmtc.press",
"dns-cloud.net",
"dns.navy",
"dnsabr.com",
"dnses.ro",
"doy.kr",
"drope.ml",
"dropmail.me",
"dynu.net",
"dzalaev-advokat.ru",
"e4ward.com",
"ediantenan.site",
"edu.auction",
"efo.kr",
"eho.kr",
"ely.kr",
"email-temp.com",
"emailfake.com",
"emailfake.ml",
"emailfreedom.ml",
"emlhub.com",
"emlpro.com",
"emltmp.com",
"emy.kr",
"enu.kr",
"eny.kr",
"epizy.com",
"escritossad.net",
"ese.kr",
"esy.es",
"ewa.kr",
"exi.kr",
"ezyro.com",
"fackme.gq",
"fassagforpresident.ga",
"firste.ml",
"flu.cc",
"foy.kr",
"fr.nf",
"freeml.net",
"gadzooks.buzz",
"gettrials.com",
"giize.com",
"gmail.gr.com",
"gmeil.me",
"gok.kr",
"gotdns.ch",
"gpa.lu",
"grigio.cf",
"guardmail.cf",
"haddo.eu",
"heliohost.org",
"higogoya.com",
"historial.store",
"hitechinfo.com",
"hix.kr",
"hiz.kr",
"hmail.us",
"hopto.org",
"hostingarif.me",
"idn.vn",
"iesco.info",
"igg.biz",
"ignorelist.com",
"iki.kr",
"ilovemyniggers.club",
"imouto.pro",
"info.tm",
"infos.st",
"irr.kr",
"isgre.at",
"it2-mail.tk",
"jil.kr",
"jindmail.club",
"jto.kr",
"junnuok.com",
"justemail.ml",
"kadokawa.top",
"kantal.buzz",
"keitin.site",
"kentel.buzz",
"kerl.cf",
"kerl.gq",
"kikwet.com",
"kondomeus.site",
"kozow.com",
"kranjingan.store",
"kranjingan.tech",
"kranjingans.tech",
"kro.kr",
"lal.kr",
"laste.ml",
"lbe.kr",
"legundi.site",
"lei.kr",
"likevip.net",
"liopers.link",
"lko.co.kr",
"lko.kr",
"ll47.net",
"lofteone.ru",
"lom.kr",
"longdz.site",
"longmusic.com",
"lostandalone.com",
"loudcannabisapp.com",
"loy.kr",
"loyalherceghalom.ml",
"luk2.com",
"luksarcenter.ru",
"luo.kr",
"lyrics-lagu.me",
"mail-temp.com",
"mail0.ga",
"mailinator.com",
"mailr.eu",
"marrone.cf",
"mbe.kr",
"mblimbingan.space",
"mebelnovation.ru",
"mefound.com",
"mintemail.com",
"mishmash.buzz",
"mko.kr",
"mlo.kr",
"mooo.com",
"motifasidiri.website",
"mp-j.cf",
"mp-j.ga",
"mp-j.gq",
"mp-j.ml",
"mp-j.tk",
"mr-meshkat.com",
"mrossi.cf",
"mrossi.gq",
"mrossi.ml",
"ms1.email",
"msdc.co",
"muabanwin.net",
"museumplanet.com",
"my.id",
"my3mail.cf",
"my3mail.ga",
"my3mail.gq",
"my3mail.ml",
"my3mail.tk",
"myddns.me",
"myeslbookclub.com",
"mymy.cf",
"mysafe.ml",
"mzon.store",
"n-e.kr",
"nafko.cf",
"nctu.me",
"netmail.tk",
"netricity.nl",
"new-mgmt.ga",
"ngalasmoen.xyz",
"ngguwokulon.online",
"njambon.space",
"nko.kr",
"now.im",
"npv.kr",
"nuo.co.kr",
"nuo.kr",
"nut.cc",
"o-r.kr",
"oazis.site",
"obo.kr",
"ocry.com",
"office.gy",
"okezone.bid",
"one.pl",
"onlysext.com",
"oovy.org",
"oppoesrt.online",
"orangotango.ml",
"otherinbox.com",
"ourhobby.com",
"owa.kr",
"owh.ooo",
"oyu.kr",
"p-e.kr",
"pafnuty.com",
"pandies.space",
"paqeh.online",
"pe.hu",
"petinggiean.tech",
"peyekkolipi.buzz",
"poderosamulher.com",
"poistaa.com",
"porco.cf",
"poy.kr",
"prapto.host",
"probatelawarizona.com",
"ptcu.dev",
"pubgm.website",
"qbi.kr",
"qc.to",
"r-e.kr",
"ragel.me",
"rao.kr",
"reilis.site",
"rf.gd",
"ringen.host",
"rko.kr",
"rosso.ml",
"row.kr",
"rr.nu",
"rshagor.xyz",
"s-ly.me",
"safe-mail.gq",
"sagun.info",
"samsueng.site",
"saucent.online",
"sborra.tk",
"schwarzmail.ga",
"seluang.com",
"sempak.link",
"sendaljepit.site",
"sendangagung.online",
"servegame.com",
"shp7.cn",
"siambretta.com",
"skodaauto.cf",
"soju.buzz",
"solidplai.us",
"somee.com",
"spamtrap.ro",
"spymail.one",
"ssanphone.me",
"standeight.com",
"statuspage.ga",
"steakbeef.site",
"stonedogdigital.com",
"stop-my-spam.pp.ua",
"storeyee.com",
"sumanan.site",
"supere.ml",
"svblog.com",
"sytes.net",
"tandy.co",
"tangtingtung.tech",
"teml.net",
"tempembus.buzz",
"tempremail.cf",
"tempremail.tk",
"tgwrzqr.top",
"thepieter.com",
"theworkpc.com",
"thinktimessolve.info",
"thumoi.com",
"tko.co.kr",
"tko.kr",
"tmo.kr",
"tmpeml.com",
"toh.info",
"toi.kr",
"tomcrusenono.host",
"topikurrohman.xyz",
"tourbalitravel.com",
"traveldesk.com",
"tricakesi.store",
"trillianpro.com",
"twilightparadox.com",
"tyrex.cf",
"uha.kr",
"uk.to",
"uko.kr",
"umy.kr",
"unaux.com",
"undo.it",
"uny.kr",
"uola.org",
"upy.kr",
"urbanban.com",
"us.to",
"usa.cc",
"uu.gl",
"uvy.kr",
"uyu.kr",
"vay.kr",
"vba.kr",
"veo.kr",
"viola.gq",
"vivoheroes.xyz",
"vkbags.in",
"vo.uk",
"volvo-xc.tk",
"vuforia.us",
"wakultimbo.buzz",
"web.id",
"weprof.it",
"werkuldino.buzz",
"wil.kr",
"wingkobabat.buzz",
"x24hr.com",
"xiaomie.store",
"xo.uk",
"xxi2.com",
"yarien.eu",
"yawahid.host",
"ye.vc",
"yertxenor.tk",
"yomail.info",
"yopmail.com",
"yoqoyyum.space",
"youdontcare.com",
"zalvisual.us",
"zapto.org",
"ze.cx",
"zeroe.ml"
]