rack-ip-authorizer 0.0.1 → 0.0.2

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.
checksums.yaml CHANGED
@@ -1,7 +1,15 @@
1
1
  ---
2
- SHA1:
3
- metadata.gz: 993db83818bbc2e86eea1a34d2e7cc95df985c54
4
- data.tar.gz: f2fc88991a8a11152171af536ec2ec4c29b35912
5
- SHA512:
6
- metadata.gz: 45726c05a235d93659029324833ecac8bbc5fffdf8ee66e9a6c7525e06c28fd724cc1fba81cb61d2e2dde7bb2dfbecff1586752561f6717108160554630b04cb
7
- data.tar.gz: bcc60a36e4e451cbf53fcaf54f28bad1f27ab47dbe799cc06b5c48df9b3935e6d096568f45b1a7a1a3ec15a97ee32521baee8647226e1197388c6e3a52739a1a
2
+ !binary "U0hBMQ==":
3
+ metadata.gz: !binary |-
4
+ NGI3ZjFkZWVhZmI3NTE1YzAzZDhkOWU2NmE5ODdkMzY4NWNhODBlNA==
5
+ data.tar.gz: !binary |-
6
+ Y2VjMjFkNWQwOTg5MmNlZmE3N2Y5NjQ1NjgwZjkxYjNhMTQ4ZjQ0Ng==
7
+ !binary "U0hBNTEy":
8
+ metadata.gz: !binary |-
9
+ NWZiYmVlZjUzM2JjYTY5ZWY1NjMwMDkwNzA3ZGMyZjA4YjEwYmY1OWM5NmFi
10
+ MTljNmNhODRlMzlmOTg4ZDdjMTRkZjAzODdiY2MyYWEyMGEwMjZlNDFhMTcz
11
+ MTM0Nzc5NDhmNWRmOTUyZTQ5Nzc0OTU4MDMzOGRjMGM0MjdhMjQ=
12
+ data.tar.gz: !binary |-
13
+ MzZmY2MyY2Y5NGJhMDI4NmM1NzYxNWFjMDNhMzIyMDRmZDdmNDlhZDBkNzJh
14
+ NDRhNjk5MzU0YWRmNzc3MzQwNzgzZTJkZDU0MWRmNGI1NDA2ZmMzZGNhNDY3
15
+ MjFiZmRkZWU2ZDBmNmFlMzI3Y2NhZWY0NGJlZGYxZGIwMmExYjg=
data/README.md CHANGED
@@ -1,6 +1,6 @@
1
1
  # Rack::Ip::Authorizer
2
2
 
3
- Basic Rack middleware for checking Rails3 request remote IP
3
+ Basic Rack middleware for Rails 3 to authorize access to path by IP
4
4
 
5
5
  ## Installation
6
6
 
@@ -20,8 +20,8 @@ Or install it yourself as:
20
20
 
21
21
  ### Rails 3 apps
22
22
 
23
- 1. Create a file named "ip_authorizations.yml" in the config directory
24
- 2. Fill it with key as path and values as IPs:
23
+ 1. Create a file named "ip_authorizations.yml" in config directory
24
+ 2. Fill it with paths (keys) and IPs (values) see example below
25
25
 
26
26
  ```yaml
27
27
  admin:
@@ -33,18 +33,20 @@ superadmin:
33
33
  - 192.168.0.2
34
34
  ```
35
35
 
36
- Environment filter
36
+ ### Environment filter
37
37
 
38
- Create an initializer and fill it with:
38
+ Create an initializer and add:
39
39
 
40
40
  ```ruby
41
41
  Rack::IpAuthorizer.env_to_check = ['staging','development']
42
42
  ```
43
43
 
44
+ Based on the file names in 'config/environments' you can use any of them including Rails defaults.
45
+
44
46
  ## Contributing
45
47
 
46
48
  1. Fork it
47
49
  2. Create your feature branch
48
50
  3. Commit your changes
49
51
  4. Push to the branch
50
- 5. Create new Pull Request
52
+ 5. Create new Pull Request
@@ -36,4 +36,4 @@ module Rack
36
36
  end
37
37
 
38
38
  end
39
- end
39
+ end
data/lib/rack/version.rb CHANGED
@@ -1,3 +1,3 @@
1
1
  module RackIpAuthorizer
2
- VERSION = "0.0.1"
3
- end
2
+ VERSION = "0.0.2"
3
+ end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: rack-ip-authorizer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.1
4
+ version: 0.0.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Thibault El Zamek, Cédric Darné, Lionel Oto
@@ -14,14 +14,14 @@ dependencies:
14
14
  name: rack
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - '>='
17
+ - - ! '>='
18
18
  - !ruby/object:Gem::Version
19
19
  version: '1.0'
20
20
  type: :runtime
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - '>='
24
+ - - ! '>='
25
25
  - !ruby/object:Gem::Version
26
26
  version: '1.0'
27
27
  - !ruby/object:Gem::Dependency
@@ -42,14 +42,14 @@ dependencies:
42
42
  name: rake
43
43
  requirement: !ruby/object:Gem::Requirement
44
44
  requirements:
45
- - - '>='
45
+ - - ! '>='
46
46
  - !ruby/object:Gem::Version
47
47
  version: '1.0'
48
48
  type: :development
49
49
  prerelease: false
50
50
  version_requirements: !ruby/object:Gem::Requirement
51
51
  requirements:
52
- - - '>='
52
+ - - ! '>='
53
53
  - !ruby/object:Gem::Version
54
54
  version: '1.0'
55
55
  - !ruby/object:Gem::Dependency
@@ -66,7 +66,7 @@ dependencies:
66
66
  - - ~>
67
67
  - !ruby/object:Gem::Version
68
68
  version: 0.6.2
69
- description: Basic Rack middleware for checking Rails3 request remote ip
69
+ description: Basic Rack middleware for Rails 3 to authorize access to path by IP
70
70
  email:
71
71
  - thibault.elzamek@c4mprod.com, cedric.darne@c4mprod.com, lionel.oto@c4mprod.com
72
72
  executables: []
@@ -75,11 +75,11 @@ extra_rdoc_files: []
75
75
  files:
76
76
  - LICENSE.txt
77
77
  - README.md
78
- - lib/rack/version.rb
79
78
  - lib/rack/ip_authorizer.rb
79
+ - lib/rack/version.rb
80
80
  - lib/rack-ip-authorizer.rb
81
81
  - spec/rake_ip_authorizer_spec.rb
82
- homepage: ''
82
+ homepage: https://github.com/c4mprod/rack-ip-authorizer
83
83
  licenses:
84
84
  - MIT
85
85
  metadata: {}
@@ -89,19 +89,20 @@ require_paths:
89
89
  - lib
90
90
  required_ruby_version: !ruby/object:Gem::Requirement
91
91
  requirements:
92
- - - '>='
92
+ - - ! '>='
93
93
  - !ruby/object:Gem::Version
94
94
  version: '0'
95
95
  required_rubygems_version: !ruby/object:Gem::Requirement
96
96
  requirements:
97
- - - '>='
97
+ - - ! '>='
98
98
  - !ruby/object:Gem::Version
99
99
  version: '0'
100
100
  requirements: []
101
101
  rubyforge_project:
102
- rubygems_version: 2.1.11
102
+ rubygems_version: 2.0.8
103
103
  signing_key:
104
104
  specification_version: 4
105
- summary: Basic Rack middleware for checking Rails3 request remote ip
105
+ summary: Basic Rack middleware for Rails 3 to authorize access to path by IP using
106
+ YML config file
106
107
  test_files:
107
108
  - spec/rake_ip_authorizer_spec.rb