From 715af77a8ca577b74679dde1e96a71b32d468fa8 Mon Sep 17 00:00:00 2001 From: Daniel Dolezal Date: Mon, 29 Dec 2025 09:12:52 +0100 Subject: [PATCH] add code to increment blocked path access --- my_helpers | 2 +- my_modules/middleware.py | 1 + 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/my_helpers b/my_helpers index 66d6af2..12e2f23 160000 --- a/my_helpers +++ b/my_helpers @@ -1 +1 @@ -Subproject commit 66d6af251d3918cbb85613860b29cdea4ea0c094 +Subproject commit 12e2f232e1d26890dba83c12187f17f09609f73d diff --git a/my_modules/middleware.py b/my_modules/middleware.py index ac5b03c..674a6d8 100644 --- a/my_modules/middleware.py +++ b/my_modules/middleware.py @@ -38,6 +38,7 @@ async def custom_middleware(): # 3. If path contains honeypot targets if await current_app.convex.is_path_blocked(path=path): await logger.warning(f"[HONEYPOT] {method} | {client_ip} accessed {path}") + await current_app.convex.increment_blocked_path_access(path=path) return await maybe_a_hacker() await logger.info(f"{method} | {client_ip} had accessed the Side {path}")