mirror of
https://gitee.com/dromara/MaxKey.git
synced 2026-05-14 20:50:14 +08:00
v 3.2.0
This commit is contained in:
@@ -36,14 +36,14 @@ import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
/**
|
||||
* @author Crystal.Sea
|
||||
*
|
||||
*/
|
||||
@Api(tags = "1-2认证总地址文档模块")
|
||||
@Tag(name = "1-2认证总地址文档模块")
|
||||
@Controller
|
||||
public class AuthorizeEndpoint extends AuthorizeBaseEndpoint{
|
||||
final static Logger _logger = LoggerFactory.getLogger(AuthorizeEndpoint.class);
|
||||
@@ -52,7 +52,7 @@ public class AuthorizeEndpoint extends AuthorizeBaseEndpoint{
|
||||
AppsCasDetailsService casDetailsService;
|
||||
|
||||
//all single sign on url
|
||||
@ApiOperation(value = "认证总地址接口", notes = "参数应用ID,分发到不同应用的认证地址",httpMethod="GET")
|
||||
@Operation(summary = "认证总地址接口", description = "参数应用ID,分发到不同应用的认证地址",method="GET")
|
||||
@RequestMapping("/authz/{id}")
|
||||
public ModelAndView authorize(
|
||||
HttpServletRequest request,
|
||||
|
||||
@@ -26,10 +26,10 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
@Api(tags = "3-1-在线ticket文档模块")
|
||||
@Tag(name = "3-1-在线ticket文档模块")
|
||||
@Controller
|
||||
@RequestMapping(value={"/onlineticket"})
|
||||
public class OnlineTicketEndpoint {
|
||||
@@ -38,7 +38,7 @@ public class OnlineTicketEndpoint {
|
||||
@Qualifier("onlineTicketServices")
|
||||
protected OnlineTicketServices onlineTicketServices;
|
||||
|
||||
@ApiOperation(value = "在线ticket验证接口", notes = "",httpMethod="GET")
|
||||
@Operation(summary = "在线ticket验证接口", description = "",method="GET")
|
||||
@ResponseBody
|
||||
@RequestMapping(value="/validate")
|
||||
public String ticketValidate(
|
||||
|
||||
@@ -34,14 +34,14 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
/**
|
||||
* @author Crystal.Sea
|
||||
* https://apereo.github.io/cas/6.2.x/protocol/CAS-Protocol-Specification.html
|
||||
*/
|
||||
@Api(tags = "2-3-CAS API文档模块")
|
||||
@Tag(name = "2-3-CAS API文档模块")
|
||||
@Controller
|
||||
public class Cas10AuthorizeEndpoint extends CasBaseAuthorizeEndpoint{
|
||||
|
||||
@@ -81,7 +81,7 @@ renew [OPTIONAL] - if this parameter is set, ticket validation will only succeed
|
||||
no<LF>
|
||||
<LF>
|
||||
*/
|
||||
@ApiOperation(value = "CAS 1.0 ticket验证接口", notes = "通过ticket获取当前登录用户信息",httpMethod="POST")
|
||||
@Operation(summary = "CAS 1.0 ticket验证接口", description = "通过ticket获取当前登录用户信息",method="POST")
|
||||
@RequestMapping(CasConstants.ENDPOINT.ENDPOINT_VALIDATE)
|
||||
@ResponseBody
|
||||
public String validate(
|
||||
|
||||
@@ -43,14 +43,14 @@ import org.springframework.stereotype.Controller;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
/**
|
||||
* @author Crystal.Sea
|
||||
* https://apereo.github.io/cas/6.2.x/protocol/CAS-Protocol-V2-Specification.html
|
||||
*/
|
||||
@Api(tags = "2-3-CAS API文档模块")
|
||||
@Tag(name = "2-3-CAS API文档模块")
|
||||
@Controller
|
||||
public class Cas20AuthorizeEndpoint extends CasBaseAuthorizeEndpoint{
|
||||
|
||||
@@ -171,7 +171,7 @@ INTERNAL_ERROR - an internal error occurred during ticket validation
|
||||
|
||||
For all error codes, it is RECOMMENDED that CAS provide a more detailed message as the body of the \<cas:authenticationFailure\> block of the XML response.
|
||||
*/
|
||||
@ApiOperation(value = "CAS 2.0 ticket验证接口", notes = "通过ticket获取当前登录用户信息",httpMethod="POST")
|
||||
@Operation(summary = "CAS 2.0 ticket验证接口", description = "通过ticket获取当前登录用户信息",method="POST")
|
||||
@RequestMapping(value=CasConstants.ENDPOINT.ENDPOINT_SERVICE_VALIDATE,produces =MediaType.APPLICATION_XML_VALUE)
|
||||
@ResponseBody
|
||||
public String serviceValidate(
|
||||
@@ -293,7 +293,7 @@ Response on ticket validation failure:
|
||||
}
|
||||
*/
|
||||
|
||||
@ApiOperation(value = "CAS 2.0 ticket代理验证接口", notes = "通过ticket获取当前登录用户信息",httpMethod="POST")
|
||||
@Operation(summary = "CAS 2.0 ticket代理验证接口", description = "通过ticket获取当前登录用户信息",method="POST")
|
||||
@RequestMapping(value=CasConstants.ENDPOINT.ENDPOINT_PROXY_VALIDATE,produces =MediaType.APPLICATION_XML_VALUE)
|
||||
@ResponseBody
|
||||
public String proxy(
|
||||
|
||||
@@ -42,20 +42,20 @@ import org.slf4j.LoggerFactory;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
/**
|
||||
* @author Crystal.Sea
|
||||
* https://apereo.github.io/cas/6.2.x/protocol/CAS-Protocol-Specification.html
|
||||
*/
|
||||
@Api(tags = "2-3-CAS API文档模块")
|
||||
@Tag(name = "2-3-CAS API文档模块")
|
||||
@Controller
|
||||
public class Cas30AuthorizeEndpoint extends CasBaseAuthorizeEndpoint{
|
||||
|
||||
final static Logger _logger = LoggerFactory.getLogger(Cas30AuthorizeEndpoint.class);
|
||||
|
||||
@ApiOperation(value = "CAS 3.0 ticket验证接口", notes = "通过ticket获取当前登录用户信息",httpMethod="POST")
|
||||
@Operation(summary = "CAS 3.0 ticket验证接口", description = "通过ticket获取当前登录用户信息",method="POST")
|
||||
@RequestMapping(value=CasConstants.ENDPOINT.ENDPOINT_SERVICE_VALIDATE_V3)
|
||||
public void serviceValidate(
|
||||
HttpServletRequest request,
|
||||
@@ -115,7 +115,7 @@ public class Cas30AuthorizeEndpoint extends CasBaseAuthorizeEndpoint{
|
||||
httpResponseAdapter.write(response,serviceResponseBuilder.serviceResponseBuilder(),format);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "CAS 3.0 ProxyTicket代理验证接口", notes = "通过ProxyGrantingTicket获取ProxyTicket",httpMethod="POST")
|
||||
@Operation(summary = "CAS 3.0 ProxyTicket代理验证接口", description = "通过ProxyGrantingTicket获取ProxyTicket",method="POST")
|
||||
@RequestMapping(CasConstants.ENDPOINT.ENDPOINT_PROXY_V3)
|
||||
public void proxy(
|
||||
HttpServletRequest request,
|
||||
@@ -141,7 +141,7 @@ public class Cas30AuthorizeEndpoint extends CasBaseAuthorizeEndpoint{
|
||||
httpResponseAdapter.write(response,proxyServiceResponseBuilder.serviceResponseBuilder(),format);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "CAS 3.0 ticket代理验证接口", notes = "通过ProxyTicket获取当前登录用户信息",httpMethod="POST")
|
||||
@Operation(summary = "CAS 3.0 ticket代理验证接口", description = "通过ProxyTicket获取当前登录用户信息",method="POST")
|
||||
@RequestMapping(CasConstants.ENDPOINT.ENDPOINT_PROXY_VALIDATE_V3)
|
||||
public void proxy(
|
||||
HttpServletRequest request,
|
||||
|
||||
@@ -42,20 +42,21 @@ import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
/**
|
||||
* @author Crystal.Sea
|
||||
* https://apereo.github.io/cas/6.2.x/protocol/CAS-Protocol.html
|
||||
*/
|
||||
@Api(tags = "2-3-CAS API文档模块")
|
||||
@Tag(name = "2-3-CAS API文档模块")
|
||||
@Controller
|
||||
public class CasAuthorizeEndpoint extends CasBaseAuthorizeEndpoint{
|
||||
|
||||
final static Logger _logger = LoggerFactory.getLogger(CasAuthorizeEndpoint.class);
|
||||
|
||||
@ApiOperation(value = "CAS页面跳转service认证接口", notes = "传递参数service",httpMethod="GET")
|
||||
@Operation(summary = "CAS页面跳转service认证接口", description = "传递参数service",method="GET")
|
||||
@RequestMapping(CasConstants.ENDPOINT.ENDPOINT_LOGIN)
|
||||
public ModelAndView casLogin(
|
||||
HttpServletRequest request,
|
||||
@@ -68,7 +69,7 @@ public class CasAuthorizeEndpoint extends CasBaseAuthorizeEndpoint{
|
||||
|
||||
}
|
||||
|
||||
@ApiOperation(value = "CAS页面跳转应用ID认证接口", notes = "传递参数应用ID",httpMethod="GET")
|
||||
@Operation(summary = "CAS页面跳转应用ID认证接口", description = "传递参数应用ID",method="GET")
|
||||
@RequestMapping(CasConstants.ENDPOINT.ENDPOINT_BASE + "/{id}")
|
||||
public ModelAndView authorize(
|
||||
HttpServletRequest request,
|
||||
@@ -171,7 +172,7 @@ public class CasAuthorizeEndpoint extends CasBaseAuthorizeEndpoint{
|
||||
* @param casService
|
||||
* @return
|
||||
*/
|
||||
@ApiOperation(value = "CAS注销接口", notes = "CAS注销接口",httpMethod="GET")
|
||||
@Operation(summary = "CAS注销接口", description = "CAS注销接口",method="GET")
|
||||
@RequestMapping(CasConstants.ENDPOINT.ENDPOINT_LOGOUT)
|
||||
public ModelAndView logout(
|
||||
HttpServletRequest request,
|
||||
|
||||
@@ -50,14 +50,14 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
/**
|
||||
* @author Crystal.Sea
|
||||
* https://apereo.github.io/cas/6.2.x/protocol/REST-Protocol.html
|
||||
*/
|
||||
@Api(tags = "2-4-CAS REST API文档模块")
|
||||
@Tag(name = "2-4-CAS REST API文档模块")
|
||||
@Controller
|
||||
public class CasRestV1Endpoint extends CasBaseAuthorizeEndpoint{
|
||||
final static Logger _logger = LoggerFactory.getLogger(CasRestV1Endpoint.class);
|
||||
@@ -66,7 +66,7 @@ public class CasRestV1Endpoint extends CasBaseAuthorizeEndpoint{
|
||||
@Qualifier("authenticationProvider")
|
||||
AbstractAuthenticationProvider authenticationProvider ;
|
||||
|
||||
@ApiOperation(value = "CAS REST认证接口", notes = "通过用户名密码获取TGT",httpMethod="POST")
|
||||
@Operation(summary = "CAS REST认证接口", description = "通过用户名密码获取TGT",method="POST")
|
||||
@RequestMapping(value=CasConstants.ENDPOINT.ENDPOINT_REST_TICKET_V1,
|
||||
method=RequestMethod.POST,
|
||||
consumes = MediaType.APPLICATION_FORM_URLENCODED_VALUE)
|
||||
@@ -105,7 +105,7 @@ public class CasRestV1Endpoint extends CasBaseAuthorizeEndpoint{
|
||||
}
|
||||
}
|
||||
|
||||
@ApiOperation(value = "CAS REST认证接口", notes = "通过TGT获取ST",httpMethod="POST")
|
||||
@Operation(summary = "CAS REST认证接口", description = "通过TGT获取ST",method="POST")
|
||||
@RequestMapping(value=CasConstants.ENDPOINT.ENDPOINT_REST_TICKET_V1+"/{ticketGrantingTicket}",
|
||||
method=RequestMethod.POST,
|
||||
consumes = MediaType.APPLICATION_FORM_URLENCODED_VALUE)
|
||||
@@ -132,7 +132,7 @@ public class CasRestV1Endpoint extends CasBaseAuthorizeEndpoint{
|
||||
}
|
||||
return new ResponseEntity<>("", HttpStatus.BAD_REQUEST);
|
||||
}
|
||||
@ApiOperation(value = "CAS REST认证接口", notes = "检查TGT状态",httpMethod="GET")
|
||||
@Operation(summary = "CAS REST认证接口", description = "检查TGT状态",method="GET")
|
||||
@RequestMapping(value=CasConstants.ENDPOINT.ENDPOINT_REST_TICKET_V1 + "/{ticketGrantingTicket}",
|
||||
method=RequestMethod.GET)
|
||||
public ResponseEntity<String> verifyTicketGrantingTicketStatus(
|
||||
@@ -151,7 +151,7 @@ public class CasRestV1Endpoint extends CasBaseAuthorizeEndpoint{
|
||||
return new ResponseEntity<>("", HttpStatus.NOT_FOUND);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "CAS REST认证接口", notes = "注销TGT状态",httpMethod="DELETE")
|
||||
@Operation(summary = "CAS REST认证接口", description = "注销TGT状态",method="DELETE")
|
||||
@RequestMapping(value=CasConstants.ENDPOINT.ENDPOINT_REST_TICKET_V1+"/{ticketGrantingTicket}",
|
||||
method=RequestMethod.DELETE)
|
||||
public ResponseEntity<String> destroyTicketGrantingTicket(
|
||||
@@ -170,7 +170,7 @@ public class CasRestV1Endpoint extends CasBaseAuthorizeEndpoint{
|
||||
return new ResponseEntity<>("", HttpStatus.NOT_FOUND);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "CAS REST认证接口", notes = "用户名密码登录接口",httpMethod="POST")
|
||||
@Operation(summary = "CAS REST认证接口", description = "用户名密码登录接口",method="POST")
|
||||
@RequestMapping(value=CasConstants.ENDPOINT.ENDPOINT_REST_USERS_V1,
|
||||
method=RequestMethod.POST,
|
||||
consumes = MediaType.APPLICATION_FORM_URLENCODED_VALUE)
|
||||
|
||||
@@ -37,19 +37,19 @@ import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
/**
|
||||
* @author Crystal.Sea
|
||||
*
|
||||
*/
|
||||
@Api(tags = "2-8-ExtendApi接口文档模块")
|
||||
@Tag(name = "2-8-ExtendApi接口文档模块")
|
||||
@Controller
|
||||
public class ExtendApiAuthorizeEndpoint extends AuthorizeBaseEndpoint{
|
||||
final static Logger _logger = LoggerFactory.getLogger(ExtendApiAuthorizeEndpoint.class);
|
||||
|
||||
@ApiOperation(value = "ExtendApi认证地址接口", notes = "参数应用ID",httpMethod="GET")
|
||||
@Operation(summary = "ExtendApi认证地址接口", description = "参数应用ID",method="GET")
|
||||
@RequestMapping("/authz/api/{id}")
|
||||
public ModelAndView authorize(HttpServletRequest request,@PathVariable("id") String id){
|
||||
|
||||
|
||||
@@ -40,14 +40,14 @@ import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
/**
|
||||
* @author Crystal.Sea
|
||||
*
|
||||
*/
|
||||
@Api(tags = "2-7-FormBased接口文档模块")
|
||||
@Tag(name = "2-7-FormBased接口文档模块")
|
||||
@Controller
|
||||
public class FormBasedAuthorizeEndpoint extends AuthorizeBaseEndpoint{
|
||||
final static Logger _logger = LoggerFactory.getLogger(FormBasedAuthorizeEndpoint.class);
|
||||
@@ -57,7 +57,7 @@ public class FormBasedAuthorizeEndpoint extends AuthorizeBaseEndpoint{
|
||||
|
||||
FormBasedDefaultAdapter defaultFormBasedAdapter=new FormBasedDefaultAdapter();
|
||||
|
||||
@ApiOperation(value = "FormBased认证地址接口", notes = "参数应用ID",httpMethod="GET")
|
||||
@Operation(summary = "FormBased认证地址接口", description = "参数应用ID",method="GET")
|
||||
@RequestMapping("/authz/formbased/{id}")
|
||||
public ModelAndView authorize(
|
||||
HttpServletRequest request,
|
||||
|
||||
@@ -43,14 +43,14 @@ import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
/**
|
||||
* @author Crystal.Sea
|
||||
*
|
||||
*/
|
||||
@Api(tags = "2-5-JWT令牌接口")
|
||||
@Tag(name = "2-5-JWT令牌接口")
|
||||
@Controller
|
||||
public class JwtAuthorizeEndpoint extends AuthorizeBaseEndpoint{
|
||||
|
||||
@@ -64,7 +64,7 @@ public class JwtAuthorizeEndpoint extends AuthorizeBaseEndpoint{
|
||||
@Autowired
|
||||
ApplicationConfig applicationConfig;
|
||||
|
||||
@ApiOperation(value = "JWT应用ID认证接口", notes = "应用ID",httpMethod="GET")
|
||||
@Operation(summary = "JWT应用ID认证接口", description = "应用ID",method="GET")
|
||||
@RequestMapping("/authz/jwt/{id}")
|
||||
public ModelAndView authorize(
|
||||
HttpServletRequest request,
|
||||
|
||||
@@ -66,8 +66,8 @@ import org.springframework.web.servlet.view.RedirectView;
|
||||
import org.springframework.web.util.UriComponents;
|
||||
import org.springframework.web.util.UriComponentsBuilder;
|
||||
import org.springframework.web.util.UriTemplate;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
@@ -86,7 +86,7 @@ import io.swagger.annotations.ApiOperation;
|
||||
* @author Vladimir Kryachko
|
||||
*
|
||||
*/
|
||||
@Api(tags = "2-1-OAuth v2.0 API文档模块")
|
||||
@Tag(name = "2-1-OAuth v2.0 API文档模块")
|
||||
@Controller
|
||||
@SessionAttributes("authorizationRequest")
|
||||
public class AuthorizationEndpoint extends AbstractEndpoint {
|
||||
@@ -111,7 +111,7 @@ public class AuthorizationEndpoint extends AbstractEndpoint {
|
||||
this.errorPage = errorPage;
|
||||
}
|
||||
|
||||
@ApiOperation(value = "OAuth 2.0 认证接口", notes = "传递参数应用ID,自动完成跳转认证拼接",httpMethod="GET")
|
||||
@Operation(summary = "OAuth 2.0 认证接口", description = "传递参数应用ID,自动完成跳转认证拼接",method="GET")
|
||||
@RequestMapping(OAuth2Constants.ENDPOINT.ENDPOINT_BASE + "/{id}")
|
||||
public ModelAndView authorize(
|
||||
HttpServletRequest request,
|
||||
@@ -135,7 +135,7 @@ public class AuthorizationEndpoint extends AbstractEndpoint {
|
||||
return WebContext.redirect(authorizationUrl);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "OAuth 2.0 认证接口", notes = "传递参数client_id,response_type,redirect_uri等",httpMethod="GET")
|
||||
@Operation(summary = "OAuth 2.0 认证接口", description = "传递参数client_id,response_type,redirect_uri等",method="GET")
|
||||
@RequestMapping(value = {
|
||||
OAuth2Constants.ENDPOINT.ENDPOINT_AUTHORIZE,
|
||||
OAuth2Constants.ENDPOINT.ENDPOINT_TENCENT_IOA_AUTHORIZE
|
||||
|
||||
@@ -45,8 +45,8 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
/**
|
||||
* Controller which decodes access tokens for clients who are not able to do so (or where opaque token values are used).
|
||||
@@ -54,7 +54,7 @@ import io.swagger.annotations.ApiOperation;
|
||||
* @author Luke Taylor
|
||||
* @author Joel D'sa
|
||||
*/
|
||||
@Api(tags = "2-1-OAuth v2.0 API文档模块")
|
||||
@Tag(name = "2-1-OAuth v2.0 API文档模块")
|
||||
@Controller
|
||||
public class CheckTokenEndpoint {
|
||||
|
||||
@@ -78,7 +78,7 @@ public class CheckTokenEndpoint {
|
||||
this.accessTokenConverter = accessTokenConverter;
|
||||
}
|
||||
|
||||
@ApiOperation(value = "OAuth 2.0 token检查接口", notes = "传递参数token",httpMethod="POST")
|
||||
@Operation(summary = "OAuth 2.0 token检查接口", description = "传递参数token",method="POST")
|
||||
@RequestMapping(value = OAuth2Constants.ENDPOINT.ENDPOINT_CHECK_TOKEN)
|
||||
@ResponseBody
|
||||
public Map<String, ?> checkToken(@RequestParam(OAuth2Constants.PARAMETER.TOKEN) String value) {
|
||||
|
||||
@@ -53,8 +53,8 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
/**
|
||||
* <p>
|
||||
@@ -73,7 +73,7 @@ import io.swagger.annotations.ApiOperation;
|
||||
* @author Dave Syer
|
||||
*
|
||||
*/
|
||||
@Api(tags = "2-1-OAuth v2.0 API文档模块")
|
||||
@Tag(name = "2-1-OAuth v2.0 API文档模块")
|
||||
@Controller
|
||||
public class TokenEndpoint extends AbstractEndpoint {
|
||||
|
||||
@@ -89,7 +89,7 @@ public class TokenEndpoint extends AbstractEndpoint {
|
||||
* @return OAuth2AccessToken Entity
|
||||
* @throws HttpRequestMethodNotSupportedException
|
||||
*/
|
||||
@ApiOperation(value = "OAuth 2.0 获取AccessToken接口", notes = "传递参数token等",httpMethod="GET")
|
||||
@Operation(summary = "OAuth 2.0 获取AccessToken接口", description = "传递参数token等",method="GET")
|
||||
@RequestMapping(value = {
|
||||
OAuth2Constants.ENDPOINT.ENDPOINT_TOKEN,
|
||||
OAuth2Constants.ENDPOINT.ENDPOINT_TENCENT_IOA_TOKEN
|
||||
@@ -103,7 +103,7 @@ public class TokenEndpoint extends AbstractEndpoint {
|
||||
return postAccessToken(parameters);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "OAuth 2.0 获取AccessToken接口", notes = "传递参数token等",httpMethod="POST")
|
||||
@Operation(summary = "OAuth 2.0 获取AccessToken接口", description = "传递参数token等",method="POST")
|
||||
@RequestMapping(value = {
|
||||
OAuth2Constants.ENDPOINT.ENDPOINT_TOKEN,
|
||||
OAuth2Constants.ENDPOINT.ENDPOINT_TENCENT_IOA_TOKEN
|
||||
|
||||
@@ -51,6 +51,7 @@ import org.springframework.beans.factory.annotation.Qualifier;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.web.bind.annotation.RequestHeader;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
import com.nimbusds.jose.EncryptionMethod;
|
||||
import com.nimbusds.jose.JWEAlgorithm;
|
||||
@@ -61,11 +62,12 @@ import com.nimbusds.jwt.EncryptedJWT;
|
||||
import com.nimbusds.jwt.JWT;
|
||||
import com.nimbusds.jwt.JWTClaimsSet;
|
||||
import com.nimbusds.jwt.JWTClaimsSet.Builder;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
import com.nimbusds.jwt.SignedJWT;
|
||||
|
||||
@Api(tags = "2-1-OAuth v2.0 API文档模块")
|
||||
@Tag(name = "2-1-OAuth v2.0 API文档模块")
|
||||
@Controller
|
||||
public class OpenIdConnectUserInfoEndpoint {
|
||||
final static Logger _logger = LoggerFactory.getLogger(OpenIdConnectUserInfoEndpoint.class);
|
||||
@@ -107,8 +109,8 @@ public class OpenIdConnectUserInfoEndpoint {
|
||||
@Autowired
|
||||
protected HttpResponseAdapter httpResponseAdapter;
|
||||
|
||||
@ApiOperation(value = "OIDC 用户信息接口", notes = "传递Authorization参数access_token",httpMethod="GET")
|
||||
@RequestMapping(value=OAuth2Constants.ENDPOINT.ENDPOINT_OPENID_CONNECT_USERINFO)
|
||||
@Operation(summary = "OIDC 用户信息接口", description = "传递Authorization参数access_token",method="GET")
|
||||
@RequestMapping(value=OAuth2Constants.ENDPOINT.ENDPOINT_OPENID_CONNECT_USERINFO, method={RequestMethod.POST, RequestMethod.GET})
|
||||
@ResponseBody
|
||||
public String connect10aUserInfo(
|
||||
@RequestHeader(value = "Authorization", required = true) String access_token,
|
||||
|
||||
@@ -49,11 +49,12 @@ import org.springframework.beans.factory.annotation.Qualifier;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.web.bind.annotation.RequestHeader;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
@Api(tags = "2-1-OAuth v2.0 API文档模块")
|
||||
@Tag(name = "2-1-OAuth v2.0 API文档模块")
|
||||
@Controller
|
||||
public class UserInfoEndpoint {
|
||||
final static Logger _logger = LoggerFactory.getLogger(UserInfoEndpoint.class);
|
||||
@@ -95,8 +96,8 @@ public class UserInfoEndpoint {
|
||||
@Autowired
|
||||
protected HttpResponseAdapter httpResponseAdapter;
|
||||
|
||||
@ApiOperation(value = "OAuth 2.0 用户信息接口", notes = "传递参数access_token",httpMethod="GET")
|
||||
@RequestMapping(value=OAuth2Constants.ENDPOINT.ENDPOINT_USERINFO)
|
||||
@Operation(summary = "OAuth 2.0 用户信息接口", description = "传递参数access_token",method="GET")
|
||||
@RequestMapping(value=OAuth2Constants.ENDPOINT.ENDPOINT_USERINFO, method={RequestMethod.POST, RequestMethod.GET})
|
||||
public void apiV20UserInfo(
|
||||
@RequestParam(value = "access_token", required = false) String access_token,
|
||||
@RequestHeader(value = "authorization", required = false) String authorization_bearer,
|
||||
|
||||
@@ -47,12 +47,13 @@ import org.springframework.beans.factory.annotation.Qualifier;
|
||||
import org.springframework.stereotype.Controller;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.bind.annotation.ResponseBody;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
@Api(tags = "2-2-SAML v2.0 API文档模块")
|
||||
@Tag(name = "2-2-SAML v2.0 API文档模块")
|
||||
@Controller
|
||||
@RequestMapping(value = { "/metadata/saml20/" })
|
||||
public class MetadataEndpoint {
|
||||
@@ -75,8 +76,8 @@ public class MetadataEndpoint {
|
||||
|
||||
public static String IDP_METADATA_PREFIX = "Idp_Metadata_";
|
||||
|
||||
@ApiOperation(value = "SAML 2.0 元数据接口", notes = "参数Idp_Metadata_应用ID",httpMethod="GET")
|
||||
@RequestMapping(value = "/{appid}.xml",produces = "application/xml")
|
||||
@Operation(summary = "SAML 2.0 元数据接口", description = "参数Idp_Metadata_应用ID",method="GET")
|
||||
@RequestMapping(value = "/{appid}.xml",produces = "application/xml", method={RequestMethod.POST, RequestMethod.GET})
|
||||
@ResponseBody
|
||||
public String metadata(HttpServletRequest request,
|
||||
HttpServletResponse response, @PathVariable("appid") String appId) {
|
||||
|
||||
@@ -40,8 +40,8 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
/**
|
||||
* idp init not need extract SAML request message
|
||||
@@ -49,7 +49,7 @@ import io.swagger.annotations.ApiOperation;
|
||||
* @author Crystal.Sea
|
||||
*
|
||||
*/
|
||||
@Api(tags = "2-2-SAML v2.0 API文档模块")
|
||||
@Tag(name = "2-2-SAML v2.0 API文档模块")
|
||||
@Controller
|
||||
public class IdpInitEndpoint {
|
||||
private final static Logger logger = LoggerFactory.getLogger(IdpInitEndpoint.class);
|
||||
@@ -85,7 +85,7 @@ public class IdpInitEndpoint {
|
||||
*
|
||||
*
|
||||
*/
|
||||
@ApiOperation(value = "SAML 2.0 IDP Init接口", notes = "传递参数应用ID",httpMethod="GET")
|
||||
@Operation(summary = "SAML 2.0 IDP Init接口", description = "传递参数应用ID",method="GET")
|
||||
@RequestMapping(value = "/authz/saml20/idpinit/{appid}", method=RequestMethod.GET)
|
||||
public ModelAndView authorizeIdpInit(
|
||||
HttpServletRequest request,
|
||||
|
||||
@@ -37,10 +37,10 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
@Api(tags = "2-2-SAML v2.0 API文档模块")
|
||||
@Tag(name = "2-2-SAML v2.0 API文档模块")
|
||||
@Controller
|
||||
public class LogoutSamlEndpoint {
|
||||
private final static Logger logger = LoggerFactory.getLogger(LogoutSamlEndpoint.class);
|
||||
@@ -53,7 +53,7 @@ public class LogoutSamlEndpoint {
|
||||
@Qualifier("samlValidaotrSuite")
|
||||
private SAML2ValidatorSuite validatorSuite;
|
||||
|
||||
@ApiOperation(value = "SAML单点注销地址接口", notes = "",httpMethod="GET")
|
||||
@Operation(summary = "SAML单点注销地址接口", description = "",method="GET")
|
||||
@SuppressWarnings("rawtypes")
|
||||
@RequestMapping(value = "/logout/saml", method=RequestMethod.GET)
|
||||
public ModelAndView samlRedirectLogout(
|
||||
|
||||
@@ -45,10 +45,10 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMethod;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
@Api(tags = "2-2-SAML v2.0 API文档模块")
|
||||
@Tag(name = "2-2-SAML v2.0 API文档模块")
|
||||
@Controller
|
||||
public class SingleSignOnEndpoint {
|
||||
private final static Logger logger = LoggerFactory.getLogger(SingleSignOnEndpoint.class);
|
||||
@@ -78,7 +78,7 @@ public class SingleSignOnEndpoint {
|
||||
@Autowired
|
||||
private AppsSaml20DetailsService saml20DetailsService;
|
||||
|
||||
@ApiOperation(value = "SAML 2.0 SP Init接收接口", notes = "传递参数应用ID",httpMethod="POST")
|
||||
@Operation(summary = "SAML 2.0 SP Init接收接口", description = "传递参数应用ID",method="POST")
|
||||
@RequestMapping(value = "/authz/saml20/{appid}", method=RequestMethod.POST)
|
||||
public ModelAndView authorizePost(
|
||||
HttpServletRequest request,
|
||||
@@ -88,7 +88,7 @@ public class SingleSignOnEndpoint {
|
||||
return extractSAMLRequest(extractPostBindingAdapter,appId,request);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "SAML 2.0 SP Init接收接口", notes = "传递参数应用ID",httpMethod="GET")
|
||||
@Operation(summary = "SAML 2.0 SP Init接收接口", description = "传递参数应用ID",method="GET")
|
||||
@RequestMapping(value = "/authz/saml20/{appid}", method=RequestMethod.GET)
|
||||
public ModelAndView authorizeRedirect(
|
||||
HttpServletRequest request,
|
||||
|
||||
@@ -43,14 +43,14 @@ import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.servlet.ModelAndView;
|
||||
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
|
||||
/**
|
||||
* @author Crystal.Sea
|
||||
*
|
||||
*/
|
||||
@Api(tags = "2-6-TokenBased接口文档模块")
|
||||
@Tag(name = "2-6-TokenBased接口文档模块")
|
||||
@Controller
|
||||
public class TokenBasedAuthorizeEndpoint extends AuthorizeBaseEndpoint{
|
||||
|
||||
@@ -63,7 +63,7 @@ public class TokenBasedAuthorizeEndpoint extends AuthorizeBaseEndpoint{
|
||||
@Autowired
|
||||
ApplicationConfig applicationConfig;
|
||||
|
||||
@ApiOperation(value = "TokenBased认证接口", notes = "传递参数应用ID",httpMethod="GET")
|
||||
@Operation(summary = "TokenBased认证接口", description = "传递参数应用ID",method="GET")
|
||||
@RequestMapping("/authz/tokenbased/{id}")
|
||||
public ModelAndView authorize(
|
||||
HttpServletRequest request,
|
||||
|
||||
Reference in New Issue
Block a user