tymondesigns / jwt-auth

🔐 JSON Web Token Authentication for Laravel & Lumen
https://jwt-auth.com
MIT License
11.24k stars 1.55k forks source link

Redis cache Blacklist standard_ref overflow #2179

Open wenjy opened 2 years ago

wenjy commented 2 years ago

Redis cache Blacklist standard_ref overflow

env

CACHE_DRIVER=redis
JWT_TTL=480
JWT_REFRESH_TTL=1400

Your environment

Q A
Bug? yes
New Feature? no
Framework Laravel
Framework version 6.20.32
Package version 1.0.2
PHP version 7.4.24

Steps to reproduce

call JWTGuard->logout

Manager->invalidate

Blacklist->add

RedisTaggedCache->put

RedisTaggedCache->pushStandardKeys

I see

redis Set add xxx:standard_ref

string xxx:standard_ref ttl=1400*60

array(1) {
  ["valid_until"]=>
  int(1650435177)
}

timeout 1400*60 string xxx:standard_ref Removed

Set xxx:standard_ref member is not Remove

Expected behaviour

Tell us what should happen

Actual behaviour

Tell us what happens instead