email_data 1607321830 → 1607427861
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/.github/FUNDING.yml +1 -2
- data/.github/workflows/package.yml +4 -23
- data/.gitignore +21 -2
- data/README.md +20 -0
- data/bin/helpers.rb +4 -4
- data/bin/package +40 -2
- data/bin/sync-disposable-emails +1 -2
- data/lib/email_data/version.rb +1 -1
- data/package.json +1 -1
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 63b2324c3c5b0b6cf82035d848fdc7bb4da8ddd7f4e5fd2ea5bacff09eb37fe0
|
4
|
+
data.tar.gz: 42505ee545597463a44604089b0d8288daee2a5b4bbddc237dbe9d6e20c59c0f
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f46c3cc8c6760ca863e8d70804f48b6badf714368815cce42a8ce12c386849e79e1f8996cf4c1168cba143ca8360797a4463b75f8921416e6b7405f412cffe3b
|
7
|
+
data.tar.gz: dc79df9eecce6e95e44c15d806668ce585ee8147bc8ac94ea614e40e1992a3310d66a877ee95d3c8f67b933623532ea0b1ecc4651438386cf6da7e1d0ebc3881
|
data/.github/FUNDING.yml
CHANGED
@@ -2,12 +2,10 @@
|
|
2
2
|
name: package
|
3
3
|
|
4
4
|
on:
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
9
|
-
# schedule:
|
10
|
-
# - cron: "0 10 * * *"
|
5
|
+
schedule:
|
6
|
+
- cron: "0 0 * * *"
|
7
|
+
workflow_dispatch:
|
8
|
+
inputs: {}
|
11
9
|
|
12
10
|
jobs:
|
13
11
|
build:
|
@@ -49,20 +47,3 @@ jobs:
|
|
49
47
|
NPM_AUTH_TOKEN: "${{ secrets.NPM_AUTH_TOKEN }}"
|
50
48
|
run: |
|
51
49
|
./bin/package
|
52
|
-
git config user.email "me@fnando.com"
|
53
|
-
git config user.name "Nando Vieira via Github Actions"
|
54
|
-
git add Gemfile.lock
|
55
|
-
git add package.json
|
56
|
-
git add lib/email_data/version.rb
|
57
|
-
git commit --message "Update lists."
|
58
|
-
git pull origin --rebase
|
59
|
-
git push origin --set-upstream
|
60
|
-
|
61
|
-
mkdir -p ~/.gem
|
62
|
-
echo ":rubygems_api_key: $RUBYGEMS_API_KEY" > ~/.gem/credentials
|
63
|
-
chmod 0600 ~/.gem/credentials
|
64
|
-
rake release
|
65
|
-
|
66
|
-
echo "//registry.npmjs.org/:_authToken=$NPM_AUTH_TOKEN" > ~/.npmrc
|
67
|
-
chmod 0600 ~/.npmrc
|
68
|
-
npm publish --access public
|
data/.gitignore
CHANGED
@@ -9,5 +9,24 @@
|
|
9
9
|
/data/disposable/**/*
|
10
10
|
/data/json/**/*
|
11
11
|
LOCK
|
12
|
-
|
13
|
-
/
|
12
|
+
bin/jq
|
13
|
+
opt/
|
14
|
+
vendor/
|
15
|
+
pkg/
|
16
|
+
VERSION
|
17
|
+
.DS_Store
|
18
|
+
.*.sw?
|
19
|
+
/.pow*
|
20
|
+
/.rvmrc
|
21
|
+
/.rbenv-version
|
22
|
+
/bin/
|
23
|
+
/.tags*
|
24
|
+
Thumbs.db
|
25
|
+
.vagrant
|
26
|
+
.bash/user.sh
|
27
|
+
.gemtags
|
28
|
+
.tags
|
29
|
+
.tags_sorted_by_file
|
30
|
+
/node_modules
|
31
|
+
/.env
|
32
|
+
/.env.*
|
data/README.md
CHANGED
@@ -41,6 +41,8 @@ EmailData.data_dir
|
|
41
41
|
|
42
42
|
# List of disposable domains. Punycode is expanded into ASCII domains.
|
43
43
|
EmailData.disposable_domains
|
44
|
+
EmailData.disposable_domains_with_mx
|
45
|
+
EmailData.disposable_domains_without_mx
|
44
46
|
|
45
47
|
# List of disposable emails. Some services use free email like Gmail to create
|
46
48
|
# disposable emails.
|
@@ -127,6 +129,18 @@ class SetupEmailData < ActiveRecord::Migration[6.1]
|
|
127
129
|
|
128
130
|
add_index :disposable_domains, :name, unique: true
|
129
131
|
|
132
|
+
create_table :disposable_domains_with_mx do |t|
|
133
|
+
t.citext :name, null: false
|
134
|
+
end
|
135
|
+
|
136
|
+
add_index :disposable_domains_with_mx, :name, unique: true
|
137
|
+
|
138
|
+
create_table :disposable_domains_without_mx do |t|
|
139
|
+
t.citext :name, null: false
|
140
|
+
end
|
141
|
+
|
142
|
+
add_index :disposable_domains_without_mx, :name, unique: true
|
143
|
+
|
130
144
|
create_table :free_email_domains do |t|
|
131
145
|
t.citext :name, null: false
|
132
146
|
end
|
@@ -176,6 +190,8 @@ COPY slds (name) FROM '/usr/local/ruby/2.7.1/lib/ruby/gems/2.7.0/gems/email_data
|
|
176
190
|
COPY country_tlds (name) FROM '/usr/local/ruby/2.7.1/lib/ruby/gems/2.7.0/gems/email_data-1601479967/data/country_tlds.txt';
|
177
191
|
COPY disposable_emails (name) FROM '/usr/local/ruby/2.7.1/lib/ruby/gems/2.7.0/gems/email_data-1601479967/data/disposable_emails.txt';
|
178
192
|
COPY disposable_domains (name) FROM '/usr/local/ruby/2.7.1/lib/ruby/gems/2.7.0/gems/email_data-1601479967/data/disposable_domains.txt';
|
193
|
+
COPY disposable_domains_with_mx (name) FROM '/usr/local/ruby/2.7.1/lib/ruby/gems/2.7.0/gems/email_data-1601479967/data/disposable_domains_with_mx.txt';
|
194
|
+
COPY disposable_domains_without_mx (name) FROM '/usr/local/ruby/2.7.1/lib/ruby/gems/2.7.0/gems/email_data-1601479967/data/disposable_domains_without_mx.txt';
|
179
195
|
COPY free_email_domains (name) FROM '/usr/local/ruby/2.7.1/lib/ruby/gems/2.7.0/gems/email_data-1601479967/data/free_email_domains.txt';
|
180
196
|
COPY roles (name) FROM '/usr/local/ruby/2.7.1/lib/ruby/gems/2.7.0/gems/email_data-1601479967/data/roles.txt';
|
181
197
|
COPY private_relays (name) FROM '/usr/local/ruby/2.7.1/lib/ruby/gems/2.7.0/gems/email_data-1601479967/data/private_relays.txt';
|
@@ -204,6 +220,8 @@ class LoadEmailData < ActiveRecord::Migration[6.1]
|
|
204
220
|
copy.call(:country_tlds)
|
205
221
|
copy.call(:disposable_emails)
|
206
222
|
copy.call(:disposable_domains)
|
223
|
+
copy.call(:disposable_domains_with_mx)
|
224
|
+
copy.call(:disposable_domains_without_mx)
|
207
225
|
copy.call(:free_email_domains)
|
208
226
|
copy.call(:roles)
|
209
227
|
copy.call(:private_relays)
|
@@ -230,6 +248,8 @@ $ npm install @fnando/email_data
|
|
230
248
|
```js
|
231
249
|
const disposableEmails = require("@fnando/email_data/data/json/disposable_emails.json");
|
232
250
|
const disposableDomains = require("@fnando/email_data/data/json/disposable_domains.json");
|
251
|
+
const disposableDomainsWithMx = require("@fnando/email_data/data/json/disposable_domains_with_mx.json");
|
252
|
+
const disposableDomainsWithoutMx = require("@fnando/email_data/data/json/disposable_domains_without_mx.json");
|
233
253
|
const freeEmailDomains = require("@fnando/email_data/data/json/free_email_domains.json");
|
234
254
|
const roles = require("@fnando/email_data/data/json/roles.json");
|
235
255
|
const privateRelays = require("@fnando/email_data/data/json/private_relays.json");
|
data/bin/helpers.rb
CHANGED
@@ -106,9 +106,9 @@ def random_timeout
|
|
106
106
|
(1..10).map {|i| (1.0 / i).round(2) }.sample
|
107
107
|
end
|
108
108
|
|
109
|
-
def refresh_list(url:, path:, verb: :get, params: nil
|
109
|
+
def refresh_list(url:, path:, verb: :get, params: nil)
|
110
110
|
response = http_request(verb, url, params)
|
111
|
-
items =
|
111
|
+
items = yield(response)
|
112
112
|
append_to_file(path, items)
|
113
113
|
rescue StandardError => error
|
114
114
|
puts "=> [ERROR] Unable to refresh list: #{url} (#{error.class}: #{error.message})"
|
@@ -191,9 +191,9 @@ def root_domains(domains)
|
|
191
191
|
processed_domains.reject(&:nil?)
|
192
192
|
end
|
193
193
|
|
194
|
-
def thread
|
194
|
+
def thread
|
195
195
|
Thread.new do
|
196
|
-
|
196
|
+
yield
|
197
197
|
rescue StandardError => error
|
198
198
|
puts "=> [ERROR] Thread has errored; #{error.class}: #{error.message}"
|
199
199
|
end
|
data/bin/package
CHANGED
@@ -8,11 +8,49 @@ chmod +x bin/jq
|
|
8
8
|
which jq
|
9
9
|
jq --version
|
10
10
|
|
11
|
-
|
12
|
-
./bin/export-json-files
|
11
|
+
./bin/sync
|
13
12
|
|
14
13
|
echo "=> Updating version files"
|
15
14
|
version=$(date "+%s")
|
16
15
|
package_json=$(cat package.json | jq --arg version "${version}.0.0" '.version = $version')
|
17
16
|
echo $package_json | jq > package.json
|
18
17
|
sed -i -E "s/[0-9]+/$version/" ./lib/email_data/version.rb
|
18
|
+
|
19
|
+
git_status=$(git status 2> /dev/null | tr "\\n" " ")
|
20
|
+
|
21
|
+
if [[ "$git_status" =~ "nothing to commit" ]]; then
|
22
|
+
echo "No changes detected. Skipping new packages."
|
23
|
+
exit
|
24
|
+
fi
|
25
|
+
|
26
|
+
git config user.email "me@fnando.com"
|
27
|
+
git config user.name "Nando Vieira via Github Actions"
|
28
|
+
git add Gemfile.lock
|
29
|
+
git add package.json
|
30
|
+
git add lib/email_data/version.rb
|
31
|
+
git commit --message "Update lists."
|
32
|
+
git reset --hard
|
33
|
+
git pull origin --rebase
|
34
|
+
git push origin --set-upstream
|
35
|
+
git tag "v$version"
|
36
|
+
git push --tags
|
37
|
+
|
38
|
+
echo "=> Check repo status"
|
39
|
+
git diff
|
40
|
+
git diff-index --cached HEAD
|
41
|
+
git status
|
42
|
+
|
43
|
+
echo "=> Generate gem package"
|
44
|
+
mkdir -p ~/.gem
|
45
|
+
echo ":rubygems_api_key: $RUBYGEMS_API_KEY" > ~/.gem/credentials
|
46
|
+
chmod 0600 ~/.gem/credentials
|
47
|
+
mkdir -p pkg
|
48
|
+
rm -rf pkg/*.gem
|
49
|
+
email_data_gem=pkg/email_data-$version.gem
|
50
|
+
gem build email_data.gemspec --silent --output $email_data_gem
|
51
|
+
gem push $email_data_gem
|
52
|
+
|
53
|
+
echo "=> Generate npm package"
|
54
|
+
echo "//registry.npmjs.org/:_authToken=$NPM_AUTH_TOKEN" > ~/.npmrc
|
55
|
+
chmod 0600 ~/.npmrc
|
56
|
+
npm publish --access public --tag "v$version"
|
data/bin/sync-disposable-emails
CHANGED
@@ -130,7 +130,7 @@ def process_scraping(element, value_selector)
|
|
130
130
|
else
|
131
131
|
element.attributes.each do |_name, attr|
|
132
132
|
attr = attr.value.to_s
|
133
|
-
value = attr if attr
|
133
|
+
value = attr if attr&.match?(host_regex)
|
134
134
|
end
|
135
135
|
end
|
136
136
|
|
@@ -172,7 +172,6 @@ threads << thread { domain_scraping("itemp", "https://itemp.email", "select[name
|
|
172
172
|
threads << thread { domain_scraping("cs", "https://www.cs.email", "select[id=gm-host-select] option::text()") }
|
173
173
|
threads << thread { domain_scraping("tempmail", "https://tempmail.io/settings/", "select[id=domain] option::text()") }
|
174
174
|
threads << thread { domain_scraping("tempemail", "https://tempemail.co", "select[name=email_domain] option::text()") }
|
175
|
-
threads << thread { domain_scraping("tmail", "https://mytemp-email.com/", "a.domain-selector::text()") }
|
176
175
|
|
177
176
|
threads.each_slice(5) do |slice|
|
178
177
|
slice.each(&:join)
|
data/lib/email_data/version.rb
CHANGED
data/package.json
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
{
|
2
2
|
"name": "@fnando/email_data",
|
3
3
|
"description": "This project is a compilation of datasets related to emails. Includes disposable emails, disposable domains, and free email services.",
|
4
|
-
"version": "
|
4
|
+
"version": "1607427861.0.0",
|
5
5
|
"license": "MIT",
|
6
6
|
"repository": {
|
7
7
|
"type": "git",
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: email_data
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: '
|
4
|
+
version: '1607427861'
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Nando Vieira
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-12-
|
11
|
+
date: 2020-12-08 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: activerecord
|
@@ -247,9 +247,9 @@ licenses:
|
|
247
247
|
metadata:
|
248
248
|
homepage_uri: https://github.com/fnando/email_data
|
249
249
|
bug_tracker_uri: https://github.com/fnando/email_data/issues
|
250
|
-
source_code_uri: https://github.com/fnando/email_data/tree/
|
251
|
-
documentation_uri: https://github.com/fnando/email_data/tree/
|
252
|
-
license_uri: https://github.com/fnando/email_data/tree/
|
250
|
+
source_code_uri: https://github.com/fnando/email_data/tree/v1607427861
|
251
|
+
documentation_uri: https://github.com/fnando/email_data/tree/v1607427861/README.md
|
252
|
+
license_uri: https://github.com/fnando/email_data/tree/v1607427861/LICENSE.md
|
253
253
|
post_install_message:
|
254
254
|
rdoc_options: []
|
255
255
|
require_paths:
|