mirror of
https://github.com/mastodon/mastodon.git
synced 2024-08-20 21:08:15 -07:00
Change rate limit for media proxy
This commit is contained in:
parent
41fe7576bf
commit
82acc07ceb
1 changed files with 1 additions and 1 deletions
|
@ -74,7 +74,7 @@ class Rack::Attack
|
||||||
req.authenticated_user_id if req.post? && req.path.match?(/\A\/api\/v\d+\/media\z/i)
|
req.authenticated_user_id if req.post? && req.path.match?(/\A\/api\/v\d+\/media\z/i)
|
||||||
end
|
end
|
||||||
|
|
||||||
throttle('throttle_media_proxy', limit: 30, period: 10.minutes) do |req|
|
throttle('throttle_media_proxy', limit: 300, period: 5.minutes) do |req|
|
||||||
req.throttleable_remote_ip if req.path.start_with?('/media_proxy')
|
req.throttleable_remote_ip if req.path.start_with?('/media_proxy')
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue