Changeset 4245 for DASISH/t5.6/backend/annotator-backend/trunk/annotator-backend/src/main/java/eu/dasish/annotation/backend/rest/UserResource.java
- Timestamp:
- 01/09/14 17:02:09 (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
DASISH/t5.6/backend/annotator-backend/trunk/annotator-backend/src/main/java/eu/dasish/annotation/backend/rest/UserResource.java
r4217 r4245 42 42 import javax.xml.parsers.ParserConfigurationException; 43 43 import org.springframework.beans.factory.annotation.Autowired; 44 import org.springframework.security.access.annotation.Secured;45 44 import org.springframework.stereotype.Component; 46 45 import org.springframework.transaction.annotation.Transactional; … … 74 73 @Produces(MediaType.TEXT_XML) 75 74 @Path("{userid: " + BackendConstants.regExpIdentifier + "}") 76 @Secured("ROLE_USER")77 75 @Transactional(readOnly = true) 78 76 public JAXBElement<User> getUser(@PathParam("userid") String ExternalIdentifier) throws SQLException, IOException { … … 91 89 @Produces(MediaType.TEXT_XML) 92 90 @Path("/info") 93 @Secured("ROLE_USER")94 91 @Transactional(readOnly = true) 95 92 public JAXBElement<User> getUserByInfo(@QueryParam("email") String email) throws SQLException, IOException { … … 107 104 @Produces(MediaType.TEXT_XML) 108 105 @Path("{userid: " + BackendConstants.regExpIdentifier + "}/current") 109 @Secured("ROLE_USER")110 106 @Transactional(readOnly = true) 111 107 public JAXBElement<CurrentUserInfo> getCurrentUserInfo(@PathParam("userid") String ExternalIdentifier) throws IOException { … … 127 123 @Produces(MediaType.TEXT_XML) 128 124 @Path("{remoteId: " + BackendConstants.regExpIdentifier + "}") 129 @Secured("ROLE_ADMIN")130 125 public JAXBElement<User> addUser(@PathParam("userid") String remoteId, User user) throws SQLException { 131 126 dbIntegrityService.setServiceURI(uriInfo.getBaseUri().toString()); … … 139 134 @Produces(MediaType.TEXT_XML) 140 135 @Path("") 141 @Secured("ROLE_ADMIN")142 136 public JAXBElement<User> updateUser(User user) throws IOException{ 143 137 dbIntegrityService.setServiceURI(uriInfo.getBaseUri().toString());
Note: See TracChangeset
for help on using the changeset viewer.