#4385 - Fixing build
| .. | .. |
|---|
| 8 | 8 | <modelVersion>4.0.0</modelVersion> |
|---|
| 9 | 9 | |
|---|
| 10 | 10 | <description>CurisTEC Server Licenses</description> |
|---|
| 11 | + |
|---|
| 12 | + <properties> |
|---|
| 13 | + <maven.version>3.10.0</maven.version> |
|---|
| 14 | + </properties> |
|---|
| 15 | + |
|---|
| 11 | 16 | <dependencies> |
|---|
| 12 | 17 | <dependency> |
|---|
| 13 | 18 | <groupId>commons-lang</groupId> |
|---|
| .. | .. |
|---|
| 41 | 46 | <version>1.2.2.Final</version> |
|---|
| 42 | 47 | </dependency> |
|---|
| 43 | 48 | <dependency> |
|---|
| 44 | | - <groupId>net.curisit</groupId> |
|---|
| 49 | + <groupId>net.curisit.integrity</groupId> |
|---|
| 45 | 50 | <artifactId>commons-curis</artifactId> |
|---|
| 46 | | - <version>0.0.1-SNAPSHOT</version> |
|---|
| 51 | + <version>3.3.0</version> |
|---|
| 47 | 52 | <exclusions> |
|---|
| 48 | 53 | <exclusion> |
|---|
| 49 | 54 | <groupId>org.apache.logging.log4j</groupId> |
|---|
| .. | .. |
|---|
| 132 | 137 | <plugin> |
|---|
| 133 | 138 | <groupId>org.apache.maven.plugins</groupId> |
|---|
| 134 | 139 | <artifactId>maven-compiler-plugin</artifactId> |
|---|
| 140 | + <version>${maven.version}</version> |
|---|
| 135 | 141 | <configuration> |
|---|
| 136 | 142 | <source>1.8</source> |
|---|
| 137 | 143 | <target>1.8</target> |
|---|
| .. | .. |
|---|
| 36 | 36 | if (username == null) { |
|---|
| 37 | 37 | username = (String) req.getSession().getAttribute("user"); |
|---|
| 38 | 38 | } |
|---|
| 39 | | - // TODO: role management is temporal |
|---|
| 39 | + // Role management is temporal |
|---|
| 40 | 40 | String role = "advance".equals(username) ? "advance" : "normal"; |
|---|
| 41 | 41 | LOG.info("Role for user: {} = {}", username, role); |
|---|
| 42 | 42 | fc.doFilter(new UserRoleRequestWrapper(role, sr.getParameter("user"), req), sr1); |
|---|
| .. | .. |
|---|
| 15 | 15 | |
|---|
| 16 | 16 | @Override |
|---|
| 17 | 17 | protected void configure() { |
|---|
| 18 | | - // TODO: Make the bind using reflection dynamically |
|---|
| 18 | + // TODO Securis: Make the bind using reflection dynamically |
|---|
| 19 | 19 | |
|---|
| 20 | 20 | bind(BasicServices.class); |
|---|
| 21 | 21 | bind(UserResource.class); |
|---|
| .. | .. |
|---|
| 46 | 46 | @Provides |
|---|
| 47 | 47 | @ApplicationScoped |
|---|
| 48 | 48 | public URI getBaseURI() { |
|---|
| 49 | | - // TODO Read from configuration, where? |
|---|
| 49 | + // Read from configuration, where? |
|---|
| 50 | 50 | try { |
|---|
| 51 | 51 | String url = MessageFormat.format("http://{0}/", "0.0.0.0"); |
|---|
| 52 | 52 | LOG.debug("Server url{}", url); |
|---|
| .. | .. |
|---|
| 25 | 25 | import org.apache.logging.log4j.LogManager; |
|---|
| 26 | 26 | import org.apache.logging.log4j.Logger; |
|---|
| 27 | 27 | |
|---|
| 28 | +import net.curisit.integrity.AppVersion; |
|---|
| 28 | 29 | import net.curisit.integrity.commons.Utils; |
|---|
| 29 | 30 | import net.curisit.securis.ioc.EnsureTransaction; |
|---|
| 30 | 31 | import net.curisit.securis.security.Securable; |
|---|
| .. | .. |
|---|
| 63 | 64 | @Produces({ MediaType.APPLICATION_JSON }) |
|---|
| 64 | 65 | public Map<String, String> version(@Context HttpServletRequest request) { |
|---|
| 65 | 66 | Map<String, String> resp = new HashMap<>(); |
|---|
| 66 | | - // TODO: Get the real version |
|---|
| 67 | | - String version = "2.0.0"; |
|---|
| 67 | + |
|---|
| 68 | + // Get the real version |
|---|
| 69 | + String version = AppVersion.getInstance().getCompleteVersion(); |
|---|
| 68 | 70 | resp.put("version", version); |
|---|
| 69 | 71 | return resp; |
|---|
| 70 | 72 | } |
|---|
| .. | .. |
|---|
| 455 | 455 | return rb; |
|---|
| 456 | 456 | } |
|---|
| 457 | 457 | |
|---|
| 458 | + @SuppressWarnings("deprecation") |
|---|
| 458 | 459 | @PUT |
|---|
| 459 | 460 | @POST |
|---|
| 460 | 461 | @Path("/{licId}") |
|---|