Skip to content

Add redis backed download count validator#1644

Open
janbro wants to merge 2 commits intoeclipse:masterfrom
yeeth-security:yeeth/download_flood_control
Open

Add redis backed download count validator#1644
janbro wants to merge 2 commits intoeclipse:masterfrom
yeeth-security:yeeth/download_flood_control

Conversation

@janbro
Copy link
Contributor

@janbro janbro commented Feb 26, 2026

Adds DownloadCountValidator that gates increaseDownloadCount in StorageUtilService.

When Redis is enabled, duplicate downloads from the same IP within 30 minutes are deduplicated and bot user-agents are ignored. Downloads are still served normally, only the counter is affected.

IPs are SHA-256 hashed before storage. Reuses the existing ip-address-function SpEL config for consistent IP resolution with rate limiting.

Before merging this PR ideally the 30 minute window is reviewed and agreed upon based on existing usage and data.

@netomi
Copy link
Contributor

netomi commented Feb 26, 2026

This PR needs to be discussed first before integrating.

My understanding was that we do a download count validator for analysing the download loads rather for the metric that are anyway just a fraction of the actual downloads. Furthermore the metrics themselves are not taken into account for anything only serve informational purpose, while the download logs directly affect the download counts.

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