spamham 0.0.3 → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- data/bin/spamham-update +5 -0
- data/lib/spamham/version.rb +1 -1
- data/lib/spamham/wordlist.rb +1 -16
- data/lib/spamham/wordlist.yml +16 -0
- metadata +7 -5
data/bin/spamham-update
ADDED
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
#!/usr/bin/env ruby
|
|
2
|
+
puts "Fetching new wordlist from github"
|
|
3
|
+
lib_path = File.expand_path("../lib/spamham/",File.dirname(__FILE__))
|
|
4
|
+
system("wget --no-check-certificate -O #{lib_path}/wordlist.yml https://github.com/Arcath/SpamHam/raw/master/lib/spamham/wordlist.yml")
|
|
5
|
+
puts "Done"
|
data/lib/spamham/version.rb
CHANGED
data/lib/spamham/wordlist.rb
CHANGED
|
@@ -1,20 +1,5 @@
|
|
|
1
1
|
class SpamHam
|
|
2
2
|
def wordlist
|
|
3
|
-
[
|
|
4
|
-
"viagra",
|
|
5
|
-
"fake watches",
|
|
6
|
-
"enlargement",
|
|
7
|
-
"penis",
|
|
8
|
-
"designer",
|
|
9
|
-
"brands",
|
|
10
|
-
"buy",
|
|
11
|
-
"online slots",
|
|
12
|
-
"valium",
|
|
13
|
-
"ambien",
|
|
14
|
-
"dosage",
|
|
15
|
-
"propecia",
|
|
16
|
-
"download",
|
|
17
|
-
"sex"
|
|
18
|
-
] + (@config[:additional_words] || [])
|
|
3
|
+
YAML.load_file(File.dirname(__FILE__) + "/wordlist.yml")["words"] + (@config[:additional_words] || [])
|
|
19
4
|
end
|
|
20
5
|
end
|
metadata
CHANGED
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
|
2
2
|
name: spamham
|
|
3
3
|
version: !ruby/object:Gem::Version
|
|
4
|
-
hash:
|
|
4
|
+
hash: 27
|
|
5
5
|
prerelease: false
|
|
6
6
|
segments:
|
|
7
7
|
- 0
|
|
8
|
+
- 1
|
|
8
9
|
- 0
|
|
9
|
-
|
|
10
|
-
version: 0.0.3
|
|
10
|
+
version: 0.1.0
|
|
11
11
|
platform: ruby
|
|
12
12
|
authors:
|
|
13
13
|
- Adam "Arcath" Laycock
|
|
@@ -22,8 +22,8 @@ dependencies: []
|
|
|
22
22
|
description: ...
|
|
23
23
|
email:
|
|
24
24
|
- adam@arcath.net
|
|
25
|
-
executables:
|
|
26
|
-
|
|
25
|
+
executables:
|
|
26
|
+
- spamham-update
|
|
27
27
|
extensions: []
|
|
28
28
|
|
|
29
29
|
extra_rdoc_files: []
|
|
@@ -33,6 +33,7 @@ files:
|
|
|
33
33
|
- Gemfile
|
|
34
34
|
- README.rdoc
|
|
35
35
|
- Rakefile
|
|
36
|
+
- bin/spamham-update
|
|
36
37
|
- init.rb
|
|
37
38
|
- lib/spamham.rb
|
|
38
39
|
- lib/spamham/configure.rb
|
|
@@ -41,6 +42,7 @@ files:
|
|
|
41
42
|
- lib/spamham/string.rb
|
|
42
43
|
- lib/spamham/version.rb
|
|
43
44
|
- lib/spamham/wordlist.rb
|
|
45
|
+
- lib/spamham/wordlist.yml
|
|
44
46
|
- spamham.gemspec
|
|
45
47
|
- spec/spamham_spec.rb
|
|
46
48
|
has_rdoc: true
|