Skip to content

Settings: purge failed logins after 4 weeks by default (B4) - #25

Open
codeling wants to merge 1 commit into
mainfrom
ccr-c4633bb2-v97st1-defaults
Open

codeling wants to merge 1 commit into
mainfrom
ccr-c4633bb2-v97st1-defaults

Conversation

@codeling

@codeling codeling commented Nov 4, 2026

Copy link
Copy Markdown
Owner

Part of B4 for the 2.0.0 release (codeling/bfstop#250). Merge together with the plugin PR on the branch of the same name in codeling/bfstop. The plugin's test compares its DefaultSettings with this form, so either one alone fails CI.

Problem

While its settings are unsaved, the plugin purges failed logins after 4 weeks, but the settings page showed 0 (never) for "Delete old entries". So the first save of the settings switched purging off, contrary to the changelog. The hints in the block list and failed login list also assumed 0 when the setting was unsaved.

Change

  • deleteOld defaults to 4 in admin/forms/settings.xml.
  • The block list and failed login list views fall back to the plugin's Bfstop::DefaultSettings['deleteOld'].

Tests

testUnsavedSettingsAreWhatTheSettingsPageShows (in the plugin repo) now covers deleteOld. It fails against this repo's main and passes with this branch. The plugin's full suite passes locally with this branch, on Joomla 5.4.10 with MySQL 8.4 and PostgreSQL 16. Language and zip lint pass.


Generated by Claude Code

The plugin purges failed logins after 4 weeks while its settings have not
been saved, but the settings page showed 0 (never) for that setting - so
saving the settings for the first time switched purging off. The page now
shows the plugin's default, and the hints of the block and failed login
lists use the plugin's default too.

Needs the plugin branch of the same name (codeling/bfstop), which adds
deleteOld to the plugin's DefaultSettings that the test compares with this
form.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01AFJFMMUpch4LGexEiXN8Nc
Sign up for free to 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.

2 participants