✨ 自定义重定向
parent
c75b9001b3
commit
27f9b99e4c
@ -1,18 +1,16 @@
|
||||
package org.alis.amu.summer.security.handler;
|
||||
|
||||
import org.springframework.security.oauth2.common.exceptions.OAuth2Exception;
|
||||
import org.springframework.security.oauth2.provider.ClientDetails;
|
||||
import org.springframework.security.oauth2.provider.endpoint.RedirectResolver;
|
||||
import org.springframework.security.oauth2.provider.endpoint.DefaultRedirectResolver;
|
||||
|
||||
/**
|
||||
* @author robin
|
||||
* @date 2022/1/26 14:26
|
||||
*/
|
||||
public class RedirectHandler implements RedirectResolver {
|
||||
public class RedirectHandler extends DefaultRedirectResolver {
|
||||
|
||||
|
||||
@Override
|
||||
public String resolveRedirect(String requestedRedirect, ClientDetails client) throws OAuth2Exception {
|
||||
return requestedRedirect;
|
||||
protected boolean redirectMatches(String requestedRedirect, String redirectUri) {
|
||||
return super.redirectMatches(requestedRedirect, redirectUri);
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue