Skip to content

Commit

Permalink
v1.23.0 更新
Browse files Browse the repository at this point in the history
  • Loading branch information
click33 committed Jul 18, 2021
1 parent 34d1008 commit c7ca8ee
Show file tree
Hide file tree
Showing 10 changed files with 13 additions and 9 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -84,6 +84,7 @@ public default String getParamNotNull(String name) {

/**
* 返回当前请求path是否为指定值
* @param path path
* @return see note
*/
public default boolean isPath(String path) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ public interface SaTokenDao {
* 写入Value,并设定存活时间 (单位: 秒)
* @param key 键名称
* @param value 值
* @param timeout 过期时间(值>0时限时存储,值=-1时永久存储,值=0或<=-2时不存储)
* @param timeout 过期时间(值大于0时限时存储,值=-1时永久存储,值=0或小于-2时不存储)
*/
public void set(String key, String value, long timeout);

Expand Down Expand Up @@ -75,7 +75,7 @@ public interface SaTokenDao {
* 写入Object,并设定存活时间 (单位: 秒)
* @param key 键名称
* @param object 值
* @param timeout 存活时间 (值>0时限时存储,值=-1时永久存储,值=0或<=-2时不存储)
* @param timeout 存活时间 (值大于0时限时存储,值=-1时永久存储,值=0或小于-2时不存储)
*/
public void setObject(String key, Object object, long timeout);

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -301,7 +301,7 @@ public void singleLogout(String secretkey, Object loginId, CallSloUrlFunction fu

/**
* 拼接key:Ticket 查 账号Id
* @param ticket
* @param ticket ticket值
* @return key
*/
public String splicingKeyTicketToId(String ticket) {
Expand Down
2 changes: 1 addition & 1 deletion sa-token-doc/doc/start/download.md
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ implementation 'cn.dev33:sa-token-core:${sa.top.version}'
├── sa-token-temp-jwt // [插件] Sa-Token 整合 jwt 临时令牌鉴权
├── sa-token-quick-login // [插件] Sa-Token 快速注入登录页插件
├── sa-token-alone-redis // [插件] Sa-Token 独立Redis插件,实现[权限缓存与业务缓存分离]
├── sa-token-oauth2 // [插件] Sa-Token 实现 OAuth2.0 模块(内测暂未发布)
├── sa-token-oauth2 // [插件] Sa-Token 实现 OAuth2.0 模块
├── sa-token-demo // [示例] Sa-Token 示例合集
├── sa-token-demo-springboot // [示例] Sa-Token 整合 SpringBoot
├── sa-token-demo-webflux // [示例] Sa-Token 整合 WebFlux
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@ public class SaOAuth2Exception extends SaTokenException {

/**
* 一个异常:代表OAuth2认证流程错误
* @param message 异常描述
*/
public SaOAuth2Exception(String message) {
super(message);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -236,6 +236,9 @@ public static Object password(SaRequest req, SaResponse res, SaOAuth2Config cfg)

/**
* 模式四:凭证式
* @param req 请求对象
* @param res 响应对象
* @param cfg 配置对象
* @return 处理结果
*/
public static Object clientToken(SaRequest req, SaResponse res, SaOAuth2Config cfg) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -779,11 +779,10 @@ public String randomRefreshToken(String clientId, Object loginId, String scope)
/**
* 随机一个 Client-Token
* @param clientId 应用id
* @param loginId 账号id
* @param scope 权限
* @return Client-Token
*/
public String randomClientToken(String clientId, Object loginId) {
public String randomClientToken(String clientId, String scope) {
return SaFoxUtil.getRandomString(60);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ public long getRefreshExpiresIn() {

/**
* 将所有属性转换为下划线形式的Map
* @return
* @return 属性转Map
*/
public Map<String, Object> toLineMap() {
Map<String, Object> map = new LinkedHashMap<String, Object>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,6 @@ public ClientTokenModel() {}
* @param accessToken accessToken
* @param clientId 应用id
* @param scope 请求授权范围
* @param loginId 对应的账号id
*/
public ClientTokenModel(String accessToken, String clientId, String scope) {
super();
Expand All @@ -66,7 +65,7 @@ public long getExpiresIn() {

/**
* 将所有属性转换为下划线形式的Map
* @return
* @return 属性转Map
*/
public Map<String, Object> toLineMap() {
Map<String, Object> map = new LinkedHashMap<String, Object>();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,7 @@ public CodeModel() {
* @param clientId 应用id
* @param scope 请求授权范围
* @param loginId 对应的账号id
* @param redirectUri 重定向地址
*/
public CodeModel(String code, String clientId, String scope, Object loginId, String redirectUri) {
super();
Expand Down

0 comments on commit c7ca8ee

Please sign in to comment.