r/linuxadmin • u/su_ble • 28d ago
If you are using Fail2Ban-Report, please update to the latest Patch
Hi, I am the Maintainer of Fail2Ban-Report,
There was a security patch 0.5.3 - if you are using Fail2Ban-Report, please update as soon as possible to this new Version 0.5.3 from any other previous version.
You will find a list of changed files in the changelog
Security Fixes & Hardening
- Fixed Stored Cross-Site Scripting (XSS) via Client Sync (0.5.1 Hotfix): Resolved a critical vulnerability in
backsync.phpandblocklist-overlay.jswhere malicious or compromised sync clients could upload a manipulated JSON file containing arbitrary JavaScript payloads (e.g., inside theiporjailfields). The UI has been refactored to baninnerHTMLusage, shifting entirely to securetextContentandcreateElementDOM manipulation to neutralize any script execution hazards. - Fixed Authentication Bypass on Read Plane (0.5.2): Resolved an architectural flaw where unauthenticated network sessions were automatically assigned a default
viewerrole, leaving sensitive firewall history, server configurations, and blocking aggregations open to anonymous actors. Access is now strictly guarded at the global gateway level. - Fixed Shell Command Injection in Helper Scripts (0.5.2): Patched
manage_users.shandmanage-clients.shwhere user-supplied inputs containing specific shell characters (like apostrophes) were interpreted as executable PHP program text. Data payloads are now passed securely using isolated environment variables (getenv()). - Fixed Credentials Leak in Process Table (0.5.2): Hardened the multi-server sync engine (
syncback.shandfail2ban_log2json.sh) to prevent sync passwords (CLIENT_PASS) from leaking into the host's public process listing (argv). Commands are now packaged dynamically inside localized, temporary configuration files (chmod 600). - Secured API Lookup Restrictions & Data Sanitization: Overhauled
action_report-ip.phpto mandate active administrator verification before reaching outbound services, preventing blind exploitation of paid lookups (AbuseIPDB / IPinfo). Integrated native IP structure enforcement (FILTER_VALIDATE_IP). Web-UI/assets/js/jsonreader.js: RefactoredrenderTable()to use XSS-safe DOM manipulation and added CSP-safe event listeners for toolbar buttons.Web-UI/assets/js/warnings.js: Refactored multi-jail status rendering to prevent XSS via safe DOM node creation.Web-UI/assets/js/fail2ban-logstats.js: Refactored top-jails list rendering to be XSS-safe and removed duplicate function definitions.Web-UI/index.php: Replaced inlineonclickattributes on toolbar buttons with IDs for CSP compatibility.Web-UI/endpoint/index.php: Added strict JSON validation (ip,jail,action,timestamp) and clean re-encoding for uploaded event and blocklist files.Web-UI/endpoint/backsync.php: Hardened upload validation (timestamp, field lengths, safe path handling) and enforced JSON re-encoding before saving.Web-UI/.htaccess: EnabledContent-Security-Policy(script-src 'self') and additional HTTP security headers.
42
Upvotes
3
u/Critical_Purple_1988 28d ago
Respect for posting the full breakdown instead of a vague "update when convenient" note, that auth bypass quietly handing anonymous users a default viewer role is a nasty one to have been sitting there. Appreciate maintainers who patch loudly and own exactly what was wrong, makes the project so much easier to trust.
6
u/mk_gecko 28d ago
Just clarify if it has anything to do with fail2ban.
Why not also provide a link to your repo if it is not https://github.com/fail2ban/fail2ban ?
It looks like fail2ban is at version 1.1.1
So nothing about 0.5.1 or 0.5.2
Your post is VERY confusing:
There was a security patch 0.5.2 - if you are using it, please update as soon as possible.
But then all you do is list all of the things that 0.5.2 fixes. -- so it looks like this is the update that we should be using.
So, is 0.5.2 GOOD OR BAD? If it is BAD (insecure), please state the version that IS patched, updated, fixed.
How about telling us also the update version that people should update to?
1
u/su_ble 14d ago
next security fix was added today for version 0.5.3 => Please upgrade asap
PHP Security is hard to stay ahead of these days
1
u/Idontremember99 28d ago
Sorry to say, but the Readme and changelog is a mess. The changelog does not say what changed in 0.5.1 and 0.5.2. The whole "What's New in v0.5.2" in the readme should be in the changelog and the link in the first part doesn't work
-4
u/mk_gecko 28d ago
Guys!
This is a classic example of why it is important to be able to write clearly,
to know how which version numbers are which and what pronouns refer to.
Someone who knows how to write English sentences clearly could have avoided the ongoing, unending confusion, but it probably is a good learning experience.