mirror of
https://gitee.com/dromara/MaxKey.git
synced 2026-05-15 04:52:09 +08:00
SslConfig
This commit is contained in:
@@ -123,8 +123,11 @@ public abstract class AbstractAuthenticationProvider {
|
||||
*/
|
||||
protected void sessionValid(String sessionId) {
|
||||
if (sessionId == null || !sessionId.equals(WebContext.getSession().getId())) {
|
||||
String message = WebContext.getI18nValue("login.error.session");
|
||||
_logger.debug("login session valid error.");
|
||||
_logger.debug("login session sessionId " + sessionId);
|
||||
_logger.debug("login getSession sessionId " + WebContext.getSession().getId());
|
||||
|
||||
String message = WebContext.getI18nValue("login.error.session");
|
||||
throw new BadCredentialsException(message);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -149,7 +149,7 @@ public class MvcAutoConfiguration implements InitializingBean {
|
||||
new MappingJackson2HttpMessageConverter();
|
||||
ArrayList<MediaType> mediaTypesList = new ArrayList<MediaType>();
|
||||
mediaTypesList.add(MediaType.APPLICATION_JSON);
|
||||
mediaTypesList.add(MediaType.TEXT_PLAIN);
|
||||
//mediaTypesList.add(MediaType.TEXT_PLAIN);
|
||||
mappingJacksonHttpMessageConverter.setSupportedMediaTypes(mediaTypesList);
|
||||
return mappingJacksonHttpMessageConverter;
|
||||
}
|
||||
|
||||
@@ -220,6 +220,7 @@ public final class WebContext {
|
||||
* @return HttpSession
|
||||
*/
|
||||
public static HttpSession getSession(boolean create) {
|
||||
System.out.println("new Session created");
|
||||
return getRequest().getSession(create);
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user