提交 c3267d4f 编写于 作者: NoSubject's avatar NoSubject

Merge branch 'fix/sso20210201' into 'wrdp'

修复sso解码出错

See merge request o2oa/o2oa!2952
......@@ -43,8 +43,9 @@ class ActionPostEncrypt extends BaseAction {
throw new ExceptionClientNotExist(wi.getClient());
}
String str = wi.getCredential() + TOKEN_SPLIT + new Date().getTime();
byte[] bs = Crypto.encrypt(str.getBytes(DefaultCharset.charset), wi.getKey().getBytes());
String token = new String(Base64.encodeBase64(bs), DefaultCharset.charset);
//byte[] bs = Crypto.encrypt(str.getBytes(DefaultCharset.charset), wi.getKey().getBytes());
//String token = new String(Base64.encodeBase64(bs), DefaultCharset.charset);
String token = Crypto.encrypt(str, wi.getKey());
Wo wo = new Wo();
wo.setToken(token);
result.setData(wo);
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册