linsc 0.0.8 → 0.0.9

Sign up to get free protection for your applications and to get access to all the features.
data/lib/linsc/duck.rb CHANGED
@@ -54,7 +54,11 @@ class DuckScraper
54
54
  append_ddg_row(input_row, "Insufficient Data", nil)
55
55
  next
56
56
  end
57
+ cert_file = Pathname.new(File.dirname __dir__).realdirpath + '../data/cacert.pem'
58
+ cert_store = OpenSSL::X509::Store.new
59
+ cert_store.add_file(cert_file.to_s)
57
60
  agent = Mechanize.new
61
+ agent.cert_store = cert_store
58
62
 
59
63
  unless @noproxy
60
64
  proxy = @proxies.get_proxy
data/lib/linsc/lin.rb CHANGED
@@ -152,7 +152,11 @@ class LinScraper
152
152
  def validate(url, row)
153
153
  puts "checking url: #{url}"
154
154
  begin
155
+ cert_file = Pathname.new(File.dirname __dir__).realdirpath + '../data/cacert.pem'
156
+ cert_store = OpenSSL::X509::Store.new
157
+ cert_store.add_file(cert_file.to_s)
155
158
  agent = Mechanize.new
159
+ agent.cert_store = cert_store
156
160
 
157
161
  unless @noproxy
158
162
  proxy = @proxies.get_proxy
data/linsc.gemspec CHANGED
@@ -4,7 +4,7 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
4
 
5
5
  Gem::Specification.new do |spec|
6
6
  spec.name = "linsc"
7
- spec.version = "0.0.8"
7
+ spec.version = "0.0.9"
8
8
  spec.authors = ["Dan Molloy"]
9
9
  spec.email = ["danieljmolloy1@gmail.com"]
10
10
  spec.date = '2016-03-31'
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: linsc
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.8
4
+ version: 0.0.9
5
5
  platform: ruby
6
6
  authors:
7
7
  - Dan Molloy
@@ -100,6 +100,7 @@ files:
100
100
  - bin/linsc
101
101
  - bin/setup
102
102
  - data/agents.txt
103
+ - data/cacert.pem
103
104
  - data/proxies.txt
104
105
  - data/recruiters.txt
105
106
  - lib/linsc.rb