Browse Source

open

master
pioneer 2 years ago
parent
commit
7c0cdfe8a9
  1. 12
      plugin.xml
  2. 6
      src/main/java/com/eco/plugin/xx/kksso/config/InitializeMonitor.java
  3. 4
      src/main/java/com/eco/plugin/xx/kksso/config/PluginSimpleConfig.java
  4. 2
      src/main/java/com/eco/plugin/xx/kksso/controller/ControllerRegisterProvider.java
  5. 14
      src/main/java/com/eco/plugin/xx/kksso/controller/ControllerSelf.java
  6. 2
      src/main/java/com/eco/plugin/xx/kksso/utils/EncryptUtils.java
  7. 2
      src/main/java/com/eco/plugin/xx/kksso/utils/FRUtils.java
  8. 7
      src/main/java/com/eco/plugin/xx/kksso/utils/RSAUtil.java
  9. 2
      src/main/java/com/eco/plugin/xx/kksso/utils/ResponseUtils.java
  10. 2
      src/main/java/com/eco/plugin/xx/kksso/utils/Utils.java

12
plugin.xml

@ -1,20 +1,20 @@
<?xml version="1.0" encoding="UTF-8" standalone="no"?><plugin>
<id>com.eco.plugin.wink.kksso</id>
<id>com.eco.plugin.xx.kksso</id>
<name><![CDATA[单点登录]]></name>
<active>yes</active>
<version>1.0.2</version>
<env-version>10.0</env-version>
<jartime>2018-07-31</jartime>
<vendor>wink</vendor>
<vendor>fr.open</vendor>
<description><![CDATA[单点登录]]></description>
<change-notes><![CDATA[
]]></change-notes>
<main-package>com.eco.plugin.wink.kksso</main-package>
<lifecycle-monitor class="com.eco.plugin.wink.kksso.config.InitializeMonitor"/>
<main-package>com.eco.plugin.xx.kksso</main-package>
<lifecycle-monitor class="com.eco.plugin.xx.kksso.config.InitializeMonitor"/>
<extra-decision>
<ControllerRegisterProvider class="com.eco.plugin.wink.kksso.controller.ControllerRegisterProvider"/>
<ControllerRegisterProvider class="com.eco.plugin.xx.kksso.controller.ControllerRegisterProvider"/>
</extra-decision>
<function-recorder class="com.eco.plugin.wink.kksso.config.PluginSimpleConfig"/>
<function-recorder class="com.eco.plugin.xx.kksso.config.PluginSimpleConfig"/>
</plugin>

6
src/main/java/com/eco/plugin/xx/kksso/config/InitializeMonitor.java

