# GHSA-VVV9-CVG5-GPCJ: Banned-IP set-key raised to the caller on Redis failure, un-banning on outage

- Database: GitHub
- Severity: CVSS 4.8 (Medium)
- Published: 2026-08-25
- Modified: 2026-08-25

## Affected versions

- guard-core (PyPI): fixed in 3.13.0

## Description

## Summary
`_ban_exact_ip` in `guard_core/handlers/ipban_handler.py` wrapped `redis_handler.set_key` so that a Redis failure (which raises `GuardRedisError(503)` out of `RedisManager.safe_operation`) propagated out of `ban_ip` on the exact-IP path, un-banning the IP during an outage and surfacing a 503 to the caller from the ban path. The CIDR path already clamped; the exact-IP path did not.

## Impact
During a Redis outage, banning an exact-IP fails open (the IP is not banned) and the outage is leaked to the requester as a 503 from the ban path. Reported by CatamountJack.

## Affected
guard-core < 3.13.0.

## Patched in 3.13.0
The exact-IP path now mirrors the CIDR path, wrapping `set_key` in try/except that clamps the duration to `LOCAL_CACHE_TTL_CAP_SECONDS` (3600) and warns, so a Redis outage degrades to a local-memory ban with a clamped TTL instead of raising and un-banning.

## Workaround
Ensure Redis availability for ban enforcement; a local-only ban still applies during outage after the fix.

## References

- https://github.com/Guard-Core/guard-core/security/advisories/GHSA-vvv9-cvg5-gpcj

Page: https://cve.now/GHSA-VVV9-CVG5-GPCJ

Wrong or missing data? Send feedback: POST https://cve.now/api/v1/feedback (see https://cve.now/agents#feedback).
