diff --git a/dmp-backend/pom.xml b/dmp-backend/pom.xml
index a81d94abd..799574d81 100644
--- a/dmp-backend/pom.xml
+++ b/dmp-backend/pom.xml
@@ -7,10 +7,14 @@
0.0.1-SNAPSHOT
war
-
+ 1.19.0
+ 1.19.0
+
0.0.1-SNAPSHOT
4.3.8.RELEASE
+
+ 4.2.3.RELEASE
1.19.1
7.0.35
5.2.9.Final
@@ -203,6 +207,54 @@
runtime
+
+
+
+
+
+
+
+
+
+
+
+ com.google.apis
+ google-api-services-oauth2
+ v2-rev75-1.19.0
+
+
+ com.google.http-client
+ google-http-client-jackson2
+ ${project.http.version}
+
+
+ com.google.oauth-client
+ google-oauth-client-jetty
+ ${project.oauth.version}
+
+
+
+
+
+
+ org.springframework.security
+ spring-security-web
+ ${org.springframework.security.version}
+
+
+ org.springframework.security
+ spring-security-config
+ ${org.springframework.security.version}
+
+
+
+ org.springframework
+ spring-tx
+ ${org.springframework.version}
+
+
+
+
org.apache.commons
@@ -211,8 +263,6 @@
-
-
diff --git a/dmp-backend/src/main/java/exceptions/NonValidTokenException.java b/dmp-backend/src/main/java/exceptions/NonValidTokenException.java
new file mode 100644
index 000000000..0d5273f5c
--- /dev/null
+++ b/dmp-backend/src/main/java/exceptions/NonValidTokenException.java
@@ -0,0 +1,11 @@
+package exceptions;
+
+public class NonValidTokenException extends Exception {
+
+ private static final long serialVersionUID = -2834659827755141154L;
+
+ public NonValidTokenException(String msg) {
+ super(msg);
+ }
+
+}
diff --git a/dmp-backend/src/main/java/rest/BackendInterface.java b/dmp-backend/src/main/java/rest/BackendInterface.java
index 5cbfa3a69..c31a769d1 100644
--- a/dmp-backend/src/main/java/rest/BackendInterface.java
+++ b/dmp-backend/src/main/java/rest/BackendInterface.java
@@ -76,6 +76,7 @@ public class BackendInterface {
+
// FETCH BY DMP(S)
@RequestMapping(method = RequestMethod.GET, value = { "/DMP" }, produces="text/plain")
diff --git a/dmp-backend/src/main/java/rest/TokenManager.java b/dmp-backend/src/main/java/rest/TokenManager.java
new file mode 100644
index 000000000..d302de706
--- /dev/null
+++ b/dmp-backend/src/main/java/rest/TokenManager.java
@@ -0,0 +1,157 @@
+//package rest;
+//
+//import java.io.BufferedReader;
+//import java.io.IOException;
+//import java.io.InputStreamReader;
+//import java.io.Serializable;
+//import java.io.UnsupportedEncodingException;
+//import java.net.HttpURLConnection;
+//import java.net.URL;
+//import java.security.GeneralSecurityException;
+//import java.util.Arrays;
+//import java.util.Base64;
+//import java.util.Collections;
+//import java.util.List;
+//import java.util.UUID;
+//
+//import org.springframework.http.HttpStatus;
+//import org.springframework.http.ResponseEntity;
+//import org.springframework.web.bind.annotation.CrossOrigin;
+//import org.springframework.web.bind.annotation.RequestBody;
+//import org.springframework.web.bind.annotation.RequestMapping;
+//import org.springframework.web.bind.annotation.RequestMethod;
+//import org.springframework.web.bind.annotation.RequestParam;
+//import org.springframework.web.bind.annotation.ResponseBody;
+//import org.springframework.web.bind.annotation.RestController;
+//
+//import com.fasterxml.jackson.databind.ObjectMapper;
+//
+//import entities.DMP;
+////import io.jsonwebtoken.Claims;
+////import io.jsonwebtoken.ExpiredJwtException;
+////import io.jsonwebtoken.Jws;
+////import io.jsonwebtoken.Jwts;
+////import io.jsonwebtoken.MalformedJwtException;
+////import io.jsonwebtoken.SignatureException;
+////import io.jsonwebtoken.UnsupportedJwtException;
+////import security.GoogleKey;
+////import security.GoogleKeys;
+//
+//
+//import com.google.api.client.googleapis.auth.oauth2.GoogleIdToken;
+//import com.google.api.client.googleapis.auth.oauth2.GoogleIdToken.Payload;
+//import com.google.api.client.googleapis.auth.oauth2.GoogleIdTokenVerifier;
+//import com.google.api.client.http.HttpTransport;
+//import com.google.api.client.http.apache.ApacheHttpTransport;
+//import com.google.api.client.http.javanet.NetHttpTransport;
+//import com.google.api.client.json.JsonFactory;
+//import com.google.api.client.json.jackson2.JacksonFactory;
+//
+//
+//
+//@RestController
+//@CrossOrigin
+//public class TokenManager {
+//
+//
+//// public static final String GOOGLE_KEYS_URL = "https://www.googleapis.com/oauth2/v3/certs";
+//// public static GoogleKeys GOOGLE_KEYS;
+//
+// private static final JacksonFactory jacksonFactory = new JacksonFactory();
+// private static final HttpTransport transport = new NetHttpTransport();
+//
+// private static GoogleIdTokenVerifier verifier;
+//
+// private static final List clientIDs = Arrays.asList("1010962018903-glegmqudqtl1lub0150vacopbu06lgsg.apps.googleusercontent.com");
+//
+//
+//
+//
+//
+//
+// static {
+// verifier = new GoogleIdTokenVerifier.Builder(transport, jacksonFactory)
+// .setAudience(clientIDs)
+// // Or, if multiple clients access the backend:
+// //.setAudience(Arrays.asList(CLIENT_ID_1, CLIENT_ID_2, CLIENT_ID_3))
+// .build();
+// }
+//
+//
+//
+//
+// @RequestMapping(method = RequestMethod.POST, value = { "/login" }, produces="text/plain")
+// public @ResponseBody ResponseEntity