@Controller @RequestMapping(value="resource") public class ProtectedResourceRegistrationEndpoint extends Object
Constructor and Description |
---|
ProtectedResourceRegistrationEndpoint() |
Modifier and Type | Method and Description |
---|---|
String |
deleteResource(String clientId,
org.springframework.ui.Model m,
org.springframework.security.oauth2.provider.OAuth2Authentication auth)
Delete the indicated client from the system.
|
String |
readResourceConfiguration(String clientId,
org.springframework.ui.Model m,
org.springframework.security.oauth2.provider.OAuth2Authentication auth)
Get the meta information for a client.
|
String |
registerNewProtectedResource(String jsonString,
org.springframework.ui.Model m)
Create a new Client, issue a client ID, and create a registration access token.
|
String |
updateProtectedResource(String clientId,
String jsonString,
org.springframework.ui.Model m,
org.springframework.security.oauth2.provider.OAuth2Authentication auth)
Update the metainformation for a given client.
|
public static final String URL
public ProtectedResourceRegistrationEndpoint()
@RequestMapping(method=POST, consumes="application/json", produces="application/json") public String registerNewProtectedResource(@RequestBody String jsonString, org.springframework.ui.Model m)
jsonString
- m
- p
- @PreAuthorize(value="hasRole(\'ROLE_CLIENT\') and #oauth2.hasScope(\'resource-token\')") @RequestMapping(value="/{id}", method=GET, produces="application/json") public String readResourceConfiguration(@PathVariable(value="id") String clientId, org.springframework.ui.Model m, org.springframework.security.oauth2.provider.OAuth2Authentication auth)
clientId
- m
- auth
- @PreAuthorize(value="hasRole(\'ROLE_CLIENT\') and #oauth2.hasScope(\'resource-token\')") @RequestMapping(value="/{id}", method=PUT, produces="application/json", consumes="application/json") public String updateProtectedResource(@PathVariable(value="id") String clientId, @RequestBody String jsonString, org.springframework.ui.Model m, org.springframework.security.oauth2.provider.OAuth2Authentication auth)
clientId
- jsonString
- m
- auth
- @PreAuthorize(value="hasRole(\'ROLE_CLIENT\') and #oauth2.hasScope(\'resource-token\')") @RequestMapping(value="/{id}", method=DELETE, produces="application/json") public String deleteResource(@PathVariable(value="id") String clientId, org.springframework.ui.Model m, org.springframework.security.oauth2.provider.OAuth2Authentication auth)
clientId
- m
- auth
- Copyright © 2018. All rights reserved.