Skip to content

[stable22] Add database ratelimiting backend - #28814

Merged
LukasReschke merged 1 commit into
stable22from
backport/28728/stable22
Sep 13, 2021
Merged

[stable22] Add database ratelimiting backend#28814
LukasReschke merged 1 commit into
stable22from
backport/28728/stable22

Conversation

@backportbot-nextcloud

@backportbot-nextcloudbackportbot-nextcloudBot commented Sep 13, 2021

Copy link
Copy Markdown

backport of #28728

@LukasReschke

Copy link
Copy Markdown
Member

Will manually backport.

In case no distributed memory cache is specified this adds
a database backend for ratelimit purposes.
Signed-off-by: Lukas Reschke <lukas@statuscode.ch>

@LukasReschkeLukasReschke left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Test plan:

  • Disable the memory cache in config.php
  • Enable the "Q&A Testing App" in the app settings
  • Go to /index.php/apps/testing/userAndAnonProtected and click a few times. Verify that the requests fails due to hitting the ratelimit.
  • Verify that expired ratelimit entries are removed on requests

@LukasReschke

Copy link
Copy Markdown
Member

Failing test seems unrelated.

@LukasReschke
LukasReschke merged commit 08673d2 into stable22Sep 13, 2021
@LukasReschke
LukasReschke deleted the backport/28728/stable22 branch September 13, 2021 17:27
@blizzzblizzz mentioned this pull request Sep 23, 2021
4 tasks
@MichaIngMichaIng modified the milestones: Nextcloud 22.1.2, Nextcloud 22.2.0Sep 24, 2021
Sign up for freeto join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants

@LukasReschke@Pytal@MichaIng