[PR #4319] [CLOSED] Preserve historical client IPs #5655

Closed
opened 2026-10-31 20:48:25 +07:00 by bsakaguchi · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/MHSanaei/3x-ui/pull/4319
Author: @vahellame
Created: 5/12/2026
Status: ❌ Closed

Base: main ← Head: main


📝 Commits (1)

  • 441b5b5 Preserve historical client IPs

📊 Changes

1 file changed (+34 additions, -71 deletions)

View changed files

📝 web/job/check_client_ip_job.go (+34 -71)

📄 Description

What is the pull request?

Preserves historical client IP records in the IP log while keeping IP Limit enforcement based only on IPs observed in the current scan.

Previously, stale client IP entries were evicted after 30 minutes. This caused the panel IP log to lose historical IP addresses even though they are useful for auditing and visibility.

This change keeps historical IPs in inbound_client_ips, while partitionLiveIps() ensures that only currently observed IPs are counted toward LimitIP and sent to fail2ban.

Which part of the application is affected by the change?

  • Frontend
  • Backend

Type of Changes

  • Bug fix
  • New feature
  • Refactoring
  • Other

Screenshots

Not applicable.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/MHSanaei/3x-ui/pull/4319 **Author:** [@vahellame](https://github.com/vahellame) **Created:** 5/12/2026 **Status:** ❌ Closed **Base:** `main` ← **Head:** `main` --- ### 📝 Commits (1) - [`441b5b5`](https://github.com/MHSanaei/3x-ui/commit/441b5b5fc825fc36edc7433d85ce6dbe970033b2) Preserve historical client IPs ### 📊 Changes **1 file changed** (+34 additions, -71 deletions) <details> <summary>View changed files</summary> 📝 `web/job/check_client_ip_job.go` (+34 -71) </details> ### 📄 Description ## What is the pull request? Preserves historical client IP records in the IP log while keeping IP Limit enforcement based only on IPs observed in the current scan. Previously, stale client IP entries were evicted after 30 minutes. This caused the panel IP log to lose historical IP addresses even though they are useful for auditing and visibility. This change keeps historical IPs in `inbound_client_ips`, while `partitionLiveIps()` ensures that only currently observed IPs are counted toward `LimitIP` and sent to fail2ban. ## Which part of the application is affected by the change? * [ ] Frontend * [x] Backend ## Type of Changes * [x] Bug fix * [ ] New feature * [ ] Refactoring * [ ] Other ## Screenshots Not applicable. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
bsakaguchi 2026-10-31 20:48:25 +07:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
MHSanaei/3x-ui#5655
No description provided.