-
Notifications
You must be signed in to change notification settings - Fork 429
Description
Please describe your feature request:
When working with stored/persistent OOB interaction (for example stored XSS) the current eviction mechanism may not remove the registration. Repeated interactions keep accessing the cache item, which increases the TTL and can delay eviction indefinitely.
Changing the storage eviction from cache.WithExpireAfterAccess to cache.WithExpireAfterWrite handles this use case and makes sure an eviction occurs after the specified eviction period.
Since changing behavior can break some other use-cases, I suggest adding a flag to the server command line to control the eviction strategy (for example --eviction-strategy fixed vs the default --eviction-strategy sliding).
Describe the use case of this feature:
- stored OOB may cause the registration stay forever
I've implemented a local fix and am happy to open a Pull Request for this feature if the solution is acceptable.