Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChristian W. Damus2013-10-22 12:04:49 -0400
committerChristian W. Damus2013-10-22 12:04:49 -0400
commitb6d4bfc8ec03699d3d035dd778748aea07908467 (patch)
treecfc2de1ce52f2bdccec0001db8b432ee1549ec8c
parente8f9b0aace03238d785617138010d0c70d04f5e5 (diff)
downloadcdo-b6d4bfc8ec03699d3d035dd778748aea07908467.tar.gz
cdo-b6d4bfc8ec03699d3d035dd778748aea07908467.tar.xz
cdo-b6d4bfc8ec03699d3d035dd778748aea07908467.zip
[399306] [Security] Add password managementbugs/399306
https://bugs.eclipse.org/bugs/show_bug.cgi?id=399306 Allow users that do not currently have a password to set a password.
-rw-r--r--plugins/org.eclipse.emf.cdo.net4j/src/org/eclipse/emf/cdo/internal/net4j/protocol/ChangeCredentialsIndication.java9
1 files changed, 3 insertions, 6 deletions
diff --git a/plugins/org.eclipse.emf.cdo.net4j/src/org/eclipse/emf/cdo/internal/net4j/protocol/ChangeCredentialsIndication.java b/plugins/org.eclipse.emf.cdo.net4j/src/org/eclipse/emf/cdo/internal/net4j/protocol/ChangeCredentialsIndication.java
index d110fbfc54..2fdd001f07 100644
--- a/plugins/org.eclipse.emf.cdo.net4j/src/org/eclipse/emf/cdo/internal/net4j/protocol/ChangeCredentialsIndication.java
+++ b/plugins/org.eclipse.emf.cdo.net4j/src/org/eclipse/emf/cdo/internal/net4j/protocol/ChangeCredentialsIndication.java
@@ -92,10 +92,7 @@ public class ChangeCredentialsIndication extends IndicationWithMonitoring
}
String authUserID = credentials.getUserID();
- if (StringUtil.isEmpty(authUserID))
- {
- throw new IllegalStateException("No userID provided"); //$NON-NLS-1$
- }
+ // don't require the current credentials because the user may not have any, yet
String authPassword = new String(credentials.getPassword());
if (StringUtil.isEmpty(authPassword))
@@ -123,8 +120,8 @@ public class ChangeCredentialsIndication extends IndicationWithMonitoring
case RESET_PASSWORD:
stream.writeString(authUserID);
stream.writeString(authPassword);
- stream.writeString(userID);
- stream.writeString(newPassword);
+ stream.writeString(userID);
+ stream.writeString(newPassword);
break;
}

Back to the top