invisible_captcha 1.1.0 → 2.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.
- checksums.yaml +4 -4
- data/.github/workflows/ci.yml +35 -0
- data/Appraisals +9 -18
- data/CHANGELOG.md +13 -0
- data/LICENSE +1 -1
- data/README.md +25 -15
- data/Rakefile +1 -6
- data/gemfiles/{rails_4.2.gemfile → rails_6.1.gemfile} +1 -1
- data/gemfiles/{rails_5.0.gemfile → rails_7.0.gemfile} +1 -1
- data/invisible_captcha.gemspec +7 -4
- data/lib/invisible_captcha/controller_ext.rb +24 -17
- data/lib/invisible_captcha/form_helpers.rb +1 -1
- data/lib/invisible_captcha/version.rb +1 -1
- data/lib/invisible_captcha/view_helpers.rb +17 -6
- data/lib/invisible_captcha.rb +15 -3
- data/spec/controllers_spec.rb +103 -51
- data/spec/dummy/app/controllers/topics_controller.rb +12 -0
- data/spec/dummy/app/views/layouts/application.html.erb +1 -2
- data/spec/dummy/config/application.rb +0 -2
- data/spec/dummy/config/environments/development.rb +1 -4
- data/spec/dummy/config/environments/test.rb +3 -8
- data/spec/dummy/config/routes.rb +2 -0
- data/spec/dummy/{app/assets/stylesheets/application.css → public/styles.css} +9 -4
- data/spec/spec_helper.rb +8 -17
- data/spec/view_helpers_spec.rb +15 -9
- metadata +61 -30
- data/.travis.yml +0 -27
- data/gemfiles/rails_5.1.gemfile +0 -7
- data/spec/dummy/app/assets/config/manifest.js +0 -2
- data/spec/dummy/app/assets/javascripts/application.js +0 -1
- data/spec/dummy/app/mailers/.gitkeep +0 -0
- data/spec/dummy/config/environments/production.rb +0 -86
- data/spec/dummy/lib/assets/.gitkeep +0 -0
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: invisible_captcha
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 2.1.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Marc Anguera Insa
|
8
|
-
autorequire:
|
8
|
+
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date:
|
11
|
+
date: 2023-03-12 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rails
|
@@ -16,28 +16,28 @@ dependencies:
|
|
16
16
|
requirements:
|
17
17
|
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
|
-
version: '
|
19
|
+
version: '5.2'
|
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
|
-
version: '
|
26
|
+
version: '5.2'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: rspec-rails
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- - "
|
31
|
+
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
|
-
version: '
|
33
|
+
version: '0'
|
34
34
|
type: :development
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- - "
|
38
|
+
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
|
-
version: '
|
40
|
+
version: '0'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: appraisal
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
@@ -52,7 +52,49 @@ dependencies:
|
|
52
52
|
- - ">="
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '0'
|
55
|
-
|
55
|
+
- !ruby/object:Gem::Dependency
|
56
|
+
name: webrick
|
57
|
+
requirement: !ruby/object:Gem::Requirement
|
58
|
+
requirements:
|
59
|
+
- - ">="
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
type: :development
|
63
|
+
prerelease: false
|
64
|
+
version_requirements: !ruby/object:Gem::Requirement
|
65
|
+
requirements:
|
66
|
+
- - ">="
|
67
|
+
- !ruby/object:Gem::Version
|
68
|
+
version: '0'
|
69
|
+
- !ruby/object:Gem::Dependency
|
70
|
+
name: simplecov
|
71
|
+
requirement: !ruby/object:Gem::Requirement
|
72
|
+
requirements:
|
73
|
+
- - ">="
|
74
|
+
- !ruby/object:Gem::Version
|
75
|
+
version: '0'
|
76
|
+
type: :development
|
77
|
+
prerelease: false
|
78
|
+
version_requirements: !ruby/object:Gem::Requirement
|
79
|
+
requirements:
|
80
|
+
- - ">="
|
81
|
+
- !ruby/object:Gem::Version
|
82
|
+
version: '0'
|
83
|
+
- !ruby/object:Gem::Dependency
|
84
|
+
name: simplecov-cobertura
|
85
|
+
requirement: !ruby/object:Gem::Requirement
|
86
|
+
requirements:
|
87
|
+
- - ">="
|
88
|
+
- !ruby/object:Gem::Version
|
89
|
+
version: '0'
|
90
|
+
type: :development
|
91
|
+
prerelease: false
|
92
|
+
version_requirements: !ruby/object:Gem::Requirement
|
93
|
+
requirements:
|
94
|
+
- - ">="
|
95
|
+
- !ruby/object:Gem::Version
|
96
|
+
version: '0'
|
97
|
+
description: Unobtrusive, flexible and complete spam protection for Rails applications
|
56
98
|
using honeypot strategy for better user experience.
|
57
99
|
email:
|
58
100
|
- srmarc.ai@gmail.com
|
@@ -60,20 +102,19 @@ executables: []
|
|
60
102
|
extensions: []
|
61
103
|
extra_rdoc_files: []
|
62
104
|
files:
|
105
|
+
- ".github/workflows/ci.yml"
|
63
106
|
- ".gitignore"
|
64
107
|
- ".rspec"
|
65
|
-
- ".travis.yml"
|
66
108
|
- Appraisals
|
67
109
|
- CHANGELOG.md
|
68
110
|
- Gemfile
|
69
111
|
- LICENSE
|
70
112
|
- README.md
|
71
113
|
- Rakefile
|
72
|
-
- gemfiles/rails_4.2.gemfile
|
73
|
-
- gemfiles/rails_5.0.gemfile
|
74
|
-
- gemfiles/rails_5.1.gemfile
|
75
114
|
- gemfiles/rails_5.2.gemfile
|
76
115
|
- gemfiles/rails_6.0.gemfile
|
116
|
+
- gemfiles/rails_6.1.gemfile
|
117
|
+
- gemfiles/rails_7.0.gemfile
|
77
118
|
- invisible_captcha.gemspec
|
78
119
|
- lib/invisible_captcha.rb
|
79
120
|
- lib/invisible_captcha/controller_ext.rb
|
@@ -84,13 +125,9 @@ files:
|
|
84
125
|
- spec/controllers_spec.rb
|
85
126
|
- spec/dummy/README.md
|
86
127
|
- spec/dummy/Rakefile
|
87
|
-
- spec/dummy/app/assets/config/manifest.js
|
88
|
-
- spec/dummy/app/assets/javascripts/application.js
|
89
|
-
- spec/dummy/app/assets/stylesheets/application.css
|
90
128
|
- spec/dummy/app/controllers/application_controller.rb
|
91
129
|
- spec/dummy/app/controllers/topics_controller.rb
|
92
130
|
- spec/dummy/app/helpers/application_helper.rb
|
93
|
-
- spec/dummy/app/mailers/.gitkeep
|
94
131
|
- spec/dummy/app/models/topic.rb
|
95
132
|
- spec/dummy/app/views/layouts/application.html.erb
|
96
133
|
- spec/dummy/app/views/topics/new.html.erb
|
@@ -103,7 +140,6 @@ files:
|
|
103
140
|
- spec/dummy/config/boot.rb
|
104
141
|
- spec/dummy/config/environment.rb
|
105
142
|
- spec/dummy/config/environments/development.rb
|
106
|
-
- spec/dummy/config/environments/production.rb
|
107
143
|
- spec/dummy/config/environments/test.rb
|
108
144
|
- spec/dummy/config/initializers/backtrace_silencers.rb
|
109
145
|
- spec/dummy/config/initializers/cookies_serializer.rb
|
@@ -116,12 +152,12 @@ files:
|
|
116
152
|
- spec/dummy/config/locales/en.yml
|
117
153
|
- spec/dummy/config/routes.rb
|
118
154
|
- spec/dummy/config/secrets.yml
|
119
|
-
- spec/dummy/lib/assets/.gitkeep
|
120
155
|
- spec/dummy/log/.gitkeep
|
121
156
|
- spec/dummy/public/404.html
|
122
157
|
- spec/dummy/public/422.html
|
123
158
|
- spec/dummy/public/500.html
|
124
159
|
- spec/dummy/public/favicon.ico
|
160
|
+
- spec/dummy/public/styles.css
|
125
161
|
- spec/invisible_captcha_spec.rb
|
126
162
|
- spec/spec_helper.rb
|
127
163
|
- spec/view_helpers_spec.rb
|
@@ -129,7 +165,7 @@ homepage: https://github.com/markets/invisible_captcha
|
|
129
165
|
licenses:
|
130
166
|
- MIT
|
131
167
|
metadata: {}
|
132
|
-
post_install_message:
|
168
|
+
post_install_message:
|
133
169
|
rdoc_options: []
|
134
170
|
require_paths:
|
135
171
|
- lib
|
@@ -144,21 +180,17 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
144
180
|
- !ruby/object:Gem::Version
|
145
181
|
version: '0'
|
146
182
|
requirements: []
|
147
|
-
rubygems_version: 3.
|
148
|
-
signing_key:
|
183
|
+
rubygems_version: 3.4.6
|
184
|
+
signing_key:
|
149
185
|
specification_version: 4
|
150
|
-
summary:
|
186
|
+
summary: Honeypot spam protection for Rails
|
151
187
|
test_files:
|
152
188
|
- spec/controllers_spec.rb
|
153
189
|
- spec/dummy/README.md
|
154
190
|
- spec/dummy/Rakefile
|
155
|
-
- spec/dummy/app/assets/config/manifest.js
|
156
|
-
- spec/dummy/app/assets/javascripts/application.js
|
157
|
-
- spec/dummy/app/assets/stylesheets/application.css
|
158
191
|
- spec/dummy/app/controllers/application_controller.rb
|
159
192
|
- spec/dummy/app/controllers/topics_controller.rb
|
160
193
|
- spec/dummy/app/helpers/application_helper.rb
|
161
|
-
- spec/dummy/app/mailers/.gitkeep
|
162
194
|
- spec/dummy/app/models/topic.rb
|
163
195
|
- spec/dummy/app/views/layouts/application.html.erb
|
164
196
|
- spec/dummy/app/views/topics/new.html.erb
|
@@ -171,7 +203,6 @@ test_files:
|
|
171
203
|
- spec/dummy/config/boot.rb
|
172
204
|
- spec/dummy/config/environment.rb
|
173
205
|
- spec/dummy/config/environments/development.rb
|
174
|
-
- spec/dummy/config/environments/production.rb
|
175
206
|
- spec/dummy/config/environments/test.rb
|
176
207
|
- spec/dummy/config/initializers/backtrace_silencers.rb
|
177
208
|
- spec/dummy/config/initializers/cookies_serializer.rb
|
@@ -184,12 +215,12 @@ test_files:
|
|
184
215
|
- spec/dummy/config/locales/en.yml
|
185
216
|
- spec/dummy/config/routes.rb
|
186
217
|
- spec/dummy/config/secrets.yml
|
187
|
-
- spec/dummy/lib/assets/.gitkeep
|
188
218
|
- spec/dummy/log/.gitkeep
|
189
219
|
- spec/dummy/public/404.html
|
190
220
|
- spec/dummy/public/422.html
|
191
221
|
- spec/dummy/public/500.html
|
192
222
|
- spec/dummy/public/favicon.ico
|
223
|
+
- spec/dummy/public/styles.css
|
193
224
|
- spec/invisible_captcha_spec.rb
|
194
225
|
- spec/spec_helper.rb
|
195
226
|
- spec/view_helpers_spec.rb
|
data/.travis.yml
DELETED
@@ -1,27 +0,0 @@
|
|
1
|
-
language: ruby
|
2
|
-
cache: bundler
|
3
|
-
rvm:
|
4
|
-
- ruby-head
|
5
|
-
- 2.6.5
|
6
|
-
- 2.5.7
|
7
|
-
- 2.4.9
|
8
|
-
- 2.3.8
|
9
|
-
gemfile:
|
10
|
-
- gemfiles/rails_6.0.gemfile
|
11
|
-
- gemfiles/rails_5.2.gemfile
|
12
|
-
- gemfiles/rails_5.1.gemfile
|
13
|
-
- gemfiles/rails_5.0.gemfile
|
14
|
-
- gemfiles/rails_4.2.gemfile
|
15
|
-
before_install:
|
16
|
-
# Rails 4.x requires Bundler version < 2.0.
|
17
|
-
- "find /home/travis/.rvm/rubies -wholename '*default/bundler-*.gemspec' -delete"
|
18
|
-
- rvm @global do gem uninstall bundler -a -x
|
19
|
-
- rvm @global do yes | gem install bundler -v '< 2'
|
20
|
-
matrix:
|
21
|
-
exclude:
|
22
|
-
- rvm: 2.4.9
|
23
|
-
gemfile: gemfiles/rails_6.0.gemfile
|
24
|
-
- rvm: 2.3.8
|
25
|
-
gemfile: gemfiles/rails_6.0.gemfile
|
26
|
-
allow_failures:
|
27
|
-
- rvm: ruby-head
|
data/gemfiles/rails_5.1.gemfile
DELETED
@@ -1 +0,0 @@
|
|
1
|
-
console.log('Hi from Invisible Captcha!');
|
File without changes
|
@@ -1,86 +0,0 @@
|
|
1
|
-
Rails.application.configure do
|
2
|
-
# Settings specified here will take precedence over those in config/application.rb.
|
3
|
-
|
4
|
-
# Code is not reloaded between requests.
|
5
|
-
config.cache_classes = true
|
6
|
-
|
7
|
-
# Eager load code on boot. This eager loads most of Rails and
|
8
|
-
# your application in memory, allowing both threaded web servers
|
9
|
-
# and those relying on copy on write to perform better.
|
10
|
-
# Rake tasks automatically ignore this option for performance.
|
11
|
-
config.eager_load = true
|
12
|
-
|
13
|
-
# Full error reports are disabled and caching is turned on.
|
14
|
-
config.consider_all_requests_local = false
|
15
|
-
config.action_controller.perform_caching = true
|
16
|
-
|
17
|
-
# Disable serving static files from the `/public` folder by default since
|
18
|
-
# Apache or NGINX already handles this.
|
19
|
-
config.public_file_server.enabled = ENV['RAILS_SERVE_STATIC_FILES'].present?
|
20
|
-
|
21
|
-
# Compress JavaScripts and CSS.
|
22
|
-
config.assets.js_compressor = :uglifier
|
23
|
-
# config.assets.css_compressor = :sass
|
24
|
-
|
25
|
-
# Do not fallback to assets pipeline if a precompiled asset is missed.
|
26
|
-
config.assets.compile = false
|
27
|
-
|
28
|
-
# `config.assets.precompile` and `config.assets.version` have moved to config/initializers/assets.rb
|
29
|
-
|
30
|
-
# Enable serving of images, stylesheets, and JavaScripts from an asset server.
|
31
|
-
# config.action_controller.asset_host = 'http://assets.example.com'
|
32
|
-
|
33
|
-
# Specifies the header that your server uses for sending files.
|
34
|
-
# config.action_dispatch.x_sendfile_header = 'X-Sendfile' # for Apache
|
35
|
-
# config.action_dispatch.x_sendfile_header = 'X-Accel-Redirect' # for NGINX
|
36
|
-
|
37
|
-
# Mount Action Cable outside main process or domain
|
38
|
-
# config.action_cable.mount_path = nil
|
39
|
-
# config.action_cable.url = 'wss://example.com/cable'
|
40
|
-
# config.action_cable.allowed_request_origins = [ 'http://example.com', /http:\/\/example.*/ ]
|
41
|
-
|
42
|
-
# Force all access to the app over SSL, use Strict-Transport-Security, and use secure cookies.
|
43
|
-
# config.force_ssl = true
|
44
|
-
|
45
|
-
# Use the lowest log level to ensure availability of diagnostic information
|
46
|
-
# when problems arise.
|
47
|
-
config.log_level = :debug
|
48
|
-
|
49
|
-
# Prepend all log lines with the following tags.
|
50
|
-
config.log_tags = [ :request_id ]
|
51
|
-
|
52
|
-
# Use a different cache store in production.
|
53
|
-
# config.cache_store = :mem_cache_store
|
54
|
-
|
55
|
-
# Use a real queuing backend for Active Job (and separate queues per environment)
|
56
|
-
# config.active_job.queue_adapter = :resque
|
57
|
-
# config.active_job.queue_name_prefix = "dummy_#{Rails.env}"
|
58
|
-
config.action_mailer.perform_caching = false
|
59
|
-
|
60
|
-
# Ignore bad email addresses and do not raise email delivery errors.
|
61
|
-
# Set this to true and configure the email server for immediate delivery to raise delivery errors.
|
62
|
-
# config.action_mailer.raise_delivery_errors = false
|
63
|
-
|
64
|
-
# Enable locale fallbacks for I18n (makes lookups for any locale fall back to
|
65
|
-
# the I18n.default_locale when a translation cannot be found).
|
66
|
-
config.i18n.fallbacks = true
|
67
|
-
|
68
|
-
# Send deprecation notices to registered listeners.
|
69
|
-
config.active_support.deprecation = :notify
|
70
|
-
|
71
|
-
# Use default logging formatter so that PID and timestamp are not suppressed.
|
72
|
-
config.log_formatter = ::Logger::Formatter.new
|
73
|
-
|
74
|
-
# Use a different logger for distributed setups.
|
75
|
-
# require 'syslog/logger'
|
76
|
-
# config.logger = ActiveSupport::TaggedLogging.new(Syslog::Logger.new 'app-name')
|
77
|
-
|
78
|
-
if ENV["RAILS_LOG_TO_STDOUT"].present?
|
79
|
-
logger = ActiveSupport::Logger.new(STDOUT)
|
80
|
-
logger.formatter = config.log_formatter
|
81
|
-
config.logger = ActiveSupport::TaggedLogging.new(logger)
|
82
|
-
end
|
83
|
-
|
84
|
-
# Do not dump schema after migrations.
|
85
|
-
config.active_record.dump_schema_after_migration = false
|
86
|
-
end
|
File without changes
|