You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
51 lines
1.2 KiB
51 lines
1.2 KiB
3 years ago
|
package com.fr.plugin.login.handler;
|
||
|
|
||
|
import com.fr.base.TemplateUtils;
|
||
|
import com.fr.decision.fun.impl.BaseHttpHandler;
|
||
|
import com.fr.plugin.transform.FunctionRecorder;
|
||
|
import com.fr.third.springframework.web.bind.annotation.RequestMethod;
|
||
|
import com.fr.web.utils.WebUtils;
|
||
|
|
||
|
import javax.servlet.http.HttpServletRequest;
|
||
|
import javax.servlet.http.HttpServletResponse;
|
||
|
import java.util.HashMap;
|
||
|
import java.util.Map;
|
||
|
|
||
|
@FunctionRecorder
|
||
|
public class ToLogin extends BaseHttpHandler {
|
||
|
|
||
|
|
||
|
public ToLogin() {
|
||
|
}
|
||
|
|
||
|
@Override
|
||
|
public RequestMethod getMethod() {
|
||
|
return RequestMethod.GET;
|
||
|
}
|
||
|
|
||
|
@Override
|
||
|
public String getPath() {
|
||
|
return "/toSso";
|
||
|
}
|
||
|
|
||
|
@Override
|
||
|
public boolean isPublic() {
|
||
|
return true;
|
||
|
}
|
||
|
|
||
|
@Override
|
||
|
public void handle(HttpServletRequest req, HttpServletResponse res) throws Exception {
|
||
|
Map<String, String> parameterMap = new HashMap<String, String>();
|
||
|
String path = "/com/fr/plugin/login/html/getcookie.html";
|
||
|
|
||
|
parameterMap.put("remoteServletURL", WebUtils.getOriginalURL(req));
|
||
|
String macPage = TemplateUtils.renderTemplate(path, parameterMap);
|
||
|
WebUtils.printAsString(res, macPage);
|
||
|
}
|
||
|
|
||
|
|
||
|
|
||
|
|
||
|
}
|
||
|
|