rack-attack 6.3.0 → 6.3.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +11 -0
- data/lib/rack/attack/store_proxy/redis_cache_store_proxy.rb +4 -0
- data/lib/rack/attack/version.rb +1 -1
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA256:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 3735d065000def3fce68a51f86fd46eec60d8ce8aac80991bd4c1fd05cf2babd
|
4
|
+
data.tar.gz: def7883dbc56f61163d54104e6a9b1aa87a93f47cdfefe60bb81880a7237aa8b
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 4c40ef6a1a7f2c1692b5bf3c46cb4f7e25bec5f413c9f96ee8b37b62e67b9f2e31e3c8067c9ecf19af4be16bbc01e016a3921052ed08c42c8a72b8a7696653e1
|
7
|
+
data.tar.gz: 3bb4d54e791d056a5e905e72b325a1eb733a6f3b660601f4d4ac39aa1b46cf480879bfae72575ce8ed8420961166ef3273cbe3590f60efa552946fbfb20cd7c2
|
data/README.md
CHANGED
@@ -37,6 +37,7 @@ See the [Backing & Hacking blog post](https://www.kickstarter.com/backing-and-ha
|
|
37
37
|
- [Customizing responses](#customizing-responses)
|
38
38
|
- [RateLimit headers for well-behaved clients](#ratelimit-headers-for-well-behaved-clients)
|
39
39
|
- [Logging & Instrumentation](#logging--instrumentation)
|
40
|
+
- [Testing](#testing)
|
40
41
|
- [How it works](#how-it-works)
|
41
42
|
- [About Tracks](#about-tracks)
|
42
43
|
- [Testing](#testing)
|
@@ -398,6 +399,16 @@ ActiveSupport::Notifications.subscribe(/rack_attack/) do |name, start, finish, r
|
|
398
399
|
end
|
399
400
|
```
|
400
401
|
|
402
|
+
## Testing
|
403
|
+
|
404
|
+
### Disabling
|
405
|
+
|
406
|
+
`Rack::Attack.enabled = false` can be used to either completely disable Rack::Attack in your tests, or to disable/enable for specific test cases only.
|
407
|
+
|
408
|
+
### Test case isolation
|
409
|
+
|
410
|
+
`Rack::Attack.reset!` can be used in your test suite to clear any Rack::Attack state between different test cases.
|
411
|
+
|
401
412
|
## How it works
|
402
413
|
|
403
414
|
The Rack::Attack middleware compares each request against *safelists*, *blocklists*, *throttles*, and *tracks* that you define. There are none by default.
|
data/lib/rack/attack/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: rack-attack
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 6.3.
|
4
|
+
version: 6.3.1
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Aaron Suggs
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2020-
|
11
|
+
date: 2020-05-21 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: rack
|
@@ -291,7 +291,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
291
291
|
- !ruby/object:Gem::Version
|
292
292
|
version: '0'
|
293
293
|
requirements: []
|
294
|
-
rubygems_version: 3.1.
|
294
|
+
rubygems_version: 3.1.3
|
295
295
|
signing_key:
|
296
296
|
specification_version: 4
|
297
297
|
summary: Block & throttle abusive requests
|