]> git.argeo.org Git - lgpl/argeo-commons.git/blobdiff - org.argeo.security.core/src/org/argeo/osgi/useradmin/UserAdminConf.java
Fix glitches while testing the Security Perspective with LDAP backend
[lgpl/argeo-commons.git] / org.argeo.security.core / src / org / argeo / osgi / useradmin / UserAdminConf.java
index 2ed7edd98e1dd55aba1703bf8341bce095fc96c3..baf487bb033cda57419034d8ffac1d00e4525c4d 100644 (file)
@@ -16,23 +16,23 @@ import javax.naming.Context;
 
 /** Properties used to configure user admins. */
 public enum UserAdminConf {
-       /** Base DN */
+       /** Base DN (cannot be configured externally) */
        baseDn("dc=example,dc=com"),
 
-       /** URI of the underlying resource */
+       /** URI of the underlying resource (cannot be configured externally) */
        uri("ldap://localhost:10389"),
 
        /** User objectClass */
        userObjectClass("inetOrgPerson"),
 
        /** Relative base DN for users */
-       userBase("ou=users"),
+       userBase("ou=People"),
 
        /** Groups objectClass */
        groupObjectClass("groupOfNames"),
 
        /** Relative base DN for users */
-       groupBase("ou=groups"),
+       groupBase("ou=Groups"),
 
        /** Read-only source */
        readOnly(null);
@@ -52,7 +52,7 @@ public enum UserAdminConf {
 
        /** For use as Java property. */
        public String property() {
-               return getPrefix() + name();
+               return getPrefix() + '.' + name();
        }
 
        public String getPrefix() {
@@ -75,7 +75,7 @@ public enum UserAdminConf {
        }
 
        public static UserAdminConf local(String property) {
-               return UserAdminConf.valueOf(property.substring(PREFIX.length()));
+               return UserAdminConf.valueOf(property.substring(PREFIX.length() + 1));
        }
 
        /** Hides host and credentials. */