resource_allow_header 0.2.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
+ SHA256:
3
+ metadata.gz: 137762279a09a5f2e409e209f7d21a13fc7e6de0a25e0f0eb0ab008990cddfcf
4
+ data.tar.gz: 8b38a2caac86462ed31294fd4fe5dc6f6196d4da839b158435e76372809b8ffb
5
+ SHA512:
6
+ metadata.gz: 9249deb003a4b6efd6087b5e1d499a8e3201efa4fbef0d9d4e8b34e3cd47a78d6b4868db4a7da5c38ad014232346260fe86ce77a03f9897d406ba1923b32daeb
7
+ data.tar.gz: 875e2f1c39afbbe8d7bd424bf36cee6ddf1dbe4c4359a3b2797009855cc9ef685cdfc2a2fd729386eb276d49a9e893b1e17f8fb3016f187617a861688a7e903c
data/.gitignore ADDED
@@ -0,0 +1,12 @@
1
+ /.bundle/
2
+ /.yardoc
3
+ /_yardoc/
4
+ /coverage/
5
+ /doc/
6
+ /pkg/
7
+ /spec/reports/
8
+ /tmp/
9
+
10
+ .idea/workspace.xml
11
+ .idea/usage.statistics.xml
12
+ .idea/tasks.xml
@@ -0,0 +1,6 @@
1
+ <component name="InspectionProjectProfileManager">
2
+ <profile version="1.0">
3
+ <option name="myName" value="Project Default" />
4
+ <inspection_tool class="Rubocop" enabled="false" level="WARNING" enabled_by_default="false" />
5
+ </profile>
6
+ </component>
data/.idea/misc.xml ADDED
@@ -0,0 +1,7 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="JavaScriptSettings">
4
+ <option name="languageLevel" value="ES6" />
5
+ </component>
6
+ <component name="ProjectRootManager" version="2" project-jdk-name="ruby-2.4.4-p296" project-jdk-type="RUBY_SDK" />
7
+ </project>
data/.idea/modules.xml ADDED
@@ -0,0 +1,8 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="ProjectModuleManager">
4
+ <modules>
5
+ <module fileurl="file://$PROJECT_DIR$/.idea/resource_allow_header.iml" filepath="$PROJECT_DIR$/.idea/resource_allow_header.iml" />
6
+ </modules>
7
+ </component>
8
+ </project>
@@ -0,0 +1,23 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <module type="RUBY_MODULE" version="4">
3
+ <component name="ModuleRunConfigurationManager">
4
+ <shared />
5
+ </component>
6
+ <component name="NewModuleRootManager">
7
+ <content url="file://$MODULE_DIR$" />
8
+ <orderEntry type="jdk" jdkName="ruby-2.5.3-p105" jdkType="RUBY_SDK" />
9
+ <orderEntry type="sourceFolder" forTests="false" />
10
+ <orderEntry type="library" scope="PROVIDED" name="activemodel (v5.2.2, ruby-2.5.3-p105) [gem]" level="application" />
11
+ <orderEntry type="library" scope="PROVIDED" name="activerecord (v5.2.2, ruby-2.5.3-p105) [gem]" level="application" />
12
+ <orderEntry type="library" scope="PROVIDED" name="activesupport (v5.2.2, ruby-2.5.3-p105) [gem]" level="application" />
13
+ <orderEntry type="library" scope="PROVIDED" name="arel (v9.0.0, ruby-2.5.3-p105) [gem]" level="application" />
14
+ <orderEntry type="library" scope="PROVIDED" name="bundler (v2.0.1, ruby-2.5.3-p105) [gem]" level="application" />
15
+ <orderEntry type="library" scope="PROVIDED" name="concurrent-ruby (v1.1.4, ruby-2.5.3-p105) [gem]" level="application" />
16
+ <orderEntry type="library" scope="PROVIDED" name="i18n (v1.5.3, ruby-2.5.3-p105) [gem]" level="application" />
17
+ <orderEntry type="library" scope="PROVIDED" name="minitest (v5.11.3, ruby-2.5.3-p105) [gem]" level="application" />
18
+ <orderEntry type="library" scope="PROVIDED" name="rack (v2.0.6, ruby-2.5.3-p105) [gem]" level="application" />
19
+ <orderEntry type="library" scope="PROVIDED" name="rake (v10.5.0, ruby-2.5.3-p105) [gem]" level="application" />
20
+ <orderEntry type="library" scope="PROVIDED" name="thread_safe (v0.3.6, ruby-2.5.3-p105) [gem]" level="application" />
21
+ <orderEntry type="library" scope="PROVIDED" name="tzinfo (v1.2.5, ruby-2.5.3-p105) [gem]" level="application" />
22
+ </component>
23
+ </module>
data/.idea/vcs.xml ADDED
@@ -0,0 +1,6 @@
1
+ <?xml version="1.0" encoding="UTF-8"?>
2
+ <project version="4">
3
+ <component name="VcsDirectoryMappings">
4
+ <mapping directory="$PROJECT_DIR$" vcs="Git" />
5
+ </component>
6
+ </project>
data/.travis.yml ADDED
@@ -0,0 +1,17 @@
1
+ ---
2
+ sudo: false
3
+ language: ruby
4
+ cache: bundler
5
+ rvm:
6
+ - 2.5
7
+ - 2.6
8
+ - ruby-head
9
+ before_install:
10
+ - gem install bundler -v 2.0.1
11
+ - gem update --system
12
+ - gem --version
13
+ matrix:
14
+ allow_failures:
15
+ - rvm: ruby-head
16
+ install:
17
+ - bundle install --with development --jobs=3 --retry=3 --path=${BUNDLE_PATH:-vendor/bundle}
data/CHANGELOG.md ADDED
@@ -0,0 +1,9 @@
1
+ # Changelog
2
+
3
+ ## 0.2.0
4
+
5
+ - Add configuration via `ResourceAllowHeader.configure`
6
+
7
+ ## 0.1.0
8
+
9
+ :baby: Initial version
@@ -0,0 +1,74 @@
1
+ # Contributor Covenant Code of Conduct
2
+
3
+ ## Our Pledge
4
+
5
+ In the interest of fostering an open and welcoming environment, we as
6
+ contributors and maintainers pledge to making participation in our project and
7
+ our community a harassment-free experience for everyone, regardless of age, body
8
+ size, disability, ethnicity, gender identity and expression, level of experience,
9
+ nationality, personal appearance, race, religion, or sexual identity and
10
+ orientation.
11
+
12
+ ## Our Standards
13
+
14
+ Examples of behavior that contributes to creating a positive environment
15
+ include:
16
+
17
+ * Using welcoming and inclusive language
18
+ * Being respectful of differing viewpoints and experiences
19
+ * Gracefully accepting constructive criticism
20
+ * Focusing on what is best for the community
21
+ * Showing empathy towards other community members
22
+
23
+ Examples of unacceptable behavior by participants include:
24
+
25
+ * The use of sexualized language or imagery and unwelcome sexual attention or
26
+ advances
27
+ * Trolling, insulting/derogatory comments, and personal or political attacks
28
+ * Public or private harassment
29
+ * Publishing others' private information, such as a physical or electronic
30
+ address, without explicit permission
31
+ * Other conduct which could reasonably be considered inappropriate in a
32
+ professional setting
33
+
34
+ ## Our Responsibilities
35
+
36
+ Project maintainers are responsible for clarifying the standards of acceptable
37
+ behavior and are expected to take appropriate and fair corrective action in
38
+ response to any instances of unacceptable behavior.
39
+
40
+ Project maintainers have the right and responsibility to remove, edit, or
41
+ reject comments, commits, code, wiki edits, issues, and other contributions
42
+ that are not aligned to this Code of Conduct, or to ban temporarily or
43
+ permanently any contributor for other behaviors that they deem inappropriate,
44
+ threatening, offensive, or harmful.
45
+
46
+ ## Scope
47
+
48
+ This Code of Conduct applies both within project spaces and in public spaces
49
+ when an individual is representing the project or its community. Examples of
50
+ representing a project or community include using an official project e-mail
51
+ address, posting via an official social media account, or acting as an appointed
52
+ representative at an online or offline event. Representation of a project may be
53
+ further defined and clarified by project maintainers.
54
+
55
+ ## Enforcement
56
+
57
+ Instances of abusive, harassing, or otherwise unacceptable behavior may be
58
+ reported by contacting the project team at derk-jan+github@karrenbeld.info. All
59
+ complaints will be reviewed and investigated and will result in a response that
60
+ is deemed necessary and appropriate to the circumstances. The project team is
61
+ obligated to maintain confidentiality with regard to the reporter of an incident.
62
+ Further details of specific enforcement policies may be posted separately.
63
+
64
+ Project maintainers who do not follow or enforce the Code of Conduct in good
65
+ faith may face temporary or permanent repercussions as determined by other
66
+ members of the project's leadership.
67
+
68
+ ## Attribution
69
+
70
+ This Code of Conduct is adapted from the [Contributor Covenant][homepage], version 1.4,
71
+ available at [http://contributor-covenant.org/version/1/4][version]
72
+
73
+ [homepage]: http://contributor-covenant.org
74
+ [version]: http://contributor-covenant.org/version/1/4/
data/Gemfile ADDED
@@ -0,0 +1,4 @@
1
+ source "https://rubygems.org"
2
+
3
+ # Specify your gem's dependencies in resource_allow_header.gemspec
4
+ gemspec
data/Gemfile.lock ADDED
@@ -0,0 +1,43 @@
1
+ PATH
2
+ remote: .
3
+ specs:
4
+ resource_allow_header (0.2.0)
5
+ activerecord (>= 4.0.0)
6
+ activesupport (>= 4.0.0)
7
+
8
+ GEM
9
+ remote: https://rubygems.org/
10
+ specs:
11
+ activemodel (5.2.2)
12
+ activesupport (= 5.2.2)
13
+ activerecord (5.2.2)
14
+ activemodel (= 5.2.2)
15
+ activesupport (= 5.2.2)
16
+ arel (>= 9.0)
17
+ activesupport (5.2.2)
18
+ concurrent-ruby (~> 1.0, >= 1.0.2)
19
+ i18n (>= 0.7, < 2)
20
+ minitest (~> 5.1)
21
+ tzinfo (~> 1.1)
22
+ arel (9.0.0)
23
+ concurrent-ruby (1.1.4)
24
+ i18n (1.5.3)
25
+ concurrent-ruby (~> 1.0)
26
+ minitest (5.11.3)
27
+ rake (10.5.0)
28
+ thread_safe (0.3.6)
29
+ tzinfo (1.2.5)
30
+ thread_safe (~> 0.1)
31
+
32
+ PLATFORMS
33
+ ruby
34
+ x64-mingw32
35
+
36
+ DEPENDENCIES
37
+ bundler (~> 2.0)
38
+ minitest (~> 5.0)
39
+ rake (~> 10.0)
40
+ resource_allow_header!
41
+
42
+ BUNDLED WITH
43
+ 2.0.1
data/LICENSE.txt ADDED
@@ -0,0 +1,21 @@
1
+ The MIT License (MIT)
2
+
3
+ Copyright (c) 2019 Derk-Jan Karrenbeld
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
13
+ all 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
21
+ THE SOFTWARE.
data/README.md ADDED
@@ -0,0 +1,72 @@
1
+ # Resource Allow Header
2
+
3
+ [![Build Status: master](https://travis-ci.com/XPBytes/resource_allow_header.svg)](https://travis-ci.com/XPBytes/resource_allow_header)
4
+ [![Gem Version](https://badge.fury.io/rb/resource_allow_header.svg)](https://badge.fury.io/rb/resource_allow_header)
5
+ [![MIT license](http://img.shields.io/badge/license-MIT-brightgreen.svg)](http://opensource.org/licenses/MIT)
6
+
7
+ CanCan supported Allow Header for Rack responses
8
+
9
+ ## Installation
10
+
11
+ Add this line to your application's Gemfile:
12
+
13
+ ```ruby
14
+ gem 'resource_allow_header'
15
+ ```
16
+
17
+ And then execute:
18
+
19
+ $ bundle
20
+
21
+ Or install it yourself as:
22
+
23
+ $ gem install resource_allow_header
24
+
25
+ ## Usage
26
+
27
+ In your controller use the `allow` class method to determine the value of the `Allow` header:
28
+ ```ruby
29
+ require 'resource_allow_header'
30
+
31
+ class BookController < ApiController
32
+ allow('HEAD', only: %i[show]) { @book }
33
+ allow('GET', only: %i[show]) { @book }
34
+ allow('POST', only: %i[create]) { Current.author.books.build }
35
+ end
36
+ ```
37
+
38
+ The allow method expects:
39
+ - `http_method`: One of `HEAD`, `GET`, `POST`, `PUT`, `PATCH`, `DELETE`.
40
+ - `ability_action` (optional): Automatically mapped from HTTP method and passed to `can?`
41
+ - `**options`: passed to `before_action` (so only set these values on show: `only: :show`)
42
+ - `&block`: the block that resolved the resource
43
+
44
+ If no block has been given, the `@allow_resource` instance variable is used, or the `@resource` variable.
45
+
46
+ The allow header is set as `after_action` callback, which allows your entire request to determine or set the
47
+ values you'll be returning in the `&block` passed to `allow`. In other words: these blocks are lazy and
48
+ executed in the context of your controller _instance_.
49
+
50
+ ### Configuration
51
+
52
+ In an initializer you can set procs in order to change the default behaviour:
53
+
54
+ ```ruby
55
+ ResourceAllowHeader.configure do |this|
56
+ this.implicit_resource_proc = proc { |controller| controller.resource }
57
+ this.can_proc = proc { |action, resource, controller| action == :whatever || controller.can?(action, resource) }
58
+ end
59
+ ```
60
+
61
+ ## Development
62
+
63
+ After checking out the repo, run `bin/setup` to install dependencies. Then, run `rake test` to run the tests. You can
64
+ also run `bin/console` for an interactive prompt that will allow you to experiment.
65
+
66
+ To install this gem onto your local machine, run `bundle exec rake install`. To release a new version, update the
67
+ version number in `version.rb`, and then run `bundle exec rake release`, which will create a git tag for the version,
68
+ push git commits and tags, and push the `.gem` file to [rubygems.org](https://rubygems.org).
69
+
70
+ ## Contributing
71
+
72
+ Bug reports and pull requests are welcome on GitHub at [XPBytes/resource_allow_header](https://github.com/XPBytes/resource_allow_header).
data/Rakefile ADDED
@@ -0,0 +1,10 @@
1
+ require "bundler/gem_tasks"
2
+ require "rake/testtask"
3
+
4
+ Rake::TestTask.new(:test) do |t|
5
+ t.libs << "test"
6
+ t.libs << "lib"
7
+ t.test_files = FileList["test/**/*_test.rb"]
8
+ end
9
+
10
+ task :default => :test
data/bin/console ADDED
@@ -0,0 +1,14 @@
1
+ #!/usr/bin/env ruby
2
+
3
+ require "bundler/setup"
4
+ require "resource_allow_header"
5
+
6
+ # You can add fixtures and/or initialization code here to make experimenting
7
+ # with your gem easier. You can also use a different console, if you like.
8
+
9
+ # (If you use this, don't forget to add pry to your Gemfile!)
10
+ # require "pry"
11
+ # Pry.start
12
+
13
+ require "irb"
14
+ IRB.start(__FILE__)
data/bin/setup ADDED
@@ -0,0 +1,8 @@
1
+ #!/usr/bin/env bash
2
+ set -euo pipefail
3
+ IFS=$'\n\t'
4
+ set -vx
5
+
6
+ bundle install
7
+
8
+ # Do any other automated setup that you need to do here
@@ -0,0 +1,3 @@
1
+ module ResourceAllowHeader
2
+ VERSION = "0.2.0"
3
+ end
@@ -0,0 +1,72 @@
1
+ require "resource_allow_header/version"
2
+ require 'active_support/concern'
3
+ require 'active_support/core_ext/module/attribute_accessors'
4
+
5
+ module ResourceAllowHeader
6
+ class Error < StandardError; end
7
+
8
+ extend ActiveSupport::Concern
9
+ protected
10
+
11
+ HEADER_ALLOW = 'Allow'
12
+
13
+ mattr_accessor :implicit_resource_proc, :can_proc
14
+
15
+ def self.configure
16
+ yield self
17
+ end
18
+
19
+ included do
20
+ attr_accessor :allow_
21
+ after_action :set_allow_header
22
+
23
+ def set_allow_header
24
+ response.header[HEADER_ALLOW] = compute_allow_header.join(', ')
25
+ end
26
+
27
+ def compute_allow_header(resource: implicit_resource)
28
+ Hash(allow_).each_with_object([]) do |(method, allow), result|
29
+ allowable_resource = allow[:resource]&.call || resource
30
+ next unless allow?(allow[:action], allowable_resource)
31
+ result << method
32
+ end
33
+ end
34
+ end
35
+
36
+ class_methods do
37
+ # noinspection RubyStringKeysInHashInspection
38
+ HTTP_ABILITY_METHOD_MAP = {
39
+ 'HEAD' => :show,
40
+ 'GET' => :show,
41
+ 'POST' => :create,
42
+ 'PUT' => :update,
43
+ 'PATCH' => :update,
44
+ 'DELETE' => :destroy
45
+ }.freeze
46
+
47
+ def allow(http_method, ability_action = map_http_method_to_ability_action(http_method), **options, &block)
48
+ before_action(**options) do
49
+ allow_resource = block_given? && proc { instance_exec(&block) } || nil
50
+ self.allow_ = Hash(allow_).merge(http_method => { resource: allow_resource, action: ability_action })
51
+ end
52
+ end
53
+
54
+ def map_http_method_to_ability_action(http_method)
55
+ HTTP_ABILITY_METHOD_MAP[http_method]
56
+ end
57
+ end
58
+
59
+ private
60
+
61
+ def implicit_resource
62
+ implicit_resource_proc&.call(self) || @allow_resource || @resource
63
+ end
64
+
65
+ def allow?(action, resource)
66
+ if can_proc.respond_to?(:call)
67
+ return can_proc(action, resource, self)
68
+ end
69
+
70
+ can?(allow[:action], allow[:resource]&.call || resource)
71
+ end
72
+ end
@@ -0,0 +1,44 @@
1
+
2
+ lib = File.expand_path("../lib", __FILE__)
3
+ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
+ require "resource_allow_header/version"
5
+
6
+ Gem::Specification.new do |spec|
7
+ spec.name = "resource_allow_header"
8
+ spec.version = ResourceAllowHeader::VERSION
9
+ spec.authors = ["Derk-Jan Karrenbeld"]
10
+ spec.email = ["derk-jan@xpbytes.com"]
11
+
12
+ spec.summary = 'CanCan supported Allow Header for Rack responses'
13
+ spec.homepage = 'https://github.com/XPBytes/resource_allow_header'
14
+ spec.license = 'MIT'
15
+
16
+ # Prevent pushing this gem to RubyGems.org. To allow pushes either set the 'allowed_push_host'
17
+ # to allow pushing to a single host or delete this section to allow pushing to any host.
18
+ if spec.respond_to?(:metadata)
19
+ # spec.metadata["allowed_push_host"] = "TODO: Set to 'http://mygemserver.com'"
20
+
21
+ spec.metadata["homepage_uri"] = spec.homepage
22
+ spec.metadata["source_code_uri"] = spec.homepage
23
+ spec.metadata["changelog_uri"] = spec.homepage + '/CHANGELOG.md'
24
+ else
25
+ raise "RubyGems 2.0 or newer is required to protect against " \
26
+ "public gem pushes."
27
+ end
28
+
29
+ # Specify which files should be added to the gem when it is released.
30
+ # The `git ls-files -z` loads the files in the RubyGem that have been added into git.
31
+ spec.files = Dir.chdir(File.expand_path('..', __FILE__)) do
32
+ `git ls-files -z`.split("\x0").reject { |f| f.match(%r{^(test|spec|features)/}) }
33
+ end
34
+ spec.bindir = "exe"
35
+ spec.executables = spec.files.grep(%r{^exe/}) { |f| File.basename(f) }
36
+ spec.require_paths = ["lib"]
37
+
38
+ spec.add_dependency 'activesupport', '>= 4.0.0'
39
+ spec.add_dependency 'activerecord', '>= 4.0.0'
40
+
41
+ spec.add_development_dependency 'bundler', "~> 2.0"
42
+ spec.add_development_dependency 'rake', "~> 10.0"
43
+ spec.add_development_dependency 'minitest', "~> 5.0"
44
+ end
metadata ADDED
@@ -0,0 +1,136 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: resource_allow_header
3
+ version: !ruby/object:Gem::Version
4
+ version: 0.2.0
5
+ platform: ruby
6
+ authors:
7
+ - Derk-Jan Karrenbeld
8
+ autorequire:
9
+ bindir: exe
10
+ cert_chain: []
11
+ date: 2019-02-14 00:00:00.000000000 Z
12
+ dependencies:
13
+ - !ruby/object:Gem::Dependency
14
+ name: activesupport
15
+ requirement: !ruby/object:Gem::Requirement
16
+ requirements:
17
+ - - ">="
18
+ - !ruby/object:Gem::Version
19
+ version: 4.0.0
20
+ type: :runtime
21
+ prerelease: false
22
+ version_requirements: !ruby/object:Gem::Requirement
23
+ requirements:
24
+ - - ">="
25
+ - !ruby/object:Gem::Version
26
+ version: 4.0.0
27
+ - !ruby/object:Gem::Dependency
28
+ name: activerecord
29
+ requirement: !ruby/object:Gem::Requirement
30
+ requirements:
31
+ - - ">="
32
+ - !ruby/object:Gem::Version
33
+ version: 4.0.0
34
+ type: :runtime
35
+ prerelease: false
36
+ version_requirements: !ruby/object:Gem::Requirement
37
+ requirements:
38
+ - - ">="
39
+ - !ruby/object:Gem::Version
40
+ version: 4.0.0
41
+ - !ruby/object:Gem::Dependency
42
+ name: bundler
43
+ requirement: !ruby/object:Gem::Requirement
44
+ requirements:
45
+ - - "~>"
46
+ - !ruby/object:Gem::Version
47
+ version: '2.0'
48
+ type: :development
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - "~>"
53
+ - !ruby/object:Gem::Version
54
+ version: '2.0'
55
+ - !ruby/object:Gem::Dependency
56
+ name: rake
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "~>"
60
+ - !ruby/object:Gem::Version
61
+ version: '10.0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - "~>"
67
+ - !ruby/object:Gem::Version
68
+ version: '10.0'
69
+ - !ruby/object:Gem::Dependency
70
+ name: minitest
71
+ requirement: !ruby/object:Gem::Requirement
72
+ requirements:
73
+ - - "~>"
74
+ - !ruby/object:Gem::Version
75
+ version: '5.0'
76
+ type: :development
77
+ prerelease: false
78
+ version_requirements: !ruby/object:Gem::Requirement
79
+ requirements:
80
+ - - "~>"
81
+ - !ruby/object:Gem::Version
82
+ version: '5.0'
83
+ description:
84
+ email:
85
+ - derk-jan@xpbytes.com
86
+ executables: []
87
+ extensions: []
88
+ extra_rdoc_files: []
89
+ files:
90
+ - ".gitignore"
91
+ - ".idea/inspectionProfiles/Project_Default.xml"
92
+ - ".idea/misc.xml"
93
+ - ".idea/modules.xml"
94
+ - ".idea/resource_allow_header.iml"
95
+ - ".idea/vcs.xml"
96
+ - ".travis.yml"
97
+ - CHANGELOG.md
98
+ - CODE_OF_CONDUCT.md
99
+ - Gemfile
100
+ - Gemfile.lock
101
+ - LICENSE.txt
102
+ - README.md
103
+ - Rakefile
104
+ - bin/console
105
+ - bin/setup
106
+ - lib/resource_allow_header.rb
107
+ - lib/resource_allow_header/version.rb
108
+ - resource_allow_header.gemspec
109
+ homepage: https://github.com/XPBytes/resource_allow_header
110
+ licenses:
111
+ - MIT
112
+ metadata:
113
+ homepage_uri: https://github.com/XPBytes/resource_allow_header
114
+ source_code_uri: https://github.com/XPBytes/resource_allow_header
115
+ changelog_uri: https://github.com/XPBytes/resource_allow_header/CHANGELOG.md
116
+ post_install_message:
117
+ rdoc_options: []
118
+ require_paths:
119
+ - lib
120
+ required_ruby_version: !ruby/object:Gem::Requirement
121
+ requirements:
122
+ - - ">="
123
+ - !ruby/object:Gem::Version
124
+ version: '0'
125
+ required_rubygems_version: !ruby/object:Gem::Requirement
126
+ requirements:
127
+ - - ">="
128
+ - !ruby/object:Gem::Version
129
+ version: '0'
130
+ requirements: []
131
+ rubyforge_project:
132
+ rubygems_version: 2.7.6
133
+ signing_key:
134
+ specification_version: 4
135
+ summary: CanCan supported Allow Header for Rack responses
136
+ test_files: []