Package org.apereo.cas.mgmt
Class DashboardController
- java.lang.Object
-
- org.apereo.cas.mgmt.DashboardController
-
@RestController @RequestMapping(path="api/dashboard", produces="application/json") public class DashboardController extends java.lang.ObjectRest API controller for the /dashboard endpoint.- Since:
- 6.0
-
-
Constructor Summary
Constructors Constructor Description DashboardController()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.util.List<org.apereo.cas.mgmt.domain.AuditLog>audit(org.springframework.security.core.Authentication authentication, javax.servlet.http.HttpServletRequest request, java.util.Map<java.lang.String,java.lang.String> query)Method calls the /auditLog endpoint in all registered CAS Servers with passef query parameters.org.apereo.cas.mgmt.domain.Cachecache(org.springframework.security.core.Authentication authentication)Method calls the CAS Cluster pool for health info.voiddownloadAudit(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, org.springframework.security.core.Authentication authentication)Downloads audit log query result into plain file that is | delimited.java.util.Map<java.lang.String,java.lang.Object>info(org.springframework.security.core.Authentication authentication)Method calls the CAS server info endpoint to display deployed cas Server info.java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>>loggers(org.springframework.security.core.Authentication authentication)Method calls the CAS servers to query all set loggers and return a map to the client.java.util.Map<java.lang.String,java.util.List<java.lang.String>>release(org.springframework.security.core.Authentication authentication, java.util.Map<java.lang.String,java.lang.String> data)Method calls the CAS Server releaseAttributes for the passed user and service and returns map of attributes.java.util.Map<java.lang.String,java.util.List<java.lang.String>>resolve(org.springframework.security.core.Authentication authentication, java.lang.String id)Method calls the CAS Server resolveAttribute for the passed user and returns a map of attributes.java.lang.Stringresponse(org.springframework.security.core.Authentication authentication, java.util.Map<java.lang.String,java.lang.String> data)Method calls the CAS Server samlResponse for the passed user and service and returns the produced SAML Response.voidsetLogger(org.springframework.security.core.Authentication authentication, java.util.Map<java.lang.String,java.lang.String> map)Method will update a logger on a CAS server to the passed log level.java.util.List<org.apereo.cas.mgmt.domain.Server>status(org.springframework.security.core.Authentication authentication)Method returns a list of Server statuses for all configured cas servers in the cluster.org.apereo.cas.mgmt.domain.Serverupdate(org.springframework.security.core.Authentication authentication, int index)Returns the server status for the configured CAS server at the passed index.java.util.Mapwebflow(org.springframework.security.core.Authentication authentication, java.lang.String flowId)Method calls the CAS servers to provide the spring webflow report.
-
-
-
Method Detail
-
status
@GetMapping public java.util.List<org.apereo.cas.mgmt.domain.Server> status(org.springframework.security.core.Authentication authentication) throws java.lang.IllegalAccessExceptionMethod returns a list of Server statuses for all configured cas servers in the cluster.- Parameters:
authentication- - the user- Returns:
- - List of Server
- Throws:
java.lang.IllegalAccessException- - insufficient permission
-
update
@GetMapping("{index}") public org.apereo.cas.mgmt.domain.Server update(org.springframework.security.core.Authentication authentication, @PathVariable int index) throws java.lang.IllegalAccessExceptionReturns the server status for the configured CAS server at the passed index.- Parameters:
authentication- - the userindex- - index of CAS server- Returns:
- - Server
- Throws:
java.lang.IllegalAccessException- - insufficient permission
-
cache
@GetMapping("/cache") public org.apereo.cas.mgmt.domain.Cache cache(org.springframework.security.core.Authentication authentication) throws java.lang.IllegalAccessExceptionMethod calls the CAS Cluster pool for health info.- Parameters:
authentication- - the user- Returns:
- - Server health
- Throws:
java.lang.IllegalAccessException- - insufficient permissions
-
resolve
@GetMapping("/resolve/{id}") public java.util.Map<java.lang.String,java.util.List<java.lang.String>> resolve(org.springframework.security.core.Authentication authentication, @PathVariable java.lang.String id) throws java.lang.IllegalAccessExceptionMethod calls the CAS Server resolveAttribute for the passed user and returns a map of attributes.- Parameters:
authentication- - the responseid- - the user id- Returns:
- - the attributes
- Throws:
java.lang.IllegalAccessException- - insufficient persmissions
-
release
@PostMapping(value="/release", consumes="application/json") public java.util.Map<java.lang.String,java.util.List<java.lang.String>> release(org.springframework.security.core.Authentication authentication, @RequestBody java.util.Map<java.lang.String,java.lang.String> data) throws java.lang.IllegalAccessExceptionMethod calls the CAS Server releaseAttributes for the passed user and service and returns map of attributes.- Parameters:
authentication- - the requestdata- - map- Returns:
- - the attributes
- Throws:
java.lang.IllegalAccessException- - insufficient permissions
-
response
@PostMapping("/response") public java.lang.String response(org.springframework.security.core.Authentication authentication, @RequestBody java.util.Map<java.lang.String,java.lang.String> data) throws java.lang.IllegalAccessExceptionMethod calls the CAS Server samlResponse for the passed user and service and returns the produced SAML Response.- Parameters:
authentication- - the requestdata- - SAML Response- Returns:
- - the attributes
- Throws:
java.lang.IllegalAccessException- - insufficient permissions
-
info
@GetMapping("/info") public java.util.Map<java.lang.String,java.lang.Object> info(org.springframework.security.core.Authentication authentication) throws java.lang.IllegalAccessExceptionMethod calls the CAS server info endpoint to display deployed cas Server info.- Parameters:
authentication- - the user- Returns:
- - map of info details
- Throws:
java.lang.IllegalAccessException- - insufficient permissions
-
webflow
@GetMapping("/webflow") public java.util.Map webflow(org.springframework.security.core.Authentication authentication, @RequestParam(name="flowId",required=false) java.lang.String flowId) throws java.lang.IllegalAccessExceptionMethod calls the CAS servers to provide the spring webflow report.- Parameters:
authentication- - the requestflowId- the flow id- Returns:
- the map
- Throws:
java.lang.IllegalAccessException- - insufficient permissions
-
loggers
@GetMapping("/loggers") public java.util.Map<java.lang.String,java.util.Map<java.lang.String,java.lang.Object>> loggers(org.springframework.security.core.Authentication authentication) throws java.lang.IllegalAccessExceptionMethod calls the CAS servers to query all set loggers and return a map to the client.- Parameters:
authentication- - the request- Returns:
- - Map of Loggers for all configured servers
- Throws:
java.lang.IllegalAccessException- - insufficient permissions
-
setLogger
@PostMapping("/loggers") @ResponseStatus(OK) public void setLogger(org.springframework.security.core.Authentication authentication, @RequestBody java.util.Map<java.lang.String,java.lang.String> map) throws java.lang.IllegalAccessExceptionMethod will update a logger on a CAS server to the passed log level.- Parameters:
authentication- - the requestmap- - server, logger, level- Throws:
java.lang.IllegalAccessException- - insufficient persmissions
-
audit
@PostMapping("/audit") public java.util.List<org.apereo.cas.mgmt.domain.AuditLog> audit(org.springframework.security.core.Authentication authentication, javax.servlet.http.HttpServletRequest request, @RequestBody java.util.Map<java.lang.String,java.lang.String> query) throws java.lang.IllegalAccessExceptionMethod calls the /auditLog endpoint in all registered CAS Servers with passef query parameters. Responses from all servers are then sorted together by whenActionWasPerformed fields in the responses.- Parameters:
authentication- - the userrequest- - the requestquery- - query params- Returns:
- - List of matching audit entries
- Throws:
java.lang.IllegalAccessException- - insufficient permissions
-
downloadAudit
@GetMapping("/audit/download") public void downloadAudit(javax.servlet.http.HttpServletRequest request, javax.servlet.http.HttpServletResponse response, org.springframework.security.core.Authentication authentication)Downloads audit log query result into plain file that is | delimited.- Parameters:
request- - the request.response- - the response.authentication- - the user
-
-