improve remember me

This commit is contained in:
Sebastian Sdorra
2013-04-24 08:33:32 +02:00
parent a71472d909
commit 2e7e4c457a
11 changed files with 17 additions and 15 deletions

View File

@@ -65,6 +65,7 @@ import javax.ws.rs.Produces;
import javax.ws.rs.WebApplicationException;
import javax.ws.rs.core.MediaType;
import javax.ws.rs.core.Response;
import sonia.scm.security.Role;
/**
*
@@ -137,7 +138,7 @@ public class ChangePasswordResource
Response response = null;
Subject subject = SecurityUtils.getSubject();
if (!subject.isAuthenticated())
if (!subject.hasRole(Role.USER))
{
throw new ScmSecurityException("user is not authenticated");
}