Netflix Shiro Pull Need #952
https://stash.corp.netflix.com/projects/CME/repos/shiro/pull-requests/952
This pull request brings support for this --max-age
plus --max-stale
red flags to the shiro
command.
The --max-age
flag identifies the maximum age of a legitimate token. If the expression is more mature compared to the specified era, it will become refreshed.
The --max-stale
flag identifies the maximum stale era of a new appropriate token. If typically the token is stagnant for more than the specified grow older, it will end up being refreshed.
These flags may be helpful regarding controlling the regularity of token refreshes. For example, when you set the particular --max-age
a flag to 1 hours, the token may be refreshed every single hour. If you set the --max-stale
flag in order to 30 minutes, this token will be refreshed every single 30 minutes.
To use these kinds of flags, just add them to this shiro
command word. For instance:
shiro --max-age 1h --max-stale 30m
This control will cause this shiro
command to refresh this token each hour, or if this is stale intended for more than 35 minutes.
Benefits of making these flags
There are usually several benefits to using the --max-age
and --max-stale
flags:
- Improved performance: Simply by handling the consistency regarding token refreshes, an individual can increase the performance of the application.
- Reduced safety measures risks: By refreshing tokens regularly, you will reduce the danger of your program being sacrificed by means of a thieved or expired token.
- Easier managing: By simply centralizing the supervision of token refreshes, you can help to make it easier for you to deal with your application's safety measures.
Conclusion
The --max-age
and --max-stale
flags are really a new valuable addition to the shiro
command. They allow you for you to control the consistency of token refreshes, which can boost performance, reduce safety risks, and make management easier.