jspwiki-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mets...@apache.org
Subject jspwiki git commit: * 2.10.3-git-27.
Date Sat, 14 Jan 2017 12:21:41 GMT
Repository: jspwiki
Updated Branches:
  refs/heads/master 544d58bd6 -> 2e3da23a8


 * 2.10.3-git-27.

       * Fixed JSPWIKI-1042 - Impossible to change user profile loginName, fullname, password
(patch by Eric Kraußer)
       * Fixed JSPWIKI-1043 - Encode email subjects as UTF-8 (patch by Eric Kraußer)


Project: http://git-wip-us.apache.org/repos/asf/jspwiki/repo
Commit: http://git-wip-us.apache.org/repos/asf/jspwiki/commit/2e3da23a
Tree: http://git-wip-us.apache.org/repos/asf/jspwiki/tree/2e3da23a
Diff: http://git-wip-us.apache.org/repos/asf/jspwiki/diff/2e3da23a

Branch: refs/heads/master
Commit: 2e3da23a887548876fa7f61303efaf1fa15fc333
Parents: 544d58b
Author: Harry Metske <harry.metske@gmail.com>
Authored: Sat Jan 14 13:21:21 2017 +0100
Committer: Harry Metske <harry.metske@gmail.com>
Committed: Sat Jan 14 13:21:21 2017 +0100

----------------------------------------------------------------------
 ChangeLog                                                 |  7 +++++++
 jspwiki-war/src/main/java/org/apache/wiki/Release.java    |  2 +-
 .../src/main/java/org/apache/wiki/auth/UserManager.java   | 10 +++++-----
 .../src/main/java/org/apache/wiki/util/MailUtil.java      |  2 +-
 4 files changed, 14 insertions(+), 7 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/jspwiki/blob/2e3da23a/ChangeLog
----------------------------------------------------------------------
diff --git a/ChangeLog b/ChangeLog
index 6e7fbee..376ae38 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2017-01-14  Harry Metske (metskem@apache.org)
+
+       * 2.10.3-git-27.
+
+       * Fixed JSPWIKI-1042 - Impossible to change user profile loginName, fullname, password
(patch by Eric Kraußer)
+       * Fixed JSPWIKI-1043 - Encode email subjects as UTF-8 (patch by Eric Kraußer)
+
 2017-01-06  Dirk Frederickx (brushed AT apache DOT org)
 
        * 2.10.3-git-26

http://git-wip-us.apache.org/repos/asf/jspwiki/blob/2e3da23a/jspwiki-war/src/main/java/org/apache/wiki/Release.java
----------------------------------------------------------------------
diff --git a/jspwiki-war/src/main/java/org/apache/wiki/Release.java b/jspwiki-war/src/main/java/org/apache/wiki/Release.java
index 60bbe09..7bbe472 100644
--- a/jspwiki-war/src/main/java/org/apache/wiki/Release.java
+++ b/jspwiki-war/src/main/java/org/apache/wiki/Release.java
@@ -72,7 +72,7 @@ public final class Release {
      *  <p>
      *  If the build identifier is empty, it is not added.
      */
-    public static final String     BUILD         = "26";
+    public static final String     BUILD         = "27";
 
     /**
      *  This is the generic version string you should use when printing out the version.
 It is of

http://git-wip-us.apache.org/repos/asf/jspwiki/blob/2e3da23a/jspwiki-war/src/main/java/org/apache/wiki/auth/UserManager.java
----------------------------------------------------------------------
diff --git a/jspwiki-war/src/main/java/org/apache/wiki/auth/UserManager.java b/jspwiki-war/src/main/java/org/apache/wiki/auth/UserManager.java
index 81d8759..1412718 100644
--- a/jspwiki-war/src/main/java/org/apache/wiki/auth/UserManager.java
+++ b/jspwiki-war/src/main/java/org/apache/wiki/auth/UserManager.java
@@ -555,8 +555,7 @@ public class UserManager {
             if ( otherProfile != null && !profile.equals( otherProfile ) &&
!fullName.equals( otherProfile.getFullname() ) )
             {
                 Object[] args = { fullName };
-                session.addMessage( SESSION_MESSAGES, MessageFormat.format( rb.getString("security.error.illegalfullname"),
-                                                                            args ) );
+                session.addMessage( SESSION_MESSAGES, MessageFormat.format( rb.getString("security.error.illegalfullname"),
args ) );
             }
         }
         catch ( NoSuchPrincipalException e)
@@ -569,8 +568,7 @@ public class UserManager {
             if ( otherProfile != null && !profile.equals( otherProfile ) &&
!loginName.equals( otherProfile.getLoginName() ) )
             {
                 Object[] args = { loginName };
-                session.addMessage( SESSION_MESSAGES, MessageFormat.format( rb.getString("security.error.illegalloginname"),
-                        args ) );
+                session.addMessage( SESSION_MESSAGES, MessageFormat.format( rb.getString("security.error.illegalloginname"),
args ) );
             }
         }
         catch ( NoSuchPrincipalException e)
@@ -580,7 +578,9 @@ public class UserManager {
         try
         {
             otherProfile = getUserDatabase().findByEmail( email );
-            if ( otherProfile != null && !profile.equals( otherProfile ) &&
StringUtils.lowerCase( email ).equals( StringUtils.lowerCase(otherProfile.getEmail() ) ) )
+            if ( otherProfile != null
+                && !profile.getUid().equals(otherProfile.getUid()) // Issue JSPWIKI-1042
+                && !profile.equals( otherProfile ) && StringUtils.lowerCase(
email ).equals( StringUtils.lowerCase(otherProfile.getEmail() ) ) )
             {
                 Object[] args = { email };
                 session.addMessage( SESSION_MESSAGES, MessageFormat.format( rb.getString("security.error.email.taken"),
args ) );

http://git-wip-us.apache.org/repos/asf/jspwiki/blob/2e3da23a/jspwiki-war/src/main/java/org/apache/wiki/util/MailUtil.java
----------------------------------------------------------------------
diff --git a/jspwiki-war/src/main/java/org/apache/wiki/util/MailUtil.java b/jspwiki-war/src/main/java/org/apache/wiki/util/MailUtil.java
index 7b209f0..d03681e 100644
--- a/jspwiki-war/src/main/java/org/apache/wiki/util/MailUtil.java
+++ b/jspwiki-war/src/main/java/org/apache/wiki/util/MailUtil.java
@@ -279,7 +279,7 @@ public final class MailUtil {
             MimeMessage msg = new MimeMessage(session);
             msg.setFrom(new InternetAddress(c_fromAddress));
             msg.setRecipients(Message.RecipientType.TO, InternetAddress.parse(to, false));
-            msg.setSubject(subject);
+            msg.setSubject(subject, "UTF-8");
             msg.setText(content, "UTF-8");
             msg.setSentDate(new Date());
 


Mime
View raw message