diff --git a/pom.xml b/pom.xml
index 00290b8d34b2647f8f64f7e26aa6565de85820ea..b3e759f9bf3c110284c48c0b5c200778bebf91f1 100644
--- a/pom.xml
+++ b/pom.xml
@@ -217,12 +217,12 @@
 		<dependency>
 			<groupId>org.pac4j</groupId>
 			<artifactId>spring-security-pac4j</artifactId>
-			<version>2.1.2</version>
+			<version>3.0.0</version>
 		</dependency>
 		<dependency>
 			<groupId>org.pac4j</groupId>
 			<artifactId>pac4j-oauth</artifactId>
-			<version>1.9.7</version>
+			<version>2.1.0</version>
 		</dependency>
 		<dependency>
 			<groupId>com.corundumstudio.socketio</groupId>
diff --git a/src/main/java/de/thm/arsnova/entities/User.java b/src/main/java/de/thm/arsnova/entities/User.java
index c3ed9bf78650a2236a06631794b71ddf6204900a..21954341a635bc94b63738f88e89507173dae22b 100644
--- a/src/main/java/de/thm/arsnova/entities/User.java
+++ b/src/main/java/de/thm/arsnova/entities/User.java
@@ -57,7 +57,7 @@ public class User implements Serializable {
 	}
 
 	public User(FacebookProfile profile) {
-		setUsername(profile.getProfileUrl());
+		setUsername(profile.getProfileUrl().toString());
 		setType(User.FACEBOOK);
 	}
 
diff --git a/src/test/java/de/thm/arsnova/services/UserServiceTest.java b/src/test/java/de/thm/arsnova/services/UserServiceTest.java
index 2421f52bbc59e3bd85c135a962aa46c518e999a6..bb1c1a04c1fd6e9834a58a3397b99f9c7bfa127b 100644
--- a/src/test/java/de/thm/arsnova/services/UserServiceTest.java
+++ b/src/test/java/de/thm/arsnova/services/UserServiceTest.java
@@ -23,9 +23,9 @@ import org.junit.Test;
 import org.junit.runner.RunWith;
 import org.junit.runners.BlockJUnit4ClassRunner;
 import org.pac4j.oauth.profile.JsonHelper;
-import org.pac4j.oauth.profile.google2.Google2AttributesDefinition;
 import org.pac4j.oauth.profile.google2.Google2Email;
 import org.pac4j.oauth.profile.google2.Google2Profile;
+import org.pac4j.oauth.profile.google2.Google2ProfileDefinition;
 import org.springframework.security.authentication.AnonymousAuthenticationToken;
 import org.springframework.security.authentication.UsernamePasswordAuthenticationToken;
 import org.springframework.security.core.GrantedAuthority;
@@ -62,8 +62,8 @@ public class UserServiceTest {
 		ArrayList<Google2Email> emails = new ArrayList<>();
 		emails.add(email);
 		Google2Profile profile = new Google2Profile();
-		profile.addAttribute(Google2AttributesDefinition.DISPLAY_NAME, "ptsr00");
-		profile.addAttribute(Google2AttributesDefinition.EMAILS, JsonHelper.toJSONString(emails));
+		profile.addAttribute(Google2ProfileDefinition.DISPLAY_NAME, "ptsr00");
+		profile.addAttribute(Google2ProfileDefinition.EMAILS, emails);
 
 		socketid2user.put(UUID.randomUUID(), new User(profile));
 		List<GrantedAuthority> authorities = new ArrayList<>();