portals-jetspeed-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From tay...@apache.org
Subject cvs commit: jakarta-jetspeed/webapp/WEB-INF/db jetspeed.data jetspeed.properties jetspeed.script
Date Sun, 08 Dec 2002 19:33:53 GMT
taylor      2002/12/08 11:33:53

  Modified:    build/torque build.xml
               build/torque/schema coffees-schema.xml
               src/java/org/apache/jetspeed/modules/localization
                        JetspeedLocalization_de.properties
                        JetspeedLocalization_el.properties
                        JetspeedLocalization_en.properties
                        JetspeedLocalization_es.properties
                        JetspeedLocalization_fr.properties
                        JetspeedLocalization_it.properties
                        JetspeedLocalization_ja.properties
                        JetspeedLocalization_my.properties
                        JetspeedLocalization_nl.properties
                        JetspeedLocalization_no.properties
               src/java/org/apache/jetspeed/om/security/ldap
                        BaseLDAPObject.java LDAPGroup.java
                        LDAPPermission.java LDAPRole.java LDAPUser.java
               src/java/org/apache/jetspeed/services/ldap LDAPService.java
                        LDAPURL.java
               src/java/org/apache/jetspeed/services/security
                        JetspeedSecurityCache.java SecurityCacheImpl.java
                        SecurityCacheService.java TestUserManagement.java
               src/java/org/apache/jetspeed/services/security/ldap
                        LDAPAuthentication.java LDAPGroupManagement.java
                        LDAPPermissionManagement.java
                        LDAPRoleManagement.java LDAPUserManagement.java
               src/java/org/apache/jetspeed/services/security/turbine
                        TurbineRoleManagement.java
               webapp/WEB-INF/db jetspeed.data jetspeed.properties
                        jetspeed.script
  Log:
  - checked in new Japanese localization from Shinsuke
  - added a few new localization properties for tutorial. didn't translate them yet, any volunteeers?
  - modified the coffee schema for tutorial
  - fixed bug #15157 (Applying new permissions to roles fails)
  - LDAP Security implementation work in progress. Still working on it, just wanted to get it checked in.
  
  Revision  Changes    Path
  1.21      +0 -1      jakarta-jetspeed/build/torque/build.xml
  
  Index: build.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/build/torque/build.xml,v
  retrieving revision 1.20
  retrieving revision 1.21
  diff -u -r1.20 -r1.21
  --- build.xml	4 Dec 2002 02:01:33 -0000	1.20
  +++ build.xml	8 Dec 2002 19:33:52 -0000	1.21
  @@ -21,7 +21,6 @@
   
       <!-- unjar templates to workaround torque problems -->
       <mkdir dir="templates.scratch"/>
  -<!--    <unjar src="../../lib/torque-3.0-b5-dev.jar" dest="templates.scratch"/> -->
       <unjar src="../../lib/torque-3.0.jar" dest="templates.scratch"/> 
   
       <antcall target="sql"/>
  
  
  
  1.2       +4 -3      jakarta-jetspeed/build/torque/schema/coffees-schema.xml
  
  Index: coffees-schema.xml
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/build/torque/schema/coffees-schema.xml,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- coffees-schema.xml	14 May 2002 06:44:36 -0000	1.1
  +++ coffees-schema.xml	8 Dec 2002 19:33:52 -0000	1.2
  @@ -31,9 +31,10 @@
   -->
   
   <database>
  -    <table name="COFFEES">
  -        <column name="COF_NAME" type="VARCHAR" size="50" />
  -        <column name="SUP_ID" type="INTEGER" />
  +    <table name="COFFEES" idMethod="native">
  +        <column name="COFFEE_ID" required="true" primaryKey="true" autoIncrement="true" type="INTEGER"/>   
  +        <column name="COFFEE_NAME" type="VARCHAR" size="50" />
  +        <column name="SUPPLIER_ID" type="INTEGER" />
           <column name="PRICE" type="FLOAT" />
           <column name="SALES" type="INTEGER" />
           <column name="TOTAL" type="INTEGER" />
  
  
  
  1.10      +7 -1      jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_de.properties
  
  Index: JetspeedLocalization_de.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_de.properties,v
  retrieving revision 1.9
  retrieving revision 1.10
  diff -u -r1.9 -r1.10
  --- JetspeedLocalization_de.properties	16 Sep 2002 17:57:14 -0000	1.9
  +++ JetspeedLocalization_de.properties	8 Dec 2002 19:33:52 -0000	1.10
  @@ -97,6 +97,7 @@
   USERFORM_LASTNAMEMSG=Nachname:
   USERFORM_EMAILMSG=Email:
   USERFORM_CANCEL=Abbrechen
  +USERFORM_SAVE=Save
   USERFORM_UPDATE=Zugang aktualisieren
   USERFORM_CREATE=Neue Registrierung
   
  @@ -112,3 +113,8 @@
   PASSWORDFORM_THESAME_MSG=Old and new passwords are the same. Please select another new password.
   PASSWORDFORM_EXPIRED_MSG=Your password has expired. Please change your password.
   PASSWORDFORM_FAILED_MSG=Invalid user name and/or password. Please reenter your credentials.
  +
  +EDIT=Edit
  +VIEW=View
  +DELETE=Delete
  +ADD=Add
  
  
  
  1.2       +6 -0      jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_el.properties
  
  	<<Binary file>>
  
  
  1.26      +7 -1      jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_en.properties
  
  Index: JetspeedLocalization_en.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_en.properties,v
  retrieving revision 1.25
  retrieving revision 1.26
  diff -u -r1.25 -r1.26
  --- JetspeedLocalization_en.properties	25 Nov 2002 03:47:17 -0000	1.25
  +++ JetspeedLocalization_en.properties	8 Dec 2002 19:33:52 -0000	1.26
  @@ -91,6 +91,7 @@
   USERFORM_FIRSTNAMEMSG=First Name:
   USERFORM_LASTNAMEMSG=Last Name:
   USERFORM_EMAILMSG=Email:
  +USERFORM_SAVE=Save
   USERFORM_CANCEL=Cancel
   USERFORM_RESET=Reset
   USERFORM_UPDATE=Update Account
  @@ -192,4 +193,9 @@
   PASSWORDFORM_THESAME_MSG=Old and new passwords are the same. Please select another new password.
   PASSWORDFORM_EXPIRED_MSG=Your password has expired. Please change your password.
   PASSWORDFORM_FAILED_MSG=Invalid user name and/or password. Please reenter your credentials.
  +
  +EDIT=Edit
  +VIEW=View
  +DELETE=Delete
  +ADD=Add
   
  
  
  
  1.9       +8 -1      jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_es.properties
  
  Index: JetspeedLocalization_es.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_es.properties,v
  retrieving revision 1.8
  retrieving revision 1.9
  diff -u -r1.8 -r1.9
  --- JetspeedLocalization_es.properties	16 Sep 2002 17:57:14 -0000	1.8
  +++ JetspeedLocalization_es.properties	8 Dec 2002 19:33:52 -0000	1.9
  @@ -57,6 +57,7 @@
   
   MAINMENU_WELCOMEMSG=Welcome 
   
  +USERFORM_SAVE=Save
   USERFORM_CANCEL=Cancelar
   USERFORM_CREATE=Crear nueva cuenta
   USERFORM_RESET=Reiniciar
  @@ -125,3 +126,9 @@
   PASSWORDFORM_THESAME_MSG=Old and new passwords are the same. Please select another new password.
   PASSWORDFORM_EXPIRED_MSG=Your password has expired. Please change your password.
   PASSWORDFORM_FAILED_MSG=Invalid user name and/or password. Please reenter your credentials.
  +
  +EDIT=Edit
  +VIEW=View
  +DELETE=Delete
  +ADD=Add
  +
  
  
  
  1.13      +6 -2      jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_fr.properties
  
  Index: JetspeedLocalization_fr.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_fr.properties,v
  retrieving revision 1.12
  retrieving revision 1.13
  diff -u -r1.12 -r1.13
  --- JetspeedLocalization_fr.properties	24 Oct 2002 10:39:57 -0000	1.12
  +++ JetspeedLocalization_fr.properties	8 Dec 2002 19:33:52 -0000	1.13
  @@ -93,6 +93,7 @@
   USERFORM_FIRSTNAMEMSG=Pr&eacute;nom :
   USERFORM_LASTNAMEMSG=Nom :
   USERFORM_EMAILMSG=Email :
  +USERFORM_SAVE=Save
   USERFORM_CANCEL=Annuler
   USERFORM_RESET=R&eacute;tablir
   USERFORM_UPDATE=Modifier ce Compte
  @@ -195,4 +196,7 @@
   PASSWORDFORM_EXPIRED_MSG=Votre mot de passe a expir&eacute;. Merci de le changer.
   PASSWORDFORM_FAILED_MSG=Identifiant et/ou mot de passe invalide. Veuillez resaisir vos informations.
   
  -
  +EDIT=Edit
  +VIEW=View
  +DELETE=Delete
  +ADD=Add
  
  
  
  1.5       +5 -0      jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_it.properties
  
  Index: JetspeedLocalization_it.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_it.properties,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- JetspeedLocalization_it.properties	23 Sep 2002 15:32:07 -0000	1.4
  +++ JetspeedLocalization_it.properties	8 Dec 2002 19:33:52 -0000	1.5
  @@ -90,6 +90,7 @@
   USERFORM_FIRSTNAMEMSG=Nome:
   USERFORM_LASTNAMEMSG=Cognome:
   USERFORM_EMAILMSG=Email:
  +USERFORM_SAVE=Save
   USERFORM_CANCEL=Cancella
   USERFORM_RESET=Cancella
   USERFORM_UPDATE=Aggiorna Account
  @@ -188,3 +189,7 @@
   PASSWORDFORM_EXPIRED_MSG=La tua password  scaduta. Cambia la tua password.
   PASSWORDFORM_FAILED_MSG=Lo username o la password sono sbagliati. Reinseriscili correttamente.
   
  +EDIT=Edit
  +VIEW=View
  +DELETE=Delete
  +ADD=Add
  
  
  
  1.6       +13 -8     jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_ja.properties
  
  Index: JetspeedLocalization_ja.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_ja.properties,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- JetspeedLocalization_ja.properties	16 Sep 2002 17:57:14 -0000	1.5
  +++ JetspeedLocalization_ja.properties	8 Dec 2002 19:33:52 -0000	1.6
  @@ -15,7 +15,7 @@
   LOGINHELP_TITLE=\u30a2\u30ab\u30a6\u30f3\u30c8\u30ed\u30b0\u30a4\u30f3\u30a2\u30b7\u30b9\u30bf\u30f3\u30c8
   LOGINHELP_NOTICE=\u3055\u3089\u306b\u652f\u63f4\u304c\u5fc5\u8981\u306a\u5834\u5408\u3001\u4ee5\u4e0b\u306e\u30a2\u30c9\u30ec\u30b9\u306b\u30e1\u30fc\u30eb\u3092\u9001\u3063\u3066\u304f\u3060\u3055\u3044\u3002
   
  -SECURITY_NO_ACCESS=\u3053\u308c\u3089\u306e Portlet \u3078\u306e\u30a2\u30af\u30bb\u30b9\u306f\u3067\u304d\u307e\u305b\u3093\u3002
  +SECURITY_NO_ACCESS=\u3053\u308c\u3089\u306e\u30dd\u30fc\u30c8\u30ec\u30c3\u30c8\u3078\u306e\u30a2\u30af\u30bb\u30b9\u306f\u3067\u304d\u307e\u305b\u3093\u3002
   
   PASSWORDREMINDER_EMAIL_HEADER=\u3053\u3093\u306b\u3061\u306f
   PASSWORDREMINDER_EMAIL_BODY1=Jetspeed \u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u30d1\u30b9\u30ef\u30fc\u30c9:
  @@ -42,7 +42,7 @@
   
   LOGOUTUSER_THANKS=\u3054\u5229\u7528\u3044\u305f\u3060\u304d\u3042\u308a\u304c\u3068\u3046\u3054\u3056\u3044\u307e\u3059\u3002\u307e\u305f\uff0c\u3054\u5229\u7528\u304f\u3060\u3055\u3044\uff0e
   
  -SENDCONFIRMATIONEMAIL_BODY1=Apache \u306e Jetspeed Portal \u3078\u3088\u3046\u3053\u305d\u3002 \u65b0\u898f\u30a2\u30ab\u30a6\u30f3\u30c8\u304c\u4f5c\u6210\u3055\u308c\u307e\u3057\u305f\u3002\n\
  +SENDCONFIRMATIONEMAIL_BODY1=Apache \u306e Jetspeed \u30dd\u30fc\u30bf\u30eb\u3078\u3088\u3046\u3053\u305d\u3002 \u65b0\u898f\u30a2\u30ab\u30a6\u30f3\u30c8\u304c\u4f5c\u6210\u3055\u308c\u307e\u3057\u305f\u3002\n\
   \u767b\u9332\u306e\u78ba\u8a8d\u306e\u305f\u3081\u3001\u4ee5\u4e0b\u306e\u30b7\u30fc\u30af\u30ec\u30c3\u30c8\u30ad\u30fc\u3067\u30ed\u30b0\u30a4\u30f3\u3057\u3066\u304f\u3060\u3055\u3044\u3002\n
   SENDCONFIRMATIONEMAIL_BODY2=\u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u78ba\u8a8d\u306e\u305f\u3081\u3001\u4ee5\u4e0b\u306e URL \u3078\u79fb\u52d5\u3057\u3066\u304f\u3060\u3055\u3044\u3002\n\n
   SENDCONFIRMATIONEMAIL_SENT=\u96fb\u5b50\u30e1\u30fc\u30eb\u3092\u9001\u4fe1\u3057\u307e\u3057\u305f\u3002
  @@ -89,6 +89,7 @@
   USERFORM_FIRSTNAMEMSG=\u540d\u524d (\u540d):
   USERFORM_LASTNAMEMSG=\u540d\u524d (\u59d3):
   USERFORM_EMAILMSG=\u96fb\u5b50\u30e1\u30fc\u30eb:
  +USERFORM_SAVE=Save
   USERFORM_CANCEL=\u30ad\u30e3\u30f3\u30bb\u30eb
   USERFORM_RESET=\u30ea\u30bb\u30c3\u30c8
   USERFORM_UPDATE=\u30a2\u30ab\u30a6\u30f3\u30c8\u306e\u66f4\u65b0
  @@ -138,7 +139,7 @@
   CUSTOMIZER_ACTION=\u30a2\u30af\u30b7\u30e7\u30f3
   CUSTOMIZER_ADD=\u8ffd\u52a0
   CUSTOMIZER_ADDPANE=\u533a\u753b\u306e\u8ffd\u52a0
  -CUSTOMIZER_ADDPORTLET=Portlet \u306e\u8ffd\u52a0
  +CUSTOMIZER_ADDPORTLET=\u30dd\u30fc\u30c8\u30ec\u30c3\u30c8\u306e\u8ffd\u52a0
   CUSTOMIZER_ADDREFERENCE=\u30ea\u30d5\u30a1\u30ec\u30f3\u30b9\u306e\u8ffd\u52a0
   CUSTOMIZER_APPLY=\u9069\u7528
   CUSTOMIZER_CANCEL=\u30ad\u30e3\u30f3\u30bb\u30eb
  @@ -159,11 +160,11 @@
   CUSTOMIZER_NAME=\u540d\u524d
   CUSTOMIZER_NEXTBTN=\u6b21\u3078 >>
   CUSTOMIZER_NEWPANENAME=\u8ffd\u52a0\u3059\u308b\u305f\u3081\u306b\u533a\u753b\u306e\u540d\u524d\u3092\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044
  -CUSTOMIZER_NOTHINGDEFINED=\u5b9a\u7fa9\u3055\u308c\u305f Portlet \u307e\u305f\u306f\u533a\u753b\u304c\u3042\u308a\u307e\u305b\u3093
  +CUSTOMIZER_NOTHINGDEFINED=\u5b9a\u7fa9\u3055\u308c\u305f\u30dd\u30fc\u30c8\u30ec\u30c3\u30c8\u307e\u305f\u306f\u533a\u753b\u304c\u3042\u308a\u307e\u305b\u3093
   CUSTOMIZER_NOPARAMETERS=\u30ab\u30b9\u30bf\u30de\u30a4\u30ba\u53ef\u80fd\u306a\u30d1\u30e9\u30e1\u30fc\u30bf\u304c\u3042\u308a\u307e\u305b\u3093
   CUSTOMIZER_NOTITLESET=\u30bf\u30a4\u30c8\u30eb\u30bb\u30c3\u30c8\u304c\u3042\u308a\u307e\u305b\u3093
   CUSTOMIZER_PANE=\u533a\u753b
  -CUSTOMIZER_PORTLET=Portlet
  +CUSTOMIZER_PORTLET=\u30dd\u30fc\u30c8\u30ec\u30c3\u30c8
   CUSTOMIZER_PREVIOUSBTN=<< \u524d\u3078
   CUSTOMIZER_REF_DEFAULTTITLE=\u30ea\u30d5\u30a1\u30ec\u30f3\u30b9
   CUSTOMIZER_REF_PATH=\u30d1\u30b9
  @@ -188,6 +189,10 @@
   PASSWORDFORM_CHANGE=\u30d1\u30b9\u30ef\u30fc\u30c9\u5909\u66f4
   PASSWORDFORM_DONE=\u30d1\u30b9\u30ef\u30fc\u30c9\u306e\u5909\u66f4\u306b\u6210\u529f\u3057\u307e\u3057\u305f\uff0e
   PASSWORDFORM_THESAME_MSG=\u53e4\u3044\u30d1\u30b9\u30ef\u30fc\u30c9\u3068\u65b0\u3057\u3044\u30d1\u30b9\u30ef\u30fc\u30c9\u304c\u540c\u3058\u3067\u3059\uff0e\u65b0\u3057\u3044\u5225\u306e\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u9078\u629e\u3057\u3066\u304f\u3060\u3055\u3044\uff0e
  -PASSWORDFORM_EXPIRED_MSG=Your password has expired. Please change your password.
  -PASSWORDFORM_FAILED_MSG=Invalid user name and/or password. Please reenter your credentials.
  +PASSWORDFORM_EXPIRED_MSG=\u30d1\u30b9\u30ef\u30fc\u30c9\u306e\u6709\u52b9\u671f\u9593\u304c\u904e\u304e\u3066\u3044\u307e\u3059\uff0e\u30d1\u30b9\u30ef\u30fc\u30c9\u3092\u5909\u66f4\u3057\u3066\u304f\u3060\u3055\u3044\uff0e
  +PASSWORDFORM_FAILED_MSG=\u30e6\u30fc\u30b6\u30fc\u540d\u307e\u305f\u306f\u30d1\u30b9\u30ef\u30fc\u30c9\u304c\u7121\u52b9\u3067\u3059\uff0e\u6709\u52b9\u306a\u60c5\u5831\u3092\u518d\u5165\u529b\u3057\u3066\u304f\u3060\u3055\u3044\uff0e
   
  +EDIT=Edit
  +VIEW=View
  +DELETE=Delete
  +ADD=Add
  
  
  
  1.4       +8 -1      jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_my.properties
  
  Index: JetspeedLocalization_my.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_my.properties,v
  retrieving revision 1.3
  retrieving revision 1.4
  diff -u -r1.3 -r1.4
  --- JetspeedLocalization_my.properties	16 Sep 2002 17:57:14 -0000	1.3
  +++ JetspeedLocalization_my.properties	8 Dec 2002 19:33:52 -0000	1.4
  @@ -90,6 +90,7 @@
   USERFORM_FIRSTNAMEMSG=Nama Pertama:
   USERFORM_LASTNAMEMSG=Nama Terakhir:
   USERFORM_EMAILMSG=Email:
  +USERFORM_SAVE=Save
   USERFORM_CANCEL=Batal
   USERFORM_RESET=Semula
   USERFORM_UPDATE=Kemaskini Akaun
  @@ -192,3 +193,9 @@
   PASSWORDFORM_THESAME_MSG=Old and new passwords are the same. Please select another new password.
   PASSWORDFORM_EXPIRED_MSG=Your password has expired. Please change your password.
   PASSWORDFORM_FAILED_MSG=Invalid user name and/or password. Please reenter your credentials.
  +
  +EDIT=Edit
  +VIEW=View
  +DELETE=Delete
  +ADD=Add
  +
  
  
  
  1.6       +6 -1      jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_nl.properties
  
  Index: JetspeedLocalization_nl.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_nl.properties,v
  retrieving revision 1.5
  retrieving revision 1.6
  diff -u -r1.5 -r1.6
  --- JetspeedLocalization_nl.properties	23 Oct 2002 22:12:03 -0000	1.5
  +++ JetspeedLocalization_nl.properties	8 Dec 2002 19:33:52 -0000	1.6
  @@ -91,6 +91,7 @@
   USERFORM_FIRSTNAMEMSG=Voornaam:
   USERFORM_LASTNAMEMSG=Naam:
   USERFORM_EMAILMSG=Email:
  +USERFORM_SAVE=Save
   USERFORM_CANCEL=Cancel
   USERFORM_RESET=Wissen
   USERFORM_UPDATE=Profiel aanpassen
  @@ -193,4 +194,8 @@
   PASSWORDFORM_EXPIRED_MSG=Uw paswoord is verlopen. Gelieve uw paswoord te wijzigen.
   PASSWORDFORM_FAILED_MSG=Foute gebruikersnaam en/of paswoord. Gelieve uw gegevens weer in te vullen.
   
  +EDIT=Edit
  +VIEW=View
  +DELETE=Delete
  +ADD=Add
   
  
  
  
  1.5       +8 -1      jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_no.properties
  
  Index: JetspeedLocalization_no.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/modules/localization/JetspeedLocalization_no.properties,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- JetspeedLocalization_no.properties	22 Oct 2002 14:13:22 -0000	1.4
  +++ JetspeedLocalization_no.properties	8 Dec 2002 19:33:52 -0000	1.5
  @@ -95,6 +95,7 @@
   USERFORM_FIRSTNAMEMSG=Fornavn:
   USERFORM_LASTNAMEMSG=Etternavn:
   USERFORM_EMAILMSG=E-post:
  +USERFORM_SAVE=Save
   USERFORM_CANCEL=Avbryt
   USERFORM_RESET=Tilbakestill
   USERFORM_UPDATE=Oppdater bruker
  @@ -196,3 +197,9 @@
   PASSWORDFORM_THESAME_MSG=Gammelt og nytt passord er det samme. Vennligst velg et annet passord.
   PASSWORDFORM_EXPIRED_MSG=Passordet ditt er utg\u00E5tt. Vennligst endre passordet.
   PASSWORDFORM_FAILED_MSG=Ugyldig brukernavn og/eller passord. Vennligst oppgi disse p\u00E5 nytt.
  +
  +EDIT=Edit
  +VIEW=View
  +DELETE=Delete
  +ADD=Add
  +
  
  
  
  1.2       +111 -96   jakarta-jetspeed/src/java/org/apache/jetspeed/om/security/ldap/BaseLDAPObject.java
  
  Index: BaseLDAPObject.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/om/security/ldap/BaseLDAPObject.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- BaseLDAPObject.java	21 Oct 2002 22:31:15 -0000	1.1
  +++ BaseLDAPObject.java	8 Dec 2002 19:33:52 -0000	1.2
  @@ -57,6 +57,7 @@
   import javax.naming.*;
   import javax.naming.directory.*;
   import java.util.Vector;
  +import java.util.Enumeration;
   import java.util.Hashtable;
   import org.apache.jetspeed.services.ldap.LDAPURL;
   
  @@ -122,11 +123,25 @@
     }
   
   //UTIL Funcs
  +  protected void removeutil(String field,boolean updatable){
  +    myAttrs.remove(field);
  +    if (updatable){
  +      rmAttrs.remove(field);
  +    }
  +  }
     protected void setutil(String field, String value){
       myAttrs.remove(field);
       myAttrs.put(field,value);
       updated = true;
     }
  +  protected void setutil(String field, Vector value){
  +    myAttrs.remove(field);
  +    for(Enumeration enum = value.elements(); enum.hasMoreElements();)
  +    {
  +      myAttrs.put(field,(String)enum.nextElement());
  +    }
  +    updated = true;
  +  }
     protected String getutil(String field){
       if (myAttrs.get(field) == null){
         return new String("");
  @@ -168,232 +183,232 @@
     }
   
       public Attributes getAttributes(Name name) throws NamingException {
  -	return getAttributes(name.toString());
  +    return getAttributes(name.toString());
       }
   
       public Attributes getAttributes(String name, String[] ids)
  -	throws NamingException {
  -	if (! name.equals("")) {
  -	    throw new NameNotFoundException();
  -	}
  -
  -	Attributes answer = new BasicAttributes(true);
  -	Attribute target;
  -	for (int i = 0; i < ids.length; i++) {
  -	    target = myAttrs.get(ids[i]);
  -	    if (target != null) {
  -		answer.put(target);
  -	    }
  -	}
  -	return answer;
  +    throws NamingException {
  +    if (! name.equals("")) {
  +        throw new NameNotFoundException();
  +    }
  +
  +    Attributes answer = new BasicAttributes(true);
  +    Attribute target;
  +    for (int i = 0; i < ids.length; i++) {
  +        target = myAttrs.get(ids[i]);
  +        if (target != null) {
  +        answer.put(target);
  +        }
  +    }
  +    return answer;
       }
   
       public Attributes getAttributes(Name name, String[] ids)
  -	throws NamingException {
  -	return getAttributes(name.toString(), ids);
  +    throws NamingException {
  +    return getAttributes(name.toString(), ids);
       }
   
       public String toString() {
  -	return ldapurl.getUrl();
  +    return ldapurl.getUrl();
       }
   
   // not used for this example
   
       public Object lookup(Name name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
       public String getNameInNamespace() throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
       public Object lookup(String name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
   
       public void bind(Name name, Object obj) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
   
       public void bind(String name, Object obj) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
   
       public void rebind(Name name, Object obj) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
   
       public void rebind(String name, Object obj) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
   
       public void unbind(Name name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
   
       public void unbind(String name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
   
       public void rename(Name oldName, Name newName) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
   
       public void rename(String oldName, String newName) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
   
       public NamingEnumeration list(Name name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
   
       public NamingEnumeration list(String name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
   
       public NamingEnumeration listBindings(Name name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
       public NamingEnumeration listBindings(String name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
       public void destroySubcontext(Name name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
       public void destroySubcontext(String name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
       public Context createSubcontext(Name name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
       public Context createSubcontext(String name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
       public Object lookupLink(Name name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
       public Object lookupLink(String name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
       public NameParser getNameParser(Name name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
       public NameParser getNameParser(String name) throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
       public String composeName(String name, String prefix)
  -	    throws NamingException {
  -	throw new OperationNotSupportedException();
  +        throws NamingException {
  +    throw new OperationNotSupportedException();
       }
   
       public Name composeName(Name name, Name prefix)
  -	    throws NamingException {
  -	throw new OperationNotSupportedException();
  +        throws NamingException {
  +    throw new OperationNotSupportedException();
       }
   
       public Object addToEnvironment(String propName, Object propVal)
  -	throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throws NamingException {
  +    throw new OperationNotSupportedException();
       }
       public Object removeFromEnvironment(String propName)
  -	throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throws NamingException {
  +    throw new OperationNotSupportedException();
       }
       public Hashtable getEnvironment() throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
       public void close() throws NamingException {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
   // -- DirContext
       public void modifyAttributes(Name name, int mod_op, Attributes attrs)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
       public void modifyAttributes(String name, int mod_op, Attributes attrs)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
       public void modifyAttributes(Name name, ModificationItem[] mods)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
       public void modifyAttributes(String name, ModificationItem[] mods)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
       public void bind(Name name, Object obj, Attributes attrs)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
   
       public void bind(String name, Object obj, Attributes attrs)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
       public void rebind(Name name, Object obj, Attributes attrs)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
       public void rebind(String name, Object obj, Attributes attrs)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
       public DirContext createSubcontext(Name name, Attributes attrs)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
       public DirContext createSubcontext(String name, Attributes attrs)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
   
       public DirContext getSchema(Name name) throws NamingException  {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
   
       public DirContext getSchema(String name) throws NamingException  {
  -	throw new OperationNotSupportedException();
  +    throw new OperationNotSupportedException();
       }
   
       public DirContext getSchemaClassDefinition(Name name)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
   
       public DirContext getSchemaClassDefinition(String name)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
   
       public NamingEnumeration search(Name name,
  -				    Attributes matchingAttributes,
  -				    String[] attributesToReturn)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +                    Attributes matchingAttributes,
  +                    String[] attributesToReturn)
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
   
       public NamingEnumeration search(String name,
  -				    Attributes matchingAttributes,
  -				    String[] attributesToReturn)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +                    Attributes matchingAttributes,
  +                    String[] attributesToReturn)
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
   
       public NamingEnumeration search(Name name,
  -				    Attributes matchingAttributes)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +                    Attributes matchingAttributes)
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
   
       public NamingEnumeration search(String name,
  -				    Attributes matchingAttributes)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +                    Attributes matchingAttributes)
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
       public NamingEnumeration search(Name name,
  -				    String filter,
  -				    SearchControls cons)
  -	    throws NamingException  {
  -	throw new OperationNotSupportedException();
  +                    String filter,
  +                    SearchControls cons)
  +        throws NamingException  {
  +    throw new OperationNotSupportedException();
       }
   
     public NamingEnumeration search(String name,
  
  
  
  1.2       +125 -37   jakarta-jetspeed/src/java/org/apache/jetspeed/om/security/ldap/LDAPGroup.java
  
  Index: LDAPGroup.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/om/security/ldap/LDAPGroup.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- LDAPGroup.java	21 Oct 2002 22:31:15 -0000	1.1
  +++ LDAPGroup.java	8 Dec 2002 19:33:52 -0000	1.2
  @@ -70,41 +70,129 @@
    * 
    */
   public class LDAPGroup extends BaseLDAPObject implements Group {
  -  private String Name;
  -  public LDAPGroup(String Name,boolean isNew) {
  -    if (isNew){
  -      this.Name = Name;
  -      myAttrs = new BasicAttributes();
  -      myAttrs.put("uid",Name);
  -      myAttrs.put("groupname",Name);
  -      Attribute oc = new BasicAttribute("objectclass");
  -      oc.add("jetspeedgroup");
  -      myAttrs.put(oc);
  -      ldapurl = JetspeedLDAP.buildURL("uid="+Name+",ou=groups,ou=jetspeed");
  -      isNew = true;
  -    }else{
  -      ldapurl =JetspeedLDAP.buildURL("uid="+Name+",ou=groups,ou=jetspeed");
  -      myAttrs =  JetspeedLDAP.read(ldapurl);
  -      this.Name = getutil("groupname");
  -    }
  -  }
  -   public LDAPGroup(LDAPURL ldapurl) {
  -    this.ldapurl = ldapurl;
  -    myAttrs =  JetspeedLDAP.read(ldapurl);
  -    this.Name = getutil("groupname");
  -  }
  -  //UPDATE
  -   public boolean update(boolean create){
  -    if (JetspeedLDAP.exists(ldapurl)){
  -      JetspeedLDAP.deleteAttrs(ldapurl,rmAttrs);
  -      JetspeedLDAP.updateEntry(ldapurl,myAttrs);
  -    }else{
  -      if (create){
  -        JetspeedLDAP.addEntry(ldapurl,myAttrs);
  -      }else {
  -        return false;
  -      }
  +
  +    protected String name;
  +    protected String id = null;
  +    protected boolean isNew = true;
  +
  +    public LDAPGroup()
  +    {
  +        isNew = true;
       }
  -    return true;
  -  }
  +
  +    public LDAPGroup(String id)
  +    {
  +        this.id = id;
  +        this.name = id;
  +        isNew = true;
  +    }
  +
  +    public LDAPGroup(String name, boolean isNew)
  +    {
  +        super.ldapurl = JetspeedLDAP.buildURL("uid=" + name + ",ou=groups");
  +        this.isNew = isNew;
  +
  +        if (isNew)
  +        {
  +            this.id = name;
  +            this.name = name;
  +            super.myAttrs = new BasicAttributes();
  +            super.myAttrs.put("uid", name);
  +            super.myAttrs.put("groupname", name);
  +
  +            Attribute oc = new BasicAttribute("objectclass");
  +            oc.add("jetspeedgroup");
  +            super.myAttrs.put(oc);
  +        }
  +        else
  +        {
  +            super.myAttrs =  JetspeedLDAP.read(ldapurl);
  +            this.id = getutil("uid");
  +            this.name = getutil("groupname");
  +        }
  +    }
  +
  +    public LDAPGroup(LDAPURL ldapurl)
  +    {
  +        super.ldapurl = ldapurl;
  +        super.myAttrs =  JetspeedLDAP.read(ldapurl);
  +        this.id = getutil("uid");
  +        this.name = getutil("groupname");
  +    }
  +
  +    public boolean update(boolean create)
  +    {
  +        removeutil("createTimeStamp", false);
  +        removeutil("modifyTimeStamp", false);       
  +
  +        if (JetspeedLDAP.exists(ldapurl))
  +        {
  +            JetspeedLDAP.deleteAttrs(super.ldapurl, super.rmAttrs);
  +            JetspeedLDAP.updateEntry(super.ldapurl, super.myAttrs);
  +        }
  +        else if (create)
  +        {
  +            JetspeedLDAP.addEntry(super.ldapurl, super.myAttrs);
  +        }
  +        else
  +        {
  +            return false;
  +        }
  +
  +        return true;
  +    }
  +
  +    /**
  +     * Get the name of the Group
  +     *
  +     * @return the name of the group.
  +     */
  +    public String getName()
  +    {
  +        return name;
  +    }
  + 
  +    /**
  +     * Set the name of the Group
  +     *
  +     * @param groupName the name of the Group.
  +     */
  +    public void setName(String groupName)
  +    {
  +        name = groupName;
  +    }
  +
  +    /**
  +     * Get the id of the Group
  +     *
  +     * @return the id of the group.
  +     */
  +    public String getId()
  +    {
  +        return id;
  +    }
  +
  +    /**
  +     * Set the id of the Group
  +     *
  +     * @param id the new id for the group
  +     */
  +    public void setId(String id)
  +    {      
  +        if (this.id == null)
  +        {
  +            this.id = id;
  +        }
  +    }
  +
  +    public boolean isNew()
  +    {
  +        return isNew;
  +    }
  +
  +    void setNew(boolean isNew)
  +    {
  +        this.isNew = isNew;
  +    }
  +
   }
  
  
  
  1.2       +125 -37   jakarta-jetspeed/src/java/org/apache/jetspeed/om/security/ldap/LDAPPermission.java
  
  Index: LDAPPermission.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/om/security/ldap/LDAPPermission.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- LDAPPermission.java	21 Oct 2002 22:31:15 -0000	1.1
  +++ LDAPPermission.java	8 Dec 2002 19:33:52 -0000	1.2
  @@ -70,41 +70,129 @@
    * 
    */
   public class LDAPPermission extends BaseLDAPObject implements Permission {
  -  private String Name;
  -  public LDAPPermission(String Name,boolean isNew) {
  -    if (isNew){
  -      this.Name = Name;
  -      myAttrs = new BasicAttributes();
  -      myAttrs.put("uid",Name);
  -      myAttrs.put("permissionname",Name);
  -      Attribute oc = new BasicAttribute("objectclass");
  -      oc.add("jetspeedpermission");
  -      myAttrs.put(oc);
  -      ldapurl = JetspeedLDAP.buildURL("uid="+Name+",ou=permissions,ou=jetspeed");
  -      isNew = true;
  -    }else{
  -      ldapurl =JetspeedLDAP.buildURL("uid="+Name+",ou=permissions,ou=jetspeed");
  -      myAttrs =  JetspeedLDAP.read(ldapurl);
  -      this.Name = getutil("permissionname");
  -    }
  -  }
  -   public LDAPPermission(LDAPURL ldapurl) {
  -    this.ldapurl = ldapurl;
  -    myAttrs =  JetspeedLDAP.read(ldapurl);
  -    this.Name = getutil("permissionname");
  -  }
  -  //UPDATE
  -   public boolean update(boolean create){
  -    if (JetspeedLDAP.exists(ldapurl)){
  -      JetspeedLDAP.deleteAttrs(ldapurl,rmAttrs);
  -      JetspeedLDAP.updateEntry(ldapurl,myAttrs);
  -    }else{
  -      if (create){
  -        JetspeedLDAP.addEntry(ldapurl,myAttrs);
  -      }else {
  -        return false;
  -      }
  +
  +    protected String name;
  +    protected String id = null;
  +    protected boolean isNew = true;
  +
  +    public LDAPPermission()
  +    {
  +        isNew = true;
       }
  -    return true;
  -  }
  +
  +    public LDAPPermission(String id)
  +    {
  +        this.id = id;
  +        this.name = id;
  +        isNew = true;
  +    }
  +
  +    public LDAPPermission(String name, boolean isNew)
  +    {
  +        super.ldapurl = JetspeedLDAP.buildURL("uid=" + name + ",ou=permissions");
  +        this.isNew = isNew;
  +
  +        if (isNew)
  +        {
  +            this.id = name;
  +            this.name = name;
  +            super.myAttrs = new BasicAttributes();
  +            myAttrs.put("uid", id);
  +            myAttrs.put("permissionname", name);
  +
  +            Attribute oc = new BasicAttribute("objectclass");
  +            oc.add("jetspeedpermission");
  +            super.myAttrs.put(oc);
  +        }
  +        else
  +        {
  +            super.myAttrs = JetspeedLDAP.read(ldapurl);
  +            this.id = getutil("uid");
  +            this.name = getutil("permissionname");
  +        }
  +    }
  +
  +    public LDAPPermission(LDAPURL ldapurl)
  +    {
  +        super.ldapurl = ldapurl;
  +        super.myAttrs = JetspeedLDAP.read(ldapurl);
  +        this.id = getutil("uid");
  +        this.name = getutil("permissionname");
  +    }
  +
  +    public boolean update(boolean create)
  +    {
  +        removeutil("createTimeStamp", false);
  +        removeutil("modifyTimeStamp", false);
  +
  +        if (JetspeedLDAP.exists(super.ldapurl))
  +        {
  +            JetspeedLDAP.deleteAttrs(super.ldapurl, super.rmAttrs);
  +            JetspeedLDAP.updateEntry(super.ldapurl, super.myAttrs);
  +        }
  +        else if (create)
  +        {
  +            JetspeedLDAP.addEntry(ldapurl,myAttrs);
  +        }
  +        else 
  +        {
  +            return false;
  +        }
  +
  +        return true;
  +    }
  +
  +    /**
  +     * Get the name of the Permission
  +     *
  +     * @return the name of the permission.
  +     */
  +    public String getName()
  +    {
  +        return name;
  +    }
  + 
  +    /**
  +     * Set the name of the Permission
  +     *
  +     * @param permissionName the name of the Permission.
  +     */
  +    public void setName(String permissionName)
  +    {
  +        name = permissionName;
  +    }
  +
  +    /**
  +     * Get the id of the Permission
  +     *
  +     * @return the id of the permission.
  +     */
  +    public String getId()
  +    {
  +        return id;
  +    }
  +
  +    /**
  +     * Set the id of the Permission
  +     *
  +     * @param id the new id for the permission
  +     */
  +    public void setId(String id)
  +    {      
  +        if (this.id == null)
  +        {
  +            this.id = id;
  +        }
  +    }
  +
  +    public boolean isNew()
  +    {
  +        return isNew;
  +    }
  +
  +    void setNew(boolean isNew)
  +    {
  +        this.isNew = isNew;
  +    }
  +
   }
  
  
  
  1.2       +196 -62   jakarta-jetspeed/src/java/org/apache/jetspeed/om/security/ldap/LDAPRole.java
  
  Index: LDAPRole.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/om/security/ldap/LDAPRole.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- LDAPRole.java	21 Oct 2002 22:31:15 -0000	1.1
  +++ LDAPRole.java	8 Dec 2002 19:33:52 -0000	1.2
  @@ -72,64 +72,198 @@
    */
   public class LDAPRole extends BaseLDAPObject implements Role {
   
  -  private Vector rolepermissions;
  -  public LDAPRole(String Name, boolean isNew) {
  -    if (isNew){
  -      rolepermissions = new Vector();
  -      this.Name = Name;
  -      myAttrs = new BasicAttributes();
  -      myAttrs.put("uid",Name);
  -      myAttrs.put("rolename",Name);
  -      Attribute oc = new BasicAttribute("objectclass");
  -      oc.add("jetspeedrole");
  -      myAttrs.put(oc);
  -      ldapurl = JetspeedLDAP.buildURL("uid="+Name+",ou=roles,ou=jetspeed");
  -      isNew = true;
  -    }else{
  -      ldapurl = JetspeedLDAP.buildURL("uid="+Name+",ou=roles,ou=jetspeed");
  -      myAttrs =  JetspeedLDAP.read(ldapurl);
  -      this.Name = getutil("rolename");
  -      this.rolepermissions = getutil("rolepermissions",true);
  -    }
  -  }
  -  public LDAPRole(LDAPURL ldapurl) {
  -    this.ldapurl = ldapurl;
  -    myAttrs =  JetspeedLDAP.read(ldapurl);
  -    this.Name = getutil("rolename");
  -    this.rolepermissions = getutil("rolepermissions",true);
  -  }
  -
  -//RolePermissions
  -  public Vector getrolepermissions(){
  -    return rolepermissions;
  -  }
  -  public void addrolepermissions(String rolepermission){
  -    if (!(permissionexist(rolepermission))){
  -      rolepermissions.add(rolepermission);
  -      myAttrs.get("rolepermissions").add(rolepermission);
  -    }
  -  }
  -  public void removerolepermissions(String rolepermission){
  -    myAttrs.get("rolepermissions").remove((Object)(rolepermission));
  -  }
  -  public boolean permissionexist(String permission){
  -    if (rolepermissions.indexOf(permission)!= -1){
  -      return true;
  -    }
  -    return false;
  -  }
  -//UPDATE
  -   public boolean update(boolean create){
  -    if (JetspeedLDAP.exists(ldapurl)){
  -      JetspeedLDAP.deleteAttrs(ldapurl,rmAttrs);
  -      JetspeedLDAP.updateEntry(ldapurl,myAttrs);
  -    }else{
  -      if (create){
  -        JetspeedLDAP.addEntry(ldapurl,myAttrs);
  -      }else {
  -        return false;
  -      }
  -    }
  -    return true;
  -  }
  -}
  \ No newline at end of file
  +    protected String name = null;
  +    protected String id = null;
  +    protected boolean isNew = true;
  +    protected Vector rolePermissions;
  +
  +    public LDAPRole()
  +    {
  +        rolePermissions = new Vector();
  +        isNew = true;
  +    }
  +
  +    public LDAPRole(String id)
  +    {
  +        rolePermissions = new Vector();
  +        this.id = id;
  +        this.name = id;
  +        isNew = true;
  +    }
  +
  +    public LDAPRole(String name, boolean isNew)
  +    {
  +        super.ldapurl = JetspeedLDAP.buildURL("uid=" + name + ",ou=roles");
  +        this.isNew = isNew;
  +
  +        if (isNew)
  +        {
  +            rolePermissions = new Vector();
  +            this.id = name;
  +            this.name = name;
  +
  +            super.myAttrs = new BasicAttributes();
  +            super.myAttrs.put("uid", this.id);
  +            super.myAttrs.put("roleName", this.name);
  +
  +            Attribute oc = new BasicAttribute("objectclass");
  +            oc.add("jetspeedrole");
  +            super.myAttrs.put(oc);
  +        }
  +        else
  +        {
  +            super.myAttrs =  JetspeedLDAP.read(super.ldapurl);
  +            this.id = getutil("uid");
  +            this.name = getutil("rolename");
  +            this.rolePermissions = getutil("rolepermissions", true);
  +        }
  +    }
  +
  +    public LDAPRole(LDAPURL ldapurl)
  +    {
  +        super.ldapurl = ldapurl;
  +        super.myAttrs =  JetspeedLDAP.read(ldapurl);
  +        this.id = getutil("uid");
  +        this.name = getutil("rolename");
  +        this.rolePermissions = getutil("rolepermissions", true);
  +    }
  +
  +    /**
  +     * Get the name of the Role
  +     *
  +     * @return the name of the role.
  +     */
  +    public String getName()
  +    {
  +        return name;
  +    }
  + 
  +    /**
  +     * Set the name of the Role
  +     *
  +     * @param roleName the name of the Role.
  +     */
  +    public void setName(String roleName)
  +    {
  +        name = roleName;
  +    }
  +
  +    /**
  +     * Get the id of the Role
  +     *
  +     * @return the id of the role.
  +     */
  +    public String getId()
  +    {
  +        return id;
  +    }
  +
  +    /**
  +     * Set the id of the Role
  +     *
  +     * @param id the new id for the role
  +     */
  +    public void setId(String id)
  +    {      
  +        if (this.id == null)
  +        {
  +            this.id = id;
  +        }
  +    }
  +
  +    public boolean isNew()
  +    {
  +        return isNew;
  +    }
  +
  +    void setNew(boolean isNew)
  +    {
  +        this.isNew = isNew;
  +    }
  +
  +    public Vector getRolePermissions()
  +    {
  +        return rolePermissions;
  +    }
  +
  +    public void addRolePermissions(String rolePermission)
  +    {
  +        if (!(permissionExists(rolePermission)))
  +        {
  +            rolePermissions.add(rolePermission);
  +        }
  +    }
  +
  +    public void removeRolePermissions(String rolePermission)
  +    {
  +        rolePermissions.remove(rolePermission);
  +    }
  +
  +    public boolean permissionExists(String rolePermission)
  +    {
  +        if (rolePermissions.indexOf(rolePermission) != -1)
  +        {
  +            return true;
  +        }
  +        else
  +        {
  +            return false;
  +        }
  +    }
  +
  +    public boolean update(boolean create)
  +    {
  +        removeutil("createTimeStamp", false);
  +        removeutil("modifyTimeStamp", false);       
  +
  +        if (JetspeedLDAP.exists(super.ldapurl))
  +        {
  +            removePreviousPermissionsFromLDAP();
  +            JetspeedLDAP.deleteAttrs(super.ldapurl, super.rmAttrs);
  +            super.myAttrs.put(toAttribute("rolepermissions", rolePermissions));
  +            JetspeedLDAP.updateEntry(super.ldapurl, super.myAttrs);
  +        }
  +        else if (create)
  +        {
  +            JetspeedLDAP.addEntry(super.ldapurl, super.myAttrs);
  +        }
  +        else
  +        {
  +            return false;
  +        }
  +
  +        return true;
  +    }
  +
  +    public void removePreviousPermissionsFromLDAP()
  +    {
  +        Vector previousPermissions = getutil("rolepermissions", true);
  +        BasicAttributes attrs = new BasicAttributes();
  + 
  +        for (int i=0; i < previousPermissions.size(); i++)
  +        {
  +            String uid = (String)previousPermissions.get(i);
  +            //Log.debug("Deleting value '" + uid + "' from rolepermissions.");
  +            attrs.put("rolepermissions", uid);
  +        }
  +
  +        JetspeedLDAP.deleteAttrs(super.ldapurl, attrs);
  +    }
  +
  +    public Attribute toAttribute(String id, Vector values)
  +    {
  +        Attribute attr = new BasicAttribute(id);
  + 
  +        for (int i=0; i < values.size(); i++)
  +        {
  +            String uid = (String)values.get(i);
  +            //Log.debug("Adding value '" + uid + "' to rolepermissions.");
  +            attr.add(uid);
  +        }
  +
  +        return attr;
  +    }
  +            
  +
  +}
  +
  
  
  
  1.2       +150 -106  jakarta-jetspeed/src/java/org/apache/jetspeed/om/security/ldap/LDAPUser.java
  
  Index: LDAPUser.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/om/security/ldap/LDAPUser.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- LDAPUser.java	21 Oct 2002 22:31:15 -0000	1.1
  +++ LDAPUser.java	8 Dec 2002 19:33:52 -0000	1.2
  @@ -84,6 +84,7 @@
   
       /** The date on which the user account was created. */
       private Date createDate = null;
  +
       /** The date on which the user last accessed the application. */
       private Date lastAccessDate = null;
   
  @@ -99,110 +100,153 @@
   
       protected boolean isNew = false;
   
  -   private Vector grouprole= null;
  -   public LDAPUser(){
  -    isNew = true;
  -   }
  +    private Vector groupRoles = null;
  +
  +    public LDAPUser()
  +    {
  +        this("TempUser", true);
  +    }
  +
       /**
        * Constructor.
        * Create a new User and set the createDate.
        */
  -    public LDAPUser(String UserName, boolean isNew)
  +    public LDAPUser(String username, boolean isNew)
       {
  -      createDate = new Date();
  -      tempStorage = new Hashtable(10);
  -      permStorage = new Hashtable(10);
  -      grouprole = new Vector();
  -      setHasLoggedIn(Boolean.FALSE);
  -      if (isNew){
  -          setDisabled(false);
  -          setUserName(UserName);
  -          myAttrs = new BasicAttributes();
  -          myAttrs.put("uid",UserName);
  -          Attribute oc = new BasicAttribute("objectclass");
  -          oc.add("jetspeeduser");
  -          myAttrs.put(oc);
  -          ldapurl = JetspeedLDAP.buildURL("uid="+UserName+",ou=users,ou=jetspeed");
  -          isNew = true;
  -      }else{
  -        ldapurl =JetspeedLDAP.buildURL("uid="+UserName+",ou=users,ou=jetspeed");
  +        ldapurl = JetspeedLDAP.buildURL("uid=" + username + ",ou=users");
  +        this.isNew = isNew;
  +
  +        createDate = new Date();
  +        tempStorage = new Hashtable(10);
  +        permStorage = new Hashtable(10);
  +        groupRoles = new Vector();
  +        setHasLoggedIn(Boolean.FALSE);
  +
  +        if (isNew)
  +        {
  +            setDisabled(false);
  +            setUserName(username);
  +
  +            myAttrs = new BasicAttributes();
  +            myAttrs.put("uid", username);
  +            Attribute oc = new BasicAttribute("objectclass");
  +            oc.add("jetspeeduser");
  +            myAttrs.put(oc);
  +        }
  +        else
  +        {
  +            myAttrs =  JetspeedLDAP.read(ldapurl);
  +            setName(getutil("name"));
  +            setEmail(getutil("mail"));
  +            setFirstName(getutil("givenName"));
  +            setLastName(getutil("sn"));
  +            setUserName(username);
  +            this.groupRoles = getutil("usergrouprole", true);
  +        }
  +    }
  +
  +    public LDAPUser( LDAPURL ldapurl )
  +    {
  +        createDate = new Date();
  +        tempStorage = new Hashtable(10);
  +        permStorage = new Hashtable(10);
  +        setHasLoggedIn(Boolean.FALSE);
  +        groupRoles = new Vector();
  +        this.ldapurl = ldapurl;
           myAttrs =  JetspeedLDAP.read(ldapurl);
  -        setName(getutil("name"));
  +    
  +        setUserName(getutil("uid"));
           setEmail(getutil("mail"));
  +        setFirstName(getutil("givenName"));
           setLastName(getutil("sn"));
  -        setUserName(UserName);
  -        this.grouprole = getutil("usergrouprole",true);
  -      }
  -    }
  -  public LDAPUser(LDAPURL ldapurl){
  -    createDate = new Date();
  -    tempStorage = new Hashtable(10);
  -    permStorage = new Hashtable(10);
  -    setHasLoggedIn(Boolean.FALSE);
  -    grouprole = new Vector();
  -    this.ldapurl = ldapurl;
  -    myAttrs =  JetspeedLDAP.read(ldapurl);
  -    Log.debug("in LDAPUser:");
  -    setUserName(getutil("uid"));
  -    setEmail(getutil("mail"));
  -    setLastName(getutil("sn"));
  -    setName(getutil("name"));
  -    setConfirmed(getutil("confirm"));
  -    try{
  -      setPassword(new String ((byte[]) myAttrs.get("userPassword").getAll().nextElement()));
  -    }catch (Exception e){
  -    }
  -     this.grouprole = getutil("usergrouprole",true);
  -  }
  -   public boolean update(boolean create){
  -    setutil("userPassword","{crypt}"+UnixCrypt.crypt((String)getPerm(User.PASSWORD)));
  -    setutil("mail",(String)getPerm(User.EMAIL));
  -    if (JetspeedLDAP.exists(ldapurl)){
  -      JetspeedLDAP.deleteAttrs(ldapurl,rmAttrs);
  -      JetspeedLDAP.updateEntry(ldapurl,myAttrs);
  -    }else{
  -      if (create){
  -        ldapurl = JetspeedLDAP.buildURL("uid="+(String)getPerm(User.USERNAME)+",ou=users,ou=jetspeed");
  -        setutil("uid",(String)getPerm(User.USERNAME));
  -        JetspeedLDAP.addEntry(ldapurl,myAttrs);
  -      }else {
  -        return false;
  -      }
  -    }
  -    return true;
  -  }
  -    //role group
  -  //role group
  -  public Vector getgrouprole(){
  -    return this.grouprole;
  -  }
  -  public void addgrouprole(String groupname, String rolename){
  -    grouprole.add(groupname+","+rolename);
  -  }
  -  public void removegroup(String groupname){
  -    String grouprolestr;
  -    for (Enumeration enum = grouprole.elements();enum.hasMoreElements();){
  -      grouprolestr = (String)enum.nextElement();
  -      if (grouprolestr.startsWith(groupname+",")){
  -        grouprole.remove(grouprolestr);
  -      }
  -    }
  -  }
  -  public void removegrouprole(String groupname,String rolename){
  -    String grouprolestr;
  -    for (Enumeration enum = grouprole.elements();enum.hasMoreElements();){
  -      grouprolestr = (String)enum.nextElement();
  -      if (grouprolestr.equalsIgnoreCase(groupname+","+rolename)){
  -        grouprole.remove(grouprolestr);
  -      }
  -    }
  -  }
  -    /**
  -      * Returns the primary principle for this User, the user id.
  -      *
  -      * @return the user id.
  -      */
  +        setName(getutil("name"));
  +        setConfirmed(getutil("confirm"));
  +    
  +        try
  +        {
  +            setPassword(new String ((byte[]) myAttrs.get("userPassword").getAll().nextElement()));
  +        }
  +        catch (Exception e)
  +        {
  +        }
  +    
  +        this.groupRoles = getutil( "usergrouprole", true );
  +    }
  +
  +    public boolean update(boolean create)
  +    {
  +        removeutil("createTimeStamp", false);
  +        removeutil("modifyTimeStamp", false);
  +
  +        setutil("userPassword",(String)getPerm(User.PASSWORD) );
  +        setutil("mail",(String)getPerm(User.EMAIL));
  +        setutil("confirm",(String)getPerm(User.CONFIRM_VALUE));
  +        setutil("sn",(String)getPerm(User.LAST_NAME));
  +        setutil("givenName",(String)getPerm(User.FIRST_NAME));
  +        setutil("usergrouprole",groupRoles);
  +
  +        if (JetspeedLDAP.exists(ldapurl))
  +        {
  +            JetspeedLDAP.deleteAttrs(ldapurl,rmAttrs);
  +            JetspeedLDAP.updateEntry(ldapurl,myAttrs);
  +        }
  +        else if (create)
  +        {
  +            ldapurl = JetspeedLDAP.buildURL("uid=" + (String)getPerm(User.USERNAME) + ",ou=users");
  +            setutil("uid", (String)getPerm(User.USERNAME));
  +            JetspeedLDAP.addEntry(ldapurl,myAttrs);
  +        }
  +        else
  +        {
  +            return false;
  +        }
  +
  +        return true;
  +    }
  +
  +    public Vector getGroupRoles()
  +    {
  +        return this.groupRoles;
  +    }
  +
  +    public void addGroupRole(String groupName, String roleName)
  +    {
  +        groupRoles.add(groupName + "," + roleName);
  +    }
  +
  +    public void removeGroup(String groupName)
  +    {
  +        for (Enumeration enum = groupRoles.elements();enum.hasMoreElements();)
  +        {
  +            String groupRoleStr = (String)enum.nextElement();
  +            if (groupRoleStr.startsWith(groupName + ","))
  +            {
  +                groupRoles.remove(groupRoleStr);
  +            }
  +        }
  +    }
  +
  +    public void removeGroupRoles(String groupName, String roleName)
  +    {
  +        for (Enumeration enum = groupRoles.elements(); enum.hasMoreElements();)
  +        {
  +            String groupRoleStr = (String)enum.nextElement();
  +            if (groupRoleStr.equalsIgnoreCase(groupName + "," + roleName))
  +            {
  +                groupRoles.remove(groupRoleStr);
  +            }
  +
  +
  +        }
  +    }
  +
  +    /**
  +     * Returns the primary principle for this User, the user id.
  +     *
  +     * @return the user id.
  +     */
       public String getUserId()
  +
       {
           String tmp = null;
           try
  @@ -279,9 +323,11 @@
        */
       public java.util.Date getLastAccessDate()
       {
  +
  +
           if (lastAccessDate == null)
           {
  -            setLastAccessDate();
  +        setLastAccessDate();
           }
           return lastAccessDate;
       }
  @@ -388,6 +434,7 @@
               val = def;
           }
           return val;
  +
       }
   
       /**
  @@ -448,8 +495,7 @@
           try
           {
               tmp = (String) getPerm (User.LAST_NAME);
  -            if (tmp.length() == 0)
  -                tmp = null;
  +            if (tmp.length() == 0) tmp = null;
           }
           catch (Exception e)
           {
  @@ -459,6 +505,7 @@
   
       /**
        * The user is considered logged in if they have not timed out.
  +
        *
        * @return Whether the user has logged in.
        */
  @@ -563,7 +610,7 @@
        */
       public void setPassword(String password)
       {
  -         setPerm(User.PASSWORD, password);
  +        setPerm(User.PASSWORD, password);
       }
   
       /**
  @@ -765,11 +812,10 @@
        */
       public void valueUnbound(HttpSessionBindingEvent hsbe)
       {
  -
           try
           {
               java.util.Date now = new java.util.Date();
  -            //System.out.println("*********** value unbound ********************: " + now.toString());
  +
               if (this.hasLoggedIn())
               {
                   if ( JetspeedResources.getBoolean("automatic.logout.save", false) )
  @@ -778,7 +824,6 @@
                   }
                   JetspeedAuthentication.logout();
               }
  -
           }
           catch ( Exception e )
           {
  @@ -794,7 +839,6 @@
           }
       }
   
  -
       /**
        * Saves this object to the data store.
        */
  @@ -825,7 +869,7 @@
               if ( tmp != null && tmp.length() > 0 )
               {
                   if (tmp.equalsIgnoreCase("T"))
  -                    disabled = true;
  +                disabled = true;
               }
           }
           catch (Exception e)
  @@ -879,4 +923,4 @@
           this.passwordChanged = value;
       }
   
  -}
  \ No newline at end of file
  +}
  
  
  
  1.2       +47 -6     jakarta-jetspeed/src/java/org/apache/jetspeed/services/ldap/LDAPService.java
  
  Index: LDAPService.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/ldap/LDAPService.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- LDAPService.java	21 Oct 2002 22:31:15 -0000	1.1
  +++ LDAPService.java	8 Dec 2002 19:33:53 -0000	1.2
  @@ -88,7 +88,12 @@
       private static String DEFAULT_CTX = "com.sun.jndi.ldap.LdapCtxFactory";
   
       private Hashtable connections;
  -    private Connector connector;
  +    private Connector connector;
  +
  +
  +
  +
  +
       private int limit;
       private int timeout;
       private int version;
  @@ -127,7 +132,7 @@
           try
           {
               DirContext ctx = new InitialDirContext(env);
  -            connections.put(basedn, ctx);
  +            // connections.put(basedn, ctx);
               if(parser == null)
                   parser = ctx.getNameParser("");
               return true;
  @@ -148,10 +153,12 @@
        */
       public DirContext connect(LDAPURL url)
       {
  +//System.out.println("LDAPService: connect = " + url);
  +
           String base = url.getBase();
           DirContext ctx = (DirContext)connections.get(base);
           if(ctx != null)
  -            return ctx;
  +            return ctx;
           setDefaultEnv();
           env.put("java.naming.provider.url", base);
           do
  @@ -159,7 +166,7 @@
               try
               {
                   ctx = new InitialDirContext(env);
  -                connections.put(base, ctx);
  +                // connections.put(base, ctx);
                   return ctx;
               }
               catch(AuthenticationException e)
  @@ -359,6 +366,8 @@
        */
       public boolean exists(LDAPURL url)
       {
  +//System.out.println("LDAPService: exists = " + url);
  +
           DirContext ctx = connect(url);
           if(ctx == null)
               return false;
  @@ -461,6 +470,9 @@
        * @return LDAPURL build with given DN.
        */
       public LDAPURL buildURL(String DN){
  +
  +//System.out.println("LDAPService: buildURL: " + DN + " ---> " + new LDAPURL(host,port,DN + "," + basedn));
  +
         return new LDAPURL(host,port,DN + "," + basedn);
       }
       /**
  @@ -595,7 +607,7 @@
               return false;
           try
           {
  -            ctx.modifyAttributes(url.getDN(), 3, ats);
  +            ctx.modifyAttributes(url.getDN(), DirContext.REMOVE_ATTRIBUTE, ats);
           }
           catch(ReferralException e)
           {
  @@ -627,6 +639,7 @@
        *
        * @param url object to delete.
        * @return boolean true if success else false.
  +
        */
       public boolean deleteEntry(LDAPURL url)
       {
  @@ -756,6 +769,7 @@
               return transferTreeSub(fromUrl, dstUrl, delete, replace);
           else
               return transferEntry(fromUrl, dstUrl, delete, replace);
  +
       }
       /**
        * Transfer with updates Function
  @@ -817,6 +831,7 @@
           DirContext ctx = connect(fromUrl);
           if(ctx == null)
               return false;
  +
           Attributes ats = read(fromUrl);
           if(ats == null)
               return false;
  @@ -978,8 +993,12 @@
       private NamingEnumeration search(DirContext ctx, String dn, String filter, String attribs[], int type)
           throws NamingException
       {
  +////System.out.println("LDAPService: search: dn = " + dn);
  +////System.out.println("LDAPService: search: filter = " + filter);
  +
           return search(ctx, dn, filter, attribs, type, true);
       }
  +
       /**
        * Search Function
        *
  @@ -997,6 +1016,9 @@
       private NamingEnumeration search(DirContext ctx, String dn, String filter, String attribs[], int type, boolean setLimits)
           throws NamingException
       {
  +////System.out.println("LDAPService: search2: dn = " + dn);
  +////System.out.println("LDAPService: search2: filter = " + filter);
  +
           SearchControls constraints = new SearchControls();
           constraints.setSearchScope(type);
           constraints.setReturningAttributes(attribs);
  @@ -1021,12 +1043,17 @@
        */
       public Vector search(LDAPURL url, String filter, String attribs[], boolean subTreeScope)
       {
  +////System.out.println("LDAPService: search3: url = " + url);
  +////System.out.println("LDAPService: search3: filter = " + filter);
  +
           Vector results = new Vector();
           String attrs[] = new String[attribs.length + 1];
           attrs[0] = "objectclass";
           System.arraycopy(attribs, 0, attrs, 1, attribs.length);
           int scope = subTreeScope ? 2 : 1;
           subSearch(url, filter, attrs, scope, results);
  +
  +////System.out.println("LDAPService: search3: results = " + results.size());
           return results;
       }
       /**
  @@ -1044,7 +1071,13 @@
   
       private boolean subSearch(LDAPURL url, String filter, String attribs[], int scope, Vector rs)
       {
  +//System.out.println("LDAPService: search4: url = " + url);
  +//System.out.println("LDAPService: search4: filter = " + filter);
  +
           DirContext ctx = connect(url);
  +
  +//System.out.println("LDAPService: ctx = " + ctx);
  +
           if(ctx == null)
               return false;
           String entryDN = null;
  @@ -1053,6 +1086,9 @@
           LDAPURL myurl = null;
           int subscope = 0;
           String baseDN = url.getDN();
  +
  +//System.out.println("LDAPService: subSearch: baseDN = " + baseDN);
  +
           boolean moreReferrals = true;
           while(moreReferrals)
               try
  @@ -1084,6 +1120,7 @@
                   }
                   moreReferrals = false;
               }
  +
               catch(ReferralException e)
               {
                   myurl = getReferralUrl(e);
  @@ -1137,8 +1174,12 @@
   
       private String getFixedDN(String rdn, String base)
       {
  +//System.out.println("LDAPService: getFixedDn: rdn = " + rdn);
  +//System.out.println("LDAPService: getFixedDn: base = " + base);
  +//System.out.println("LDAPService: getFixedDn: result = " + getDN(fixName(rdn), base));
           return getDN(fixName(rdn), base);
       }
  +
       /**
        * Return Name Function
        *
  
  
  
  1.3       +7 -2      jakarta-jetspeed/src/java/org/apache/jetspeed/services/ldap/LDAPURL.java
  
  Index: LDAPURL.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/ldap/LDAPURL.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- LDAPURL.java	23 Oct 2002 05:29:30 -0000	1.2
  +++ LDAPURL.java	8 Dec 2002 19:33:53 -0000	1.3
  @@ -65,7 +65,6 @@
    */
   public class LDAPURL
   {
  -
       private String host;
       private int port;
       private String dn;
  @@ -243,4 +242,10 @@
           msg.append(dn);
           return msg.toString();
       }
  +
  +    public String toString()
  +    {
  +        return "LDAPURL: base = " + base + ", url = " + toUrl(host, port, dn, false);
  +    }
  +
   }
  
  
  
  1.5       +6 -1      jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/JetspeedSecurityCache.java
  
  Index: JetspeedSecurityCache.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/JetspeedSecurityCache.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- JetspeedSecurityCache.java	16 Jul 2002 17:27:05 -0000	1.4
  +++ JetspeedSecurityCache.java	8 Dec 2002 19:33:53 -0000	1.5
  @@ -122,6 +122,11 @@
           return getService().getRole(username, roleName);
       }
       
  +    public static void addRole(Role role)
  +    {
  +        getService().addRole(role);
  +    }
  +
       public static void addRole(String username, Role role)
       {
           getService().addRole(username, role);
  
  
  
  1.5       +16 -1     jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/SecurityCacheImpl.java
  
  Index: SecurityCacheImpl.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/SecurityCacheImpl.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- SecurityCacheImpl.java	16 Jul 2002 17:27:05 -0000	1.4
  +++ SecurityCacheImpl.java	8 Dec 2002 19:33:53 -0000	1.5
  @@ -122,6 +122,11 @@
           acls.remove(username);
       }
   
  +    public Role getRole(String roleName)
  +    {
  +        return (Role)perms.get(roleName);
  +    }
  +
       public Role getRole(String username, String roleName)
       {
           CachedAcl acl = (CachedAcl)acls.get(username);
  @@ -132,6 +137,14 @@
           return acl.getRole(roleName);
       }
       
  +    public void addRole(Role role)
  +    {
  +        if (!perms.containsKey(role.getName()))
  +        {
  +            perms.put(role.getName(), new HashMap());
  +        }        
  +    }
  +
       public void addRole(String username, Role role)
       {
           CachedAcl acl = (CachedAcl)acls.get(username);
  @@ -153,6 +166,7 @@
           return false;
       }
   
  +
       public void removeRole(String username, String roleName)
       {
           CachedAcl acl = (CachedAcl)acls.get(username);
  @@ -167,6 +181,7 @@
       {
           return (CachedAcl)acls.get(username);
       }
  +
   
       public Iterator getRoles(String username)
       {
  
  
  
  1.5       +3 -1      jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/SecurityCacheService.java
  
  Index: SecurityCacheService.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/SecurityCacheService.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- SecurityCacheService.java	16 Jul 2002 17:27:05 -0000	1.4
  +++ SecurityCacheService.java	8 Dec 2002 19:33:53 -0000	1.5
  @@ -106,6 +106,8 @@
        *  Retrieves a role from the cache for the given username.
        *
        */ 
  +    public void addRole(Role role);
  +
       public void addRole(String username, Role role);
   
       public boolean hasRole(String username, String roleName);
  
  
  
  1.5       +2 -2      jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/TestUserManagement.java
  
  Index: TestUserManagement.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/TestUserManagement.java,v
  retrieving revision 1.4
  retrieving revision 1.5
  diff -u -r1.4 -r1.5
  --- TestUserManagement.java	17 Oct 2002 21:11:01 -0000	1.4
  +++ TestUserManagement.java	8 Dec 2002 19:33:53 -0000	1.5
  @@ -140,7 +140,7 @@
           {
               fail(StringUtils.stackTrace(e));
           }
  -
  +        assertNotNull(user);
           assertTrue(user.getUserId().equals("2"));
           assertTrue(user.getUserName().equals("turbine"));
           assertTrue(user.getFirstName().equals("Tommy"));
  
  
  
  1.2       +6 -2      jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/ldap/LDAPAuthentication.java
  
  Index: LDAPAuthentication.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/ldap/LDAPAuthentication.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- LDAPAuthentication.java	21 Oct 2002 22:31:15 -0000	1.1
  +++ LDAPAuthentication.java	8 Dec 2002 19:33:53 -0000	1.2
  @@ -150,6 +150,10 @@
           // Mark the user as being logged in.
           user.setHasLoggedIn(new Boolean(true));
   
  +        // Store the clear-text password to session if some of the 
  +        // portlets need it (for example to single-signon functionality) 
  +        user.setTemp( "sessionPassword", password );
  +
           // Set the last_login date in the database.
           try
           {
  @@ -285,4 +289,4 @@
           return rundata;
       }
   
  -}
  \ No newline at end of file
  +}
  
  
  
  1.3       +22 -16    jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/ldap/LDAPGroupManagement.java
  
  Index: LDAPGroupManagement.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/ldap/LDAPGroupManagement.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- LDAPGroupManagement.java	8 Nov 2002 10:05:18 -0000	1.2
  +++ LDAPGroupManagement.java	8 Dec 2002 19:33:53 -0000	1.3
  @@ -147,6 +147,7 @@
       {
           StringTokenizer st;
           LDAPUser user;
  +
           try
           {
               user = (LDAPUser)JetspeedSecurity.getUser(new UserNamePrincipal(username));
  @@ -158,10 +159,11 @@
           Vector groups= new Vector();
           try
           {
  -          for (Enumeration enum = user.getgrouprole().elements() ;enum.hasMoreElements() ;){
  -            st = new StringTokenizer((String)enum.nextElement(),",");
  -            groups.add(new LDAPGroup(st.nextToken(),false));
  -          }
  +            for (Enumeration enum = user.getGroupRoles().elements() ;enum.hasMoreElements() ;)
  +            {
  +                st = new StringTokenizer((String)enum.nextElement(),",");
  +                groups.add(new LDAPGroup(st.nextToken(),false));
  +            }
           }
           catch(Exception e)
           {
  @@ -187,7 +189,7 @@
           Vector userurls;
           try
           {
  -            userurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=groups, ou=jetspeed"),
  +            userurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=groups"),
                                           "(objectclass=jetspeedgroup)",attrs,true);
             if (userurls.size() > 0){
               for (Enumeration enum = userurls.elements();enum.hasMoreElements() ;){
  @@ -362,7 +364,7 @@
           }
           try
           {
  -          user.addgrouprole(groupname,defaultRole);
  +          user.addGroupRole(groupname,defaultRole);
             user.update(false);
           }
           catch(Exception e)
  @@ -380,7 +382,7 @@
        * @exception GroupException when the security provider has a general failure retrieving users.
        * @exception InsufficientPrivilegeException when the requestor is denied due to insufficient privilege
        */
  -    public void unjoinGroup(String username, String groupname)
  +    public void unjoinGroup(String username, String groupName)
           throws JetspeedSecurityException
       {
           LDAPUser user;
  @@ -394,7 +396,7 @@
           }
           try
           {
  -          user.removegroup(groupname);
  +          user.removeGroup(groupName);
             user.update(false);
           }
           catch(Exception e)
  @@ -417,6 +419,7 @@
       {
           StringTokenizer st;
           LDAPUser user;
  +
           try
           {
               user = (LDAPUser)JetspeedSecurity.getUser(new UserNamePrincipal(username));
  @@ -425,15 +428,18 @@
           {
               throw new GroupException("Failed to Retrieve User: ", e);
           }
  +
           Vector groups= new Vector();
           try
           {
  -          for (Enumeration enum = user.getgrouprole().elements() ;enum.hasMoreElements() ;){
  -            st = new StringTokenizer((String)enum.nextElement(),",");
  -            if (st.nextToken().equalsIgnoreCase(groupname)){
  -              return true;
  +            for (Enumeration enum = user.getGroupRoles().elements() ;enum.hasMoreElements() ;)
  +            {
  +                st = new StringTokenizer((String)enum.nextElement(),",");
  +                if (st.nextToken().equalsIgnoreCase(groupname))
  +                {
  +                    return true;
  +                }
               }
  -          }
           }
           catch(Exception e)
           {
  @@ -463,7 +469,7 @@
           Vector userurls;
           try
           {
  -            userurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=groups, ou=jetspeed"),
  +            userurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=groups"),
                                           "(&(uid="+ groupname+")(objectclass=jetspeedgroup))",attrs,true);
             if (userurls.size() == 1){
                 return new LDAPGroup((LDAPURL) ((Vector)userurls.elementAt(0)).firstElement());
  @@ -511,7 +517,7 @@
           Vector userurls;
           try
           {
  -            userurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=groups, ou=jetspeed"),
  +            userurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=groups"),
                                           "(&(uid="+ groupName+")(objectclass=jetspeedgroup))",attrs,true);
             if (userurls.size() > 0){
               return true;
  
  
  
  1.2       +105 -62   jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/ldap/LDAPPermissionManagement.java
  
  Index: LDAPPermissionManagement.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/ldap/LDAPPermissionManagement.java,v
  retrieving revision 1.1
  retrieving revision 1.2
  diff -u -r1.1 -r1.2
  --- LDAPPermissionManagement.java	21 Oct 2002 22:31:15 -0000	1.1
  +++ LDAPPermissionManagement.java	8 Dec 2002 19:33:53 -0000	1.2
  @@ -120,25 +120,25 @@
       private final static boolean DEFAULT_CASCADE_DELETE = true;
       private boolean cascadeDelete;
       private final static String CACHING_ENABLE = "caching.enable";
  -    private boolean cachingEnable = true;
  -    String[] attrs = {"ou","uid"};
  +    private boolean cachingEnable = false;
  +    String[] attrs = {"ou", "uid"};
   
       ///////////////////////////////////////////////////////////////////////////
       // Permission Management Interfaces
       ///////////////////////////////////////////////////////////////////////////
   
       /**
  -     * Retrieves all <code>Permission</code>s for a given rolename principal.
  +     * Retrieves all <code>Permission</code>s for a given roleName principal.
        *
        * The security service may optionally check the current user context
        * to determine if the requestor has permission to perform this action.
        *
  -     * @param rolename a role name identity to be retrieved.
  +     * @param roleName a role name identity to be retrieved.
        * @return Iterator over all permissions associated to the role principal.
        * @exception PermissionException when the security provider has a general failure.
        * @exception InsufficientPrivilegeException when the requestor is denied due to insufficient privilege
        */
  -    public Iterator getPermissions(String rolename)
  +    public Iterator getPermissions(String roleName)
           throws JetspeedSecurityException
       {
           Vector perms = new Vector();
  @@ -146,26 +146,30 @@
           LDAPRole role;
           LDAPPermission permission;
           Vector userurls;
  -       try
  +
  +        try
           {
               if (cachingEnable)
               {
  -                Iterator iterator = JetspeedSecurityCache.getPermissions(rolename);
  +                Iterator iterator = JetspeedSecurityCache.getPermissions(roleName);
                   if (iterator != null)
                   {
                       return iterator;
                   }
               }
  -            userurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=roles, ou=jetspeed"),
  -                                        "(&(uid="+ rolename+")(objectclass=jetspeedrole))",attrs,true);
  -          if (userurls.size() > 0){
  -              role = new LDAPRole((LDAPURL) ((Vector)userurls.elementAt(0)).firstElement());
  -
  -            for (Enumeration enum= role.getrolepermissions().elements();enum.hasMoreElements();){
  -                permission = new LDAPPermission((String)enum.nextElement(),false);
  -                perms.add(permission);
  +
  +            userurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=roles"),
  +                       "(&(uid="+ roleName+")(objectclass=jetspeedrole))",attrs,true);
  +
  +            if (userurls.size() > 0)
  +            {
  +                role = new LDAPRole((LDAPURL) ((Vector)userurls.elementAt(0)).firstElement());
  +                for (Enumeration enum= role.getRolePermissions().elements();enum.hasMoreElements();)
  +                {
  +                    permission = new LDAPPermission((String)enum.nextElement(), false);
  +                    perms.add(permission);
  +                }
               }
  -          }
           }
           catch(Exception e)
           {
  @@ -174,6 +178,7 @@
   
           return perms.iterator();
       }
  +
       /**
        * Retrieves all <code>Permission</code>s.
        *
  @@ -185,30 +190,41 @@
        * @exception InsufficientPrivilegeException when the requestor is denied due to insufficient privilege
        */
       public Iterator getPermissions()
  -        throws JetspeedSecurityException
  +        throws JetspeedSecurityException
  +
  +
  +
  +
  +
       {
           BasicAttributes attr= new BasicAttributes();
           Vector permissions = new Vector();
           Vector permissionurls;
  + 
           try
           {
  -            permissionurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=roles, ou=jetspeed"),"(objectclass=jetspeedrole)",attrs,true);
  -          if (permissionurls.size() > 0){
  -            for (Enumeration enum = permissionurls.elements();enum.hasMoreElements() ;){
  -              permissions.add(new LDAPRole((LDAPURL) (((Vector)enum.nextElement()).firstElement())));
  -            }
  -          } else {
  -            throw new PermissionException("No permission ");
  -          }
  +            permissionurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=permissions"),
  +                             "(objectclass=jetspeedpermission)",attrs,true);
  +
  +            if (permissionurls.size() > 0)
  +            {
  +                for (Enumeration enum = permissionurls.elements();enum.hasMoreElements() ;)
  +                {
  +                    permissions.add(new LDAPPermission((LDAPURL) (((Vector)enum.nextElement()).firstElement())));
  +                }
  +            }
  +            else
  +            {
  +                throw new PermissionException("No permission ");
  +            }
           }
           catch(Exception e)
           {
               throw new PermissionException("Failed to retrieve permissions ", e);
           }
           return permissions.iterator();
  -
  -
       }
  +
       /**
        * Adds a <code>Permission</code> into permanent storage.
        *
  @@ -237,6 +253,7 @@
           }
       }
   
  +
       /**
        * Saves a <code>Permission</code> into permanent storage.
        *
  @@ -268,9 +285,11 @@
           {
               LDAPPermission permission = new LDAPPermission(permissionName,false);
               JetspeedLDAP.deleteEntry(permission.getldapurl());
  +
               if(cascadeDelete)
               {
               }
  +
               if (cachingEnable)
               {
                   JetspeedSecurityCache.removeAllPermissions(permissionName);
  @@ -290,6 +309,7 @@
        * to determine if the requestor has permission to perform this action.
        *
        * @param roleName grant a permission to this role.
  +
        * @param permissionName the permission to grant to the role.
        * @exception PermissionException when the security provider has a general failure retrieving permissions.
        * @exception InsufficientPrivilegeException when the requestor is denied due to insufficient privilege
  @@ -297,18 +317,22 @@
       public void grantPermission(String roleName, String permissionName)
           throws JetspeedSecurityException
       {
  -        BasicAttributes attr= new BasicAttributes();
  +        BasicAttributes attr = new BasicAttributes();
           LDAPRole role;
           LDAPPermission permission;
  -       try
  +
  +        try
           {
               role = (LDAPRole)JetspeedSecurity.getRole(roleName);
               permission = (LDAPPermission)JetspeedSecurity.getPermission(permissionName);
  -            role.addrolepermissions(permissionName);
  +
  +            role.addRolePermissions(permissionName);
               role.update(false);
  +
               if (cachingEnable)
               {
  -                JetspeedSecurityCache.addPermission(roleName,permission);
  +System.out.println("Adding permission " + permissionName + " to Security cache.");
  +                JetspeedSecurityCache.addPermission(roleName, permission);
               }
   
           }
  @@ -321,6 +345,7 @@
       /**
        * Revokes a permission from a role.
        *
  +
        * The security service may optionally check the current user context
        * to determine if the requestor has permission to perform this action.
        *
  @@ -335,25 +360,27 @@
           BasicAttributes attr= new BasicAttributes();
           LDAPRole role;
           Vector userurls;
  -       try
  +
  +        try
           {
  -            userurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=roles, ou=jetspeed"),
  -                                        "(&(uid="+ roleName+")(objectclass=jetspeedrole))",attrs,true);
  -          if (userurls.size() > 0){
  -            role = new LDAPRole((LDAPURL) ((Vector)userurls.elementAt(0)).firstElement());
  -            role.getrolepermissions().remove(permissionName);
  -            role.update(false);
  -            if (cachingEnable)
  +            userurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=roles"),
  +                       "(&(uid="+ roleName+")(objectclass=jetspeedrole))",attrs,true);
  +            if (userurls.size() > 0)
               {
  -                JetspeedSecurityCache.removePermission(roleName, permissionName);
  +                role = new LDAPRole((LDAPURL) ((Vector)userurls.elementAt(0)).firstElement());
  +                role.getRolePermissions().remove(permissionName);
  +                role.update(false);
  +
  +                if (cachingEnable)
  +                {
  +                    JetspeedSecurityCache.removePermission(roleName, permissionName);
  +                }
               }
  -          }
           }
           catch(Exception e)
           {
               throw new PermissionException("Revoke permission '" + permissionName + "' to role '" + roleName + "' failed: ", e);
          }
  -
       }
   
       /**
  @@ -373,19 +400,22 @@
           BasicAttributes attr= new BasicAttributes();
           LDAPRole role;
           Vector userurls;
  -       try
  +
  +        try
           {
               if (cachingEnable)
               {
                   return JetspeedSecurityCache.hasPermission(roleName, permissionName);
               }
  -            userurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=roles, ou=jetspeed"),
  -                                        "(&(uid="+ roleName+")(objectclass=jetspeedrole))",attrs,true);
  -          if (userurls.size() > 0){
  -            role = new LDAPRole((LDAPURL) ((Vector)userurls.elementAt(0)).firstElement());
  -            return role.permissionexist(permissionName);
  -          }
   
  +            userurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=roles"),
  +                       "(&(uid="+ roleName+")(objectclass=jetspeedrole))",attrs,true);
  +            if (userurls.size() > 0)
  +            {
  +                role = new LDAPRole((LDAPURL) ((Vector)userurls.elementAt(0)).firstElement());
  +
  +                return role.permissionExists(permissionName);
  +            }
           }
           catch(Exception e)
           {
  @@ -408,11 +438,14 @@
       public Permission getPermission(String permissionName)
           throws JetspeedSecurityException
       {
  -      if (permissionExists(permissionName)){
  -        return new LDAPPermission(permissionName,false);
  -      }else {
  -        throw new PermissionException("Unknown permission '" + permissionName + "'");
  -      }
  +        if (permissionExists(permissionName))
  +        {
  +            return new LDAPPermission(permissionName, false);
  +        }
  +        else
  +        {
  +            throw new PermissionException("Unknown permission '" + permissionName + "'");
  +        }
       }
   
       ///////////////////////////////////////////////////////////////////////////
  @@ -444,19 +477,26 @@
       {
           BasicAttributes attr= new BasicAttributes();
           Vector permissionurls;
  +
           try
           {
  -            permissionurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=permissions, ou=jetspeed"),
  -                                        "(&(uid="+ permissionName+")(objectclass=jetspeedpermission))",attrs,true);
  -          if (permissionurls.size() > 0){
  -            return true;
  -          }
  +            permissionurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=permissions"),
  +                             "(&(uid=" + permissionName + ")(objectclass=jetspeedpermission))",attrs,true);
  +
  +            if (permissionurls.size() > 0)
  +            {
  +                return true;
  +            }
  +            else
  +            {
  +                return false;
  +            }
           }
           catch(Exception e)
           {
  +            e.printStackTrace();
               throw new PermissionException("Failed to retrieve permission ", e);
           }
  -        return false;
       }
   
       ///////////////////////////////////////////////////////////////////////////
  @@ -488,5 +528,8 @@
           cascadeDelete = serviceConf.getBoolean( CASCADE_DELETE, DEFAULT_CASCADE_DELETE );
           cachingEnable = serviceConf.getBoolean( CACHING_ENABLE, cachingEnable );
           setInit(true);
  +
  +//cachingEnable = false;
  +System.out.println("LDAPPermissionManagement: cache = " + cachingEnable);
        }
  -}
  \ No newline at end of file
  +}
  
  
  
  1.3       +56 -43    jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/ldap/LDAPRoleManagement.java
  
  Index: LDAPRoleManagement.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/ldap/LDAPRoleManagement.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- LDAPRoleManagement.java	8 Nov 2002 10:05:18 -0000	1.2
  +++ LDAPRoleManagement.java	8 Dec 2002 19:33:53 -0000	1.3
  @@ -163,14 +163,16 @@
           {
               throw new RoleException("Failed to Retrieve User: ", e);
           }
  +
           Vector roles= new Vector();
           try
           {
  -          for (Enumeration enum = user.getgrouprole().elements() ;enum.hasMoreElements() ;){
  -            st = new StringTokenizer((String)enum.nextElement(),",");
  -            st.nextToken();
  -            roles.add(new LDAPRole(st.nextToken(),false));
  -          }
  +            for (Enumeration enum = user.getGroupRoles().elements() ;enum.hasMoreElements() ;)
  +            {
  +                st = new StringTokenizer((String)enum.nextElement(), ",");
  +                st.nextToken();
  +                roles.add(new LDAPRole(st.nextToken(), false));
  +            }
           }
           catch(Exception e)
           {
  @@ -197,7 +199,7 @@
           Vector roleurls;
           try
           {
  -            roleurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=roles, ou=jetspeed"),"(objectclass=jetspeedrole)",attrs,true);
  +            roleurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=roles"),"(objectclass=jetspeedrole)",attrs,true);
             if (roleurls.size() > 0){
               for (Enumeration enum = roleurls.elements();enum.hasMoreElements() ;){
                 roles.add(new LDAPRole((LDAPURL) (((Vector)enum.nextElement()).firstElement())));
  @@ -320,16 +322,16 @@
        * The security service may optionally check the current user context
        * to determine if the requestor has permission to perform this action.
        *
  -     * @param rolename the principal identity of the role to be retrieved.
  +     * @param roleName the principal identity of the role to be retrieved.
        * @exception RoleException when the security provider has a general failure.
        * @exception InsufficientPrivilegeException when the requestor is denied due to insufficient privilege
        */
  -    public void removeRole(String rolename)
  +    public void removeRole(String roleName)
           throws JetspeedSecurityException
       {
           try
           {
  -            LDAPRole role = new LDAPRole(rolename,false);
  +            LDAPRole role = new LDAPRole(roleName,false);
               JetspeedLDAP.deleteEntry(role.getldapurl());
               PsmlManager.removeRoleDocuments(role);
               if(cascadeDelete)
  @@ -337,13 +339,13 @@
               }
               if (cachingEnable)
               {
  -                JetspeedSecurityCache.removeAllRoles(rolename);
  +                JetspeedSecurityCache.removeAllRoles(roleName);
               }
           }
           catch(Exception e)
           {
               throw new RoleException("Failed to remove group '" +
  -                rolename + "'", e);
  +                roleName + "'", e);
           }
   
       }
  @@ -356,7 +358,7 @@
        * @exception RoleException when the security provider has a general failure retrieving users.
        * @exception InsufficientPrivilegeException when the requestor is denied due to insufficient privilege
        */
  -    public void grantRole(String username, String rolename)
  +    public void grantRole(String username, String roleName)
           throws JetspeedSecurityException
       {
           LDAPUser user;
  @@ -364,16 +366,18 @@
           try
           {
               user = (LDAPUser)JetspeedSecurity.getUser(new UserNamePrincipal(username));
  -            role = (LDAPRole)JetspeedSecurity.getRole(rolename);
  +            role = (LDAPRole)JetspeedSecurity.getRole(roleName);
           }
           catch(JetspeedSecurityException e)
           {
               throw new RoleException("Failed to Retrieve User or Role: ", e);
           }
  +
           try
           {
  -          user.addgrouprole(JetspeedSecurity.JETSPEED_GROUP,rolename);
  +          user.addGroupRole(JetspeedSecurity.JETSPEED_GROUP, roleName);
             user.update(false);
  +
             if (cachingEnable)
             {
                 JetspeedSecurityCache.addRole(username, role);
  @@ -395,10 +399,11 @@
        * @exception RoleException when the security provider has a general failure retrieving users.
        * @exception InsufficientPrivilegeException when the requestor is denied due to insufficient privilege
        */
  -    public void revokeRole(String username, String rolename)
  +    public void revokeRole(String username, String roleName)
           throws JetspeedSecurityException
       {
           LDAPUser user;
  +
           try
           {
               user = (LDAPUser)JetspeedSecurity.getUser(new UserNamePrincipal(username));
  @@ -407,14 +412,16 @@
           {
               throw new RoleException("Failed to Retrieve User: ", e);
           }
  +
           try
           {
  -          user.removegrouprole(JetspeedSecurity.JETSPEED_GROUP,rolename);
  -          user.update(false);
  -          if (cachingEnable)
  -          {
  -              JetspeedSecurityCache.removeRole(username, rolename);
  -          }
  +            user.removeGroupRoles(JetspeedSecurity.JETSPEED_GROUP, roleName);
  +            user.update(false);
  +
  +            if (cachingEnable)
  +            {
  +                JetspeedSecurityCache.removeRole(username, roleName);
  +            }
           }
           catch(Exception e)
           {
  @@ -431,7 +438,7 @@
        * @exception RoleException when the security provider has a general failure retrieving users.
        * @exception InsufficientPrivilegeException when the requestor is denied due to insufficient privilege
        */
  -    public boolean hasRole(String username, String rolename)
  +    public boolean hasRole(String username, String roleName)
           throws JetspeedSecurityException
       {
           StringTokenizer st;
  @@ -443,7 +450,7 @@
                   CachedAcl acl = JetspeedSecurityCache.getAcl(username);
                   if (null != acl)
                   {
  -                    return acl.hasRole(rolename);
  +                    return acl.hasRole(roleName);
                   }
               }
               user = (LDAPUser)JetspeedSecurity.getUser(new UserNamePrincipal(username));
  @@ -454,13 +461,15 @@
           }
           try
           {
  -          for (Enumeration enum = user.getgrouprole().elements() ;enum.hasMoreElements() ;){
  -            st = new StringTokenizer((String)enum.nextElement(),",");
  -            st.nextToken();
  -            if (st.nextToken().equalsIgnoreCase(rolename)){
  -              return true;
  +            for (Enumeration enum = user.getGroupRoles().elements() ;enum.hasMoreElements() ;)
  +            {
  +                st = new StringTokenizer((String)enum.nextElement(),",");
  +                st.nextToken();
  +                if (st.nextToken().equalsIgnoreCase(roleName))
  +                {
  +                    return true;
  +                }
               }
  -          }
           }
           catch(Exception e)
           {
  @@ -469,38 +478,42 @@
           return false;
       }
   
  -
       /**
  -     * Retrieves a single <code>Role</code> for a given rolename principal.
  +     * Retrieves a single <code>Role</code> for a given roleName principal.
        *
        * The security service may optionally check the current user context
        * to determine if the requestor has permission to perform this action.
        *
  -     * @param rolename a role principal identity to be retrieved.
  +     * @param roleName a role principal identity to be retrieved.
        * @return Role the role record retrieved.
        * @exception RoleException when the security provider has a general failure.
        * @exception InsufficientPrivilegeException when the requestor is denied due to insufficient privilege
        */
  -    public Role getRole(String rolename)
  +    public Role getRole(String roleName)
           throws JetspeedSecurityException
       {
           BasicAttributes attr= new BasicAttributes();
           Vector roleurls;
  +
           try
           {
  -            roleurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=roles, ou=jetspeed"),
  -                                        "(&(uid="+ rolename+")(objectclass=jetspeedrole))",attrs,true);
  -          if (roleurls.size() == 1){
  -              return new LDAPRole((LDAPURL) ((Vector)roleurls.elementAt(0)).firstElement());
  -          }else if(roleurls.size() > 1){
  -            throw new RoleException("Multiple roles with same name");
  -          }
  +            roleurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=roles"),
  +                       "(&(uid="+ roleName+")(objectclass=jetspeedrole))",attrs,true);
  +
  +            if (roleurls.size() == 1)
  +            {
  +                return new LDAPRole((LDAPURL) ((Vector)roleurls.elementAt(0)).firstElement());
  +            }
  +            else if(roleurls.size() > 1)
  +            {
  +                throw new RoleException("Multiple roles with same name");
  +            }
           }
           catch(Exception e)
           {
               throw new RoleException("Failed to retrieve roles ", e);
           }
  -        throw new RoleException("Unknown role '" + rolename + "'");
  +        throw new RoleException("Unknown role '" + roleName + "'");
       }
       ///////////////////////////////////////////////////////////////////////////
       // Internal
  @@ -533,7 +546,7 @@
           Vector roleurls;
           try
           {
  -            roleurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=roles, ou=jetspeed"),
  +            roleurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=roles"),
                                           "(&(uid="+ roleName+")(objectclass=jetspeedrole))",attrs,true);
             if (roleurls.size() > 0){
               return true;
  
  
  
  1.3       +128 -60   jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/ldap/LDAPUserManagement.java
  
  Index: LDAPUserManagement.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/ldap/LDAPUserManagement.java,v
  retrieving revision 1.2
  retrieving revision 1.3
  diff -u -r1.2 -r1.3
  --- LDAPUserManagement.java	8 Nov 2002 10:05:18 -0000	1.2
  +++ LDAPUserManagement.java	8 Dec 2002 19:33:53 -0000	1.3
  @@ -90,6 +90,7 @@
   
   import java.security.Principal;
   import java.util.Iterator;
  +import java.util.List;
   import javax.servlet.ServletConfig;
   import javax.naming.*;
   import javax.naming.directory.*;
  @@ -106,20 +107,17 @@
                                      implements UserManagement,
                                                 CredentialsManagement
   {
  -    private final static String CONFIG_SECURE_PASSWORDS_KEY = "secure.passwords";
  +    private final static String CONFIG_SECURE_PASSWORDS_KEY       = "secure.passwords";
       private final static String CONFIG_SECURE_PASSWORDS_ALGORITHM = "secure.passwords.algorithm";
  -
  -    boolean securePasswords = false;
  -    String passwordsAlgorithm = "SHA";
  -
  -    private final static String CONFIG_NEWUSER_ROLES     = "newuser.roles";
  -    private final static String [] DEFAULT_CONFIG_NEWUSER_ROLES =
  -    { "user" };
  -
  -    String roles[] = null;
  -
  -    String[] attrs = {"ou","userPassword","uid","mail"};
  -
  +    private final static String CONFIG_SECURE_PASSWORDS_SUFFIX    = "secure.passwords.suffix";
  +    private final static String CONFIG_NEWUSER_ROLES              = "newuser.roles";
  +    private final static String [] DEFAULT_CONFIG_NEWUSER_ROLES   = { "user" };
  +
  +    protected boolean securePasswords   = false;
  +    protected String passwordsAlgorithm = "crypt";
  +    protected String passwordsSuffix    = "{crypt}";
  +    protected String roles[]            = null;
  +    protected String[] attrs            = { "ou", "userPassword", "uid", "mail"};
   
       /** The JetspeedRunData Service. */
       private JetspeedRunDataService runDataService = null;
  @@ -150,25 +148,33 @@
           BasicAttributes attr= new BasicAttributes();
           Vector userurls = new Vector();
           LDAPUser user = null;
  -          try{
   
  -            userurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=users,ou=jetspeed"),
  -                                        "(&(uid="+principal.getName()+")(objectclass=jetspeeduser))",attrs,true);
  -          }catch (Exception e){
  -            throw new UserException("Failed to retrieve user '" +
  -                principal.getName() + "'", e);
  -          }
  -          if (userurls.size() == 1){
  -              user = new LDAPUser((LDAPURL) ((Vector)userurls.elementAt(0)).firstElement());
  -              return user;
  -          }else if(userurls.size() > 1){
  -            throw new UserException(
  -                "Multiple Users with same username '" + principal.getName() + "'");
  -          } else {
  +        try
  +        {
  +            userurls = JetspeedLDAP.search(JetspeedLDAP.buildURL("ou=users"),
  +                       "(&(uid="+principal.getName()+")(objectclass=jetspeeduser))",attrs,true);
  +        }
  +        catch (Exception e)
  +        {
  +            throw new UserException("Failed to retrieve user '" + principal.getName() + "'", e);
  +        }
  +         
  +        if (userurls.size() == 1)
  +        {
  +            user = new LDAPUser((LDAPURL) ((Vector)userurls.elementAt(0)).firstElement());
  +            return user;
  +        }
  +        else if(userurls.size() > 1)
  +        {
  +            throw new UserException("Multiple Users with same username '" + principal.getName() + "'");
  +        }
  +        else
  +        {
               throw new UnknownUserException("Unknown user '" + principal.getName() + "'");
  -          }
  +        }
       }
  -  /**
  +
  +    /**
        * Retrieves a collection of all <code>JetspeedUser</code>s.
        * The security service may optionally check the current user context
        * to determine if the requestor has permission to perform this action.
  @@ -180,8 +186,10 @@
       public Iterator getUsers()
           throws JetspeedSecurityException
       {
  -        return null;
  +        String filter = "(objectclass=jetspeeduser)";
  +        return getUsersUsingLDAPSpecificFilter(filter);
       }
  +
       /**
        * Retrieves a collection of <code>JetspeedUser</code>s filtered by a security
        * provider-specific query string. For example SQL, OQL, JDOQL.
  @@ -195,7 +203,45 @@
       public Iterator getUsers(String filter)
           throws JetspeedSecurityException
       {
  -        return null;
  +        // String ldapFilter = convert(filter);
  +        return getUsersUsingLDAPSpecificFilter(filter);
  +    }
  +
  +    /**
  +     * Retrieves a collection of <code>JetspeedUser</code>s filtered by a security
  +     * provider-specific query string. For example SQL, OQL, JDOQL.
  +     * The security service may optionally check the current user context
  +     * to determine if the requestor has permission to perform this action.
  +     *
  +     * @return a collection of <code>JetspeedUser</code> entities.
  +     * @exception UserException when the security provider has a general failure retrieving users.
  +     * @exception InsufficientPrivilegeException when the requestor is denied due to insufficient privilege
  +     */
  +    private Iterator getUsersUsingLDAPSpecificFilter(String filter)
  +        throws JetspeedSecurityException
  +    {
  +        String baseDN = "ou=users";
  +        Vector userurls = new Vector();
  +
  +        try
  +        {
  +            LDAPURL url = JetspeedLDAP.buildURL( baseDN );
  +            userurls = JetspeedLDAP.search( url, filter, attrs, true );
  +        }
  +        catch ( Exception e )
  +        {
  +            throw new UserException( "Failed to retrieve user with filter:" + filter, e );
  +        }
  +
  +        List resultList = new Vector( userurls.size() );
  +        for ( int i = 0; i < userurls.size(); i++ )
  +        {
  +            Vector v = (Vector) userurls.get( i );
  +            LDAPURL userurl = (LDAPURL) v.firstElement();
  +            LDAPUser user = new LDAPUser( userurl );
  +            resultList.add( user );
  +        }
  +        return ( resultList.iterator() );
       }
   
       /**
  @@ -217,14 +263,14 @@
           }
           try
           {
  -          ((LDAPUser)user).update(false);
  +            ((LDAPUser)user).update(false);
           }
           catch(Exception e)
           {
               throw new UserException("Failed to save user object ", e);
           }
  -
       }
  +
       /**
        * Adds a <code>JetspeedUser</code> into permanent storage.
        * The security service can throw a <code>NotUniqueUserException</code> when the public
  @@ -240,7 +286,12 @@
       public void addUser(JetspeedUser user)
           throws JetspeedSecurityException
       {
  -      ((LDAPUser)user).update(true);
  +
  +        String initialPassword = user.getPassword();
  +        String encrypted = JetspeedSecurity.encryptPassword(initialPassword);
  +        user.setPassword(encrypted);
  +        ((LDAPUser)user).update(true);
  +        addDefaultPSML(user);
       }
   
       /*
  @@ -299,6 +350,7 @@
           BasicAttributes attr= new BasicAttributes();
           Vector userurls = new Vector();
           LDAPUser user = (LDAPUser)getUser(principal);
  +
           try
           {
               JetspeedLDAP.deleteEntry(user.getldapurl());
  @@ -322,6 +374,8 @@
        * @param oldPassword the current password supplied by the user.
        * @param newPassword the current password requested by the user.
        * @exception UserException when the security provider has a general failure retrieving a user.
  +
  +
        * @exception UnknownUserException when the security provider cannot match
        *            the principal identity to a user.
        * @exception InsufficientPrivilegeException when the requestor is denied due to insufficient privilege
  @@ -339,13 +393,16 @@
               throw new UnknownUserException("The account '" +
                   user.getUserName() + "' does not exist");
           }
  -        if(!UnixCrypt.matches(user.getPassword(),oldPassword))
  +        if(!UnixCrypt.matches( user.getPassword().substring(passwordsSuffix.length()) , oldPassword))
           {
               throw new UserException(
                  "The supplied old password for '" + user.getUserName() +
                   "' was incorrect");
           }
  -        user.setPassword(newPassword);
  +
  +        String encrypted = JetspeedSecurity.encryptPassword( newPassword );
  +        user.setPassword(encrypted);
  +
           // save the changes in the database immediately, to prevent the password
           // being 'reverted' to the old value if the user data is lost somehow
           // before it is saved at session's expiry.
  @@ -374,7 +431,10 @@
               throw new UnknownUserException("The account '" +
                   user.getUserName() + "' does not exist");
           }
  -        user.setPassword(password);
  +
  +        String encrypted = JetspeedSecurity.encryptPassword( password );
  +        user.setPassword(encrypted);
  +
           // save the changes in the database immediately, to prevent the
           // password being 'reverted' to the old value if the user data
           // is lost somehow before it is saved at session's expiry.
  @@ -403,14 +463,13 @@
           {
               return null;
           }
  -        return "{crypt}" + UnixCrypt.crypt(password);
  +        return passwordsSuffix + UnixCrypt.crypt(password);
       }
   
       ///////////////////////////////////////////////////////////////////////////
       // Service Init
       ///////////////////////////////////////////////////////////////////////////
   
  -
       /**
        * This is the early initialization method called by the
        * Turbine <code>Service</code> framework
  @@ -433,25 +492,28 @@
                                                     securePasswords);
           passwordsAlgorithm = serviceConf.getString(CONFIG_SECURE_PASSWORDS_ALGORITHM,
                                                      passwordsAlgorithm);
  +        passwordsSuffix = serviceConf.getString(CONFIG_SECURE_PASSWORDS_SUFFIX,
  +                                                   passwordsSuffix);
   
  -       try
  +        try
           {
               roles = serviceConf.getStringArray(CONFIG_NEWUSER_ROLES);
           }
           catch (Exception e)
  -        {}
  +        {
  +        }
   
           if (null == roles || roles.length == 0)
           {
               roles = DEFAULT_CONFIG_NEWUSER_ROLES;
           }
   
  -        this.runDataService =
  -           (JetspeedRunDataService)TurbineServices.getInstance()
  +        this.runDataService = (JetspeedRunDataService)TurbineServices.getInstance()
                  .getService(RunDataService.SERVICE_NAME);
   
           setInit(true);
        }
  +
       ///////////////////////////////////////////////////////////////////////////
       // Internal
       ///////////////////////////////////////////////////////////////////////////
  @@ -467,6 +529,7 @@
        * @throws UserException if there was a general db access error
        *
        */
  +
       protected boolean accountExists( JetspeedUser user )
           throws UserException
       {
  @@ -476,24 +539,29 @@
       protected boolean accountExists( JetspeedUser user, boolean checkUniqueId )
           throws UserException
       {
  -      UserNamePrincipal principal = new UserNamePrincipal(user.getUserName());
  -      try{
  -        getUser(principal);
  -        return true;
  -      }catch (Exception e){
  -        return false;
  -      }
  +        UserNamePrincipal principal = new UserNamePrincipal(user.getUserName());
  +
  +        try
  +        {
  +            getUser(principal);
  +            return true;
  +        }
  +        catch (Exception e)
  +        {
  +            return false;
  +        }
       }
   
       protected JetspeedRunData getRunData()
  -     {
  -         JetspeedRunData rundata = null;
  -         if (this.runDataService != null)
  -         {
  -             rundata = this.runDataService.getCurrentRunData();
  -         }
  -         return rundata;
  -     }
  +    {
  +        JetspeedRunData rundata = null;
   
  +        if (this.runDataService != null)
  +        {
  +            rundata = this.runDataService.getCurrentRunData();
  +        }
  +
  +        return rundata;
  +    }
   
  -}
  \ No newline at end of file
  +}
  
  
  
  1.7       +6 -1      jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/turbine/TurbineRoleManagement.java
  
  Index: TurbineRoleManagement.java
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/src/java/org/apache/jetspeed/services/security/turbine/TurbineRoleManagement.java,v
  retrieving revision 1.6
  retrieving revision 1.7
  diff -u -r1.6 -r1.7
  --- TurbineRoleManagement.java	8 Nov 2002 10:05:18 -0000	1.6
  +++ TurbineRoleManagement.java	8 Dec 2002 19:33:53 -0000	1.7
  @@ -256,6 +256,11 @@
                   role.getName() + "'", e);
           }
   
  +        if (cachingEnable)
  +        {
  +            JetspeedSecurityCache.addRole(role);
  +        }
  +
           try
           {
               addDefaultRolePSML(role);
  
  
  
  1.2       +0 -1      jakarta-jetspeed/webapp/WEB-INF/db/jetspeed.data
  
  	<<Binary file>>
  
  
  1.23      +2 -2      jakarta-jetspeed/webapp/WEB-INF/db/jetspeed.properties
  
  Index: jetspeed.properties
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/webapp/WEB-INF/db/jetspeed.properties,v
  retrieving revision 1.22
  retrieving revision 1.23
  diff -u -r1.22 -r1.23
  --- jetspeed.properties	5 Dec 2002 19:59:43 -0000	1.22
  +++ jetspeed.properties	8 Dec 2002 19:33:53 -0000	1.23
  @@ -1,5 +1,5 @@
   #HSQL database
  -#Thu Dec 05 11:38:22 PST 2002
  +#Sat Dec 07 22:50:05 PST 2002
   sql.strict_fk=false
   readonly=false
   sql.strong_fk=true
  @@ -9,7 +9,7 @@
   sql.compare_in_locale=false
   sql.month=true
   hsqldb.log_size=200
  -modified=no
  +modified=yes
   hsqldb.cache_version=1.7.0
   hsqldb.original_version=1.7.1
   hsqldb.compatible_version=1.7.0
  
  
  
  1.25      +140 -1    jakarta-jetspeed/webapp/WEB-INF/db/jetspeed.script
  
  Index: jetspeed.script
  ===================================================================
  RCS file: /home/cvs/jakarta-jetspeed/webapp/WEB-INF/db/jetspeed.script,v
  retrieving revision 1.24
  retrieving revision 1.25
  diff -u -r1.24 -r1.25
  --- jetspeed.script	5 Dec 2002 19:59:43 -0000	1.24
  +++ jetspeed.script	8 Dec 2002 19:33:53 -0000	1.25
  @@ -19,8 +19,8 @@
   CREATE TABLE COFFEES(COFFEE_ID INTEGER NOT NULL IDENTITY PRIMARY KEY,COFFEE_NAME VARCHAR(50),SUPPLIER_ID INTEGER,PRICE FLOAT,SALES INTEGER,TOTAL INTEGER)
   CREATE TABLE JETSPEED_ACL(ACL_ID INTEGER,SECURITY_ID INTEGER,RESOURCE VARCHAR,RESOURCE_TYPE VARCHAR,ACTION VARCHAR,ALLOW_TYPE VARCHAR,PRINCIPAL VARCHAR,CONSTRAINT SYS_CT_17 UNIQUE(ACL_ID))
   CREATE INDEX JETSPEED_ACL_I_2 ON JETSPEED_ACL(SECURITY_ID)
  -GRANT ALL ON CLASS "java.lang.Math" TO PUBLIC
   GRANT ALL ON CLASS "org.hsqldb.Library" TO PUBLIC
  +GRANT ALL ON CLASS "java.lang.Math" TO PUBLIC
   GRANT ALL ON CLASS "org.hsql.Library" TO PUBLIC
   CREATE USER SA PASSWORD "" ADMIN
   CREATE ALIAS DAYNAME FOR "org.hsqldb.Library.dayname"
  @@ -153,3 +153,142 @@
   INSERT INTO COFFEES VALUES(9,'KenyanGrade',2,7.99E0,1,2)
   INSERT INTO COFFEES VALUES(10,'JoeGrade',3,7.99E0,1,2)
   INSERT INTO COFFEES VALUES(11,'CantThinkOfAnymoreGrade',4,7.99E0,1,2)
  +/*C2*/CONNECT USER sa PASSWORD ""
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  +SET AUTOCOMMIT TRUE
  +SET READONLY FALSE
  
  
  

--
To unsubscribe, e-mail:   <mailto:jetspeed-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:jetspeed-dev-help@jakarta.apache.org>


Mime
View raw message