@ -1,12 +1,12 @@
package com.eco.plugin.wink.kksso.config;
package com.eco.plugin.xx.kksso.config;
import com.fr.plugin.context.PluginContext;
import com.fr.plugin.observer.inner.AbstractPluginLifecycleMonitor;
/**
* @author wink
* @author xx
* @version 10.0
* Created by wink on 2021-12-03
* Created by xx on 2021-12-03
*/
public class InitializeMonitor extends AbstractPluginLifecycleMonitor {
@Override

4
src/main/java/com/eco/plugin/xx/kksso/config/PluginSimpleConfig.java

@ -1,4 +1,4 @@
package com.eco.plugin.wink.kksso.config;
package com.eco.plugin.xx.kksso.config;
import com.fr.config.*;
import com.fr.config.holder.Conf;
@ -13,7 +13,7 @@ public class PluginSimpleConfig extends DefaultConfiguration {
private static volatile PluginSimpleConfig config = null;
@Focus(id="com.eco.plugin.wink.kksso.config", text = "单点登录配置", source = Original.PLUGIN)
@Focus(id="com.eco.plugin.xx.kksso.config", text = "单点登录配置", source = Original.PLUGIN)
public static PluginSimpleConfig getInstance() {
if (config == null) {
config = ConfigContext.getConfigInstance(PluginSimpleConfig.class);

2
src/main/java/com/eco/plugin/xx/kksso/controller/ControllerRegisterProvider.java

@ -1,4 +1,4 @@
package com.eco.plugin.wink.kksso.controller;
package com.eco.plugin.xx.kksso.controller;
import com.fr.decision.fun.impl.AbstractControllerRegisterProvider;
import com.fr.plugin.transform.FunctionRecorder;

14
src/main/java/com/eco/plugin/xx/kksso/controller/ControllerSelf.java

@ -1,10 +1,10 @@
package com.eco.plugin.wink.kksso.controller;
package com.eco.plugin.xx.kksso.controller;
import com.eco.plugin.wink.kksso.config.PluginSimpleConfig;
import com.eco.plugin.wink.kksso.utils.FRUtils;
import com.eco.plugin.wink.kksso.utils.RSAUtil;
import com.eco.plugin.wink.kksso.utils.ResponseUtils;
import com.eco.plugin.wink.kksso.utils.Utils;
import com.eco.plugin.xx.kksso.config.PluginSimpleConfig;
import com.eco.plugin.xx.kksso.utils.FRUtils;
import com.eco.plugin.xx.kksso.utils.RSAUtil;
import com.eco.plugin.xx.kksso.utils.ResponseUtils;
import com.eco.plugin.xx.kksso.utils.Utils;
import com.fr.decision.webservice.annotation.LoginStatusChecker;
import com.fr.plugin.context.PluginContexts;
import com.fr.stable.fun.Authorize;
@ -16,7 +16,7 @@ import javax.servlet.http.HttpServletResponse;
@Controller
@LoginStatusChecker(required = false)
@Authorize(callSignKey = "com.eco.plugin.wink.kksso")
@Authorize(callSignKey = "com.eco.plugin.xx.kksso")
public class ControllerSelf {
@GetMapping(value = "/mobileSSOLogin")

2
src/main/java/com/eco/plugin/xx/kksso/utils/EncryptUtils.java

@ -1,4 +1,4 @@
package com.eco.plugin.wink.kksso.utils;
package com.eco.plugin.xx.kksso.utils;
import com.fr.json.JSONObject;
import com.fr.log.FineLoggerFactory;

2
src/main/java/com/eco/plugin/xx/kksso/utils/FRUtils.java

@ -1,4 +1,4 @@
package com.eco.plugin.wink.kksso.utils;
package com.eco.plugin.xx.kksso.utils;
import com.fr.base.ServerConfig;
import com.fr.base.TableData;

7
src/main/java/com/eco/plugin/xx/kksso/utils/RSAUtil.java

@ -1,4 +1,4 @@
package com.eco.plugin.wink.kksso.utils;
package com.eco.plugin.xx.kksso.utils;
import javax.crypto.Cipher;
import java.security.KeyFactory;
@ -28,9 +28,4 @@ public class RSAUtil {
return outStr;
}
public static void main(String[] args) throws Exception {
String key = "MIICdgIBADANBgkqhkiG9w0BAQEFAASCAmAwggJcAgEAAoGBAJ9mAcsCn52HD0aFqb79uGWEwcirWq3zd06fftI018HFwnuz3Db7VaIuI0bWX6xtAmkv86uqtFZrnn8/9XVxhR1uk26JHCTRGhHr/+yZZqpdhi44uYtFhCBECpWKz0Xqvb4Fnrd+tMI4i/s5FuwTJzcY4MRSDU9aAwtGlE74p6sdAgMBAAECgYANqCC5MwVX6s1tPmB3w6c7028C8WN4ieaL7vBftDVUHcx26scQUuJYXdmZ5R4XWNOfDYO0DpEa4meXAXTXVh2Qb6upFXl5sySzUWYtTBCttbj4Sx7NjwDPGu8Z+1OovQurRcvvAWjcat+dJDDXsqu5bRlAz/YcIGARAKWVKCYVIQJBAPbe16TacJ/85QYZowaPP8cqTjXNj+f0GLr8ax1Ww7zX3iqMYRaYmN7920BC666vL52tMZYomeO1wENCrl4RYTkCQQClSw4EjlYbZNNCYizW6WPSSBZaaKVALzt6ACCPaF2sZcqiWHegsirpfPtHebBDfInWWtUD4xBCdHCAt1o4x+0FAkBqeoVScnE/YEm8DtS1IJYmpkWjiS03o54DEJp2xhSY4BbQDUpW/6x4CdBGcFbNOnx0Kt6HYK23fI4XtKwWoLJpAkEAi5e2L+zRFXNx4qcsvRb/oVAV6KZloK4C6cZ/uPzn1zdkCPTzmne9O9C8GaHQVT4w3iF5sj2ptqXFeT7faAKXzQJAL15yVhanXqN/EuxmAQZ8K4E4wFolsqK7ncsYCw0j9/NFYLtFiISol5A0jUhc7AaMEybQqMtm4pJOhym2tvcpDg==";
String token = "Zj5NhKG9gcOwRMcAyUJD0fc2Vzhz0xFbEU9AQjuV4cAFiCkRKNU6BOyD59Hvtqy9tWjJUM6ZMoKtywJASFN87pLN5DjdBGLkJCZBGMWj97g6mf7r7j1x+4aTw1Jj5FcIEQnK+HpAQzDve/0Y/D0cjWn2AYy9FUeE9e40lxT6aqQ=";
System.out.println(decrypt(token,key));
}
}

2
src/main/java/com/eco/plugin/xx/kksso/utils/ResponseUtils.java

@ -1,4 +1,4 @@
package com.eco.plugin.wink.kksso.utils;
package com.eco.plugin.xx.kksso.utils;
import com.fr.json.JSONObject;
import com.fr.log.FineLoggerFactory;

2
src/main/java/com/eco/plugin/xx/kksso/utils/Utils.java

@ -1,4 +1,4 @@
package com.eco.plugin.wink.kksso.utils;
package com.eco.plugin.xx.kksso.utils;
import com.fr.base.TemplateUtils;
import com.fr.data.NetworkHelper;

Loading…
Cancel
Save