# Token Cache Configuration
/*
|--------------------------------------------------------------------------
| Token Cache Configuration
|--------------------------------------------------------------------------
|
| Configure the cache-backed mechanisms used to manage token state,
| such as blacklist and whitelist lookups.
| The cache is used as a fast lookup layer to reduce database hits.
| When both blacklist and whitelist are enabled, blacklist checks take precedence.
|
*/
'cache' => [
/*
|--------------------------------------------------------------------------
| Token Cache Store
|--------------------------------------------------------------------------
|
| The cache store to be used for managing token states (blacklist/whitelist).
| You may specify any of the stores defined in your cache.php configuration
| file, such as "redis", "memcached", "file", or "database".
|
*/
'driver' => env('TOKEN_CACHE_DRIVER', env('CACHE_STORE', env('CACHE_DRIVER', 'file'))),
/*
|--------------------------------------------------------------------------
| Blacklist Feature
|--------------------------------------------------------------------------
|
| Enable or disable the token blacklist feature.
| When enabled, tokens added to the blacklist will be considered invalid
| and denied access, regardless of their expiration status.
|
*/
'blacklist_enabled' => env('TOKEN_BLACKLIST_ENABLED', true),
/*
|--------------------------------------------------------------------------
| Whitelist Feature
|--------------------------------------------------------------------------
|
| Enable or disable the token whitelist feature.
| When enabled, tokens added to the whitelist will always be considered
| valid and granted access, provided they are not expired or revoked in the database.
|
*/
'whitelist_enabled' => env('TOKEN_WHITELIST_ENABLED', false),
/*
|--------------------------------------------------------------------------
| Token Cache Key Prefix
|--------------------------------------------------------------------------
|
| This value will be prepended to all token-related cache keys to prevent
| naming collisions across different applications or environments.
|
*/
'prefix' => env('TOKEN_CACHE_PREFIX', 'tokenable:'),
],
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65