记得上下班打卡 | git大法好,push需谨慎

Commit 2982d798 authored by 张国柄's avatar 张国柄

zull auth filter skip kylin station-验票redis校验(redis.db库不同);

parent 04de239e
...@@ -122,14 +122,14 @@ public class GlobalAuthFilter extends ZuulFilter { ...@@ -122,14 +122,14 @@ public class GlobalAuthFilter extends ZuulFilter {
} }
if (PathMatchUtil.isPathMatch(KYLIN_STATION_JWT_VALID, ctx.getRequest().getRequestURI())) {// 专业版APP if (PathMatchUtil.isPathMatch(KYLIN_STATION_JWT_VALID, ctx.getRequest().getRequestURI())) {// 专业版APP
// adam:identity:sso:${uid}:MD5(${token})=${1-在线|0-离线} // adam:identity:sso:${uid}:MD5(${token})=${1-在线|0-离线}
String ssoUidM5TokenKey = jwtValidator.getSsoRedisKey() // String ssoUidM5TokenKey = jwtValidator.getSsoRedisKey()
.concat(uid).concat(":").concat(DigestUtils.md5DigestAsHex(uToken.getBytes(StandardCharsets.UTF_8))); // .concat(uid).concat(":").concat(DigestUtils.md5DigestAsHex(uToken.getBytes(StandardCharsets.UTF_8)));
Integer online = (Integer) redisUtil.get(ssoUidM5TokenKey); // Integer online = (Integer) redisUtil.get(ssoUidM5TokenKey);
if (null == online || online != 1) { // if (null == online || online != 1) {
this.respHandler(ctx, TOKEN_INVALID); // this.respHandler(ctx, TOKEN_INVALID);
} else { // } else {
ctx.setSendZuulResponse(true); ctx.setSendZuulResponse(true);
} // }
} else { } else {
// adam:identity:sso:${uid}=MD5(${token}) // adam:identity:sso:${uid}=MD5(${token})
String ssoKey = jwtValidator.getSsoRedisKey().concat(uid); String ssoKey = jwtValidator.getSsoRedisKey().concat(uid);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment