firewall_constraint 0.0.9 → 0.1.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: efc4913bfe2b68d887b588522408747764370913
4
+ data.tar.gz: 2ec1595b75cbf0d0a39345b0fa185fdb2498ca31
5
+ SHA512:
6
+ metadata.gz: 54d4b0919b64a7fbba2f200982ac3c62aab220ae9c7e7d18f7b2543c4e2122ea5c5543b24eab5eb527be2dab4bc40ade201e4bc8174448b514c0a501dd40046a
7
+ data.tar.gz: 278bdea46548a350d988f16c952e41f3c135007113ffd2c22a6ec86cb24cd95a473d33f7ce076c374f80b00f79812fbc1002ad9a02d95ba80d640e1529744dc6
data/.gitignore CHANGED
@@ -1,5 +1,5 @@
1
1
  *.gem
2
2
  .bundle
3
- Gemfile.lock
4
3
  pkg/*
5
- coverage
4
+ coverage
5
+ vendor
data/.travis.yml CHANGED
@@ -1,6 +1,5 @@
1
1
  rvm:
2
- - 1.8.7
3
- - 1.9.2
4
2
  - 1.9.3
5
- - rbx
6
- - jruby
3
+ - 2.0
4
+ - 2.1
5
+ - jruby
data/Gemfile CHANGED
@@ -1,4 +1,5 @@
1
1
  source "http://rubygems.org"
2
2
 
3
+ gem 'rails', '4.2.1'
3
4
  # Specify your gem's dependencies in firewallconstraint.gemspec
4
5
  gemspec
data/Gemfile.lock ADDED
@@ -0,0 +1,127 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ firewall_constraint (0.1.0)
5
+ ipaddress
6
+ rails (> 3.0.0, < 5.0.0)
7
+
8
+ GEM
9
+ remote: http://rubygems.org/
10
+ specs:
11
+ actionmailer (4.2.1)
12
+ actionpack (= 4.2.1)
13
+ actionview (= 4.2.1)
14
+ activejob (= 4.2.1)
15
+ mail (~> 2.5, >= 2.5.4)
16
+ rails-dom-testing (~> 1.0, >= 1.0.5)
17
+ actionpack (4.2.1)
18
+ actionview (= 4.2.1)
19
+ activesupport (= 4.2.1)
20
+ rack (~> 1.6)
21
+ rack-test (~> 0.6.2)
22
+ rails-dom-testing (~> 1.0, >= 1.0.5)
23
+ rails-html-sanitizer (~> 1.0, >= 1.0.1)
24
+ actionview (4.2.1)
25
+ activesupport (= 4.2.1)
26
+ builder (~> 3.1)
27
+ erubis (~> 2.7.0)
28
+ rails-dom-testing (~> 1.0, >= 1.0.5)
29
+ rails-html-sanitizer (~> 1.0, >= 1.0.1)
30
+ activejob (4.2.1)
31
+ activesupport (= 4.2.1)
32
+ globalid (>= 0.3.0)
33
+ activemodel (4.2.1)
34
+ activesupport (= 4.2.1)
35
+ builder (~> 3.1)
36
+ activerecord (4.2.1)
37
+ activemodel (= 4.2.1)
38
+ activesupport (= 4.2.1)
39
+ arel (~> 6.0)
40
+ activesupport (4.2.1)
41
+ i18n (~> 0.7)
42
+ json (~> 1.7, >= 1.7.7)
43
+ minitest (~> 5.1)
44
+ thread_safe (~> 0.3, >= 0.3.4)
45
+ tzinfo (~> 1.1)
46
+ arel (6.0.0)
47
+ builder (3.2.2)
48
+ diff-lcs (1.2.5)
49
+ erubis (2.7.0)
50
+ globalid (0.3.5)
51
+ activesupport (>= 4.1.0)
52
+ i18n (0.7.0)
53
+ ipaddress (0.8.0)
54
+ json (1.8.2)
55
+ loofah (2.0.2)
56
+ nokogiri (>= 1.5.9)
57
+ mail (2.6.3)
58
+ mime-types (>= 1.16, < 3)
59
+ mime-types (2.5)
60
+ mini_portile (0.6.2)
61
+ minitest (5.6.1)
62
+ nokogiri (1.6.6.2)
63
+ mini_portile (~> 0.6.0)
64
+ rack (1.6.1)
65
+ rack-test (0.6.3)
66
+ rack (>= 1.0)
67
+ rails (4.2.1)
68
+ actionmailer (= 4.2.1)
69
+ actionpack (= 4.2.1)
70
+ actionview (= 4.2.1)
71
+ activejob (= 4.2.1)
72
+ activemodel (= 4.2.1)
73
+ activerecord (= 4.2.1)
74
+ activesupport (= 4.2.1)
75
+ bundler (>= 1.3.0, < 2.0)
76
+ railties (= 4.2.1)
77
+ sprockets-rails
78
+ rails-deprecated_sanitizer (1.0.3)
79
+ activesupport (>= 4.2.0.alpha)
80
+ rails-dom-testing (1.0.6)
81
+ activesupport (>= 4.2.0.beta, < 5.0)
82
+ nokogiri (~> 1.6.0)
83
+ rails-deprecated_sanitizer (>= 1.0.1)
84
+ rails-html-sanitizer (1.0.2)
85
+ loofah (~> 2.0)
86
+ railties (4.2.1)
87
+ actionpack (= 4.2.1)
88
+ activesupport (= 4.2.1)
89
+ rake (>= 0.8.7)
90
+ thor (>= 0.18.1, < 2.0)
91
+ rake (10.4.2)
92
+ rspec-core (3.2.3)
93
+ rspec-support (~> 3.2.0)
94
+ rspec-expectations (3.2.1)
95
+ diff-lcs (>= 1.2.0, < 2.0)
96
+ rspec-support (~> 3.2.0)
97
+ rspec-mocks (3.2.1)
98
+ diff-lcs (>= 1.2.0, < 2.0)
99
+ rspec-support (~> 3.2.0)
100
+ rspec-rails (3.2.1)
101
+ actionpack (>= 3.0, < 4.3)
102
+ activesupport (>= 3.0, < 4.3)
103
+ railties (>= 3.0, < 4.3)
104
+ rspec-core (~> 3.2.0)
105
+ rspec-expectations (~> 3.2.0)
106
+ rspec-mocks (~> 3.2.0)
107
+ rspec-support (~> 3.2.0)
108
+ rspec-support (3.2.2)
109
+ sprockets (3.0.3)
110
+ rack (~> 1.0)
111
+ sprockets-rails (2.3.0)
112
+ actionpack (>= 3.0)
113
+ activesupport (>= 3.0)
114
+ sprockets (>= 2.8, < 4.0)
115
+ thor (0.19.1)
116
+ thread_safe (0.3.5)
117
+ tzinfo (1.2.2)
118
+ thread_safe (~> 0.1)
119
+
120
+ PLATFORMS
121
+ ruby
122
+
123
+ DEPENDENCIES
124
+ firewall_constraint!
125
+ rails (= 4.2.1)
126
+ rake
127
+ rspec-rails (~> 3.2.0)
data/LICENSE ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2015 Mike Auclair
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.
data/README.md CHANGED
@@ -1,7 +1,10 @@
1
1
  FirewallConstraint
2
2
  ========
3
3
 
4
- Easy whitelist firewalling for Rails 3 route constraints
4
+ [![Build Status](https://travis-ci.org/mikeauclair/firewall_constraint.svg?branch=master)](https://travis-ci.org/mikeauclair/firewall_constraint)
5
+
6
+
7
+ Easy whitelist firewalling for Rails 3+4 route constraints
5
8
 
6
9
  gem 'firewall_constraint'
7
10
 
@@ -10,16 +13,17 @@ Or:
10
13
  gem install firewall_constraint
11
14
 
12
15
  -----
16
+ ##Example
13
17
 
14
18
  config/routes.rb:
15
19
 
16
20
  get 'dummy/index' => 'dummy#index'
17
21
  get 'dummy/blocked_by_inline' => 'dummy#blocked_by_inline', :constraints => FirewallConstraint.new
18
-
22
+
19
23
  constraints FirewallConstraint.new do
20
24
  get 'dummy/blocked_by_block' => 'dummy#blocked_by_block'
21
25
  end
22
-
26
+
23
27
  constraints FirewallConstraint.new(['127.0.0.1']) do
24
28
  get 'dummy/blocked_by_dynamic' => 'dummy#blocked_by_dynamic'
25
29
  end
@@ -29,8 +33,9 @@ config/routes.rb:
29
33
  end
30
34
 
31
35
  ----
36
+ ##Configuration
32
37
 
33
- Uses a config file if ips not present in routes
38
+ Uses a config file if ips are not provided on instantiation
34
39
 
35
40
  config/firewall_constraint.yml:
36
41
 
@@ -38,7 +43,22 @@ config/firewall_constraint.yml:
38
43
  - 10.0.0.0/8
39
44
 
40
45
  ----
46
+ ##Advanced Usage
41
47
 
42
- You should be able to do DB-based whitelisting using the Proc whitelisting and an activerecord lookup or something similar to:
48
+ You can also do DB-based whitelisting using the Proc-based whitelisting method:
49
+
50
+ app/models/valid_ip.rb:
51
+
52
+ class ValidIp < ActiveRecord::Base
53
+ end
54
+
55
+ config/routes.rb:
56
+
57
+ constraints FirewallConstraint.new(Proc.new{ValidIp.pluck(:ip)}) do
58
+ get '/blah'
59
+ end
60
+
61
+ ----
62
+ ##Notes
43
63
 
44
- constraints FirewallConstraint.new(Proc.new{ValidIps.all.map{|x| x.ip}})
64
+ Because parsing IPs with the IPAddress can take some time, this gem will only reparse ips returned by the Proc method if they have changed. Make sure you return your ips in the same order to avoid unnecessary reparsing.
data/Rakefile CHANGED
@@ -1,6 +1,9 @@
1
1
  require 'bundler'
2
- require 'rspec'
3
- require 'rspec/core/rake_task'
2
+ begin
3
+ require 'rspec/core/rake_task'
4
+ rescue LoadError
5
+ end
6
+
4
7
  Bundler::GemHelper.install_tasks
5
8
 
6
9
  desc 'Default: Run specs'
@@ -28,4 +31,4 @@ end
28
31
  # desc "Run all specs with rcov"
29
32
  # RSpec::Core::RakeTask.new(:rcov => spec_prereq) do |t|
30
33
  #
31
- # end
34
+ # end
@@ -5,20 +5,20 @@ require "firewall_constraint/version"
5
5
  Gem::Specification.new do |s|
6
6
  s.name = "firewall_constraint"
7
7
  s.version = FirewallConstraint::VERSION
8
+ s.licenses = 'MIT'
8
9
  s.platform = Gem::Platform::RUBY
9
10
  s.authors = ["Mike Auclair"]
10
11
  s.email = ["mike@mikeauclair.com"]
11
12
  s.homepage = "http://github.com/mikeauclair/firewall_constraint"
12
- s.summary = %q{Rails 3 firewall route constraints}
13
- s.description = %q{Rails 3 firewall route constraints}
13
+ s.summary = %q{Rails 3+4 firewall route constraints}
14
+ s.description = %q{Rails 3+4 firewall route constraints for keeping the bad guys out.}
14
15
 
15
16
  s.rubyforge_project = "firewallconstraint"
16
17
 
17
- s.add_development_dependency(%q<rails>, ["3.2.0"])
18
- s.add_dependency(%q<rails>, ">= 3.0.0", "<3.3.0")
19
- s.add_dependency(%q<ipaddress>)
20
- s.add_development_dependency(%q<shoulda>, "~> 3.0.0")
21
- s.add_development_dependency(%q<rspec-rails>, ["~> 2.5.0"])
18
+ s.add_dependency(%q<rails>, ["> 3.0.0", "< 5.0.0"])
19
+ s.add_dependency(%q<ipaddress>, ['~> 0.8'])
20
+ s.add_development_dependency(%q<rake>, ['~> 0'])
21
+ s.add_development_dependency(%q<rspec-rails>, ["~> 3.2"])
22
22
 
23
23
  s.files = `git ls-files`.split("\n")
24
24
  s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
@@ -1,3 +1,3 @@
1
1
  module FirewallConstraint
2
- VERSION = "0.0.9"
2
+ VERSION = "0.1.0"
3
3
  end
@@ -2,7 +2,6 @@ require File.expand_path('../boot', __FILE__)
2
2
 
3
3
  require "action_controller/railtie"
4
4
  require "action_mailer/railtie"
5
- require "active_resource/railtie"
6
5
  require "rails/test_unit/railtie"
7
6
  # If you have a Gemfile, require the gems listed there, including any gems
8
7
  # you've limited to :test, :development, or :production.
@@ -1,7 +1,7 @@
1
1
  require 'rubygems'
2
2
 
3
3
  # Set up gems listed in the Gemfile.
4
- gemfile = File.expand_path('../../Gemfile', __FILE__)
4
+ gemfile = File.expand_path('../../../../Gemfile', __FILE__)
5
5
  begin
6
6
  ENV['BUNDLE_GEMFILE'] = gemfile
7
7
  require 'bundler'
@@ -11,7 +11,6 @@ RailsApp::Application.configure do
11
11
 
12
12
  # Show full error reports and disable caching
13
13
  config.consider_all_requests_local = true
14
- config.action_view.debug_rjs = true
15
14
  config.action_controller.perform_caching = false
16
15
 
17
16
  # Don't care if the mailer can't send
@@ -19,7 +19,7 @@ RailsApp::Application.configure do
19
19
 
20
20
  # Disable request forgery protection in test environment
21
21
  config.action_controller.allow_forgery_protection = false
22
-
22
+ config.eager_load = false
23
23
  # Tell Action Mailer not to deliver emails to the real world.
24
24
  # The :test delivery method accumulates sent emails in the
25
25
  # ActionMailer::Base.deliveries array.
@@ -0,0 +1,8 @@
1
+ development:
2
+ secret_key_base: 2adf83d015938c2685060afba136c6445019a4290b806f24ae053bbec784d9cd4f3ca1d3b75f3b4f6b9e26bfa29d664402bef7bcf408be76b5c91e55534aee59
3
+
4
+ test:
5
+ secret_key_base: 2adf83d015938c2685060afba136c6445019a4290b806f24ae053bbec784d9cd4f3ca1d3b75f3b4f6b9e26bfa29d664402bef7bcf408be76b5c91e55534aee59
6
+
7
+ production:
8
+ secret_key_base: <%= ENV["SECRET_KEY_BASE"] %>
@@ -1,12 +1,9 @@
1
1
  require 'spec_helper'
2
2
 
3
- describe "dummy stuff" do
4
- before(:all) do
5
-
6
- end
3
+ describe "DummyController", type: :request do
7
4
  it 'should get default action' do
8
5
  get '/dummy/index'
9
- response.should be_success
6
+ expect(response).to be_success
10
7
  end
11
8
 
12
9
  it 'should get dynamic constraint' do
@@ -14,7 +11,7 @@ describe "dummy stuff" do
14
11
  open_session do |sess|
15
12
  sess.remote_addr = '127.0.0.1'
16
13
  get '/dummy/blocked_by_dynamic'
17
- response.should be_success
14
+ expect(response).to be_success
18
15
  end
19
16
  end
20
17
 
@@ -23,7 +20,7 @@ describe "dummy stuff" do
23
20
  open_session do |sess|
24
21
  sess.remote_addr = '127.0.0.1'
25
22
  get '/dummy/blocked_by_proc'
26
- response.should be_success
23
+ expect(response).to be_success
27
24
  end
28
25
  end
29
26
 
@@ -33,7 +30,8 @@ describe "dummy stuff" do
33
30
  open_session do |sess|
34
31
  sess.remote_addr = ipv6
35
32
  get '/dummy/blocked_by_ipv6'
36
- response.should be_success
33
+ expect(response).to be_success
34
+
37
35
  end
38
36
  end
39
37
 
@@ -48,11 +46,11 @@ describe "dummy stuff" do
48
46
  end
49
47
 
50
48
  it 'should not vomit on an ipv4 rule' do
51
- lambda { get '/dummy/blocked_by_block' }.should raise_error ActionController::RoutingError
49
+ expect { get '/dummy/blocked_by_block' }.to raise_error ActionController::RoutingError
52
50
  end
53
51
 
54
52
  it 'should block on an ipv6 rule' do
55
- lambda { get '/dummy/blocked_by_ipv6'}.should raise_error ActionController::RoutingError
53
+ expect { get '/dummy/blocked_by_ipv6'}.to raise_error ActionController::RoutingError
56
54
  end
57
55
  end
58
56
 
@@ -61,7 +59,7 @@ describe "dummy stuff" do
61
59
  get root_path, nil, "REMOTE_ADDR" => ipv6
62
60
  open_session do |sess|
63
61
  sess.remote_addr = ipv6
64
- lambda {get '/dummy/blocked_by_block'}.should raise_error ActionController::RoutingError
62
+ expect {get '/dummy/blocked_by_block'}.to raise_error ActionController::RoutingError
65
63
  end
66
64
  end
67
65
 
@@ -75,13 +73,13 @@ describe "dummy stuff" do
75
73
  end
76
74
 
77
75
  it 'should get inline constraint' do
78
- get '/dummy/blocked_by_inline'
79
- response.should be_success
76
+ get '/dummy/blocked_by_inline'
77
+ expect(response).to be_success
80
78
  end
81
79
 
82
80
  it 'should get block constraint' do
83
81
  get '/dummy/blocked_by_block'
84
- response.should be_success
82
+ expect(response).to be_success
85
83
  end
86
84
  end
87
85
 
@@ -95,24 +93,24 @@ describe "dummy stuff" do
95
93
  end
96
94
 
97
95
  it 'should not vomit on an ipv4 rule' do
98
- lambda {get '/dummy/blocked_by_ipv6'}.should raise_error ActionController::RoutingError
96
+ expect {get '/dummy/blocked_by_ipv6'}.to raise_error ActionController::RoutingError
99
97
 
100
98
  end
101
99
 
102
100
  it 'should not get inline constraint' do
103
- lambda {get '/dummy/blocked_by_inline'}.should raise_error ActionController::RoutingError
101
+ expect {get '/dummy/blocked_by_inline'}.to raise_error ActionController::RoutingError
104
102
  end
105
103
 
106
104
  it 'should not get procced constraint' do
107
- lambda {get '/dummy/blocked_by_proc'}.should raise_error ActionController::RoutingError
105
+ expect {get '/dummy/blocked_by_proc'}.to raise_error ActionController::RoutingError
108
106
  end
109
107
 
110
108
  it 'should not get block constraint' do
111
- lambda{get '/dummy/blocked_by_block'}.should raise_error ActionController::RoutingError
109
+ expect{get '/dummy/blocked_by_block'}.to raise_error ActionController::RoutingError
112
110
  end
113
111
 
114
112
  it 'should not get dynamic constraint' do
115
- lambda{get '/dummy/blocked_by_dynamic'}.should raise_error ActionController::RoutingError
113
+ expect{get '/dummy/blocked_by_dynamic'}.to raise_error ActionController::RoutingError
116
114
  end
117
115
  end
118
- end
116
+ end
data/spec/spec_helper.rb CHANGED
@@ -11,4 +11,4 @@ RSpec.configure do |config|
11
11
  end
12
12
  end
13
13
 
14
- end
14
+ end
metadata CHANGED
@@ -1,128 +1,95 @@
1
- --- !ruby/object:Gem::Specification
1
+ --- !ruby/object:Gem::Specification
2
2
  name: firewall_constraint
3
- version: !ruby/object:Gem::Version
4
- hash: 13
5
- prerelease:
6
- segments:
7
- - 0
8
- - 0
9
- - 9
10
- version: 0.0.9
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.1.0
11
5
  platform: ruby
12
- authors:
6
+ authors:
13
7
  - Mike Auclair
14
8
  autorequire:
15
9
  bindir: bin
16
10
  cert_chain: []
17
-
18
- date: 2012-03-27 00:00:00 Z
19
- dependencies:
20
- - !ruby/object:Gem::Dependency
11
+ date: 2015-05-09 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
21
14
  name: rails
22
- prerelease: false
23
- requirement: &id001 !ruby/object:Gem::Requirement
24
- none: false
25
- requirements:
26
- - - "="
27
- - !ruby/object:Gem::Version
28
- hash: 15
29
- segments:
30
- - 3
31
- - 2
32
- - 0
33
- version: 3.2.0
34
- type: :development
35
- version_requirements: *id001
36
- - !ruby/object:Gem::Dependency
37
- name: rails
38
- prerelease: false
39
- requirement: &id002 !ruby/object:Gem::Requirement
40
- none: false
41
- requirements:
42
- - - ">="
43
- - !ruby/object:Gem::Version
44
- hash: 7
45
- segments:
46
- - 3
47
- - 0
48
- - 0
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">"
18
+ - !ruby/object:Gem::Version
49
19
  version: 3.0.0
50
- - - <
51
- - !ruby/object:Gem::Version
52
- hash: 11
53
- segments:
54
- - 3
55
- - 3
56
- - 0
57
- version: 3.3.0
20
+ - - "<"
21
+ - !ruby/object:Gem::Version
22
+ version: 5.0.0
58
23
  type: :runtime
59
- version_requirements: *id002
60
- - !ruby/object:Gem::Dependency
61
- name: ipaddress
62
24
  prerelease: false
63
- requirement: &id003 !ruby/object:Gem::Requirement
64
- none: false
65
- requirements:
66
- - - ">="
67
- - !ruby/object:Gem::Version
68
- hash: 3
69
- segments:
70
- - 0
71
- version: "0"
25
+ version_requirements: !ruby/object:Gem::Requirement
26
+ requirements:
27
+ - - ">"
28
+ - !ruby/object:Gem::Version
29
+ version: 3.0.0
30
+ - - "<"
31
+ - !ruby/object:Gem::Version
32
+ version: 5.0.0
33
+ - !ruby/object:Gem::Dependency
34
+ name: ipaddress
35
+ requirement: !ruby/object:Gem::Requirement
36
+ requirements:
37
+ - - "~>"
38
+ - !ruby/object:Gem::Version
39
+ version: '0.8'
72
40
  type: :runtime
73
- version_requirements: *id003
74
- - !ruby/object:Gem::Dependency
75
- name: shoulda
76
41
  prerelease: false
77
- requirement: &id004 !ruby/object:Gem::Requirement
78
- none: false
79
- requirements:
80
- - - ~>
81
- - !ruby/object:Gem::Version
82
- hash: 7
83
- segments:
84
- - 3
85
- - 0
86
- - 0
87
- version: 3.0.0
42
+ version_requirements: !ruby/object:Gem::Requirement
43
+ requirements:
44
+ - - "~>"
45
+ - !ruby/object:Gem::Version
46
+ version: '0.8'
47
+ - !ruby/object:Gem::Dependency
48
+ name: rake
49
+ requirement: !ruby/object:Gem::Requirement
50
+ requirements:
51
+ - - "~>"
52
+ - !ruby/object:Gem::Version
53
+ version: '0'
88
54
  type: :development
89
- version_requirements: *id004
90
- - !ruby/object:Gem::Dependency
91
- name: rspec-rails
92
55
  prerelease: false
93
- requirement: &id005 !ruby/object:Gem::Requirement
94
- none: false
95
- requirements:
96
- - - ~>
97
- - !ruby/object:Gem::Version
98
- hash: 27
99
- segments:
100
- - 2
101
- - 5
102
- - 0
103
- version: 2.5.0
56
+ version_requirements: !ruby/object:Gem::Requirement
57
+ requirements:
58
+ - - "~>"
59
+ - !ruby/object:Gem::Version
60
+ version: '0'
61
+ - !ruby/object:Gem::Dependency
62
+ name: rspec-rails
63
+ requirement: !ruby/object:Gem::Requirement
64
+ requirements:
65
+ - - "~>"
66
+ - !ruby/object:Gem::Version
67
+ version: '3.2'
104
68
  type: :development
105
- version_requirements: *id005
106
- description: Rails 3 firewall route constraints
107
- email:
69
+ prerelease: false
70
+ version_requirements: !ruby/object:Gem::Requirement
71
+ requirements:
72
+ - - "~>"
73
+ - !ruby/object:Gem::Version
74
+ version: '3.2'
75
+ description: Rails 3+4 firewall route constraints for keeping the bad guys out.
76
+ email:
108
77
  - mike@mikeauclair.com
109
78
  executables: []
110
-
111
79
  extensions: []
112
-
113
80
  extra_rdoc_files: []
114
-
115
- files:
116
- - .gitignore
117
- - .travis.yml
81
+ files:
82
+ - ".gitignore"
83
+ - ".travis.yml"
118
84
  - Gemfile
85
+ - Gemfile.lock
86
+ - LICENSE
119
87
  - README.md
120
88
  - Rakefile
121
89
  - firewall_constraint.gemspec
122
90
  - lib/firewall_constraint.rb
123
91
  - lib/firewall_constraint/version.rb
124
92
  - spec/rails_app/.gitignore
125
- - spec/rails_app/Gemfile
126
93
  - spec/rails_app/README
127
94
  - spec/rails_app/Rakefile
128
95
  - spec/rails_app/app/controllers/application_controller.rb
@@ -141,10 +108,10 @@ files:
141
108
  - spec/rails_app/config/initializers/backtrace_silencers.rb
142
109
  - spec/rails_app/config/initializers/inflections.rb
143
110
  - spec/rails_app/config/initializers/mime_types.rb
144
- - spec/rails_app/config/initializers/secret_token.rb
145
111
  - spec/rails_app/config/initializers/session_store.rb
146
112
  - spec/rails_app/config/locales/en.yml
147
113
  - spec/rails_app/config/routes.rb
114
+ - spec/rails_app/config/secrets.yml
148
115
  - spec/rails_app/db/seeds.rb
149
116
  - spec/rails_app/doc/README_FOR_APP
150
117
  - spec/rails_app/lib/tasks/.gitkeep
@@ -169,41 +136,31 @@ files:
169
136
  - spec/requests/dummy_controller_spec.rb
170
137
  - spec/spec_helper.rb
171
138
  homepage: http://github.com/mikeauclair/firewall_constraint
172
- licenses: []
173
-
139
+ licenses:
140
+ - MIT
141
+ metadata: {}
174
142
  post_install_message:
175
143
  rdoc_options: []
176
-
177
- require_paths:
144
+ require_paths:
178
145
  - lib
179
- required_ruby_version: !ruby/object:Gem::Requirement
180
- none: false
181
- requirements:
146
+ required_ruby_version: !ruby/object:Gem::Requirement
147
+ requirements:
182
148
  - - ">="
183
- - !ruby/object:Gem::Version
184
- hash: 3
185
- segments:
186
- - 0
187
- version: "0"
188
- required_rubygems_version: !ruby/object:Gem::Requirement
189
- none: false
190
- requirements:
149
+ - !ruby/object:Gem::Version
150
+ version: '0'
151
+ required_rubygems_version: !ruby/object:Gem::Requirement
152
+ requirements:
191
153
  - - ">="
192
- - !ruby/object:Gem::Version
193
- hash: 3
194
- segments:
195
- - 0
196
- version: "0"
154
+ - !ruby/object:Gem::Version
155
+ version: '0'
197
156
  requirements: []
198
-
199
157
  rubyforge_project: firewallconstraint
200
- rubygems_version: 1.8.11
158
+ rubygems_version: 2.2.2
201
159
  signing_key:
202
- specification_version: 3
203
- summary: Rails 3 firewall route constraints
204
- test_files:
160
+ specification_version: 4
161
+ summary: Rails 3+4 firewall route constraints
162
+ test_files:
205
163
  - spec/rails_app/.gitignore
206
- - spec/rails_app/Gemfile
207
164
  - spec/rails_app/README
208
165
  - spec/rails_app/Rakefile
209
166
  - spec/rails_app/app/controllers/application_controller.rb
@@ -222,10 +179,10 @@ test_files:
222
179
  - spec/rails_app/config/initializers/backtrace_silencers.rb
223
180
  - spec/rails_app/config/initializers/inflections.rb
224
181
  - spec/rails_app/config/initializers/mime_types.rb
225
- - spec/rails_app/config/initializers/secret_token.rb
226
182
  - spec/rails_app/config/initializers/session_store.rb
227
183
  - spec/rails_app/config/locales/en.yml
228
184
  - spec/rails_app/config/routes.rb
185
+ - spec/rails_app/config/secrets.yml
229
186
  - spec/rails_app/db/seeds.rb
230
187
  - spec/rails_app/doc/README_FOR_APP
231
188
  - spec/rails_app/lib/tasks/.gitkeep
@@ -249,4 +206,3 @@ test_files:
249
206
  - spec/rails_app/vendor/plugins/.gitkeep
250
207
  - spec/requests/dummy_controller_spec.rb
251
208
  - spec/spec_helper.rb
252
- has_rdoc:
@@ -1,30 +0,0 @@
1
- source 'http://rubygems.org'
2
-
3
- gem 'rails', '3.2.0'
4
-
5
- # Bundle edge Rails instead:
6
- # gem 'rails', :git => 'git://github.com/rails/rails.git'
7
-
8
- # gem 'sqlite3-ruby', :require => 'sqlite3'
9
-
10
- # Use unicorn as the web server
11
- # gem 'unicorn'
12
-
13
- # Deploy with Capistrano
14
- # gem 'capistrano'
15
-
16
- # To use debugger
17
- # gem 'ruby-debug'
18
-
19
- # Bundle the extra gems:
20
- # gem 'bj'
21
- # gem 'nokogiri'
22
- # gem 'sqlite3-ruby', :require => 'sqlite3'
23
- # gem 'aws-s3', :require => 'aws/s3'
24
-
25
- # Bundle gems for the local environment. Make sure to
26
- # put test-only gems in this group so their generators
27
- # and rake tasks are available in development mode:
28
- # group :development, :test do
29
- # gem 'webrat'
30
- # end
@@ -1,7 +0,0 @@
1
- # Be sure to restart your server when you modify this file.
2
-
3
- # Your secret key for verifying the integrity of signed cookies.
4
- # If you change this key, all old signed cookies will become invalid!
5
- # Make sure the secret is at least 30 characters and all random,
6
- # no regular words or you'll be exposed to dictionary attacks.
7
- RailsApp::Application.config.secret_token = '74bf2795e4dd05a1af91fb30451eabb561e4a95f9b9db076aa0f0e22b31f191369e4cd6fd761cff8eb6420951b5cf153dae080c822f99bb6bb229013c84f99c8'