[math] Update developer section.
Repository: commons-math Updated Branches: refs/heads/master 41b21f83d -> a614e8520 Update developer section. Project: http://git-wip-us.apache.org/repos/asf/commons-math/repo Commit: http://git-wip-us.apache.org/repos/asf/commons-math/commit/a614e852 Tree: http://git-wip-us.apache.org/repos/asf/commons-math/tree/a614e852 Diff: http://git-wip-us.apache.org/repos/asf/commons-math/diff/a614e852 Branch: refs/heads/master Commit: a614e852048ecda642ef1de00ce80a3193bae9e0 Parents: 41b21f8 Author: Thomas Neidhart <thomas.neidh...@gmail.com> Authored: Fri Jan 1 21:25:39 2016 +0100 Committer: Thomas Neidhart <thomas.neidh...@gmail.com> Committed: Fri Jan 1 21:25:39 2016 +0100 -- pom.xml | 8 +++- 1 file changed, 3 insertions(+), 5 deletions(-) -- http://git-wip-us.apache.org/repos/asf/commons-math/blob/a614e852/pom.xml -- diff --git a/pom.xml b/pom.xml index 56f985a..35684a2 100644 --- a/pom.xml +++ b/pom.xml @@ -128,11 +128,6 @@ brentworden at apache dot org - Thomas Neidhart - tn - tn at apache dot org - - Evan Ward evanward evanward at apache dot org @@ -278,6 +273,9 @@ Venkatesha Murthy + Thomas Neidhart + + Christopher Nix
[math] Fix compilation problems with java 1.5: remove @Override tags for interfaces, fix problem with cast, remove unneeded type parameters in test methods. Additionally, added @Override tags for impl
Repository: commons-math Updated Branches: refs/heads/MATH_3_X df1ce13f9 -> 56a628776 Fix compilation problems with java 1.5: remove @Override tags for interfaces, fix problem with cast, remove unneeded type parameters in test methods. Additionally, added @Override tags for implemented abstract methods as suggested by eclipse, small typo fixes. Project: http://git-wip-us.apache.org/repos/asf/commons-math/repo Commit: http://git-wip-us.apache.org/repos/asf/commons-math/commit/56a62877 Tree: http://git-wip-us.apache.org/repos/asf/commons-math/tree/56a62877 Diff: http://git-wip-us.apache.org/repos/asf/commons-math/diff/56a62877 Branch: refs/heads/MATH_3_X Commit: 56a6287761d0ca1e8d360bce1765f5ec697e7d04 Parents: df1ce13 Author: Thomas NeidhartAuthored: Tue Dec 29 20:47:31 2015 +0100 Committer: Thomas Neidhart Committed: Tue Dec 29 20:47:31 2015 +0100 -- .../interpolation/MicrosphereProjectionInterpolator.java| 2 -- .../math3/analysis/polynomials/PolynomialsUtils.java| 5 - .../commons/math3/dfp/BracketingNthOrderBrentSolverDFP.java | 1 - .../apache/commons/math3/distribution/ZipfDistribution.java | 2 ++ .../math3/fitting/leastsquares/LeastSquaresFactory.java | 1 + .../java/org/apache/commons/math3/fraction/BigFraction.java | 9 - .../commons/math3/geometry/partitioning/RegionFactory.java | 2 +- .../org/apache/commons/math3/ml/neuralnet/MapUtils.java | 1 - .../math3/ml/neuralnet/sofm/KohonenUpdateAction.java| 1 - .../math3/ml/neuralnet/twod/util/QuantizationError.java | 1 - .../commons/math3/ode/nonstiff/AdamsFieldIntegrator.java| 1 - .../math3/ode/nonstiff/AdamsFieldStepInterpolator.java | 1 + .../math3/ode/nonstiff/AdamsNordsieckFieldTransformer.java | 9 + .../ode/nonstiff/ClassicalRungeKuttaFieldIntegrator.java| 3 --- .../nonstiff/ClassicalRungeKuttaFieldStepInterpolator.java | 1 + .../math3/ode/nonstiff/DormandPrince54FieldIntegrator.java | 3 --- .../ode/nonstiff/DormandPrince54FieldStepInterpolator.java | 1 + .../math3/ode/nonstiff/DormandPrince853FieldIntegrator.java | 3 --- .../ode/nonstiff/DormandPrince853FieldStepInterpolator.java | 1 + .../ode/nonstiff/EmbeddedRungeKuttaFieldIntegrator.java | 1 - .../commons/math3/ode/nonstiff/EulerFieldIntegrator.java| 3 --- .../math3/ode/nonstiff/EulerFieldStepInterpolator.java | 1 + .../commons/math3/ode/nonstiff/GillFieldIntegrator.java | 3 --- .../math3/ode/nonstiff/GillFieldStepInterpolator.java | 1 + .../math3/ode/nonstiff/HighamHall54FieldIntegrator.java | 3 --- .../ode/nonstiff/HighamHall54FieldStepInterpolator.java | 1 + .../commons/math3/ode/nonstiff/LutherFieldIntegrator.java | 3 --- .../math3/ode/nonstiff/LutherFieldStepInterpolator.java | 1 + .../commons/math3/ode/nonstiff/MidpointFieldIntegrator.java | 3 --- .../math3/ode/nonstiff/MidpointFieldStepInterpolator.java | 1 + .../math3/ode/nonstiff/RungeKuttaFieldIntegrator.java | 1 - .../math3/ode/nonstiff/RungeKuttaFieldStepInterpolator.java | 7 ++- .../math3/ode/nonstiff/ThreeEighthesFieldIntegrator.java| 3 --- .../ode/nonstiff/ThreeEighthesFieldStepInterpolator.java| 1 + .../java/org/apache/commons/math3/util/IntegerSequence.java | 7 +-- .../org/apache/commons/math3/util/IterationManager.java | 1 - .../MicrosphereProjectionInterpolatorTest.java | 1 - .../commons/math3/distribution/ZipfDistributionTest.java| 2 +- .../AbstractEmbeddedRungeKuttaFieldIntegratorTest.java | 6 +++--- .../ode/nonstiff/AbstractRungeKuttaFieldIntegratorTest.java | 6 +++--- .../math3/ode/nonstiff/EulerFieldIntegratorTest.java| 1 + 41 files changed, 30 insertions(+), 75 deletions(-) -- http://git-wip-us.apache.org/repos/asf/commons-math/blob/56a62877/src/main/java/org/apache/commons/math3/analysis/interpolation/MicrosphereProjectionInterpolator.java -- diff --git a/src/main/java/org/apache/commons/math3/analysis/interpolation/MicrosphereProjectionInterpolator.java b/src/main/java/org/apache/commons/math3/analysis/interpolation/MicrosphereProjectionInterpolator.java index 700b290..28f5b26 100644 --- a/src/main/java/org/apache/commons/math3/analysis/interpolation/MicrosphereProjectionInterpolator.java +++ b/src/main/java/org/apache/commons/math3/analysis/interpolation/MicrosphereProjectionInterpolator.java @@ -124,7 +124,6 @@ public class MicrosphereProjectionInterpolator * @throws DimensionMismatchException if the space dimension of the * given samples does not match the space dimension of the microsphere. */ -@Override public MultivariateFunction interpolate(final double[][] xval,
[math] Add userguide example for image clustering.
Repository: commons-math Updated Branches: refs/heads/master 81585a3c4 -> f0943a724 Add userguide example for image clustering. Project: http://git-wip-us.apache.org/repos/asf/commons-math/repo Commit: http://git-wip-us.apache.org/repos/asf/commons-math/commit/f0943a72 Tree: http://git-wip-us.apache.org/repos/asf/commons-math/tree/f0943a72 Diff: http://git-wip-us.apache.org/repos/asf/commons-math/diff/f0943a72 Branch: refs/heads/master Commit: f0943a7242041a16c8f7fca845592e48bb19ac74 Parents: 81585a3 Author: Thomas NeidhartAuthored: Mon Dec 28 21:01:18 2015 +0100 Committer: Thomas Neidhart Committed: Mon Dec 28 21:01:18 2015 +0100 -- .../commons/math4/userguide/ExampleUtils.java | 10 + .../clustering/ImageClusteringExample.java | 203 +++ src/userguide/resources/ColorfulBird.jpg| Bin 0 -> 98227 bytes src/userguide/resources/references.txt | 4 +- 4 files changed, 216 insertions(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/commons-math/blob/f0943a72/src/userguide/java/org/apache/commons/math4/userguide/ExampleUtils.java -- diff --git a/src/userguide/java/org/apache/commons/math4/userguide/ExampleUtils.java b/src/userguide/java/org/apache/commons/math4/userguide/ExampleUtils.java index e58540d..dddc96c 100644 --- a/src/userguide/java/org/apache/commons/math4/userguide/ExampleUtils.java +++ b/src/userguide/java/org/apache/commons/math4/userguide/ExampleUtils.java @@ -17,12 +17,14 @@ package org.apache.commons.math4.userguide; import java.awt.Component; +import java.awt.Graphics2D; import java.awt.event.ActionEvent; import java.awt.event.ActionListener; import java.awt.event.InputEvent; import java.awt.event.KeyEvent; import java.awt.image.BufferedImage; import java.io.File; +import java.io.IOException; import javax.imageio.ImageIO; import javax.swing.JFileChooser; @@ -100,5 +102,13 @@ public class ExampleUtils { component.paint(image.getGraphics()); return image; } + +public static BufferedImage resizeImage(BufferedImage originalImage, int width, int height, int type) throws IOException { +BufferedImage resizedImage = new BufferedImage(width, height, type); +Graphics2D g = resizedImage.createGraphics(); +g.drawImage(originalImage, 0, 0, width, height, null); +g.dispose(); +return resizedImage; +} } http://git-wip-us.apache.org/repos/asf/commons-math/blob/f0943a72/src/userguide/java/org/apache/commons/math4/userguide/clustering/ImageClusteringExample.java -- diff --git a/src/userguide/java/org/apache/commons/math4/userguide/clustering/ImageClusteringExample.java b/src/userguide/java/org/apache/commons/math4/userguide/clustering/ImageClusteringExample.java new file mode 100644 index 000..67e197a --- /dev/null +++ b/src/userguide/java/org/apache/commons/math4/userguide/clustering/ImageClusteringExample.java @@ -0,0 +1,203 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.commons.math4.userguide.clustering; + +import java.awt.BorderLayout; +import java.awt.Color; +import java.awt.Component; +import java.awt.Dimension; +import java.awt.FlowLayout; +import java.awt.Graphics; +import java.awt.GridLayout; +import java.awt.event.ActionEvent; +import java.awt.event.ActionListener; +import java.awt.image.BufferedImage; +import java.awt.image.Raster; +import java.awt.image.WritableRaster; +import java.io.File; +import java.util.ArrayList; +import java.util.List; + +import javax.imageio.ImageIO; +import javax.swing.BorderFactory; +import javax.swing.Box; +import javax.swing.ImageIcon; +import javax.swing.JButton; +import javax.swing.JLabel; +import javax.swing.JPanel; +import javax.swing.JSpinner; +import javax.swing.SpinnerNumberModel; + +import org.apache.commons.math4.ml.clustering.CentroidCluster; +import
svn commit: r1719572 - /commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileObject.java
Author: tn Date: Fri Dec 11 21:47:09 2015 New Revision: 1719572 URL: http://svn.apache.org/viewvc?rev=1719572=rev Log: Fix some typos. Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileObject.java Modified: commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileObject.java URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileObject.java?rev=1719572=1719571=1719572=diff == --- commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileObject.java (original) +++ commons/proper/vfs/trunk/core/src/main/java/org/apache/commons/vfs2/provider/AbstractFileObject.java Fri Dec 11 21:47:09 2015 @@ -412,7 +412,7 @@ public abstract class AbstractFileObject } */ -// Traverse up the heirarchy and make sure everything is a folder +// Traverse up the hierarchy and make sure everything is a folder final FileObject parent = getParent(); if (parent != null) { @@ -558,7 +558,7 @@ public abstract class AbstractFileObject } /** - * Detaches this file, invaliating all cached info. This will force + * Detaches this file, invalidating all cached info. This will force * a call to {@link #doAttach} next time this file is used. * @throws Exception if an error occurs. */ @@ -994,7 +994,7 @@ public abstract class AbstractFileObject } /** - * Called when the ouput stream for this file is closed. + * Called when the output stream for this file is closed. * @throws Exception if an error occurs. */ protected void endOutput() throws Exception @@ -1359,11 +1359,11 @@ public abstract class AbstractFileObject * write the content of the file to. * * @param bAppend true when append to the file. - *Note: If the underlaying filesystem does not support appending, + *Note: If the underlying filesystem does not support appending, *a FileSystemException is thrown. * @return An OutputStream where the new contents of the file can be written. * @throws FileSystemException if an error occurs; for example: - * bAppend is true, and the unbderlying FileSystem does not support it + * bAppend is true, and the underlying FileSystem does not support it */ public OutputStream getOutputStream(final boolean bAppend) throws FileSystemException { @@ -1881,7 +1881,7 @@ public abstract class AbstractFileObject try { attach(); -// remeber type to avoid attach +// remember type to avoid attach FileType srcType = getType(); doRename(destFile); @@ -1980,7 +1980,7 @@ public abstract class AbstractFileObject } /** - * This will prepare the fileObject to get resynchronized with the underlaying filesystem if required. + * This will prepare the fileObject to get resynchronized with the underlying filesystem if required. * @throws FileSystemException if an error occurs. */ @Override
svn commit: r1719563 - in /commons/proper/vfs/trunk: pom.xml src/changes/changes.xml
Author: tn Date: Fri Dec 11 21:14:46 2015 New Revision: 1719563 URL: http://svn.apache.org/viewvc?rev=1719563=rev Log: Update to latest release of collections. Modified: commons/proper/vfs/trunk/pom.xml commons/proper/vfs/trunk/src/changes/changes.xml Modified: commons/proper/vfs/trunk/pom.xml URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/pom.xml?rev=1719563=1719562=1719563=diff == --- commons/proper/vfs/trunk/pom.xml (original) +++ commons/proper/vfs/trunk/pom.xml Fri Dec 11 21:14:46 2015 @@ -371,7 +371,7 @@ org.apache.commons commons-collections4 -4.0 +4.1 commons-httpclient Modified: commons/proper/vfs/trunk/src/changes/changes.xml URL: http://svn.apache.org/viewvc/commons/proper/vfs/trunk/src/changes/changes.xml?rev=1719563=1719562=1719563=diff == --- commons/proper/vfs/trunk/src/changes/changes.xml (original) +++ commons/proper/vfs/trunk/src/changes/changes.xml Fri Dec 11 21:14:46 2015 @@ -200,7 +200,7 @@ Wrong assertion messages in RAM provider test case. -Update to Apache Commons Collection 4.0 from 3.2.1 and use generics. +Update to Apache Commons Collection 4.1 from 3.2.1 and use generics. Update Apache Commons Logging to 1.1.3 from 1.1.2.
svn commit: r1718095 - /commons/cms-site/trunk/conf/component_releases.properties
Author: tn Date: Sat Dec 5 15:06:05 2015 New Revision: 1718095 URL: http://svn.apache.org/viewvc?rev=1718095=rev Log: Functor was never released. Modified: commons/cms-site/trunk/conf/component_releases.properties Modified: commons/cms-site/trunk/conf/component_releases.properties URL: http://svn.apache.org/viewvc/commons/cms-site/trunk/conf/component_releases.properties?rev=1718095=1718094=1718095=diff == --- commons/cms-site/trunk/conf/component_releases.properties (original) +++ commons/cms-site/trunk/conf/component_releases.properties Sat Dec 5 15:06:05 2015 @@ -48,8 +48,8 @@ execVersion=1.3 execReleased=2014-11-06 fileuploadVersion=1.3.1 fileuploadReleased=2014-02-07 -functorVersion=1.0 -functorReleased=2011-??-?? +functorVersion=N/A +functorReleased=N/A httpclientVersion=N/A httpclientReleased=N/A imagingVersion=0.97-incubator
[math] Update latest version in README.
Repository: commons-math Updated Branches: refs/heads/master 7d32a990e -> f504277bc Update latest version in README. Project: http://git-wip-us.apache.org/repos/asf/commons-math/repo Commit: http://git-wip-us.apache.org/repos/asf/commons-math/commit/f504277b Tree: http://git-wip-us.apache.org/repos/asf/commons-math/tree/f504277b Diff: http://git-wip-us.apache.org/repos/asf/commons-math/diff/f504277b Branch: refs/heads/master Commit: f504277bcad0c519d3df008c635856962323aa5b Parents: 7d32a99 Author: Thomas NeidhartAuthored: Wed Dec 2 20:43:44 2015 +0100 Committer: Thomas Neidhart Committed: Wed Dec 2 20:43:44 2015 +0100 -- README.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/commons-math/blob/f504277b/README.md -- diff --git a/README.md b/README.md index bd623d7..8bdcd2a 100644 --- a/README.md +++ b/README.md @@ -67,7 +67,7 @@ Alternatively you can pull it from the central Maven repositories: org.apache.commons commons-math3 - 3.4.1 + 3.5 ```
[math] Add badges and initial travis configuration. This closes #11.
Repository: commons-math Updated Branches: refs/heads/master bdc329db9 -> 7d32a990e Add badges and initial travis configuration. This closes #11. Project: http://git-wip-us.apache.org/repos/asf/commons-math/repo Commit: http://git-wip-us.apache.org/repos/asf/commons-math/commit/7d32a990 Tree: http://git-wip-us.apache.org/repos/asf/commons-math/tree/7d32a990 Diff: http://git-wip-us.apache.org/repos/asf/commons-math/diff/7d32a990 Branch: refs/heads/master Commit: 7d32a990e9696bd1a2f3ecab08a58b8751008365 Parents: bdc329d Author: Thomas NeidhartAuthored: Wed Dec 2 20:42:31 2015 +0100 Committer: Thomas Neidhart Committed: Wed Dec 2 20:42:31 2015 +0100 -- .travis.yml | 15 +++ README.md | 5 + pom.xml | 37 +++-- 3 files changed, 55 insertions(+), 2 deletions(-) -- http://git-wip-us.apache.org/repos/asf/commons-math/blob/7d32a990/.travis.yml -- diff --git a/.travis.yml b/.travis.yml new file mode 100644 index 000..bd60a9f --- /dev/null +++ b/.travis.yml @@ -0,0 +1,15 @@ +language: java +sudo: false + +jdk: + - openjdk6 + - openjdk7 + - oraclejdk8 + +# only build trunk +branches: + only: +- master + +after_success: + - mvn clean test jacoco:report coveralls:report http://git-wip-us.apache.org/repos/asf/commons-math/blob/7d32a990/README.md -- diff --git a/README.md b/README.md index 08172f4..bd623d7 100644 --- a/README.md +++ b/README.md @@ -43,6 +43,11 @@ Apache Commons Math === +[![Build Status](https://travis-ci.org/apache/commons-math.svg?branch=master)](https://travis-ci.org/apache/commons-math) +[![Coverage Status](https://coveralls.io/repos/apache/commons-math/badge.svg?branch=master=github)](https://coveralls.io/github/apache/commons-math?branch=master) +[![Maven Central](https://maven-badges.herokuapp.com/maven-central/org.apache.commons/commons-math3/badge.svg)](https://maven-badges.herokuapp.com/maven-central/org.apache.commons/commons-math3/) +[![License](http://img.shields.io/:license-apache-blue.svg)](http://www.apache.org/licenses/LICENSE-2.0.html) + The Apache Commons Math project is a library of lightweight, self-contained mathematics and statistics components addressing the most common practical problems not immediately available in the Java programming language or commons-lang. Documentation http://git-wip-us.apache.org/repos/asf/commons-math/blob/7d32a990/pom.xml -- diff --git a/pom.xml b/pom.xml index 65ea6c3..def8dfa 100644 --- a/pom.xml +++ b/pom.xml @@ -813,7 +813,40 @@ - + + travis + + + env.TRAVIS + true + + + +true + + + + +org.jacoco +jacoco-maven-plugin +${commons.jacoco.version} + + +prepare-agent + + prepare-agent + + + + + +org.eluder.coveralls +coveralls-maven-plugin +3.1.0 + + + + + -
[math] Apply fix for timestamp format.
Repository: commons-math Updated Branches: refs/heads/master 25de9b780 -> 9085dfacc Apply fix for timestamp format. Project: http://git-wip-us.apache.org/repos/asf/commons-math/repo Commit: http://git-wip-us.apache.org/repos/asf/commons-math/commit/9085dfac Tree: http://git-wip-us.apache.org/repos/asf/commons-math/tree/9085dfac Diff: http://git-wip-us.apache.org/repos/asf/commons-math/diff/9085dfac Branch: refs/heads/master Commit: 9085dfacc0e84ed1fbe4e961563cdfffbca42e10 Parents: 25de9b7 Author: Thomas NeidhartAuthored: Wed Dec 2 21:19:37 2015 +0100 Committer: Thomas Neidhart Committed: Wed Dec 2 21:19:37 2015 +0100 -- pom.xml | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/commons-math/blob/9085dfac/pom.xml -- diff --git a/pom.xml b/pom.xml index def8dfa..56f985a 100644 --- a/pom.xml +++ b/pom.xml @@ -422,6 +422,8 @@ 1.2.10 ${git.revision}; ${maven.build.timestamp} + +{0,date,-MM-dd HH:mm:ssZ} @@ -822,9 +824,6 @@ true - -true -
[math] MATH 4 requires at least java 7, build also the MATH_3_X branch.
Repository: commons-math Updated Branches: refs/heads/master 7afc1c34f -> 25de9b780 MATH 4 requires at least java 7, build also the MATH_3_X branch. Project: http://git-wip-us.apache.org/repos/asf/commons-math/repo Commit: http://git-wip-us.apache.org/repos/asf/commons-math/commit/25de9b78 Tree: http://git-wip-us.apache.org/repos/asf/commons-math/tree/25de9b78 Diff: http://git-wip-us.apache.org/repos/asf/commons-math/diff/25de9b78 Branch: refs/heads/master Commit: 25de9b7800887c12365f6a19b13cf32baf5bfe2f Parents: 7afc1c3 Author: Thomas NeidhartAuthored: Wed Dec 2 21:08:41 2015 +0100 Committer: Thomas Neidhart Committed: Wed Dec 2 21:08:41 2015 +0100 -- .travis.yml | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) -- http://git-wip-us.apache.org/repos/asf/commons-math/blob/25de9b78/.travis.yml -- diff --git a/.travis.yml b/.travis.yml index bd60a9f..3177040 100644 --- a/.travis.yml +++ b/.travis.yml @@ -2,14 +2,14 @@ language: java sudo: false jdk: - - openjdk6 - openjdk7 - oraclejdk8 -# only build trunk +# only build master and the MATH_3_X branch branches: only: - master +- MATH_3_X after_success: - mvn clean test jacoco:report coveralls:report
[math] Add missing Override tags -> trigger travis build.
Repository: commons-math Updated Branches: refs/heads/master f504277bc -> 7afc1c34f Add missing Override tags -> trigger travis build. Project: http://git-wip-us.apache.org/repos/asf/commons-math/repo Commit: http://git-wip-us.apache.org/repos/asf/commons-math/commit/7afc1c34 Tree: http://git-wip-us.apache.org/repos/asf/commons-math/tree/7afc1c34 Diff: http://git-wip-us.apache.org/repos/asf/commons-math/diff/7afc1c34 Branch: refs/heads/master Commit: 7afc1c34fc16ec04f82105f9106b7d1e5232c4d0 Parents: f504277 Author: Thomas NeidhartAuthored: Wed Dec 2 21:03:30 2015 +0100 Committer: Thomas Neidhart Committed: Wed Dec 2 21:03:30 2015 +0100 -- .../apache/commons/math4/random/RandomAdaptorTest.java | 11 +++ .../math4/random/SynchronizedRandomGeneratorTest.java| 1 + 2 files changed, 12 insertions(+) -- http://git-wip-us.apache.org/repos/asf/commons-math/blob/7afc1c34/src/test/java/org/apache/commons/math4/random/RandomAdaptorTest.java -- diff --git a/src/test/java/org/apache/commons/math4/random/RandomAdaptorTest.java b/src/test/java/org/apache/commons/math4/random/RandomAdaptorTest.java index da7e763..df8bdba 100644 --- a/src/test/java/org/apache/commons/math4/random/RandomAdaptorTest.java +++ b/src/test/java/org/apache/commons/math4/random/RandomAdaptorTest.java @@ -71,43 +71,54 @@ public class RandomAdaptorTest { this.value = value; } +@Override public boolean nextBoolean() { return false; } +@Override public void nextBytes(byte[] bytes) { } +@Override public double nextDouble() { return value; } +@Override public float nextFloat() { return (float) value; } +@Override public double nextGaussian() { return value; } +@Override public int nextInt() { return (int) value; } +@Override public int nextInt(int n) { return (int) value; } +@Override public long nextLong() { return (int) value; } +@Override public void setSeed(int seed) { } +@Override public void setSeed(int[] seed) { } +@Override public void setSeed(long seed) { } http://git-wip-us.apache.org/repos/asf/commons-math/blob/7afc1c34/src/test/java/org/apache/commons/math4/random/SynchronizedRandomGeneratorTest.java -- diff --git a/src/test/java/org/apache/commons/math4/random/SynchronizedRandomGeneratorTest.java b/src/test/java/org/apache/commons/math4/random/SynchronizedRandomGeneratorTest.java index 2c1fe43..b66a127 100644 --- a/src/test/java/org/apache/commons/math4/random/SynchronizedRandomGeneratorTest.java +++ b/src/test/java/org/apache/commons/math4/random/SynchronizedRandomGeneratorTest.java @@ -98,6 +98,7 @@ public class SynchronizedRandomGeneratorTest { final List tasks = new ArrayList (); for (int i = 0; i < numGenerators; i++) { tasks.add(new Callable() { +@Override public Double call() { Double lastValue = 0d; for (int j = 0; j < numSamples; j++) {
svn commit: r1717588 - /commons/proper/collections/trunk/.travis.yml
Author: tn Date: Wed Dec 2 09:02:12 2015 New Revision: 1717588 URL: http://svn.apache.org/viewvc?rev=1717588=rev Log: Update travis configuration: only build trunk Modified: commons/proper/collections/trunk/.travis.yml Modified: commons/proper/collections/trunk/.travis.yml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/.travis.yml?rev=1717588=1717587=1717588=diff == --- commons/proper/collections/trunk/.travis.yml (original) +++ commons/proper/collections/trunk/.travis.yml Wed Dec 2 09:02:12 2015 @@ -6,5 +6,10 @@ jdk: - openjdk7 - oraclejdk8 +# only build trunk +branches: + only: +- trunk + after_success: - mvn clean test jacoco:report coveralls:report
svn commit: r1717614 - /commons/proper/collections/trunk/README.md
Author: tn Date: Wed Dec 2 11:36:14 2015 New Revision: 1717614 URL: http://svn.apache.org/viewvc?rev=1717614=rev Log: Update readme with latest version. Modified: commons/proper/collections/trunk/README.md Modified: commons/proper/collections/trunk/README.md URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/README.md?rev=1717614=1717613=1717614=diff == --- commons/proper/collections/trunk/README.md (original) +++ commons/proper/collections/trunk/README.md Wed Dec 2 11:36:14 2015 @@ -67,7 +67,7 @@ Alternatively you can pull it from the c org.apache.commons commons-collections4 - 4.0 + 4.1 ```
svn commit: r1717423 - /commons/proper/collections/trunk/pom.xml
Author: tn Date: Tue Dec 1 13:09:11 2015 New Revision: 1717423 URL: http://svn.apache.org/viewvc?rev=1717423=rev Log: Try out different timestamp format for coverall plugin. Modified: commons/proper/collections/trunk/pom.xml Modified: commons/proper/collections/trunk/pom.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/pom.xml?rev=1717423=1717422=1717423=diff == --- commons/proper/collections/trunk/pom.xml (original) +++ commons/proper/collections/trunk/pom.xml Tue Dec 1 13:09:11 2015 @@ -501,6 +501,9 @@ 2.9.1 + + +{0,date,-MM-dd HH:mm:ssZ}
svn commit: r1716924 - /commons/proper/collections/tags/COLLECTIONS_4_1/
Author: tn Date: Fri Nov 27 21:53:17 2015 New Revision: 1716924 URL: http://svn.apache.org/viewvc?rev=1716924=rev Log: RC2 becomes the official Collections 4.1 release. Added: commons/proper/collections/tags/COLLECTIONS_4_1/ - copied from r1716923, commons/proper/collections/tags/COLLECTIONS_4_1_RC2/
svn commit: r1716923 - in /commons/proper/collections/trunk: doap_collections.rdf src/changes/changes.xml
Author: tn Date: Fri Nov 27 21:51:47 2015 New Revision: 1716923 URL: http://svn.apache.org/viewvc?rev=1716923=rev Log: Update doap and changes file after release. Modified: commons/proper/collections/trunk/doap_collections.rdf commons/proper/collections/trunk/src/changes/changes.xml Modified: commons/proper/collections/trunk/doap_collections.rdf URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/doap_collections.rdf?rev=1716923=1716922=1716923=diff == --- commons/proper/collections/trunk/doap_collections.rdf (original) +++ commons/proper/collections/trunk/doap_collections.rdf Fri Nov 27 21:51:47 2015 @@ -36,6 +36,13 @@ commons-collections +2015-11-27 +4.1 + + + + +commons-collections 2013-11-24 4.0 Modified: commons/proper/collections/trunk/src/changes/changes.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/changes/changes.xml?rev=1716923=1716922=1716923=diff == --- commons/proper/collections/trunk/src/changes/changes.xml (original) +++ commons/proper/collections/trunk/src/changes/changes.xml Fri Nov 27 21:51:47 2015 @@ -20,7 +20,8 @@ Commons Collections Changes - + + Added new interfaces "MultiValuedMap", "ListValuedMap" and "SetValuedMap"
svn commit: r1716926 - /commons/cms-site/trunk/content/xdoc/security.xml
Author: tn Date: Fri Nov 27 21:56:57 2015 New Revision: 1716926 URL: http://svn.apache.org/viewvc?rev=1716926=rev Log: Add link to security report for collections. Modified: commons/cms-site/trunk/content/xdoc/security.xml Modified: commons/cms-site/trunk/content/xdoc/security.xml URL: http://svn.apache.org/viewvc/commons/cms-site/trunk/content/xdoc/security.xml?rev=1716926=1716925=1716926=diff == --- commons/cms-site/trunk/content/xdoc/security.xml (original) +++ commons/cms-site/trunk/content/xdoc/security.xml Fri Nov 27 21:56:57 2015 @@ -70,6 +70,7 @@ https://commons.apache.org/proper/commons-compress/security-reports.html#Apache_Commons_Compress_Security_Vulnerabilities;>Apache Commons Compress Security Vulnerabilities + https://commons.apache.org/proper/commons-collections/security-reports.html#Apache_Commons_Collections_Security_Vulnerabilities;>Apache Commons Collections Security Vulnerabilities If you have encountered an unlisted security vulnerability
svn commit: r1716925 - /commons/cms-site/trunk/conf/component_releases.properties
Author: tn Date: Fri Nov 27 21:56:40 2015 New Revision: 1716925 URL: http://svn.apache.org/viewvc?rev=1716925=rev Log: Update latest release of collections. Modified: commons/cms-site/trunk/conf/component_releases.properties Modified: commons/cms-site/trunk/conf/component_releases.properties URL: http://svn.apache.org/viewvc/commons/cms-site/trunk/conf/component_releases.properties?rev=1716925=1716924=1716925=diff == --- commons/cms-site/trunk/conf/component_releases.properties (original) +++ commons/cms-site/trunk/conf/component_releases.properties Fri Nov 27 21:56:40 2015 @@ -10,8 +10,8 @@ cliVersion=1.3.1 cliReleased=2015-06-17 codecVersion=1.10 codecReleased=2014-11-09 -collectionsVersion=4.0 -collectionsReleased=2013-11-24 +collectionsVersion=4.1 +collectionsReleased=2015-11-27 commons-buildVersion=N/A commons-buildReleased=N/A commons-build-pluginVersion=N/A
svn commit: r1716919 - /commons/proper/collections/trunk/src/site/xdoc/download_collections.xml
Author: tn Date: Fri Nov 27 21:48:37 2015 New Revision: 1716919 URL: http://svn.apache.org/viewvc?rev=1716919=rev Log: Update download page after release. Modified: commons/proper/collections/trunk/src/site/xdoc/download_collections.xml Modified: commons/proper/collections/trunk/src/site/xdoc/download_collections.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/download_collections.xml?rev=1716919=1716918=1716919=diff == --- commons/proper/collections/trunk/src/site/xdoc/download_collections.xml (original) +++ commons/proper/collections/trunk/src/site/xdoc/download_collections.xml Fri Nov 27 21:48:37 2015 @@ -95,32 +95,32 @@ limitations under the License. - + - commons-collections4-4.0-bin.tar.gz - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.tar.gz.md5;>md5 - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.tar.gz.asc;>pgp + commons-collections4-4.1-bin.tar.gz + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5;>md5 + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc;>pgp - commons-collections4-4.0-bin.zip - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.zip.md5;>md5 - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.zip.asc;>pgp + commons-collections4-4.1-bin.zip + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.zip.md5;>md5 + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc;>pgp - commons-collections4-4.0-src.tar.gz - http://www.apache.org/dist/commons/collections/source/commons-collections4-4.0-src.tar.gz.md5;>md5 - http://www.apache.org/dist/commons/collections/source/commons-collections4-4.0-src.tar.gz.asc;>pgp + commons-collections4-4.1-src.tar.gz + http://www.apache.org/dist/commons/collections/source/commons-collections4-4.1-src.tar.gz.md5;>md5 + http://www.apache.org/dist/commons/collections/source/commons-collections4-4.1-src.tar.gz.asc;>pgp - commons-collections4-4.0-src.zip - http://www.apache.org/dist/commons/collections/source/commons-collections4-4.0-src.zip.md5;>md5 - http://www.apache.org/dist/commons/collections/source/commons-collections4-4.0-src.zip.asc;>pgp + commons-collections4-4.1-src.zip + http://www.apache.org/dist/commons/collections/source/commons-collections4-4.1-src.zip.md5;>md5 + http://www.apache.org/dist/commons/collections/source/commons-collections4-4.1-src.zip.asc;>pgp
svn commit: r1716921 - /commons/proper/collections/trunk/src/site/xdoc/index.xml
Author: tn Date: Fri Nov 27 21:49:43 2015 New Revision: 1716921 URL: http://svn.apache.org/viewvc?rev=1716921=rev Log: Update site after release. Modified: commons/proper/collections/trunk/src/site/xdoc/index.xml Modified: commons/proper/collections/trunk/src/site/xdoc/index.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/index.xml?rev=1716921=1716920=1716921=diff == --- commons/proper/collections/trunk/src/site/xdoc/index.xml (original) +++ commons/proper/collections/trunk/src/site/xdoc/index.xml Fri Nov 27 21:49:43 2015 @@ -57,7 +57,7 @@ as are various current release 4.0 +The current release 4.1 The latest 3.x release - version 3.2.2 The latest 2.x release - version 2.1.1 The latest SVN @@ -70,9 +70,9 @@ The sub -The latest version is v4.0 - +The latest version is v4.1 - http://commons.apache.org/collections/download_collections.cgi;>Download now! -It is built for Java 1.5+ and the release notes are also available. +It is built for Java 1.6+ and the release notes are also available. For previous releases, see the http://archive.apache.org/dist/commons/collections/;>Apache Archive
svn commit: r1716920 - /commons/proper/collections/trunk/pom.xml
Author: tn Date: Fri Nov 27 21:49:23 2015 New Revision: 1716920 URL: http://svn.apache.org/viewvc?rev=1716920=rev Log: Update pom after release. Modified: commons/proper/collections/trunk/pom.xml Modified: commons/proper/collections/trunk/pom.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/pom.xml?rev=1716920=1716919=1716920=diff == --- commons/proper/collections/trunk/pom.xml (original) +++ commons/proper/collections/trunk/pom.xml Fri Nov 27 21:49:23 2015 @@ -24,7 +24,7 @@ 4.0.0 org.apache.commons commons-collections4 - 4.1-SNAPSHOT + 4.2-SNAPSHOT Apache Commons Collections 2001 @@ -479,8 +479,8 @@ collections4 -4.0 -(Java 5.0+) +4.1 +(Java 6.0+) 3.2.2 @@ -639,6 +639,7 @@ site-content/**/* src/test/resources/data/test/* maven-eclipse.xml +.travis.yml
svn commit: r1716922 - /commons/proper/collections/trunk/default.properties
Author: tn Date: Fri Nov 27 21:50:16 2015 New Revision: 1716922 URL: http://svn.apache.org/viewvc?rev=1716922=rev Log: Update default.properties after release. Modified: commons/proper/collections/trunk/default.properties Modified: commons/proper/collections/trunk/default.properties URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/default.properties?rev=1716922=1716921=1716922=diff == --- commons/proper/collections/trunk/default.properties (original) +++ commons/proper/collections/trunk/default.properties Fri Nov 27 21:50:16 2015 @@ -39,7 +39,7 @@ component.package = org.apache.commons.c component.title = Commons Collections # The current version number of this component -component.version = 4.1-SNAPSHOT +component.version = 4.2-SNAPSHOT # The name that is used to create the jar file final.name = ${component.name}-${component.version}
svn commit: r11334 - in /release/commons/collections: RELEASE-NOTES-4.0.txt RELEASE-NOTES.txt
Author: tn Date: Fri Nov 27 08:05:19 2015 New Revision: 11334 Log: Move old release notes. Added: release/commons/collections/RELEASE-NOTES-4.0.txt - copied unchanged from r11333, release/commons/collections/RELEASE-NOTES.txt Removed: release/commons/collections/RELEASE-NOTES.txt
svn commit: r11335 - in /release/commons/collections: ./ binaries/ source/
Author: tn Date: Fri Nov 27 08:06:06 2015 New Revision: 11335 Log: Remove old 3.2.1 release. Removed: release/commons/collections/RELEASE-NOTES-3.2.1.html release/commons/collections/binaries/commons-collections-3.2.1-bin.tar.gz release/commons/collections/binaries/commons-collections-3.2.1-bin.tar.gz.asc release/commons/collections/binaries/commons-collections-3.2.1-bin.tar.gz.md5 release/commons/collections/binaries/commons-collections-3.2.1-bin.zip release/commons/collections/binaries/commons-collections-3.2.1-bin.zip.asc release/commons/collections/binaries/commons-collections-3.2.1-bin.zip.md5 release/commons/collections/source/commons-collections-3.2.1-src.tar.gz release/commons/collections/source/commons-collections-3.2.1-src.tar.gz.asc release/commons/collections/source/commons-collections-3.2.1-src.tar.gz.md5 release/commons/collections/source/commons-collections-3.2.1-src.zip release/commons/collections/source/commons-collections-3.2.1-src.zip.asc release/commons/collections/source/commons-collections-3.2.1-src.zip.md5
svn commit: r11337 - /release/commons/collections/README.html
Author: tn Date: Fri Nov 27 08:13:56 2015 New Revision: 11337 Log: Update readme with latest release. Modified: release/commons/collections/README.html Modified: release/commons/collections/README.html == --- release/commons/collections/README.html (original) +++ release/commons/collections/README.html Fri Nov 27 08:13:56 2015 @@ -1,7 +1,7 @@ -Commons-Collections v4.0 +Commons-Collections v4.1 -This is the 4.0 release of commons-collections. +This is the 4.1 release of commons-collections. It is available in both binary and source distributions. @@ -40,13 +40,13 @@ HREF="http://www.apache.org/dist/commons Always test available signatures, e.g., $ pgpk -a KEYS -$ pgpv commons-collections4-4.0-bin.tar.gz.asc +$ pgpv commons-collections4-4.1-bin.tar.gz.asc or, $ pgp -ka KEYS -$ pgp commons-collections4-4.0-bin.tar.gz.asc +$ pgp commons-collections4-4.1-bin.tar.gz.asc or, $ gpg --import KEYS -$ gpg --verify commons-collections4-4.0-bin.tar.gz.asc +$ gpg --verify commons-collections4-4.1-bin.tar.gz.asc
svn commit: r11336 - /dev/commons/collections/ /dev/commons/collections/binaries/ /dev/commons/collections/source/ /release/commons/collections/ /release/commons/collections/binaries/ /release/commons
Author: tn Date: Fri Nov 27 08:12:22 2015 New Revision: 11336 Log: Publish commons-collections 4.1 Release Added: release/commons/collections/RELEASE-NOTES.txt - copied unchanged from r11335, dev/commons/collections/RELEASE-NOTES.txt release/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz - copied unchanged from r11335, dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz release/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc - copied unchanged from r11335, dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc release/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5 - copied unchanged from r11335, dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5 release/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.sha1 - copied unchanged from r11335, dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.sha1 release/commons/collections/binaries/commons-collections4-4.1-bin.zip - copied unchanged from r11335, dev/commons/collections/binaries/commons-collections4-4.1-bin.zip release/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc - copied unchanged from r11335, dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc release/commons/collections/binaries/commons-collections4-4.1-bin.zip.md5 - copied unchanged from r11335, dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.md5 release/commons/collections/binaries/commons-collections4-4.1-bin.zip.sha1 - copied unchanged from r11335, dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.sha1 release/commons/collections/source/commons-collections4-4.1-src.tar.gz - copied unchanged from r11335, dev/commons/collections/source/commons-collections4-4.1-src.tar.gz release/commons/collections/source/commons-collections4-4.1-src.tar.gz.asc - copied unchanged from r11335, dev/commons/collections/source/commons-collections4-4.1-src.tar.gz.asc release/commons/collections/source/commons-collections4-4.1-src.tar.gz.md5 - copied unchanged from r11335, dev/commons/collections/source/commons-collections4-4.1-src.tar.gz.md5 release/commons/collections/source/commons-collections4-4.1-src.tar.gz.sha1 - copied unchanged from r11335, dev/commons/collections/source/commons-collections4-4.1-src.tar.gz.sha1 release/commons/collections/source/commons-collections4-4.1-src.zip - copied unchanged from r11335, dev/commons/collections/source/commons-collections4-4.1-src.zip release/commons/collections/source/commons-collections4-4.1-src.zip.asc - copied unchanged from r11335, dev/commons/collections/source/commons-collections4-4.1-src.zip.asc release/commons/collections/source/commons-collections4-4.1-src.zip.md5 - copied unchanged from r11335, dev/commons/collections/source/commons-collections4-4.1-src.zip.md5 release/commons/collections/source/commons-collections4-4.1-src.zip.sha1 - copied unchanged from r11335, dev/commons/collections/source/commons-collections4-4.1-src.zip.sha1 Removed: dev/commons/collections/RELEASE-NOTES.txt dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5 dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.sha1 dev/commons/collections/binaries/commons-collections4-4.1-bin.zip dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.md5 dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.sha1 dev/commons/collections/source/commons-collections4-4.1-src.tar.gz dev/commons/collections/source/commons-collections4-4.1-src.tar.gz.asc dev/commons/collections/source/commons-collections4-4.1-src.tar.gz.md5 dev/commons/collections/source/commons-collections4-4.1-src.tar.gz.sha1 dev/commons/collections/source/commons-collections4-4.1-src.zip dev/commons/collections/source/commons-collections4-4.1-src.zip.asc dev/commons/collections/source/commons-collections4-4.1-src.zip.md5 dev/commons/collections/source/commons-collections4-4.1-src.zip.sha1
svn commit: r1716479 - /commons/proper/collections/trunk/README.md
Author: tn Date: Wed Nov 25 16:41:08 2015 New Revision: 1716479 URL: http://svn.apache.org/viewvc?rev=1716479=rev Log: Update coveralls badge. Modified: commons/proper/collections/trunk/README.md Modified: commons/proper/collections/trunk/README.md URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/README.md?rev=1716479=1716478=1716479=diff == --- commons/proper/collections/trunk/README.md (original) +++ commons/proper/collections/trunk/README.md Wed Nov 25 16:41:08 2015 @@ -44,7 +44,7 @@ Apache Commons Collections === [![Build Status](https://travis-ci.org/apache/commons-collections.svg?branch=master)](https://travis-ci.org/apache/commons-collections) -[![Coverage Status](https://coveralls.io/repos/apache/commons-collections/badge.svg?branch=master)](https://coveralls.io/r/apache/commons-collections) +[![Coverage Status](https://coveralls.io/repos/apache/commons-collections/badge.svg?branch=trunk=github)](https://coveralls.io/github/apache/commons-collections?branch=trunk) [![Maven Central](https://maven-badges.herokuapp.com/maven-central/org.apache.commons/commons-collections4/badge.svg)](https://maven-badges.herokuapp.com/maven-central/org.apache.commons/commons-collections4/) [![License](http://img.shields.io/:license-apache-blue.svg)](http://www.apache.org/licenses/LICENSE-2.0.html)
svn commit: r1716519 - /commons/proper/collections/trunk/README.md
Author: tn Date: Wed Nov 25 19:39:02 2015 New Revision: 1716519 URL: http://svn.apache.org/viewvc?rev=1716519=rev Log: Collections still uses subversion. Modified: commons/proper/collections/trunk/README.md Modified: commons/proper/collections/trunk/README.md URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/README.md?rev=1716519=1716518=1716519=diff == --- commons/proper/collections/trunk/README.md (original) +++ commons/proper/collections/trunk/README.md Wed Nov 25 19:39:02 2015 @@ -43,7 +43,7 @@ Apache Commons Collections === -[![Build Status](https://travis-ci.org/apache/commons-collections.svg?branch=master)](https://travis-ci.org/apache/commons-collections) +[![Build Status](https://travis-ci.org/apache/commons-collections.svg?branch=trunk)](https://travis-ci.org/apache/commons-collections) [![Coverage Status](https://coveralls.io/repos/apache/commons-collections/badge.svg?branch=trunk=github)](https://coveralls.io/github/apache/commons-collections?branch=trunk) [![Maven Central](https://maven-badges.herokuapp.com/maven-central/org.apache.commons/commons-collections4/badge.svg)](https://maven-badges.herokuapp.com/maven-central/org.apache.commons/commons-collections4/) [![License](http://img.shields.io/:license-apache-blue.svg)](http://www.apache.org/licenses/LICENSE-2.0.html)
svn commit: r1716533 - /commons/proper/collections/trunk/pom.xml
Author: tn Date: Wed Nov 25 20:24:26 2015 New Revision: 1716533 URL: http://svn.apache.org/viewvc?rev=1716533=rev Log: The buildnumber plugin seems to mess with the coveralls plugin. Disable it when run on travis. Modified: commons/proper/collections/trunk/pom.xml Modified: commons/proper/collections/trunk/pom.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/pom.xml?rev=1716533=1716532=1716533=diff == --- commons/proper/collections/trunk/pom.xml (original) +++ commons/proper/collections/trunk/pom.xml Wed Nov 25 20:24:26 2015 @@ -699,6 +699,9 @@ true + +true +
svn commit: r1716547 - /commons/proper/collections/tags/COLLECTIONS_4_1_RC2/
Author: tn Date: Wed Nov 25 21:24:53 2015 New Revision: 1716547 URL: http://svn.apache.org/viewvc?rev=1716547=rev Log: drop Collections 4.1 RC2 tag: before vote was called and detected a small glitch, rebuilding. Removed: commons/proper/collections/tags/COLLECTIONS_4_1_RC2/
svn commit: r11307 - in /dev/commons/collections: binaries/ source/
Author: tn Date: Wed Nov 25 22:03:47 2015 New Revision: 11307 Log: Creating distribution files for Collections 4.1 RC2 Modified: dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5 dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.sha1 dev/commons/collections/binaries/commons-collections4-4.1-bin.zip dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.md5 dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.sha1 dev/commons/collections/source/commons-collections4-4.1-src.tar.gz dev/commons/collections/source/commons-collections4-4.1-src.tar.gz.asc dev/commons/collections/source/commons-collections4-4.1-src.tar.gz.md5 dev/commons/collections/source/commons-collections4-4.1-src.tar.gz.sha1 dev/commons/collections/source/commons-collections4-4.1-src.zip dev/commons/collections/source/commons-collections4-4.1-src.zip.asc dev/commons/collections/source/commons-collections4-4.1-src.zip.md5 dev/commons/collections/source/commons-collections4-4.1-src.zip.sha1 Modified: dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz == Binary files - no diff available. Modified: dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc == --- dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc (original) +++ dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc Wed Nov 25 22:03:47 2015 @@ -1,17 +1,17 @@ -BEGIN PGP SIGNATURE- Version: GnuPG v1 -iQIcBAABAgAGBQJWVh3GAAoJEKQfE8mZlFKTdOEQAMLHCMktUr00WgXwnBy3UF1v -meJA5i8ZmDTT3aXA+I4F+Llqhnl0f6uiW/DCxUz131d0qY9gEfs5aJeUTdQ61fSI -hozWD0/ypTNbXvAi5OpXdOyOPyl99mwi+e0jT5FdRPpmFCEMkcyr+Vh5mtEBiQww -RVAVx8/bgL4XwJn3sHGKMOc509HnJ58zKeN5cvPxugBEMzqK1shvFfhQqt4Ww15Y -1OEUe7bioWlEwYKyHpX0mNrrsLH62xocVEwrywN75l0JymKobcbw3R6TPyEExqBq -rMhqxikvq/xAOeBchghrBs+ZsRLTSVLWXyOn6aoW4J5XUIkoOSaEEPYY2s7N296y -VAC5v8nwHLjiUMYk7kR+ohuh2G2lQgewNDUIwo36SoEduJbuzJHEpeEl36DIaKWE -r/fvR2aT1KE1piySJhFiQjjEr+NlUQZBj/yIdRkO8q7A1fWv5UwZ+6G9tTk6xOBX -bTN7qchVVSgvx93GJDLlwcwhHWtw0me/EbNYyYUu/P2NicAA/FovkvMIENAXFnch -eXFzPHhp6EufP3eM0c9AnfsqV5OfMVqJ/IbX5LzCwG2hn+mvnV4GO3U4m6rtfSYk -OLg/BOuSi1kKr4qT9/IYQnj5SVreGK6KS/S9RmLWDYru4arxy9yUAtDEwytqIOxX -kDhVkjgEGUddlYzfEIG6 -=ce8C +iQIcBAABAgAGBQJWVi4vAAoJEKQfE8mZlFKTz78QAKacDT7OWAU0qqkGEve2vzgE +97dPI8AcOHS+GfWGseaf1KBJZkhimcVxZTkKIdWq84Mlw7X7vldE0N9+mUUqqgG1 +3oukG03IXRp4e0KLoTU/98/Ix5Jpi85Bx2FI062yl7qInswwgY0z3XNYDoAuvqP2 +LMkqomFrmW/olitYaL7s1KjzXMxYLpg1gD+7QtgOCLN7vk5PbsC1LNz/s4/9UJGM +YfCCVVNm8+t4Ha2QhHbe3RyppJgFStWQVWXfMV89Q3Hm6v4GSXxnOfoSNJsYEUQu +UzWDn4pO4v+DiYRp0jrs3tU+2lhtOeaDcD+MgYvPLBG9BUX1U2IOI2NyQR4u1+qw +EAxyEwlCfzYYsuhIP0i0V9YPvn7kBWvh/umO9VRCI/oP6Ql1RcBLnushQLjMXCWI +AICBhR4DQ2yU4pBNNqPD4xMxBgufJ/R6aYu/+KH5cYXuoExiGH7qUyk8uhgv6FHD +5MuF+ZlXoUeBa/QFHgSApIv+KxUO5HoQ6QJDDluDuazOK3A86nLujSUJCBMarX1h +PevnJxGe1795NQFZ+AFLnTrZVZ4hnz6ta3IjORmwCTAo9VEyJF6k4+EgmpTEJdbz +54X8R7ZkdNvCdUsL4QvMKTjBPJbSLMnXY1vdXqffw2rv1lgBKfdoAm0FLZPTi38g +18dtd/W9KohXJN1A5KNu +=UOQN -END PGP SIGNATURE- Modified: dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5 == --- dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5 (original) +++ dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5 Wed Nov 25 22:03:47 2015 @@ -1 +1 @@ -a7a41da9b0c9cc9b290abf7286c41896 \ No newline at end of file +907da49beeb57f91f97a99feb1b563ef \ No newline at end of file Modified: dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.sha1 == --- dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.sha1 (original) +++ dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.sha1 Wed Nov 25 22:03:47 2015 @@ -1 +1 @@ -6add8c3716ffb1c9d213eb75528e9129bc85ca6f \ No newline at end of file +44b42164aa99e6627872923bca3e32d7a092eaf1 \ No newline at end of file Modified: dev/commons/collections/binaries/commons-collections4-4.1-bin.zip == Binary files - no diff available. Modified: dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc == --- dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc (original) +++ dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc Wed Nov 25 22
svn commit: r1716550 - in /commons/proper/collections/tags/COLLECTIONS_4_1_RC2: ./ default.properties pom.xml src/site/xdoc/download_collections.xml src/site/xdoc/index.xml
Author: tn Date: Wed Nov 25 21:52:13 2015 New Revision: 1716550 URL: http://svn.apache.org/viewvc?rev=1716550=rev Log: Creating Commons Collections v4.1 RC2 tag, take 2. Added: commons/proper/collections/tags/COLLECTIONS_4_1_RC2/ - copied from r1716547, commons/proper/collections/trunk/ commons/proper/collections/tags/COLLECTIONS_4_1_RC2/pom.xml - copied, changed from r1716549, commons/proper/collections/trunk/pom.xml Modified: commons/proper/collections/tags/COLLECTIONS_4_1_RC2/default.properties commons/proper/collections/tags/COLLECTIONS_4_1_RC2/src/site/xdoc/download_collections.xml commons/proper/collections/tags/COLLECTIONS_4_1_RC2/src/site/xdoc/index.xml Modified: commons/proper/collections/tags/COLLECTIONS_4_1_RC2/default.properties URL: http://svn.apache.org/viewvc/commons/proper/collections/tags/COLLECTIONS_4_1_RC2/default.properties?rev=1716550=1716547=1716550=diff == --- commons/proper/collections/tags/COLLECTIONS_4_1_RC2/default.properties (original) +++ commons/proper/collections/tags/COLLECTIONS_4_1_RC2/default.properties Wed Nov 25 21:52:13 2015 @@ -39,7 +39,7 @@ component.package = org.apache.commons.c component.title = Commons Collections # The current version number of this component -component.version = 4.1-SNAPSHOT +component.version = 4.1 # The name that is used to create the jar file final.name = ${component.name}-${component.version} Copied: commons/proper/collections/tags/COLLECTIONS_4_1_RC2/pom.xml (from r1716549, commons/proper/collections/trunk/pom.xml) URL: http://svn.apache.org/viewvc/commons/proper/collections/tags/COLLECTIONS_4_1_RC2/pom.xml?p2=commons/proper/collections/tags/COLLECTIONS_4_1_RC2/pom.xml=commons/proper/collections/trunk/pom.xml=1716549=1716550=1716550=diff == --- commons/proper/collections/trunk/pom.xml (original) +++ commons/proper/collections/tags/COLLECTIONS_4_1_RC2/pom.xml Wed Nov 25 21:52:13 2015 @@ -24,7 +24,7 @@ 4.0.0 org.apache.commons commons-collections4 - 4.1-SNAPSHOT + 4.1 Apache Commons Collections 2001 @@ -479,8 +479,8 @@ collections4 -4.0 -(Java 5.0+) +4.1 +(Java 6.0+) 3.2.2 @@ -491,7 +491,7 @@ COLLECTIONS 12310465 -RC1 +RC2 2.9.1 collections @@ -639,6 +639,7 @@ site-content/**/* src/test/resources/data/test/* maven-eclipse.xml +.travis.yml Modified: commons/proper/collections/tags/COLLECTIONS_4_1_RC2/src/site/xdoc/download_collections.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/tags/COLLECTIONS_4_1_RC2/src/site/xdoc/download_collections.xml?rev=1716550=1716547=1716550=diff == --- commons/proper/collections/tags/COLLECTIONS_4_1_RC2/src/site/xdoc/download_collections.xml (original) +++ commons/proper/collections/tags/COLLECTIONS_4_1_RC2/src/site/xdoc/download_collections.xml Wed Nov 25 21:52:13 2015 @@ -95,32 +95,32 @@ limitations under the License. - + - commons-collections4-4.0-bin.tar.gz - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.tar.gz.md5;>md5 - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.tar.gz.asc;>pgp + commons-collections4-4.1-bin.tar.gz + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5;>md5 + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc;>pgp - commons-collections4-4.0-bin.zip - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.zip.md5;>md5 - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.zip.asc;>pgp + commons-collections4-4.1-bin.zip + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.zip.md5;>md5 + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc;>pgp - commons-collections4-4.0-src.tar.gz - http://www.apache.org/dist/commons/collections/source/commons-collections4-4.0-src.tar.gz.md5;>md5 - http://www.apache.org/dist/commons/collections/source/commons-collections4-4.0-src.tar.gz.asc;>pgp + commons-collections4-4.1-src.tar.gz + http://www.apache.org/dist/commons/collections/source/commons-collections4-4.1-src.tar.gz.md5;>md5 + h
svn commit: r1716540 - in /commons/proper/collections/tags/COLLECTIONS_4_1_RC2: ./ default.properties pom.xml src/site/xdoc/download_collections.xml src/site/xdoc/index.xml
Author: tn Date: Wed Nov 25 20:42:26 2015 New Revision: 1716540 URL: http://svn.apache.org/viewvc?rev=1716540=rev Log: Creating Commons Collections v4.1 RC2 tag. Added: commons/proper/collections/tags/COLLECTIONS_4_1_RC2/ - copied from r1716538, commons/proper/collections/trunk/ Modified: commons/proper/collections/tags/COLLECTIONS_4_1_RC2/default.properties commons/proper/collections/tags/COLLECTIONS_4_1_RC2/pom.xml commons/proper/collections/tags/COLLECTIONS_4_1_RC2/src/site/xdoc/download_collections.xml commons/proper/collections/tags/COLLECTIONS_4_1_RC2/src/site/xdoc/index.xml Modified: commons/proper/collections/tags/COLLECTIONS_4_1_RC2/default.properties URL: http://svn.apache.org/viewvc/commons/proper/collections/tags/COLLECTIONS_4_1_RC2/default.properties?rev=1716540=1716538=1716540=diff == --- commons/proper/collections/tags/COLLECTIONS_4_1_RC2/default.properties (original) +++ commons/proper/collections/tags/COLLECTIONS_4_1_RC2/default.properties Wed Nov 25 20:42:26 2015 @@ -39,7 +39,7 @@ component.package = org.apache.commons.c component.title = Commons Collections # The current version number of this component -component.version = 4.1-SNAPSHOT +component.version = 4.1 # The name that is used to create the jar file final.name = ${component.name}-${component.version} Modified: commons/proper/collections/tags/COLLECTIONS_4_1_RC2/pom.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/tags/COLLECTIONS_4_1_RC2/pom.xml?rev=1716540=1716538=1716540=diff == --- commons/proper/collections/tags/COLLECTIONS_4_1_RC2/pom.xml (original) +++ commons/proper/collections/tags/COLLECTIONS_4_1_RC2/pom.xml Wed Nov 25 20:42:26 2015 @@ -24,7 +24,7 @@ 4.0.0 org.apache.commons commons-collections4 - 4.1-SNAPSHOT + 4.1 Apache Commons Collections 2001 @@ -479,8 +479,8 @@ collections4 -4.0 -(Java 5.0+) +4.1 +(Java 6.0+) 3.2.2 @@ -491,7 +491,7 @@ COLLECTIONS 12310465 -RC1 +RC2 2.9.1 collections Modified: commons/proper/collections/tags/COLLECTIONS_4_1_RC2/src/site/xdoc/download_collections.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/tags/COLLECTIONS_4_1_RC2/src/site/xdoc/download_collections.xml?rev=1716540=1716538=1716540=diff == --- commons/proper/collections/tags/COLLECTIONS_4_1_RC2/src/site/xdoc/download_collections.xml (original) +++ commons/proper/collections/tags/COLLECTIONS_4_1_RC2/src/site/xdoc/download_collections.xml Wed Nov 25 20:42:26 2015 @@ -95,32 +95,32 @@ limitations under the License. - + - commons-collections4-4.0-bin.tar.gz - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.tar.gz.md5;>md5 - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.tar.gz.asc;>pgp + commons-collections4-4.1-bin.tar.gz + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5;>md5 + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc;>pgp - commons-collections4-4.0-bin.zip - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.zip.md5;>md5 - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.zip.asc;>pgp + commons-collections4-4.1-bin.zip + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.zip.md5;>md5 + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc;>pgp - commons-collections4-4.0-src.tar.gz - http://www.apache.org/dist/commons/collections/source/commons-collections4-4.0-src.tar.gz.md5;>md5 - http://www.apache.org/dist/commons/collections/source/commons-collections4-4.0-src.tar.gz.asc;>pgp + commons-collections4-4.1-src.tar.gz + http://www.apache.org/dist/commons/collections/source/commons-collections4-4.1-src.tar.gz.md5;>md5 + http://www.apache.org/dist/commons/collections/source/commons-collections4-4.1-src.tar.gz.asc;>pgp - commons-collections4-4.0-src.zip - http://www.apache.org/dist/commons/collections/source/commons-collections4-4.0-src.zip.md5;>md5 - http://www.apache.org/dist/commons/collections/source/commons-collections4-4.0-src.zip.asc;>pgp +
svn commit: r1716549 - /commons/proper/collections/trunk/pom.xml
Author: tn Date: Wed Nov 25 21:42:06 2015 New Revision: 1716549 URL: http://svn.apache.org/viewvc?rev=1716549=rev Log: Revert travis env property. Modified: commons/proper/collections/trunk/pom.xml Modified: commons/proper/collections/trunk/pom.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/pom.xml?rev=1716549=1716548=1716549=diff == --- commons/proper/collections/trunk/pom.xml (original) +++ commons/proper/collections/trunk/pom.xml Wed Nov 25 21:42:06 2015 @@ -695,7 +695,7 @@ travis - TRAVIS + env.TRAVIS true
svn commit: r1716537 - /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java
Author: tn Date: Wed Nov 25 20:27:24 2015 New Revision: 1716537 URL: http://svn.apache.org/viewvc?rev=1716537=rev Log: Remove wrong statement in interface Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java?rev=1716537=1716536=1716537=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java Wed Nov 25 20:27:24 2015 @@ -299,8 +299,7 @@ public interface MultiValuedMap<K, V> { * Changes to the returned map or the collections that serve as its values * will update the underlying multi-valued map, and vice versa. The map does * not support {@code put} or {@code putAll}, nor do its entries support - * {@link Map.Entry#setValue setValue} and iterators support - * {@link java.util.Iterator#remove remove}. + * {@link Map.Entry#setValue setValue}. * * @return a map view of the mappings in this multi-valued map */
svn commit: r1716538 - /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/IterableUtils.java
Author: tn Date: Wed Nov 25 20:27:49 2015 New Revision: 1716538 URL: http://svn.apache.org/viewvc?rev=1716538=rev Log: Fix javadoc for IterableUtils: remove() is normally supported. Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/IterableUtils.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/IterableUtils.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/IterableUtils.java?rev=1716538=1716537=1716538=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/IterableUtils.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/IterableUtils.java Wed Nov 25 20:27:49 2015 @@ -217,8 +217,8 @@ public class IterableUtils { * provided comparator. If the comparator is null, natural ordering will be * used. * - * The returned iterable's iterator supports {@code remove()} when the corresponding - * input iterator supports it. + * The returned iterable's iterator supports {@code remove()} when the + * corresponding input iterator supports it. * * @param the element type * @param comparator the comparator defining an ordering over the elements, @@ -247,7 +247,8 @@ public class IterableUtils { * Returns a view of the given iterable that only contains elements matching * the provided predicate. * - * The returned iterable's iterator does not support {@code remove()}. + * The returned iterable's iterator supports {@code remove()} when the + * corresponding input iterator supports it. * * @param the element type * @param iterable the iterable to filter, may not be null @@ -436,7 +437,9 @@ public class IterableUtils { /** * Returns a unique view of the given iterable. * - * The returned iterable's iterator does not support {@code remove()}. + * The returned iterable's iterator supports {@code remove()} when the + * corresponding input iterator supports it. Calling {@code remove()} + * will only remove a single element from the underlying iterator. * * @param the element type * @param iterable the iterable to use, may not be null
svn commit: r11305 - in /dev/commons/collections: binaries/ source/
Author: tn Date: Wed Nov 25 20:55:43 2015 New Revision: 11305 Log: Creating distribution files for Collections 4.1 RC2 Modified: dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5 dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.sha1 dev/commons/collections/binaries/commons-collections4-4.1-bin.zip dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.md5 dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.sha1 dev/commons/collections/source/commons-collections4-4.1-src.tar.gz dev/commons/collections/source/commons-collections4-4.1-src.tar.gz.asc dev/commons/collections/source/commons-collections4-4.1-src.tar.gz.md5 dev/commons/collections/source/commons-collections4-4.1-src.tar.gz.sha1 dev/commons/collections/source/commons-collections4-4.1-src.zip dev/commons/collections/source/commons-collections4-4.1-src.zip.asc dev/commons/collections/source/commons-collections4-4.1-src.zip.md5 dev/commons/collections/source/commons-collections4-4.1-src.zip.sha1 Modified: dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz == Binary files - no diff available. Modified: dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc == --- dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc (original) +++ dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc Wed Nov 25 20:55:43 2015 @@ -1,17 +1,17 @@ -BEGIN PGP SIGNATURE- Version: GnuPG v1 -iQIcBAABAgAGBQJWUjZbAAoJEKQfE8mZlFKTcBIQAIuFIgJkqypV7vLC5K8pDc+1 -AUiDujOM7CfiBPBsJbNJqIIlN8J8VlyZaIWmUWjUxpeMiYzCD+eTIjvr9dBNV/Ph -hWkQeHhUO6ySthqHvBEhk4KG89ib8wBQh5n1qlD20BFcdfbwgsV8rwgo4kkOKvTU -3xKacU8y82DEiZUbxQsG/A43vk9dshwBodxpMDmOB+/xA7b8l2nWbzqdswhv5PBu -kD1nLkhYLqnDuEO1xwn0ghMh06Ud+YAq9nB2ODyKhi2LCKZ2kWmgCXskxSrTnNtx -oSD37Hqkk2s5wjJ1zISwlU573lf7fgM7Sv6VYQGZwGKuC3FmucHc7cVVtGKusKn5 -bt4YLZP/izbQpHtieAKDlTTB+t4JJBjNnovdKKEc6wwYBEEat8Qt362OQVYMhJ1b -MUdW7HvtxdMG04HUQkNPughp0ie97RWRkexYoBDFQrRWgeLuG//MU7gRSG/o6+LY -aZtoiai4MZchrE4QDHNiLeQj0iOsikLjMviEq52QSGPgVmJD9HLG0bDQTG7KGwYk -l1PQXqdm5sBWIVAZ/eOcRY3YUAQkf88Lg17rr9UPpTehb8Y3PsCy81o7h41Agp8i -s3MoHH3cfkTnQ1b1IneHd2wHeSt0z+q/R3KPmoaRVzFWzJGYXTHl/Jica4oVC90/ -V1bRhBn23fZE7meaYBoL -=Ecsk +iQIcBAABAgAGBQJWVh3GAAoJEKQfE8mZlFKTdOEQAMLHCMktUr00WgXwnBy3UF1v +meJA5i8ZmDTT3aXA+I4F+Llqhnl0f6uiW/DCxUz131d0qY9gEfs5aJeUTdQ61fSI +hozWD0/ypTNbXvAi5OpXdOyOPyl99mwi+e0jT5FdRPpmFCEMkcyr+Vh5mtEBiQww +RVAVx8/bgL4XwJn3sHGKMOc509HnJ58zKeN5cvPxugBEMzqK1shvFfhQqt4Ww15Y +1OEUe7bioWlEwYKyHpX0mNrrsLH62xocVEwrywN75l0JymKobcbw3R6TPyEExqBq +rMhqxikvq/xAOeBchghrBs+ZsRLTSVLWXyOn6aoW4J5XUIkoOSaEEPYY2s7N296y +VAC5v8nwHLjiUMYk7kR+ohuh2G2lQgewNDUIwo36SoEduJbuzJHEpeEl36DIaKWE +r/fvR2aT1KE1piySJhFiQjjEr+NlUQZBj/yIdRkO8q7A1fWv5UwZ+6G9tTk6xOBX +bTN7qchVVSgvx93GJDLlwcwhHWtw0me/EbNYyYUu/P2NicAA/FovkvMIENAXFnch +eXFzPHhp6EufP3eM0c9AnfsqV5OfMVqJ/IbX5LzCwG2hn+mvnV4GO3U4m6rtfSYk +OLg/BOuSi1kKr4qT9/IYQnj5SVreGK6KS/S9RmLWDYru4arxy9yUAtDEwytqIOxX +kDhVkjgEGUddlYzfEIG6 +=ce8C -END PGP SIGNATURE- Modified: dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5 == --- dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5 (original) +++ dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5 Wed Nov 25 20:55:43 2015 @@ -1 +1 @@ -caf674ba9ea43c1a1d9bef0d98508c84 \ No newline at end of file +a7a41da9b0c9cc9b290abf7286c41896 \ No newline at end of file Modified: dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.sha1 == --- dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.sha1 (original) +++ dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.sha1 Wed Nov 25 20:55:43 2015 @@ -1 +1 @@ -3e0ea8c26e264b539f237ae35db4346cbec9b2bc \ No newline at end of file +6add8c3716ffb1c9d213eb75528e9129bc85ca6f \ No newline at end of file Modified: dev/commons/collections/binaries/commons-collections4-4.1-bin.zip == Binary files - no diff available. Modified: dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc == --- dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc (original) +++ dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc Wed Nov 25 20
svn commit: r1716529 - /commons/proper/collections/trunk/pom.xml
Author: tn Date: Wed Nov 25 20:11:16 2015 New Revision: 1716529 URL: http://svn.apache.org/viewvc?rev=1716529=rev Log: try different property to activate coveralls. Modified: commons/proper/collections/trunk/pom.xml Modified: commons/proper/collections/trunk/pom.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/pom.xml?rev=1716529=1716528=1716529=diff == --- commons/proper/collections/trunk/pom.xml (original) +++ commons/proper/collections/trunk/pom.xml Wed Nov 25 20:11:16 2015 @@ -695,7 +695,7 @@ travis - env.TRAVIS + TRAVIS true
svn commit: r1716081 - /commons/proper/collections/trunk/.travis.yml
Author: tn Date: Tue Nov 24 09:09:56 2015 New Revision: 1716081 URL: http://svn.apache.org/viewvc?rev=1716081=rev Log: Add travis configuration. Added: commons/proper/collections/trunk/.travis.yml Added: commons/proper/collections/trunk/.travis.yml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/.travis.yml?rev=1716081=auto == --- commons/proper/collections/trunk/.travis.yml (added) +++ commons/proper/collections/trunk/.travis.yml Tue Nov 24 09:09:56 2015 @@ -0,0 +1,7 @@ +language: java +sudo: false + +jdk: + - openjdk6 + - openjdk7 + - oraclejdk8
svn commit: r1716090 - in /commons/proper/collections/trunk: .travis.yml README.md pom.xml
Author: tn Date: Tue Nov 24 09:25:40 2015 New Revision: 1716090 URL: http://svn.apache.org/viewvc?rev=1716090=rev Log: Add travis configuration for jacoco and coveralls. Add badges to Readme.md. Modified: commons/proper/collections/trunk/.travis.yml commons/proper/collections/trunk/README.md commons/proper/collections/trunk/pom.xml Modified: commons/proper/collections/trunk/.travis.yml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/.travis.yml?rev=1716090=1716089=1716090=diff == --- commons/proper/collections/trunk/.travis.yml (original) +++ commons/proper/collections/trunk/.travis.yml Tue Nov 24 09:25:40 2015 @@ -5,3 +5,6 @@ jdk: - openjdk6 - openjdk7 - oraclejdk8 + +after_success: + - mvn clean test jacoco:report coveralls:report Modified: commons/proper/collections/trunk/README.md URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/README.md?rev=1716090=1716089=1716090=diff == --- commons/proper/collections/trunk/README.md (original) +++ commons/proper/collections/trunk/README.md Tue Nov 24 09:25:40 2015 @@ -43,6 +43,11 @@ Apache Commons Collections === +[![Build Status](https://travis-ci.org/apache/commons-collections.svg?branch=master)](https://travis-ci.org/apache/commons-collections) +[![Coverage Status](https://coveralls.io/repos/apache/commons-collections/badge.svg?branch=master)](https://coveralls.io/r/apache/commons-collections) +[![Maven Central](https://maven-badges.herokuapp.com/maven-central/org.apache.commons/commons-collections4/badge.svg)](https://maven-badges.herokuapp.com/maven-central/org.apache.commons/commons-collections4/) +[![License](http://img.shields.io/:license-apache-blue.svg)](http://www.apache.org/licenses/LICENSE-2.0.html) + The Apache Commons Collections package contains types that extend and augment the Java Collections Framework. Documentation Modified: commons/proper/collections/trunk/pom.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/pom.xml?rev=1716090=1716089=1716090=diff == --- commons/proper/collections/trunk/pom.xml (original) +++ commons/proper/collections/trunk/pom.xml Tue Nov 24 09:25:40 2015 @@ -690,6 +690,38 @@ + + + travis + + + env.TRAVIS + true + + + + + +org.jacoco +jacoco-maven-plugin +${commons.jacoco.version} + + +prepare-agent + + prepare-agent + + + + + +org.eluder.coveralls +coveralls-maven-plugin +3.1.0 + + + +
[math] [MATH-1294] Fix potential race condition in PolynomialUtils. Thanks to Kamil WÅ‚odarczyk
Repository: commons-math Updated Branches: refs/heads/MATH_3_X 978f89c75 -> fe23c9b04 [MATH-1294] Fix potential race condition in PolynomialUtils. Thanks to Kamil Włodarczyk Project: http://git-wip-us.apache.org/repos/asf/commons-math/repo Commit: http://git-wip-us.apache.org/repos/asf/commons-math/commit/fe23c9b0 Tree: http://git-wip-us.apache.org/repos/asf/commons-math/tree/fe23c9b0 Diff: http://git-wip-us.apache.org/repos/asf/commons-math/diff/fe23c9b0 Branch: refs/heads/MATH_3_X Commit: fe23c9b04aff89b3c6da20b4769157b8c577d071 Parents: 978f89c Author: Thomas NeidhartAuthored: Mon Nov 23 23:16:58 2015 +0100 Committer: Thomas Neidhart Committed: Mon Nov 23 23:16:58 2015 +0100 -- src/changes/changes.xml | 5 + .../math3/analysis/polynomials/PolynomialsUtils.java | 10 +++--- 2 files changed, 12 insertions(+), 3 deletions(-) -- http://git-wip-us.apache.org/repos/asf/commons-math/blob/fe23c9b0/src/changes/changes.xml -- diff --git a/src/changes/changes.xml b/src/changes/changes.xml index 7dfacc5..3448c23 100644 --- a/src/changes/changes.xml +++ b/src/changes/changes.xml @@ -51,6 +51,11 @@ If the output is not quite correct, check for invisible trailing spaces! + +Fixed potential race condition in PolynomialUtils#buildPolynomial in +case polynomials are generated from multiple threads. Furthermore, the +synchronization is now performed on the coefficient list instead of the class. + Added bootstrap method to KolmogorovSmirnov test. http://git-wip-us.apache.org/repos/asf/commons-math/blob/fe23c9b0/src/main/java/org/apache/commons/math3/analysis/polynomials/PolynomialsUtils.java -- diff --git a/src/main/java/org/apache/commons/math3/analysis/polynomials/PolynomialsUtils.java b/src/main/java/org/apache/commons/math3/analysis/polynomials/PolynomialsUtils.java index 5604149..2efa07d 100644 --- a/src/main/java/org/apache/commons/math3/analysis/polynomials/PolynomialsUtils.java +++ b/src/main/java/org/apache/commons/math3/analysis/polynomials/PolynomialsUtils.java @@ -107,6 +107,7 @@ public class PolynomialsUtils { /** Fixed recurrence coefficients. */ private final BigFraction[] coeffs = { BigFraction.ZERO, BigFraction.TWO, BigFraction.ONE }; /** {@inheritDoc} */ +@Override public BigFraction[] generate(int k) { return coeffs; } @@ -131,6 +132,7 @@ public class PolynomialsUtils { return buildPolynomial(degree, HERMITE_COEFFICIENTS, new RecurrenceCoefficientsGenerator() { /** {@inheritDoc} */ +@Override public BigFraction[] generate(int k) { return new BigFraction[] { BigFraction.ZERO, @@ -157,6 +159,7 @@ public class PolynomialsUtils { return buildPolynomial(degree, LAGUERRE_COEFFICIENTS, new RecurrenceCoefficientsGenerator() { /** {@inheritDoc} */ +@Override public BigFraction[] generate(int k) { final int kP1 = k + 1; return new BigFraction[] { @@ -184,6 +187,7 @@ public class PolynomialsUtils { return buildPolynomial(degree, LEGENDRE_COEFFICIENTS, new RecurrenceCoefficientsGenerator() { /** {@inheritDoc} */ +@Override public BigFraction[] generate(int k) { final int kP1 = k + 1; return new BigFraction[] { @@ -234,6 +238,7 @@ public class PolynomialsUtils { return buildPolynomial(degree, JACOBI_COEFFICIENTS.get(key), new RecurrenceCoefficientsGenerator() { /** {@inheritDoc} */ +@Override public BigFraction[] generate(int k) { k++; final int kvw = k + v + w; @@ -359,9 +364,8 @@ public class PolynomialsUtils { private static PolynomialFunction buildPolynomial(final int degree, final List coefficients, final RecurrenceCoefficientsGenerator generator) { - -final int maxDegree = (int) FastMath.floor(FastMath.sqrt(2 * coefficients.size())) - 1; -synchronized (PolynomialsUtils.class) { +synchronized (coefficients) { +final int maxDegree = (int) FastMath.floor(FastMath.sqrt(2 * coefficients.size())) - 1; if (degree > maxDegree) {
[math] [MATH-1294] Fix potential race condition in PolynomialUtils. Thanks to Kamil WÅ‚odarczyk
Repository: commons-math Updated Branches: refs/heads/master 03326f611 -> 487ac1980 [MATH-1294] Fix potential race condition in PolynomialUtils. Thanks to Kamil Włodarczyk Project: http://git-wip-us.apache.org/repos/asf/commons-math/repo Commit: http://git-wip-us.apache.org/repos/asf/commons-math/commit/487ac198 Tree: http://git-wip-us.apache.org/repos/asf/commons-math/tree/487ac198 Diff: http://git-wip-us.apache.org/repos/asf/commons-math/diff/487ac198 Branch: refs/heads/master Commit: 487ac1980148522d628e1d2aab50b107c372798b Parents: 03326f6 Author: Thomas NeidhartAuthored: Mon Nov 23 23:13:10 2015 +0100 Committer: Thomas Neidhart Committed: Mon Nov 23 23:13:10 2015 +0100 -- src/changes/changes.xml | 5 + .../commons/math4/analysis/polynomials/PolynomialsUtils.java| 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) -- http://git-wip-us.apache.org/repos/asf/commons-math/blob/487ac198/src/changes/changes.xml -- diff --git a/src/changes/changes.xml b/src/changes/changes.xml index 74341f0..fc75ddc 100644 --- a/src/changes/changes.xml +++ b/src/changes/changes.xml @@ -54,6 +54,11 @@ If the output is not quite correct, check for invisible trailing spaces! + +Fixed potential race condition in PolynomialUtils#buildPolynomial in +case polynomials are generated from multiple threads. Furthermore, the +synchronization is now performed on the coefficient list instead of the class. + Added bootstrap method to 2-sample KolmogorovSmirnovTest. http://git-wip-us.apache.org/repos/asf/commons-math/blob/487ac198/src/main/java/org/apache/commons/math4/analysis/polynomials/PolynomialsUtils.java -- diff --git a/src/main/java/org/apache/commons/math4/analysis/polynomials/PolynomialsUtils.java b/src/main/java/org/apache/commons/math4/analysis/polynomials/PolynomialsUtils.java index 8574b86..346644e 100644 --- a/src/main/java/org/apache/commons/math4/analysis/polynomials/PolynomialsUtils.java +++ b/src/main/java/org/apache/commons/math4/analysis/polynomials/PolynomialsUtils.java @@ -365,8 +365,8 @@ public class PolynomialsUtils { final List coefficients, final RecurrenceCoefficientsGenerator generator) { -final int maxDegree = (int) FastMath.floor(FastMath.sqrt(2 * coefficients.size())) - 1; -synchronized (PolynomialsUtils.class) { +synchronized (coefficients) { +final int maxDegree = (int) FastMath.floor(FastMath.sqrt(2 * coefficients.size())) - 1; if (degree > maxDegree) { computeUpToDegree(degree, maxDegree, generator, coefficients); }
svn commit: r1715956 - /commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/FluentIterableTest.java
Author: tn Date: Mon Nov 23 21:23:14 2015 New Revision: 1715956 URL: http://svn.apache.org/viewvc?rev=1715956=rev Log: Add explicit cast to prevent compilation error with jdk 1.8 Modified: commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/FluentIterableTest.java Modified: commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/FluentIterableTest.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/FluentIterableTest.java?rev=1715956=1715955=1715956=diff == --- commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/FluentIterableTest.java (original) +++ commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/FluentIterableTest.java Mon Nov 23 21:23:14 2015 @@ -239,7 +239,7 @@ public class FluentIterableTest { assertEquals(expectedSum, sum.get()); try { -FluentIterable.of(iterableA).forEach(null); +FluentIterable.of(iterableA).forEach((Closure) null); fail("expecting NullPointerException"); } catch (NullPointerException npe) { // expected
svn commit: r1715958 - in /commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap: ArrayListValuedHashMapTest.java HashSetValuedHashMapTest.java TransformedMultiValued
Author: tn Date: Mon Nov 23 21:23:57 2015 New Revision: 1715958 URL: http://svn.apache.org/viewvc?rev=1715958=rev Log: Comment out test that create the serialized test objects. Modified: commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMapTest.java commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/HashSetValuedHashMapTest.java commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/TransformedMultiValuedMapTest.java commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/UnmodifiableMultiValuedMapTest.java Modified: commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMapTest.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMapTest.java?rev=1715958=1715957=1715958=diff == --- commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMapTest.java (original) +++ commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMapTest.java Mon Nov 23 21:23:57 2015 @@ -146,11 +146,11 @@ public class ArrayListValuedHashMapTest< assertNotSame(map1.hashCode(), map2.hashCode()); } -public void testCreate() throws Exception { -writeExternalFormToDisk((java.io.Serializable) makeObject(), - "src/test/resources/data/test/ArrayListValuedHashMap.emptyCollection.version4.1.obj"); -writeExternalFormToDisk((java.io.Serializable) makeFullMap(), - "src/test/resources/data/test/ArrayListValuedHashMap.fullCollection.version4.1.obj"); -} +//public void testCreate() throws Exception { +//writeExternalFormToDisk((java.io.Serializable) makeObject(), +// "src/test/resources/data/test/ArrayListValuedHashMap.emptyCollection.version4.1.obj"); +//writeExternalFormToDisk((java.io.Serializable) makeFullMap(), +// "src/test/resources/data/test/ArrayListValuedHashMap.fullCollection.version4.1.obj"); +//} } Modified: commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/HashSetValuedHashMapTest.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/HashSetValuedHashMapTest.java?rev=1715958=1715957=1715958=diff == --- commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/HashSetValuedHashMapTest.java (original) +++ commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/HashSetValuedHashMapTest.java Mon Nov 23 21:23:57 2015 @@ -126,11 +126,11 @@ public class HashSetValuedHashMapTest<K, assertNotSame(map1.hashCode(), map2.hashCode()); } -public void testCreate() throws Exception { -writeExternalFormToDisk((java.io.Serializable) makeObject(), - "src/test/resources/data/test/HashSetValuedHashMap.emptyCollection.version4.1.obj"); -writeExternalFormToDisk((java.io.Serializable) makeFullMap(), - "src/test/resources/data/test/HashSetValuedHashMap.fullCollection.version4.1.obj"); -} +//public void testCreate() throws Exception { +//writeExternalFormToDisk((java.io.Serializable) makeObject(), +// "src/test/resources/data/test/HashSetValuedHashMap.emptyCollection.version4.1.obj"); +//writeExternalFormToDisk((java.io.Serializable) makeFullMap(), +// "src/test/resources/data/test/HashSetValuedHashMap.fullCollection.version4.1.obj"); +//} } Modified: commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/TransformedMultiValuedMapTest.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/TransformedMultiValuedMapTest.java?rev=1715958=1715957=1715958=diff == --- commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/TransformedMultiValuedMapTest.java (original) +++ commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/TransformedMultiValuedMapTest.java Mon Nov 23 21:23:57 2015 @@ -134,11 +134,11 @@ public class TransformedMultiValuedMapTe assertEquals(true, trans.get((K) "D").contains(Integer.valueOf(4))); } -public void testCreate() throws Exception { -writeExterna
svn commit: r1715973 - in /commons/proper/collections/trunk/src: main/java/org/apache/commons/collections4/ test/java/org/apache/commons/collections4/ test/java/org/apache/commons/collections4/map/
Author: tn Date: Mon Nov 23 21:42:01 2015 New Revision: 1715973 URL: http://svn.apache.org/viewvc?rev=1715973=rev Log: Make eclipse compiler happy. Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/IteratorUtils.java commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/CollectionUtilsTest.java commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/map/TransformedMapTest.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/IteratorUtils.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/IteratorUtils.java?rev=1715973=1715972=1715973=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/IteratorUtils.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/IteratorUtils.java Mon Nov 23 21:42:01 2015 @@ -573,7 +573,8 @@ public class IteratorUtils { final Iterator iterator1, final Iterator iterator2) { @SuppressWarnings("unchecked") -final Comparator comp = comparator == null ? ComparatorUtils.NATURAL_COMPARATOR : comparator; +final Comparator comp = +comparator == null ? ComparatorUtils.NATURAL_COMPARATOR : (Comparator) comparator; return new CollatingIterator(comp, iterator1, iterator2); } @@ -596,7 +597,8 @@ public class IteratorUtils { public static Iterator collatedIterator(final Comparator comparator, final Iterator... iterators) { @SuppressWarnings("unchecked") -final Comparator comp = comparator == null ? ComparatorUtils.NATURAL_COMPARATOR : comparator; +final Comparator comp = +comparator == null ? ComparatorUtils.NATURAL_COMPARATOR : (Comparator) comparator; return new CollatingIterator(comp, iterators); } @@ -620,7 +622,8 @@ public class IteratorUtils { public static Iterator collatedIterator(final Comparator comparator, final Collection<Iterator> iterators) { @SuppressWarnings("unchecked") -final Comparator comp = comparator == null ? ComparatorUtils.NATURAL_COMPARATOR : comparator; +final Comparator comp = +comparator == null ? ComparatorUtils.NATURAL_COMPARATOR : (Comparator) comparator; return new CollatingIterator(comp, iterators); } Modified: commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/CollectionUtilsTest.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/CollectionUtilsTest.java?rev=1715973=1715972=1715973=diff == --- commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/CollectionUtilsTest.java (original) +++ commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/CollectionUtilsTest.java Mon Nov 23 21:42:01 2015 @@ -16,8 +16,13 @@ */ package org.apache.commons.collections4; -import static org.apache.commons.collections4.functors.EqualPredicate.*; -import static org.junit.Assert.*; +import static org.apache.commons.collections4.functors.EqualPredicate.equalPredicate; +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertFalse; +import static org.junit.Assert.assertNull; +import static org.junit.Assert.assertSame; +import static org.junit.Assert.assertTrue; +import static org.junit.Assert.fail; import java.util.ArrayList; import java.util.Arrays; @@ -109,7 +114,7 @@ public class CollectionUtilsTest extends private Iterable iterableB2 = null; -private Collection emptyCollection = new ArrayList(1); +private final Collection emptyCollection = new ArrayList(1); @Before public void setUp() { @@ -439,6 +444,7 @@ public class CollectionUtilsTest extends public void testSubtractWithPredicate() { // greater than 3 final Predicate predicate = new Predicate() { +@Override public boolean evaluate(final Number n) { return n.longValue() > 3L; } @@ -559,6 +565,7 @@ public class CollectionUtilsTest extends // odd / even equator final Equator e = new Equator() { +@Override public boolean equate(final Integer o1, final Integer o2) { if (o1.intValue() % 2 == 0 ^ o2.intValue() % 2 == 0) { return false; @@ -567,6 +574,7 @@ p
svn commit: r1715653 - in /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap: AbstractMultiValuedMap.java AbstractSetValuedMap.java
Author: tn Date: Sun Nov 22 17:14:42 2015 New Revision: 1715653 URL: http://svn.apache.org/viewvc?rev=1715653=rev Log: Document the todos wrt size() and wrapped collections: for the 4.1 release we leave it as is as it would require too much work and can be improved later. Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractSetValuedMap.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java?rev=1715653=1715652=1715653=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java Sun Nov 22 17:14:42 2015 @@ -140,7 +140,6 @@ public abstract class AbstractMultiValue */ @Override public Collection get(final K key) { -// TODO: wrap collection based on class type - needed for proper equals return new WrappedCollection(key); } @@ -194,9 +193,19 @@ public abstract class AbstractMultiValue return getMap().keySet(); } +/** + * {@inheritDoc} + * + * This implementation does not cache the total size + * of the multi-valued map, but rather calculates it by iterating + * over the entries of the underlying map. + */ @Override public int size() { -// TODO: cache the total size +// the total size should be cached to improve performance +// but this requires that all modifications of the multimap +// (including the wrapped collections and entry/value +// collections) are tracked. int size = 0; for (final Collection col : getMap().values()) { size += col.size(); @@ -376,9 +385,16 @@ public abstract class AbstractMultiValue // --- /** - * Wrapped collection to handle add and remove on the collection returned by get(object) + * Wrapped collection to handle add and remove on the collection returned + * by get(object). + * + * Currently, the wrapped collection is not cached and has to be retrieved + * from the underlying map. This is safe, but not very efficient and + * should be improved in subsequent releases. For this purpose, the + * scope of this collection is set to package private to simplify later + * refactoring. */ -protected class WrappedCollection implements Collection { +class WrappedCollection implements Collection { protected final K key; Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractSetValuedMap.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractSetValuedMap.java?rev=1715653=1715652=1715653=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractSetValuedMap.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractSetValuedMap.java Sun Nov 22 17:14:42 2015 @@ -100,7 +100,7 @@ public abstract class AbstractSetValuedM * Wrapped set to handle add and remove on the collection returned by * {@code get(Object)}. */ -protected class WrappedSet extends WrappedCollection implements Set { +private class WrappedSet extends WrappedCollection implements Set { public WrappedSet(final K key) { super(key);
svn commit: r1715695 - in /commons/proper/collections/trunk/src: main/java/org/apache/commons/collections4/ main/java/org/apache/commons/collections4/multimap/ test/java/org/apache/commons/collections
Author: tn Date: Sun Nov 22 21:11:49 2015 New Revision: 1715695 URL: http://svn.apache.org/viewvc?rev=1715695=rev Log: [COLLECTIONS-508] Added asMap() implementation for MultiValuedMaps. Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractListValuedMap.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractSetValuedMap.java commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/map/AbstractMapTest.java commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMapTest.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java?rev=1715695=1715694=1715695=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java Sun Nov 22 21:11:49 2015 @@ -17,6 +17,7 @@ package org.apache.commons.collections4; import java.util.Collection; +import java.util.Iterator; import java.util.Map; import java.util.Map.Entry; import java.util.Set; @@ -289,8 +290,18 @@ public interface MultiValuedMap<K, V> { Collection values(); /** - * Returns a {@link Map} view of this MultiValuedMap with a Collection as - * its value. The Collection holds all the values mapped to that key. + * Returns a view of this multi-valued map as a {@code Map} from each distinct + * key to the non-empty collection of that key's associated values. + * + * Note that {@code this.asMap().get(k)} is equivalent to {@code this.get(k)} + * only when {@code k} is a key contained in the multi-valued map; otherwise it + * returns {@code null} as opposed to an empty collection. + * + * Changes to the returned map or the collections that serve as its values + * will update the underlying multi-valued map, and vice versa. The map does + * not support {@code put} or {@code putAll}, nor do its entries support + * {@link Map.Entry#setValue setValue} and iterators support + * {@link Iterator#remove remove}. * * @return a map view of the mappings in this multi-valued map */ Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractListValuedMap.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractListValuedMap.java?rev=1715695=1715694=1715695=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractListValuedMap.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractListValuedMap.java Sun Nov 22 21:11:49 2015 @@ -79,6 +79,11 @@ public abstract class AbstractListValued */ @Override public List get(final K key) { +return wrappedCollection(key); +} + +@Override +List wrappedCollection(final K key) { return new WrappedList(key); } Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java?rev=1715695=1715694=1715695=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java Sun Nov 22 21:11:49 2015 @@ -20,6 +20,8 @@ import java.io.IOException; import java.io.ObjectInputStream; import java.io.ObjectOutputStream; import java.util.AbstractCollection; +import java.util.AbstractMap; +import java.util.AbstractSet; import java.util.ArrayList; import java.util.Collection; import java.util.Iterator; @@ -33,11 +35,13 @@ import org.apache.commons.collections4.M import org.apache.commons.collections4.MultiSet; import org.apache.commons.collections4.MultiValuedMap; import org.apache.commons.collections4.Transformer; +import org.apache.commons.collec
svn commit: r1715697 - /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java
Author: tn Date: Sun Nov 22 21:20:04 2015 New Revision: 1715697 URL: http://svn.apache.org/viewvc?rev=1715697=rev Log: Use getMap() instead of asMap(). Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java?rev=1715697=1715696=1715697=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java Sun Nov 22 21:20:04 2015 @@ -383,12 +383,12 @@ public abstract class AbstractMultiValue @Override public int hashCode() { -return asMap().hashCode(); +return getMap().hashCode(); } @Override public String toString() { -return asMap().toString(); +return getMap().toString(); } // ---
svn commit: r1715698 - /commons/proper/collections/trunk/src/changes/changes.xml
Author: tn Date: Sun Nov 22 21:20:23 2015 New Revision: 1715698 URL: http://svn.apache.org/viewvc?rev=1715698=rev Log: Add description to changelog. Modified: commons/proper/collections/trunk/src/changes/changes.xml Modified: commons/proper/collections/trunk/src/changes/changes.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/changes/changes.xml?rev=1715698=1715697=1715698=diff == --- commons/proper/collections/trunk/src/changes/changes.xml (original) +++ commons/proper/collections/trunk/src/changes/changes.xml Sun Nov 22 21:20:23 2015 @@ -21,7 +21,7 @@ - + Added new interfaces "MultiValuedMap", "ListValuedMap" and "SetValuedMap" as a replacement for "MultiMap". Decorators and implementations reside in
svn commit: r1715700 - /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java
Author: tn Date: Sun Nov 22 21:27:38 2015 New Revision: 1715700 URL: http://svn.apache.org/viewvc?rev=1715700=rev Log: Remove unused import. Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java?rev=1715700=1715699=1715700=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiValuedMap.java Sun Nov 22 21:27:38 2015 @@ -17,7 +17,6 @@ package org.apache.commons.collections4; import java.util.Collection; -import java.util.Iterator; import java.util.Map; import java.util.Map.Entry; import java.util.Set; @@ -301,7 +300,7 @@ public interface MultiValuedMap<K, V> { * will update the underlying multi-valued map, and vice versa. The map does * not support {@code put} or {@code putAll}, nor do its entries support * {@link Map.Entry#setValue setValue} and iterators support - * {@link Iterator#remove remove}. + * {@link java.util.Iterator#remove remove}. * * @return a map view of the mappings in this multi-valued map */
svn commit: r1715701 - /commons/proper/collections/trunk/src/conf/checkstyle.xml
Author: tn Date: Sun Nov 22 21:30:36 2015 New Revision: 1715701 URL: http://svn.apache.org/viewvc?rev=1715701=rev Log: Remove obsolete checkstyle module. Modified: commons/proper/collections/trunk/src/conf/checkstyle.xml Modified: commons/proper/collections/trunk/src/conf/checkstyle.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/conf/checkstyle.xml?rev=1715701=1715700=1715701=diff == --- commons/proper/collections/trunk/src/conf/checkstyle.xml (original) +++ commons/proper/collections/trunk/src/conf/checkstyle.xml Sun Nov 22 21:30:36 2015 @@ -38,9 +38,6 @@ - - -
svn commit: r1715703 - in /commons/proper/collections/tags/COLLECTIONS_4_1_RC1: ./ default.properties pom.xml src/site/xdoc/download_collections.xml src/site/xdoc/index.xml
Author: tn Date: Sun Nov 22 21:38:37 2015 New Revision: 1715703 URL: http://svn.apache.org/viewvc?rev=1715703=rev Log: Creating Commons Collections v4.1 RC1 tag. Added: commons/proper/collections/tags/COLLECTIONS_4_1_RC1/ - copied from r1715702, commons/proper/collections/trunk/ Modified: commons/proper/collections/tags/COLLECTIONS_4_1_RC1/default.properties commons/proper/collections/tags/COLLECTIONS_4_1_RC1/pom.xml commons/proper/collections/tags/COLLECTIONS_4_1_RC1/src/site/xdoc/download_collections.xml commons/proper/collections/tags/COLLECTIONS_4_1_RC1/src/site/xdoc/index.xml Modified: commons/proper/collections/tags/COLLECTIONS_4_1_RC1/default.properties URL: http://svn.apache.org/viewvc/commons/proper/collections/tags/COLLECTIONS_4_1_RC1/default.properties?rev=1715703=1715702=1715703=diff == --- commons/proper/collections/tags/COLLECTIONS_4_1_RC1/default.properties (original) +++ commons/proper/collections/tags/COLLECTIONS_4_1_RC1/default.properties Sun Nov 22 21:38:37 2015 @@ -39,7 +39,7 @@ component.package = org.apache.commons.c component.title = Commons Collections # The current version number of this component -component.version = 4.1-SNAPSHOT +component.version = 4.1 # The name that is used to create the jar file final.name = ${component.name}-${component.version} Modified: commons/proper/collections/tags/COLLECTIONS_4_1_RC1/pom.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/tags/COLLECTIONS_4_1_RC1/pom.xml?rev=1715703=1715702=1715703=diff == --- commons/proper/collections/tags/COLLECTIONS_4_1_RC1/pom.xml (original) +++ commons/proper/collections/tags/COLLECTIONS_4_1_RC1/pom.xml Sun Nov 22 21:38:37 2015 @@ -24,7 +24,7 @@ 4.0.0 org.apache.commons commons-collections4 - 4.1-SNAPSHOT + 4.1 Apache Commons Collections 2001 @@ -479,8 +479,8 @@ collections4 -4.0 -(Java 5.0+) +4.1 +(Java 6.0+) 3.2.2 Modified: commons/proper/collections/tags/COLLECTIONS_4_1_RC1/src/site/xdoc/download_collections.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/tags/COLLECTIONS_4_1_RC1/src/site/xdoc/download_collections.xml?rev=1715703=1715702=1715703=diff == --- commons/proper/collections/tags/COLLECTIONS_4_1_RC1/src/site/xdoc/download_collections.xml (original) +++ commons/proper/collections/tags/COLLECTIONS_4_1_RC1/src/site/xdoc/download_collections.xml Sun Nov 22 21:38:37 2015 @@ -95,32 +95,32 @@ limitations under the License. - + - commons-collections4-4.0-bin.tar.gz - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.tar.gz.md5;>md5 - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.tar.gz.asc;>pgp + commons-collections4-4.1-bin.tar.gz + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5;>md5 + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc;>pgp - commons-collections4-4.0-bin.zip - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.zip.md5;>md5 - http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.0-bin.zip.asc;>pgp + commons-collections4-4.1-bin.zip + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.zip.md5;>md5 + http://www.apache.org/dist/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc;>pgp - commons-collections4-4.0-src.tar.gz - http://www.apache.org/dist/commons/collections/source/commons-collections4-4.0-src.tar.gz.md5;>md5 - http://www.apache.org/dist/commons/collections/source/commons-collections4-4.0-src.tar.gz.asc;>pgp + commons-collections4-4.1-src.tar.gz + http://www.apache.org/dist/commons/collections/source/commons-collections4-4.1-src.tar.gz.md5;>md5 + http://www.apache.org/dist/commons/collections/source/commons-collections4-4.1-src.tar.gz.asc;>pgp - commons-collections4-4.0-src.zip - http://www.apache.org/dist/commons/collections/source/commons-collections4-4.0-src.zip.md5;>md5 - http://www.apache.org/dist/commons/collections/source/commons-collections4-4.0-src.zip.asc;>pgp + commons-collections4-4.1-src.zip + http://www.apache.org/dist/commons/collections/s
svn commit: r11263 - in /dev/commons/collections: ./ binaries/ source/
Author: tn Date: Sun Nov 22 21:54:32 2015 New Revision: 11263 Log: Creating distribution files for Commons Collections 4.1 RC1. Added: dev/commons/collections/RELEASE-NOTES.txt (with props) dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz (with props) dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.asc dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.md5 dev/commons/collections/binaries/commons-collections4-4.1-bin.tar.gz.sha1 dev/commons/collections/binaries/commons-collections4-4.1-bin.zip (with props) dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.asc dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.md5 dev/commons/collections/binaries/commons-collections4-4.1-bin.zip.sha1 dev/commons/collections/source/commons-collections4-4.1-src.tar.gz (with props) dev/commons/collections/source/commons-collections4-4.1-src.tar.gz.asc dev/commons/collections/source/commons-collections4-4.1-src.tar.gz.md5 dev/commons/collections/source/commons-collections4-4.1-src.tar.gz.sha1 dev/commons/collections/source/commons-collections4-4.1-src.zip (with props) dev/commons/collections/source/commons-collections4-4.1-src.zip.asc dev/commons/collections/source/commons-collections4-4.1-src.zip.md5 dev/commons/collections/source/commons-collections4-4.1-src.zip.sha1 Added: dev/commons/collections/RELEASE-NOTES.txt == --- dev/commons/collections/RELEASE-NOTES.txt (added) +++ dev/commons/collections/RELEASE-NOTES.txt Sun Nov 22 21:54:32 2015 @@ -0,0 +1,163 @@ + + Apache Commons Collections + Version 4.1 +RELEASE NOTES + +INTRODUCTION: + +Apache Commons Collections is a project to develop and maintain collection +classes based on and inspired by the JDK collection framework. + +This v4.1 release is a minor and security release, fixing several bugs present in +previous releases of the 4.X branch. Additionally, this release provides a mitigation +for a known remote code exploitation via the standard java object serialization +mechanism. Serialization support for unsafe classes in the functor package has been +completely removed (classes do not implement the Serializable interface anymore). +For more details, please refer to COLLECTIONS-580. + +All users are strongly encouraged to updated to this release. + + +Compatibility +- + + o Java 6 or later is now required (previous version 4.0 required Java 5). + o This release is source and binary compatible with the previous 4.0 release + of Commons Collections with the exception that some classes in the functor + package do not implement the Serializable interface anymore (see COLLECTIONS-580). + o some unit tests are disabled when executed with an IBM JDK 6 due to a faulty + java.util.TreeMap implementation. + +Major changes since 4.0 +--- + + o Added interface MultiSet (package multiset) + o Added interfaces MultiValuedMap, ListValuedMap and SetValuedMap (package multimap) + o Added fluent API for Iterable instances (class FluentIterable) + + +Changes +--- + +o [COLLECTIONS-580]: Serialization support for unsafe classes in the functor package + has been removed as this can be exploited for remote code execution + attacks. Classes considered to be unsafe are: CloneTransformer, + ForClosure, InstantiateFactory, InstantiateTransformer, InvokerTransformer, + PrototypeCloneFactory, PrototypeSerializationFactory, WhileClosure. +o [COLLECTIONS-551]: Deprecated various method in "CollectionUtils" in favor of similar + methods in the newly introduced "IterableUtils". +o [COLLECTIONS-570]: All constructors and static factory methods will now throw a "NullPointerException" + if a required input argument is null. Previously sometimes a "IllegalArgumentException" + was used. +o [COLLECTIONS-571]: Deprecated methods "synchronizedCollection(Collection)" and + "unmodifiableCollection(Collection)" in class "CollectionUtils", the corresponding + methods in "java.util.Collections" should be used instead. +o [COLLECTIONS-562]: Upgraded minimum java requirement to Java 6 (up from Java 5). + + +New features + + +o [COLLECTIONS-508]: Added new interfaces "MultiValuedMap", "ListValuedMap" and "SetValuedMap" + as a replacement for "MultiMap". Decorators and implementations reside in + the "multimap" package and a "MultiMapUtils" class has been added. +
svn commit: r1715588 - /commons/proper/collections/trunk/src/changes/changes.xml
Author: tn Date: Sat Nov 21 23:10:14 2015 New Revision: 1715588 URL: http://svn.apache.org/viewvc?rev=1715588=rev Log: Add COLLECTIONS-508 change. Modified: commons/proper/collections/trunk/src/changes/changes.xml Modified: commons/proper/collections/trunk/src/changes/changes.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/changes/changes.xml?rev=1715588=1715587=1715588=diff == --- commons/proper/collections/trunk/src/changes/changes.xml (original) +++ commons/proper/collections/trunk/src/changes/changes.xml Sat Nov 21 23:10:14 2015 @@ -22,6 +22,13 @@ + + Added new interfaces "MultiValuedMap", "ListValuedMap" and "SetValuedMap" + as a replacement for "MultiMap". Decorators and implementations reside in + the "multimap" package and a "MultiMapUtils" class has been added. + The existing interface "MultiMap" as well as the concrete implementation + "MultiValueMap" has been deprecated. + Deprecated various method in "CollectionUtils" in favor of similar methods in the newly introduced "IterableUtils".
svn commit: r1715589 - /commons/proper/collections/trunk/src/site/xdoc/history.xml
Author: tn Date: Sat Nov 21 23:23:38 2015 New Revision: 1715589 URL: http://svn.apache.org/viewvc?rev=1715589=rev Log: Update history. Modified: commons/proper/collections/trunk/src/site/xdoc/history.xml Modified: commons/proper/collections/trunk/src/site/xdoc/history.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/history.xml?rev=1715589=1715588=1715589=diff == --- commons/proper/collections/trunk/src/site/xdoc/history.xml (original) +++ commons/proper/collections/trunk/src/site/xdoc/history.xml Sat Nov 21 23:23:38 2015 @@ -121,6 +121,18 @@ been replaced by java.util.Queue. Also a an implementation of a Patricia Trie. + +Collections 4.1 fixed some bugs in v4.0 and adds a few new enhancements. +The most notable changes are new interfaces MultiSet (a replacement for the Bag +interface which is fully compliant to the general Collection contract) and +MultiValuedMapeList (a replacement for the MultiMap interface) as well as fluent +API for Iterable instances (FluentIterable). + + +Additionally, serialization support for unsafe classes in the functor package +has been completely removed (see entry for Collections 3.2.2 for more details). + +
svn commit: r1715592 - /commons/proper/collections/trunk/RELEASE-NOTES.txt
Author: tn Date: Sat Nov 21 23:47:52 2015 New Revision: 1715592 URL: http://svn.apache.org/viewvc?rev=1715592=rev Log: Update release notes for 4.1. Modified: commons/proper/collections/trunk/RELEASE-NOTES.txt Modified: commons/proper/collections/trunk/RELEASE-NOTES.txt URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/RELEASE-NOTES.txt?rev=1715592=1715591=1715592=diff == --- commons/proper/collections/trunk/RELEASE-NOTES.txt (original) +++ commons/proper/collections/trunk/RELEASE-NOTES.txt Sat Nov 21 23:47:52 2015 @@ -1,364 +1,163 @@ Apache Commons Collections - Version 4.0 + Version 4.1 RELEASE NOTES INTRODUCTION: -Commons collections is a project to develop and maintain collection classes -based on and inspired by the JDK collection framework. -This version uses the generics features of Java 5 and is not compatible with -earlier JDK versions. - -The process of generifying an API is complex. -For commons-collections, we have chosen to break the API in various ways. -The aim behind this is to provide an API design that better suits generics. -We have also removed all deprecated classes and fixed oddities in the previous -API that we couldn't fix due to backwards compatibility restrictions. - -As such, this release can not be considered to be a simple, drop-in, replacement -for commons-collections. To help with the migration to this new version, the -package has changed to "org.apache.commons.collections4", thus it is possible -to have both commons-collections versions in the classpath. - -These release notes will try to guide you in the process of upgrading, however you -should remember that this is a new API based on the original, so some concepts -have changed. +Apache Commons Collections is a project to develop and maintain collection +classes based on and inspired by the JDK collection framework. + +This v4.1 release is a minor and security release, fixing several bugs present in +previous releases of the 4.X branch. Additionally, this release provides a mitigation +for a known remote code exploitation via the standard java object serialization +mechanism. Serialization support for unsafe classes in the functor package has been +completely removed (classes do not implement the Serializable interface anymore). +For more details, please refer to COLLECTIONS-580. + +All users are strongly encouraged to updated to this release. + Compatibility - - o Java 5 or later is required. - o This release is not source or binary compatible with previous releases of - Commons Collections. This includes releases from the 3.x branch as well as - preceding alpha releases for 4.0 (see details of changes below). + o Java 6 or later is now required (previous version 4.0 required Java 5). + o This release is source and binary compatible with the previous 4.0 release + of Commons Collections with the exception that some classes in the functor + package do not implement the Serializable interface anymore (see COLLECTIONS-580). o some unit tests are disabled when executed with an IBM JDK 6 due to a faulty java.util.TreeMap implementation. +Major changes since 4.0 +--- -Major changes since 3.2.1 -- - - o Use of generics and other language features introduced in Java 5 (varargs, Iterable) - o Removed deprecated classes / methods and features which are now supported by the JDK - o Replaced Buffer interface with java.util.Queue - o Added concept of split maps with respective interfaces Put / Get (see also package splitmap) - o Added new Trie interface together with an implementation of a Patricia Trie - - -Changes since 4.0-alpha1 - - - o [COLLECTIONS-502] Resolved generic parameter inconsistency for various static fields, e.g. BagUtils.EMPTY_BAG, - TruePredicate.INSTANCE and many others. All accessible static fields use raw types so that - they can be used directly without explicit casting. To avoid compiler warnings about unchecked - conversion and/or rawtypes use the corresponding factory methods, e.g. BagUtils.emptyBag(). - o [COLLECTIONS-501] Renamed methods "V MultiKeyMap#remove(Object, Object, ...)" to - "V MultiKeyMap#removeMultiKey(Object, Object, ...)" to avoid future conflicts - with a default method of the Map interface in Java 8. - o [COLLECTIONS-500] Renamed "V MultiMap#remove(K, V)" to "boolean MultiMap#removeMapping(K, V)" - to avoid future conflicts with a default method of the Map interface in Java 8. - o [COLLECTIONS-499] Refactored the test framework for Bag implementations to extend from - "AbstractC
svn commit: r1715563 - in /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset: AbstractMapMultiSet.java AbstractMultiSet.java HashMultiSet.java
Author: tn Date: Sat Nov 21 20:13:35 2015 New Revision: 1715563 URL: http://svn.apache.org/viewvc?rev=1715563=rev Log: Add abstract class to simplify creation of MultiSet implementations, needed for MultiValuedMap; additional cleanup. Added: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMultiSet.java (with props) Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/HashMultiSet.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java?rev=1715563=1715562=1715563=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java Sat Nov 21 20:13:35 2015 @@ -20,16 +20,11 @@ import java.io.IOException; import java.io.ObjectInputStream; import java.io.ObjectOutputStream; import java.lang.reflect.Array; -import java.util.AbstractCollection; -import java.util.AbstractSet; -import java.util.Collection; import java.util.ConcurrentModificationException; import java.util.Iterator; import java.util.Map; -import java.util.Set; import org.apache.commons.collections4.MultiSet; -import org.apache.commons.collections4.collection.AbstractCollectionDecorator; import org.apache.commons.collections4.iterators.AbstractIteratorDecorator; /** @@ -43,7 +38,7 @@ import org.apache.commons.collections4.i * @since 4.1 * @version $Id$ */ -public abstract class AbstractMapMultiSet extends AbstractCollection implements MultiSet { +public abstract class AbstractMapMultiSet extends AbstractMultiSet { /** The map to use to store the data */ private transient Map<E, MutableInteger> map; @@ -51,10 +46,6 @@ public abstract class AbstractMapMultiSe private transient int size; /** The modification count for fail fast iterators */ private transient int modCount; -/** View of the elements */ -private transient Set uniqueSet; -/** View of the entries */ -private transient Set<Entry> entrySet; /** * Constructor needed for subclass serialisation. @@ -78,12 +69,23 @@ public abstract class AbstractMapMultiSe * Utility method for implementations to access the map that backs this multiset. * Not intended for interactive use outside of subclasses. * - * @return the map being used by the Bag + * @return the map being used by the MultiSet */ protected Map<E, MutableInteger> getMap() { return map; } +/** + * Sets the map being wrapped. + * + * NOTE: this method should only be used during deserialization + * + * @param map the map to wrap + */ +protected void setMap(Map<E, MutableInteger> map) { +this.map = map; +} + //--- /** * Returns the number of elements in this multiset. @@ -121,21 +123,6 @@ public abstract class AbstractMapMultiSe return 0; } -@Override -public int setCount(final E object, final int count) { -if (count < 0) { -throw new IllegalArgumentException("Count must not be negative."); -} - -int oldCount = getCount(object); -if (oldCount < count) { -add(object, count - oldCount); -} else { -remove(object, oldCount - count); -} -return oldCount; -} - //--- /** * Determines if the multiset contains the given element by checking if the @@ -158,13 +145,13 @@ public abstract class AbstractMapMultiSe */ @Override public Iterator iterator() { -return new MultiSetIterator(this); +return new MapBasedMultiSetIterator(this); } /** * Inner class iterator for the MultiSet. */ -static class MultiSetIterator implements Iterator { +private static class MapBasedMultiSetIterator implements Iterator { private final AbstractMapMultiSet parent; private final Iterator<Map.Entry<E, MutableInteger>> entryIterator; private Map.Entry<E, MutableInteger> current; @@ -177,7 +164,7 @@ public abstract class AbstractMapMultiSe * * @param parent the parent multiset */ -public MultiSetIterator(final AbstractMapMultiSet parent) { +
svn commit: r1715565 - /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java
Author: tn Date: Sat Nov 21 20:14:15 2015 New Revision: 1715565 URL: http://svn.apache.org/viewvc?rev=1715565=rev Log: Complete KeysMultiSet view. Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java?rev=1715565=1715564=1715565=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java Sat Nov 21 20:14:15 2015 @@ -19,7 +19,6 @@ package org.apache.commons.collections4. import java.io.IOException; import java.io.ObjectInputStream; import java.io.ObjectOutputStream; -import java.lang.reflect.Array; import java.util.AbstractCollection; import java.util.ArrayList; import java.util.Collection; @@ -39,7 +38,8 @@ import org.apache.commons.collections4.i import org.apache.commons.collections4.iterators.LazyIteratorChain; import org.apache.commons.collections4.iterators.TransformIterator; import org.apache.commons.collections4.keyvalue.AbstractMapEntry; -import org.apache.commons.collections4.set.UnmodifiableSet; +import org.apache.commons.collections4.multiset.AbstractMultiSet; +import org.apache.commons.collections4.multiset.UnmodifiableMultiSet; /** * Abstract implementation of the {@link MultiValuedMap} interface to simplify @@ -59,7 +59,7 @@ public abstract class AbstractMultiValue private transient EntryValues entryValuesView; /** The KeyMultiSet view */ -private transient KeysMultiSet keysMultiSetView; +private transient MultiSet keysMultiSetView; /** The map used to store the data */ private transient Map<K, Collection> map; @@ -308,8 +308,10 @@ public abstract class AbstractMultiValue */ @Override public MultiSet keys() { -return keysMultiSetView != null ? keysMultiSetView -: (keysMultiSetView = new KeysMultiSet()); +if (keysMultiSetView == null) { +keysMultiSetView = UnmodifiableMultiSet.unmodifiableMultiSet(new KeysMultiSet()); +} +return keysMultiSetView; } @Override @@ -526,17 +528,7 @@ public abstract class AbstractMultiValue /** * Inner class that provides a MultiSet keys view. */ -private class KeysMultiSet implements MultiSet { - -@Override -public boolean addAll(Collection c) { -throw new UnsupportedOperationException(); -} - -@Override -public void clear() { -throw new UnsupportedOperationException(); -} +private class KeysMultiSet extends AbstractMultiSet { @Override public boolean contains(Object o) { @@ -549,45 +541,13 @@ public abstract class AbstractMultiValue } @Override -public Object[] toArray() { -final Object[] result = new Object[size()]; -int i = 0; -final Iterator it = getMap().keySet().iterator(); -while (it.hasNext()) { -final K current = it.next(); -for (int index = getCount(current); index > 0; index--) { -result[i++] = current; -} -} -return result; +public int size() { +return AbstractMultiValuedMap.this.size(); } @Override -public T[] toArray(T[] array) { -final int size = size(); -if (array.length < size) { -@SuppressWarnings("unchecked") -// safe as both are of type T -final T[] unchecked = (T[]) Array.newInstance(array.getClass().getComponentType(), size); -array = unchecked; -} - -int i = 0; -final Iterator it = getMap().keySet().iterator(); -while (it.hasNext()) { -final K current = it.next(); -for (int index = getCount(current); index > 0; index--) { -// unsafe, will throw ArrayStoreException if types are not -// compatible, see javadoc -@SuppressWarnings("unchecked") -final T unchecked = (T) current; -array[i++] = unchecked; -} -} -while (i < array.length) { -array[i++] = null; -} -return array; +protected int uniqueElements() { +return getMap().size();
svn commit: r1715595 - in /commons/proper/collections/trunk: RELEASE-NOTES.txt src/site/site.xml src/site/xdoc/release_3_2_2.xml src/site/xdoc/release_4_0.xml src/site/xdoc/release_4_1.xml
Author: tn Date: Sun Nov 22 00:37:47 2015 New Revision: 1715595 URL: http://svn.apache.org/viewvc?rev=1715595=rev Log: Update release notes. Added: commons/proper/collections/trunk/src/site/xdoc/release_4_1.xml (with props) Modified: commons/proper/collections/trunk/RELEASE-NOTES.txt commons/proper/collections/trunk/src/site/site.xml commons/proper/collections/trunk/src/site/xdoc/release_3_2_2.xml commons/proper/collections/trunk/src/site/xdoc/release_4_0.xml Modified: commons/proper/collections/trunk/RELEASE-NOTES.txt URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/RELEASE-NOTES.txt?rev=1715595=1715594=1715595=diff == --- commons/proper/collections/trunk/RELEASE-NOTES.txt (original) +++ commons/proper/collections/trunk/RELEASE-NOTES.txt Sun Nov 22 00:37:47 2015 @@ -32,7 +32,7 @@ Major changes since 4.0 --- o Added interface MultiSet (package multiset) - o Added interface MultiValuedMap, ListValuedMap and SetValuedMap (package multimap) + o Added interfaces MultiValuedMap, ListValuedMap and SetValuedMap (package multimap) o Added fluent API for Iterable instances (class FluentIterable) Modified: commons/proper/collections/trunk/src/site/site.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/site.xml?rev=1715595=1715594=1715595=diff == --- commons/proper/collections/trunk/src/site/site.xml (original) +++ commons/proper/collections/trunk/src/site/site.xml Sun Nov 22 00:37:47 2015 @@ -29,6 +29,7 @@ + Modified: commons/proper/collections/trunk/src/site/xdoc/release_3_2_2.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/release_3_2_2.xml?rev=1715595=1715594=1715595=diff == --- commons/proper/collections/trunk/src/site/xdoc/release_3_2_2.xml (original) +++ commons/proper/collections/trunk/src/site/xdoc/release_3_2_2.xml Sun Nov 22 00:37:47 2015 @@ -23,9 +23,6 @@ - -These are the release notes for Commons Collections v3.2.2: - Commons collections is a project to develop and maintain collection classes @@ -43,9 +40,8 @@ an instance of these classes. For more d All users are strongly encouraged to updated to this release. - -COMPATIBILITY +Compatibility This release is fully source and binary compatible with v3.2. For changes since the v3.1 see the v3.2 Release Notes. Note that the method @@ -53,10 +49,10 @@ v3.1 see the added. -Changes +Security Changes - COLLECTIONS-580 + COLLECTIONS-580 Serialization support for unsafe classes in the functor package is disabled by default as this can be exploited for remote code execution attacks. To re-enable the feature the system property @@ -67,81 +63,9 @@ added. -Bugfixes - - - COLLECTIONS-538 - "ExtendedProperties" will now use a privileged action to access the "file.separator" system property. - In case the class does not have permission to read system properties, the "File#separator" field will - be used instead. Thanks to Trejkaz. - - - COLLECTIONS-447 - Tree traversal with a TreeListIterator will not be affected anymore by - the removal of an element directly after a call to previous(). Thanks to Jeffrey Barnes. - - - COLLECTIONS-444 - SetUniqueList.set(int, Object) now works correctly if the object to be inserted - is already placed at the given position. Thanks to Thomas Vahrst, John Vasileff. - - - COLLECTIONS-350 - Removed debug output in "MapUtils#getNumber(Map)". Thanks to Michael Akerman. - - - COLLECTIONS-335 - Fixed cache assignment for "TreeBidiMap#entrySet". Thanks to sebb. - - - COLLECTIONS-334 - Synchronized access to lock in "StaticBucketMap#size()". Thanks to sebb. - - - COLLECTIONS-307 - "SetUniqueList#subList()#contains(Object)" will now correctly check the subList - rather than the parent list. Thanks to Christian Semrau. - - - COLLECTIONS-304 - "SetUniqueList#set(int, Object)" will now correctly enforce the uniqueness constraint. - Thanks to Rafa? Figas,Bjorn Townsend. - - - COLLECTIONS-294 - "CaseInsensitiveMap" will now convert input strings to lower-case in a - locale-independent manner. Thanks to Benjamin Bentmann. - - - COLLECTIONS-266 - "MultiKey" will now be correctly serialized/de-serialized. Thanks to Joerg Schaible. - - - COLLECTIONS-261 - "Flat3Map#remove(Object)" will now return the correct value mapped to the removed key - if the size of the map is less or equal 3. Thanks to ori. - - - COLLECTIONS-249 - "SetUniqueList.addAll(int, Collection)" now correctly
svn commit: r1715488 - /commons/proper/collections/trunk/src/changes/changes.xml
Author: tn Date: Sat Nov 21 09:51:19 2015 New Revision: 1715488 URL: http://svn.apache.org/viewvc?rev=1715488=rev Log: Add 3.2.2 changes. Modified: commons/proper/collections/trunk/src/changes/changes.xml Modified: commons/proper/collections/trunk/src/changes/changes.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/changes/changes.xml?rev=1715488=1715487=1715488=diff == --- commons/proper/collections/trunk/src/changes/changes.xml (original) +++ commons/proper/collections/trunk/src/changes/changes.xml Sat Nov 21 09:51:19 2015 @@ -768,5 +768,72 @@ features, this release includes numerous Added class "ComparatorPredicate". + + + Serialization support for unsafe classes in the functor package is disabled + by default as this can be exploited for remote code execution attacks. + To re-enable the feature the system property "org.apache.commons.collections.enableUnsafeSerialization" + needs to be set to "true". + Classes considered to be unsafe are: CloneTransformer, ForClosure, InstantiateFactory, + InstantiateTransformer, InvokerTransformer, PrototypeCloneFactory, + PrototypeSerializationFactory, WhileClosure. + + + "ExtendedProperties" will now use a privileged action to access the + "file.separator" system property. In case the class does not have + permission to read system properties, the "File#separator" field will + be used instead. + + + Tree traversal with a TreeListIterator will not be affected anymore by + the removal of an element directly after a call to previous(). + + + SetUniqueList.set(int, Object) now works correctly if the object to be inserted + is already placed at the given position. + + + Removed debug output in "MapUtils#getNumber(Map)". + + + Fixed cache assignment for "TreeBidiMap#entrySet". + + + Synchronized access to lock in "StaticBucketMap#size()". + + + "SetUniqueList#subList()#contains(Object)" will now correctly check the subList + rather than the parent list. + + + "SetUniqueList#set(int, Object)" will now correctly enforce the uniqueness constraint. + + + "CaseInsensitiveMap" will now convert input strings to lower-case in a + locale-independent manner. + + + "MultiKey" will now be correctly serialized/de-serialized. + + + "Flat3Map#remove(Object)" will now return the correct value mapped to the removed key + if the size of the map is less or equal 3. + + + "SetUniqueList.addAll(int, Collection)" now correctly add the collection at the + provided index. + + + "MultiValueMap#put(Object, Object)" and "MultiValueMap#putAll(Object, Collection)" + now correctly return if the map has changed by this operation. + + + "CollectionUtils#removeAll" wrongly called "ListUtils#retainAll". + + + Calling "setValue(Object)" on any Entry returned by a "Flat3Map" will now + correctly set the value for the current entry. + +
svn commit: r1715490 - /commons/proper/collections/trunk/src/site/xdoc/
Author: tn Date: Sat Nov 21 09:52:05 2015 New Revision: 1715490 URL: http://svn.apache.org/viewvc?rev=1715490=rev Log: Fix apache license header. Modified: commons/proper/collections/trunk/src/site/xdoc/building.xml commons/proper/collections/trunk/src/site/xdoc/compatibility.xml commons/proper/collections/trunk/src/site/xdoc/history.xml commons/proper/collections/trunk/src/site/xdoc/index.xml commons/proper/collections/trunk/src/site/xdoc/issue-tracking.xml commons/proper/collections/trunk/src/site/xdoc/mail-lists.xml commons/proper/collections/trunk/src/site/xdoc/pick.xml commons/proper/collections/trunk/src/site/xdoc/proposal.xml commons/proper/collections/trunk/src/site/xdoc/release_3_2.xml commons/proper/collections/trunk/src/site/xdoc/release_3_2_1.xml commons/proper/collections/trunk/src/site/xdoc/release_3_2_2.xml commons/proper/collections/trunk/src/site/xdoc/release_4_0.xml commons/proper/collections/trunk/src/site/xdoc/userguide.xml Modified: commons/proper/collections/trunk/src/site/xdoc/building.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/building.xml?rev=1715490=1715489=1715490=diff == --- commons/proper/collections/trunk/src/site/xdoc/building.xml (original) +++ commons/proper/collections/trunk/src/site/xdoc/building.xml Sat Nov 21 09:52:05 2015 @@ -1,19 +1,19 @@ Modified: commons/proper/collections/trunk/src/site/xdoc/compatibility.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/compatibility.xml?rev=1715490=1715489=1715490=diff == --- commons/proper/collections/trunk/src/site/xdoc/compatibility.xml (original) +++ commons/proper/collections/trunk/src/site/xdoc/compatibility.xml Sat Nov 21 09:52:05 2015 @@ -1,11 +1,11 @@ - - +--> Modified: commons/proper/collections/trunk/src/site/xdoc/history.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/history.xml?rev=1715490=1715489=1715490=diff == --- commons/proper/collections/trunk/src/site/xdoc/history.xml (original) +++ commons/proper/collections/trunk/src/site/xdoc/history.xml Sat Nov 21 09:52:05 2015 @@ -1,11 +1,11 @@ - - +--> Modified: commons/proper/collections/trunk/src/site/xdoc/index.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/index.xml?rev=1715490=1715489=1715490=diff == --- commons/proper/collections/trunk/src/site/xdoc/index.xml (original) +++ commons/proper/collections/trunk/src/site/xdoc/index.xml Sat Nov 21 09:52:05 2015 @@ -1,11 +1,11 @@ - +--> Home Modified: commons/proper/collections/trunk/src/site/xdoc/issue-tracking.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/issue-tracking.xml?rev=1715490=1715489=1715490=diff == --- commons/proper/collections/trunk/src/site/xdoc/issue-tracking.xml (original) +++ commons/proper/collections/trunk/src/site/xdoc/issue-tracking.xml Sat Nov 21 09:52:05 2015 @@ -1,19 +1,19 @@ - +--> Modified: commons/proper/collections/trunk/src/site/xdoc/proposal.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/proposal.xml?rev=1715490=1715489=1715490=diff == --- commons/proper/collections/trunk/src/site/xdoc/proposal.xml (original) +++ commons/proper/collections/trunk/src/site/xdoc/proposal.xml Sat Nov 21 09:52:05 2015 @@ -1,19 +1,19 @@ Modified: commons/proper/collections/trunk/src/site/xdoc/release_3_2.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/release_3_2.xml?rev=1715490=1715489=1715490=diff == --- commons/proper/collections/trunk/src/site/xdoc/release_3_2.xml (original) +++ commons/proper/collections/trunk/src/site/xdoc/release_3_2.xml Sat Nov 21 09:52:05 2015 @@ -1,19 +1,19 @@ Modified: commons/proper/collections/trunk/src/site/xdoc/release_3_2_1.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/release_3_2_1.xml?rev=1715490=1715489=1715490=diff == --- commons/proper/collections/trunk/src/site/xdoc/release_3_2_1.xml (original) +++ commons/proper/collections/trunk/src/site/xdoc/release_3_2_1.xml Sat Nov 21 09:52:05 2015 @@ -1,19 +1,19 @@ Modified: commons/proper/collections/trunk/src/site/xdoc/release_3_2_2.xml URL: http://svn.apache.org/vi
svn commit: r1715489 - in /commons/proper/collections/trunk/src/site: site.xml xdoc/security-reports.xml
Author: tn Date: Sat Nov 21 09:51:39 2015 New Revision: 1715489 URL: http://svn.apache.org/viewvc?rev=1715489=rev Log: Add security report. Added: commons/proper/collections/trunk/src/site/xdoc/security-reports.xml (with props) Modified: commons/proper/collections/trunk/src/site/site.xml Modified: commons/proper/collections/trunk/src/site/site.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/site.xml?rev=1715489=1715488=1715489=diff == --- commons/proper/collections/trunk/src/site/site.xml (original) +++ commons/proper/collections/trunk/src/site/site.xml Sat Nov 21 09:51:39 2015 @@ -24,15 +24,16 @@ - - - - - + + + + + + - - - + + + Added: commons/proper/collections/trunk/src/site/xdoc/security-reports.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/security-reports.xml?rev=1715489=auto == --- commons/proper/collections/trunk/src/site/xdoc/security-reports.xml (added) +++ commons/proper/collections/trunk/src/site/xdoc/security-reports.xml Sat Nov 21 09:51:39 2015 @@ -0,0 +1,111 @@ + + + + +Commons Collections Security Reports +Commons Documentation Team + + + +For information about reporting or asking questions about +security problems, please see the http://commons.apache.org/security.html;>security page +of the Commons project. + + + +This page lists all security vulnerabilities fixed in +released versions of Apache Commons Collections. Each +vulnerability is given a security impact rating by the +development team - please note that this rating may vary from +platform to platform. We also list the versions of Commons +Collections the flaw is known to affect, and where a flaw has not +been verified list the version with a question mark. + +Please note that binary patches are never provided. If you +need to apply a source code patch, use the building +instructions for the Commons Collections version that you are +using. + +If you need help on building Commons Collections or other help +on following the instructions to mitigate the known +vulnerabilities listed here, please send your questions to the +public Collections Users mailing +list. + +If you have encountered an unlisted security vulnerability +or other unexpected behaviour that has security impact, or if +the descriptions here are incomplete, please report them +privately to the Apache Security Team. Thank you. + + + High: Remote Code Execution during object de-serialization + + The Apache Commons Collections library contains various classes + in the "functor" package which are serializable and use reflection. + This can be exploited for remote code execution attacks by injecting + specially crafted objects to applications that de-serialize + java objects from untrusted sources and have the Apache Commons Collections + library in their classpath and do not perform any kind of input + validation. + + The implemented fix can be tracked via its related issue + https://issues.apache.org/jira/browse/COLLECTIONS-580;>COLLECTIONS-580: + + +3.2.2: de-serialization of unsafe classes in the functor package +will trigger an "UnsupportedOperationException" by default. In order to re-enable +the previous behavior, the system property +"org.apache.commons.collections.enableUnsafeSerialization" has to be set to "true". +4.1: de-serialization support for unsafe classes in the functor package +has been completely removed (unsafe classes do not implement Serializable anymore). + + + The potential exploit was first presented at AppSecCali2015 [3] on 28 January 2015 by + Gabriel Lawrence and Chris Frohoff. Based on these exploits, Stephen Breen published + on 06 November 2015 attack scenarios [4] for various products like WebSphere, JBoss, Jenkins, + WebLogic, and OpenNMS. The Security team was not informed about these security + problems prior to their publication. No CVE id was assigned for the Apache Commons + Collections library, please refer to [1] or [2] for more information about the gene
svn commit: r1715492 - in /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap: AbstractMultiValuedMap.java ArrayListValuedHashMap.java HashSetValuedHashMap.java
Author: tn Date: Sat Nov 21 10:09:31 2015 New Revision: 1715492 URL: http://svn.apache.org/viewvc?rev=1715492=rev Log: Fix checkstyle warnings, add missing AL header. Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMap.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/HashSetValuedHashMap.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java?rev=1715492=1715491=1715492=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java Sat Nov 21 10:09:31 2015 @@ -74,7 +74,6 @@ public abstract class AbstractMultiValue /** * Constructor that wraps (not copies). * - * @param the collection type * @param map the map to wrap, must not be null * @throws NullPointerException if the map is null */ Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMap.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMap.java?rev=1715492=1715491=1715492=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMap.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMap.java Sat Nov 21 10:09:31 2015 @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.apache.commons.collections4.multimap; import java.io.IOException; @@ -9,11 +25,10 @@ import java.util.Collection; import java.util.HashMap; import java.util.Map; -import org.apache.commons.collections4.ListValuedMap; import org.apache.commons.collections4.MultiValuedMap; /** - * Implements a {@link ListValuedMap}, using a {@link HashMap} to provide data + * Implements a {@code ListValuedMap}, using a {@link HashMap} to provide data * storage and {@link ArrayList}s as value collections. This is the standard * implementation of a ListValuedMap. * @@ -48,7 +63,7 @@ public class ArrayListValuedHashMap<K, V /** * Creates an empty ArrayListValuedHashMap with the default initial - * map capacity (16) and the default initial list capacity (3). + * map capacity (16) and the default initial list capacity (3). */ public ArrayListValuedHashMap() { this(DEFAULT_INITIAL_MAP_CAPACITY, DEFAULT_INITIAL_LIST_CAPACITY); @@ -56,7 +71,7 @@ public class ArrayListValuedHashMap<K, V /** * Creates an empty ArrayListValuedHashMap with the default initial - * map capacity (16) and the specified initial list capacity. + * map capacity (16) and the specified initial list capacity. * * @param initialListCapacity the initial capacity used for value collections */ @@ -66,7 +81,7 @@ public class ArrayListValuedHashMap<K, V /** * Creates an empty ArrayListValuedHashMap with the specified initial - * map and list capacities. + * map and list capacities. * * @param initialMapCapacity the initial hashmap capacity * @param initialListCapacity the initial capacity used for value collections @@ -118,7 +133,7 @@ public class ArrayListValuedHashMap<K, V oos.defaultWriteObject(); doWriteObject(oos); } - + private void readObject(ObjectInputStream ois) throws IOEx
svn commit: r1715302 - in /commons/proper/collections/trunk/src: main/java/org/apache/commons/collections4/ main/java/org/apache/commons/collections4/multimap/ test/java/org/apache/commons/collections
Author: tn Date: Thu Nov 19 23:08:01 2015 New Revision: 1715302 URL: http://svn.apache.org/viewvc?rev=1715302=rev Log: [COLLECTIONS-580] Do not use InstantiateFactory anymore for MultiValuedMaps: different MultiValuedMap implementations are now fully typed for the used underlying map and value collection class being used. This has pros and cons, but it is certainly safer to do it that way. Added: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMap.java (with props) commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/HashSetValuedHashMap.java (with props) commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/ArrayListValuedHashMapTest.java (with props) commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/HashSetValuedHashMapTest.java (with props) commons/proper/collections/trunk/src/test/resources/data/test/ArrayListValuedHashMap.emptyCollection.version4.1.obj (with props) commons/proper/collections/trunk/src/test/resources/data/test/ArrayListValuedHashMap.fullCollection.version4.1.obj (with props) commons/proper/collections/trunk/src/test/resources/data/test/HashSetValuedHashMap.emptyCollection.version4.1.obj (with props) commons/proper/collections/trunk/src/test/resources/data/test/HashSetValuedHashMap.fullCollection.version4.1.obj (with props) Removed: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/MultiValuedHashMap.java commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/MultiValuedHashMapTest.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiMapUtils.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractListValuedMap.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMapDecorator.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractSetValuedMap.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/TransformedMultiValuedMap.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/package-info.java commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/MultiMapUtilsTest.java commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMapTest.java commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/TransformedMultiValuedMapTest.java commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/UnmodifiableMultiValuedMapTest.java commons/proper/collections/trunk/src/test/resources/data/test/TransformedMultiValuedMap.emptyCollection.version4.1.obj commons/proper/collections/trunk/src/test/resources/data/test/TransformedMultiValuedMap.fullCollection.version4.1.obj commons/proper/collections/trunk/src/test/resources/data/test/UnmodifiableMultiValuedMap.emptyCollection.version4.1.obj commons/proper/collections/trunk/src/test/resources/data/test/UnmodifiableMultiValuedMap.fullCollection.version4.1.obj Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiMapUtils.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiMapUtils.java?rev=1715302=1715301=1715302=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiMapUtils.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiMapUtils.java Thu Nov 19 23:08:01 2015 @@ -23,7 +23,8 @@ import java.util.List; import java.util.Set; import org.apache.commons.collections4.bag.HashBag; -import org.apache.commons.collections4.multimap.MultiValuedHashMap; +import org.apache.commons.collections4.multimap.ArrayListValuedHashMap; +import org.apache.commons.collections4.multimap.HashSetValuedHashMap; import org.apache.commons.collections4.multimap.TransformedMultiValuedMap; import org.apache.commons.collections4.multimap.UnmodifiableMultiValuedMap; @@ -52,7 +53,7 @@ public class MultiMapUtils { */ @SuppressWarnings({ "rawtypes", "unchecked" }) public static final MultiValuedMap EMPTY_MULTI_VALUED_MAP = -UnmodifiableMultiValuedMap.unmodifiableMultiValuedMap(new MultiValuedHashMap()); +UnmodifiableMultiValuedMap.unmodifiab
svn commit: r1714707 - /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java
Author: tn Date: Mon Nov 16 23:08:26 2015 New Revision: 1714707 URL: http://svn.apache.org/viewvc?rev=1714707=rev Log: Fix size calculation of entrySet in MultiSet. Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java?rev=1714707=1714706=1714707=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java Mon Nov 16 23:08:26 2015 @@ -558,7 +558,7 @@ public abstract class AbstractMapMultiSe @Override public int size() { -return parent.entrySet.size(); +return parent.map.entrySet().size(); } @Override
svn commit: r1714708 - /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java
Author: tn Date: Mon Nov 16 23:09:01 2015 New Revision: 1714708 URL: http://svn.apache.org/viewvc?rev=1714708=rev Log: Add toString method in AbstractMultiValuedMap#KeysMultiSet. Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java?rev=1714708=1714707=1714708=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMap.java Mon Nov 16 23:09:01 2015 @@ -716,6 +716,28 @@ public abstract class AbstractMultiValue }; } +@Override +public String toString() { +if (size() == 0) { +return "[]"; +} +final StringBuilder buf = new StringBuilder(); +buf.append('['); +final Iterator it = KeysMultiSet.this.uniqueSet().iterator(); +while (it.hasNext()) { +final Object current = it.next(); +final int count = getCount(current); +buf.append(current); +buf.append(':'); +buf.append(count); +if (it.hasNext()) { +buf.append(", "); +} +} +buf.append(']'); +return buf.toString(); +} + } /**
svn commit: r1714424 - in /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4: ./ collection/ multiset/
Author: tn Date: Sun Nov 15 10:06:16 2015 New Revision: 1714424 URL: http://svn.apache.org/viewvc?rev=1714424=rev Log: [COLLECTIONS-567] Add MultiSetUtils, fix typos, remove references to bag. Added: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiSetUtils.java (with props) Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiSet.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/collection/PredicatedCollection.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/HashMultiSet.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/SynchronizedMultiSet.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiSet.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiSet.java?rev=1714424=1714423=1714424=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiSet.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiSet.java Sun Nov 15 10:06:16 2015 @@ -123,8 +123,8 @@ public interface MultiSet extends Col * * The returned set is backed by this multiset, so any change to either * is immediately reflected in the other. Only removal operations are - * supporting, in which case all occurrences of the removed elements - * are removed from the backing multiset. + * supported, in which case all occurrences of the element are removed + * from the backing multiset. * * @return the Set of unique MultiSet elements */ Added: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiSetUtils.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiSetUtils.java?rev=1714424=auto == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiSetUtils.java (added) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/MultiSetUtils.java Sun Nov 15 10:06:16 2015 @@ -0,0 +1,119 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ +package org.apache.commons.collections4; + +import org.apache.commons.collections4.multiset.HashMultiSet; +import org.apache.commons.collections4.multiset.PredicatedMultiSet; +import org.apache.commons.collections4.multiset.SynchronizedMultiSet; +import org.apache.commons.collections4.multiset.UnmodifiableMultiSet; + +/** + * Provides utility methods and decorators for {@link MultiSet} instances. + * + * @since 4.1 + * @version $Id$ + */ +public class MultiSetUtils { + +/** + * An empty unmodifiable multiset. + */ +@SuppressWarnings("rawtypes") // OK, empty multiset is compatible with any type +public static final MultiSet EMPTY_MULTISET = +UnmodifiableMultiSet.unmodifiableMultiSet(new HashMultiSet()); + +/** + * Instantiation of MultiSetUtils is not intended or required. + */ +private MultiSetUtils() {} + +//--- +/** + * Returns a synchronized (thread-safe) multiset backed by the given multiset. + * In order to guarantee serial access, it is critical that all access to the + * backing multiset is accomplished through the returned multiset. + * + * It is imperative that the user manually synchronize on the returned multiset + * when iterating over it: + * + * + * MultiSet multiset = MultiSetUtils.synchronizedMultiSet(new HashMultiSet()); + * ... + * synchronized(multiset) { + * Iterator i = multiset.iterator(); // Must be in synchronized bloc
svn commit: r1714463 - /commons/proper/collections/trunk/src/changes/changes.xml
Author: tn Date: Sun Nov 15 15:08:39 2015 New Revision: 1714463 URL: http://svn.apache.org/viewvc?rev=1714463=rev Log: Added changelog entry. Modified: commons/proper/collections/trunk/src/changes/changes.xml Modified: commons/proper/collections/trunk/src/changes/changes.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/changes/changes.xml?rev=1714463=1714462=1714463=diff == --- commons/proper/collections/trunk/src/changes/changes.xml (original) +++ commons/proper/collections/trunk/src/changes/changes.xml Sun Nov 15 15:08:39 2015 @@ -34,6 +34,11 @@ only Collection classes are allowed, otherwise an UnsupportedOperationException will be thrown during de-serialization. + + Added new MultiSet interface which is intended to be a replacement for + the Bag interface. The main difference is that a MultiSet is fully compatible + to the Collection contract. + Subclasses of MultiKey did not re-calculate their hashcode after de-serialization.
svn commit: r1714462 - in /commons/proper/collections/trunk/src: main/java/org/apache/commons/collections4/multiset/ test/java/org/apache/commons/collections4/multiset/ test/resources/data/test/
Author: tn Date: Sun Nov 15 15:04:19 2015 New Revision: 1714462 URL: http://svn.apache.org/viewvc?rev=1714462=rev Log: [COLLECTIONS-567] Add missing unit tests, fix problems with remove method. Added: commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multiset/HashMultiSetTest.java (with props) commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multiset/PredicatedMultiSetTest.java (with props) commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multiset/SynchronizedMultiSetTest.java (with props) commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multiset/UnmodifiableMultiSetTest.java (with props) commons/proper/collections/trunk/src/test/resources/data/test/HashMultiSet.emptyCollection.version4.1.obj (with props) commons/proper/collections/trunk/src/test/resources/data/test/HashMultiSet.fullCollection.version4.1.obj (with props) commons/proper/collections/trunk/src/test/resources/data/test/PredicatedMultiSet.emptyCollection.version4.1.obj (with props) commons/proper/collections/trunk/src/test/resources/data/test/PredicatedMultiSet.fullCollection.version4.1.obj (with props) commons/proper/collections/trunk/src/test/resources/data/test/SynchronizedMultiSet.emptyCollection.version4.1.obj (with props) commons/proper/collections/trunk/src/test/resources/data/test/SynchronizedMultiSet.fullCollection.version4.1.obj (with props) commons/proper/collections/trunk/src/test/resources/data/test/UnmodifiableMultiSet.emptyCollection.version4.1.obj (with props) commons/proper/collections/trunk/src/test/resources/data/test/UnmodifiableMultiSet.fullCollection.version4.1.obj (with props) Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multiset/AbstractMultiSetTest.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java?rev=1714462=1714461=1714462=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/multiset/AbstractMapMultiSet.java Sun Nov 15 15:04:19 2015 @@ -267,14 +267,7 @@ public abstract class AbstractMapMultiSe @Override public boolean remove(final Object object) { -final MutableInteger mut = map.get(object); -if (mut == null) { -return false; -} -modCount++; -map.remove(object); -size -= mut.value; -return true; +return remove(object, 1) != 0; } @Override Modified: commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multiset/AbstractMultiSetTest.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multiset/AbstractMultiSetTest.java?rev=1714462=1714461=1714462=diff == --- commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multiset/AbstractMultiSetTest.java (original) +++ commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multiset/AbstractMultiSetTest.java Sun Nov 15 15:04:19 2015 @@ -28,7 +28,6 @@ import java.util.List; import java.util.NoSuchElementException; import java.util.Set; -import org.apache.commons.collections4.Bag; import org.apache.commons.collections4.BulkTest; import org.apache.commons.collections4.MultiSet; import org.apache.commons.collections4.collection.AbstractCollectionTest; @@ -41,19 +40,20 @@ import org.apache.commons.collections4.s * To use, simply extend this class, and implement * the {@link #makeObject} method. * - * If your bag fails one of these tests by design, + * If your multiset fails one of these tests by design, * you may still use this base set of cases. Simply override the - * test case (method) your bag fails. + * test case (method) your multiset fails. * - * This abstract test class does wrap the concrete bag implementation + * This abstract test class does wrap the concrete multiset implementation * with such a decorator, see the overridden {@link #resetEmpty()} and * {@link #resetFull()} methods. * * In addition to the generic collection tests (prefix testCollection) inherited - * from AbstractCollectionTest, there are test methods that test the "normal" Bag - * interface (prefix testBag
svn commit: r1714464 - /commons/proper/collections/trunk/src/changes/changes.xml
Author: tn Date: Sun Nov 15 15:13:13 2015 New Revision: 1714464 URL: http://svn.apache.org/viewvc?rev=1714464=rev Log: Add changelog entry for COLLECTIONS-551. Modified: commons/proper/collections/trunk/src/changes/changes.xml Modified: commons/proper/collections/trunk/src/changes/changes.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/changes/changes.xml?rev=1714464=1714463=1714464=diff == --- commons/proper/collections/trunk/src/changes/changes.xml (original) +++ commons/proper/collections/trunk/src/changes/changes.xml Sun Nov 15 15:13:13 2015 @@ -22,6 +22,10 @@ + + Deprecated various method in "CollectionUtils" in favor of similar + methods in the newly introduced "IterableUtils". + Serialization support for unsafe classes in the functor package has been removed as this can be exploited for remote code execution
svn commit: r1714484 - /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/collection/PredicatedCollection.java
Author: tn Date: Sun Nov 15 18:20:41 2015 New Revision: 1714484 URL: http://svn.apache.org/viewvc?rev=1714484=rev Log: Fix javadoc. Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/collection/PredicatedCollection.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/collection/PredicatedCollection.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/collection/PredicatedCollection.java?rev=1714484=1714483=1714484=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/collection/PredicatedCollection.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/collection/PredicatedCollection.java Sun Nov 15 18:20:41 2015 @@ -349,7 +349,7 @@ public class PredicatedCollection ext * The builder is not modified by this method, so it is possible to create more collections * or add more elements afterwards. Further changes will not propagate to the returned multiset. * - * @param bag the multiset to decorate, must not be null + * @param multiset the multiset to decorate, must not be null * @return the decorated multiset. * @throws NullPointerException if multiset is null * @throws IllegalArgumentException if multiset contains invalid elements
svn commit: r1714322 - /commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMapTest.java
Author: tn Date: Sat Nov 14 13:38:05 2015 New Revision: 1714322 URL: http://svn.apache.org/viewvc?rev=1714322=rev Log: Temporarily disable tests for new multi-valued maps wrt serialization until support is restored. Modified: commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMapTest.java Modified: commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMapTest.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMapTest.java?rev=1714322=1714321=1714322=diff == --- commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMapTest.java (original) +++ commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/multimap/AbstractMultiValuedMapTest.java Sat Nov 14 13:38:05 2015 @@ -104,6 +104,12 @@ public abstract class AbstractMultiValue return true; } +// FIXME: tests ignore to fix serialization issues +@Override +public boolean isTestSerialization() { +return false; +} + /** * Returns the set of keys in the mappings used to test the map. This method * must return an array with the same length as {@link #getSampleValues()} @@ -756,15 +762,17 @@ public abstract class AbstractMultiValue // extend the AbstractTestMap // --- -public void testEmptyMapCompatibility() throws Exception { +// FIXME: tests ignore to fix serialization issues +public void xtestEmptyMapCompatibility() throws Exception { final MultiValuedMap map = makeObject(); final MultiValuedMap map2 = (MultiValuedMap) readExternalFormFromDisk(getCanonicalEmptyCollectionName(map)); assertEquals("Map is empty", 0, map2.size()); } +// FIXME: tests ignore to fix serialization issues @SuppressWarnings({ "rawtypes", "unchecked" }) -public void testFullMapCompatibility() throws Exception { +public void xtestFullMapCompatibility() throws Exception { final MultiValuedMap map = makeFullMap(); final MultiValuedMap map2 = (MultiValuedMap) readExternalFormFromDisk(getCanonicalFullCollectionName(map));
svn commit: r1714319 - in /commons/proper/collections/trunk/src/site: site.xml xdoc/download_collections.xml xdoc/history.xml xdoc/index.xml xdoc/release_3_2_2.xml
Author: tn Date: Sat Nov 14 13:37:02 2015 New Revision: 1714319 URL: http://svn.apache.org/viewvc?rev=1714319=rev Log: Update site for latest 3.2.2 release. Added: commons/proper/collections/trunk/src/site/xdoc/release_3_2_2.xml (with props) Modified: commons/proper/collections/trunk/src/site/site.xml commons/proper/collections/trunk/src/site/xdoc/download_collections.xml commons/proper/collections/trunk/src/site/xdoc/history.xml commons/proper/collections/trunk/src/site/xdoc/index.xml Modified: commons/proper/collections/trunk/src/site/site.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/site.xml?rev=1714319=1714318=1714319=diff == --- commons/proper/collections/trunk/src/site/site.xml (original) +++ commons/proper/collections/trunk/src/site/site.xml Sat Nov 14 13:37:02 2015 @@ -29,8 +29,9 @@ - - + + + Modified: commons/proper/collections/trunk/src/site/xdoc/download_collections.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/download_collections.xml?rev=1714319=1714318=1714319=diff == --- commons/proper/collections/trunk/src/site/xdoc/download_collections.xml (original) +++ commons/proper/collections/trunk/src/site/xdoc/download_collections.xml Sat Nov 14 13:37:02 2015 @@ -125,32 +125,32 @@ limitations under the License. - + - commons-collections-3.2.1-bin.tar.gz - http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.1-bin.tar.gz.md5;>md5 - http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.1-bin.tar.gz.asc;>pgp + commons-collections-3.2.2-bin.tar.gz + http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.md5;>md5 + http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.asc;>pgp - commons-collections-3.2.1-bin.zip - http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.1-bin.zip.md5;>md5 - http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.1-bin.zip.asc;>pgp + commons-collections-3.2.2-bin.zip + http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.2-bin.zip.md5;>md5 + http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.2-bin.zip.asc;>pgp - commons-collections-3.2.1-src.tar.gz - http://www.apache.org/dist/commons/collections/source/commons-collections-3.2.1-src.tar.gz.md5;>md5 - http://www.apache.org/dist/commons/collections/source/commons-collections-3.2.1-src.tar.gz.asc;>pgp + commons-collections-3.2.2-src.tar.gz + http://www.apache.org/dist/commons/collections/source/commons-collections-3.2.2-src.tar.gz.md5;>md5 + http://www.apache.org/dist/commons/collections/source/commons-collections-3.2.2-src.tar.gz.asc;>pgp - commons-collections-3.2.1-src.zip - http://www.apache.org/dist/commons/collections/source/commons-collections-3.2.1-src.zip.md5;>md5 - http://www.apache.org/dist/commons/collections/source/commons-collections-3.2.1-src.zip.asc;>pgp + commons-collections-3.2.2-src.zip + http://www.apache.org/dist/commons/collections/source/commons-collections-3.2.2-src.zip.md5;>md5 + http://www.apache.org/dist/commons/collections/source/commons-collections-3.2.2-src.zip.asc;>pgp Modified: commons/proper/collections/trunk/src/site/xdoc/history.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/history.xml?rev=1714319=1714318=1714319=diff == --- commons/proper/collections/trunk/src/site/xdoc/history.xml (original) +++ commons/proper/collections/trunk/src/site/xdoc/history.xml Sat Nov 14 13:37:02 2015 @@ -105,6 +105,14 @@ Notably MultiValueMap is a new more flex +Collections 3.2.2 Serialization support for unsafe classes in the functor package is disabled by default as +this can be exploited for remote code execution attacks. To re-enable the feature the system property +"org.apache.commons.collections.enableUnsafeSerialization" needs to be set to "true". Classes considered to be +unsafe are: Clone
svn commit: r1714320 - /commons/proper/collections/trunk/doap_collections.rdf
Author: tn Date: Sat Nov 14 13:37:20 2015 New Revision: 1714320 URL: http://svn.apache.org/viewvc?rev=1714320=rev Log: Update doap file with latest release information. Modified: commons/proper/collections/trunk/doap_collections.rdf Modified: commons/proper/collections/trunk/doap_collections.rdf URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/doap_collections.rdf?rev=1714320=1714319=1714320=diff == --- commons/proper/collections/trunk/doap_collections.rdf (original) +++ commons/proper/collections/trunk/doap_collections.rdf Sat Nov 14 13:37:20 2015 @@ -43,6 +43,13 @@ commons-collections +2015-11-14 +3.2.2 + + + + +commons-collections 2008-04-15 3.2.1
svn commit: r1714321 - /commons/proper/collections/trunk/pom.xml
Author: tn Date: Sat Nov 14 13:37:36 2015 New Revision: 1714321 URL: http://svn.apache.org/viewvc?rev=1714321=rev Log: Update pom with latest release. Modified: commons/proper/collections/trunk/pom.xml Modified: commons/proper/collections/trunk/pom.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/pom.xml?rev=1714321=1714320=1714321=diff == --- commons/proper/collections/trunk/pom.xml (original) +++ commons/proper/collections/trunk/pom.xml Sat Nov 14 13:37:36 2015 @@ -483,15 +483,15 @@ (Java 5.0+) -3.2.1 -(Requires Java 1.2 or later) +3.2.2 +(Requires Java 1.3 or later) commons-collections-${commons.release.2.version} COLLECTIONS 12310465 -RC5 +RC1 2.9.1 collections
svn commit: r11174 - in /release/commons/collections: RELEASE-NOTES-3.2.2.txt RELEASE-NOTES.txt
Author: tn Date: Sat Nov 14 13:20:42 2015 New Revision: 11174 Log: Restore 4.0 release notes, add release notes for 3.2.2. Added: release/commons/collections/RELEASE-NOTES-3.2.2.txt (with props) Modified: release/commons/collections/RELEASE-NOTES.txt Added: release/commons/collections/RELEASE-NOTES-3.2.2.txt == --- release/commons/collections/RELEASE-NOTES-3.2.2.txt (added) +++ release/commons/collections/RELEASE-NOTES-3.2.2.txt Sat Nov 14 13:20:42 2015 @@ -0,0 +1,71 @@ + Apache Commons Collections +Version 3.2.2 +RELEASE NOTES + + +INTRODUCTION: + +Commons collections is a project to develop and maintain collection classes +based on and inspired by the JDK collection framework. +This release is JDK1.3 compatible, and does not use JDK1.5 generics. + +This v3.2.2 release is a bugfix release, fixing several bugs present in the previous +releases of the 3.2 branch. Additionally, this release provides a mitigation for a +known remote code exploitation via the standard java object serialization mechanism. +By default, serialization support for unsafe classes in the functor package is +disabled and will result in an exception when either trying to serialize or de-serialize +an instance of these classes. For more details, please refer to COLLECTIONS-580. + +All users are strongly encouraged to updated to this release. + + +Changes in this version include: + +CHANGES +=== + +o COLLECTIONS-580: Serialization support for unsafe classes in the functor package is +disabled by default as this can be exploited for remote code execution +attacks. To re-enable the feature the system property +"org.apache.commons.collections.enableUnsafeSerialization" needs to be +set to "true". +Classes considered to be unsafe are: CloneTransformer, ForClosure, +InstantiateFactory, InstantiateTransformer, InvokerTransformer, +PrototypeCloneFactory, PrototypeSerializationFactory, WhileClosure. + +BUGFIXES + + +o COLLECTIONS-538: "ExtendedProperties" will now use a privileged action to access the +"file.separator" system property. In case the class does not have +permission to read system properties, the "File#separator" field will +be used instead. Thanks to Trejkaz. +o COLLECTIONS-447: Tree traversal with a TreeListIterator will not be affected anymore by +the removal of an element directly after a call to previous(). Thanks to Jeffrey Barnes. +o COLLECTIONS-444: SetUniqueList.set(int, Object) now works correctly if the object to be inserted +is already placed at the given position. Thanks to Thomas Vahrst, John Vasileff. +o COLLECTIONS-350: Removed debug output in "MapUtils#getNumber(Map)". Thanks to Michael Akerman. +o COLLECTIONS-335: Fixed cache assignment for "TreeBidiMap#entrySet". Thanks to sebb. +o COLLECTIONS-334: Synchronized access to lock in "StaticBucketMap#size()". Thanks to sebb. +o COLLECTIONS-307: "SetUniqueList#subList()#contains(Object)" will now correctly check the subList +rather than the parent list. Thanks to Christian Semrau. +o COLLECTIONS-304: "SetUniqueList#set(int, Object)" will now correctly enforce the uniqueness constraint. +Thanks to Rafa? Figas,Bjorn Townsend. +o COLLECTIONS-294: "CaseInsensitiveMap" will now convert input strings to lower-case in a +locale-independent manner. Thanks to Benjamin Bentmann. +o COLLECTIONS-266: "MultiKey" will now be correctly serialized/de-serialized. Thanks to Joerg Schaible. +o COLLECTIONS-261: "Flat3Map#remove(Object)" will now return the correct value mapped to the removed key +if the size of the map is less or equal 3. Thanks to ori. +o COLLECTIONS-249: "SetUniqueList.addAll(int, Collection)" now correctly add the collection at the +provided index. Thanks to Joe Kelly. +o COLLECTIONS-228: "MultiValueMap#put(Object, Object)" and "MultiValueMap#putAll(Object, Collection)" +now correctly return if the map has changed by this operation. +o COLLECTIONS-219: "CollectionUtils#removeAll" wrongly called "ListUtils#retainAll". Thanks to Tom Leccese. +o COLLECTIONS-217: Calling "setValue(Object)" on any Entry returned by a "Flat3Map" will now +correctly set the value for the current entry. Thanks to Matt Bishop. + + +For complete information on Apache Commons Collections, including instructions
svn commit: r1714323 - /commons/proper/collections/tags/COLLECTIONS_3_2_2/
Author: tn Date: Sat Nov 14 13:42:27 2015 New Revision: 1714323 URL: http://svn.apache.org/viewvc?rev=1714323=rev Log: RC3 becomes the official Commons Collections 3.2.2 version. Added: commons/proper/collections/tags/COLLECTIONS_3_2_2/ - copied from r1714322, commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/
svn commit: r1714318 - in /commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4: FactoryUtilsTest.java TransformerUtilsTest.java
Author: tn Date: Sat Nov 14 13:24:24 2015 New Revision: 1714318 URL: http://svn.apache.org/viewvc?rev=1714318=rev Log: [COLLECTIONS-580] Remove serialization tests for classes which are not serializable anymore. Modified: commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/FactoryUtilsTest.java commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/TransformerUtilsTest.java Modified: commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/FactoryUtilsTest.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/FactoryUtilsTest.java?rev=1714318=1714317=1714318=diff == --- commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/FactoryUtilsTest.java (original) +++ commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/FactoryUtilsTest.java Sat Nov 14 13:24:24 2015 @@ -16,14 +16,14 @@ */ package org.apache.commons.collections4; -import static org.junit.Assert.*; +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertNotNull; +import static org.junit.Assert.assertNull; +import static org.junit.Assert.assertSame; +import static org.junit.Assert.assertTrue; +import static org.junit.Assert.fail; -import java.io.ByteArrayInputStream; -import java.io.ByteArrayOutputStream; import java.io.IOException; -import java.io.NotSerializableException; -import java.io.ObjectInputStream; -import java.io.ObjectOutputStream; import java.io.Serializable; import java.util.Date; import java.util.TimeZone; @@ -106,15 +106,6 @@ public class FactoryUtilsTest { final Date created = factory.create(); assertTrue(proto != created); assertEquals(proto, created); - -// check serialisation works -final ByteArrayOutputStream buffer = new ByteArrayOutputStream(); -final ObjectOutputStream out = new ObjectOutputStream(buffer); -out.writeObject(factory); -out.close(); -final ObjectInputStream in = new ObjectInputStream(new ByteArrayInputStream(buffer.toByteArray())); -in.readObject(); -in.close(); } @Test @@ -125,23 +116,6 @@ public class FactoryUtilsTest { final Object created = factory.create(); assertTrue(proto != created); assertEquals(proto, created); - -// check serialisation works -ByteArrayOutputStream buffer = new ByteArrayOutputStream(); -ObjectOutputStream out = new ObjectOutputStream(buffer); -try { -out.writeObject(factory); -} catch (final NotSerializableException ex) { -out.close(); -} -factory = FactoryUtils.prototypeFactory(new Mock2("S")); -buffer = new ByteArrayOutputStream(); -out = new ObjectOutputStream(buffer); -out.writeObject(factory); -out.close(); -final ObjectInputStream in = new ObjectInputStream(new ByteArrayInputStream(buffer.toByteArray())); -in.readObject(); -in.close(); } @Test @@ -152,15 +126,6 @@ public class FactoryUtilsTest { final Integer created = factory.create(); assertTrue(proto != created); assertEquals(proto, created); - -// check serialisation works -final ByteArrayOutputStream buffer = new ByteArrayOutputStream(); -final ObjectOutputStream out = new ObjectOutputStream(buffer); -out.writeObject(factory); -out.close(); -final ObjectInputStream in = new ObjectInputStream(new ByteArrayInputStream(buffer.toByteArray())); -in.readObject(); -in.close(); } @Test Modified: commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/TransformerUtilsTest.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/TransformerUtilsTest.java?rev=1714318=1714317=1714318=diff == --- commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/TransformerUtilsTest.java (original) +++ commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/TransformerUtilsTest.java Sat Nov 14 13:24:24 2015 @@ -16,7 +16,10 @@ */ package org.apache.commons.collections4; -import static org.junit.Assert.*; +import static org.junit.Assert.assertEquals; +import static org.junit.Assert.assertNotNull; +import static org.junit.Assert.assertSame; +import static org.junit.Assert.fail; import java.util.ArrayList; import java.util.Collection; @@ -26,7 +29,6 @@ import java.util.HashMap; import java.util.List; import java.util.Map; -import org.apache.commons.collections4.functors.CloneTransformer; import org.apache.commons.co
svn commit: r1714331 - in /commons/proper/collections/trunk/src/site: site.xml xdoc/release_3_2_2.xml
Author: tn Date: Sat Nov 14 14:16:00 2015 New Revision: 1714331 URL: http://svn.apache.org/viewvc?rev=1714331=rev Log: Update 3.2.2 release notes site + add link to release notes in navigation. Modified: commons/proper/collections/trunk/src/site/site.xml commons/proper/collections/trunk/src/site/xdoc/release_3_2_2.xml Modified: commons/proper/collections/trunk/src/site/site.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/site.xml?rev=1714331=1714330=1714331=diff == --- commons/proper/collections/trunk/src/site/site.xml (original) +++ commons/proper/collections/trunk/src/site/site.xml Sat Nov 14 14:16:00 2015 @@ -29,6 +29,7 @@ + Modified: commons/proper/collections/trunk/src/site/xdoc/release_3_2_2.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/site/xdoc/release_3_2_2.xml?rev=1714331=1714330=1714331=diff == --- commons/proper/collections/trunk/src/site/xdoc/release_3_2_2.xml (original) +++ commons/proper/collections/trunk/src/site/xdoc/release_3_2_2.xml Sat Nov 14 14:16:00 2015 @@ -30,10 +30,18 @@ These are the release notes for Commons Commons collections is a project to develop and maintain collection classes based on and inspired by the JDK collection framework. -This project is JDK 1.2 compatible, and does not use JDK 1.5 generics. +This project is JDK 1.3 compatible, and does not use JDK 1.5 generics. -This v3.2.2 release is a security and bug fix release. +This v3.2.2 release is a bugfix release, fixing several bugs present in the previous +releases of the 3.2 branch. Additionally, this release provides a mitigation for a +known remote code exploitation via the standard java object serialization mechanism. +By default, serialization support for unsafe classes in the functor package is +disabled and will result in an exception when either trying to serialize or de-serialize +an instance of these classes. For more details, please refer to COLLECTIONS-580. + + +All users are strongly encouraged to updated to this release. @@ -42,8 +50,98 @@ This v3.2.2 release is a security and bu This release is fully source and binary compatible with v3.2. For changes since the v3.1 see the v3.2 Release Notes. Note that the method 'protected java.util.Set createSetBasedOnList(java.util.Set, java.util.List)' has been -added +added. + +Changes + + + COLLECTIONS-580 + Serialization support for unsafe classes in the functor package is + disabled by default as this can be exploited for remote code execution + attacks. To re-enable the feature the system property + "org.apache.commons.collections.enableUnsafeSerialization" needs to be set to "true". + Classes considered to be unsafe are: CloneTransformer, ForClosure, + InstantiateFactory, InstantiateTransformer, InvokerTransformer, + PrototypeCloneFactory, PrototypeSerializationFactory, WhileClosure. + + + +Bugfixes + + + COLLECTIONS-538 + "ExtendedProperties" will now use a privileged action to access the "file.separator" system property. + In case the class does not have permission to read system properties, the "File#separator" field will + be used instead. Thanks to Trejkaz. + + + COLLECTIONS-447 + Tree traversal with a TreeListIterator will not be affected anymore by + the removal of an element directly after a call to previous(). Thanks to Jeffrey Barnes. + + + COLLECTIONS-444 + SetUniqueList.set(int, Object) now works correctly if the object to be inserted + is already placed at the given position. Thanks to Thomas Vahrst, John Vasileff. + + + COLLECTIONS-350 + Removed debug output in "MapUtils#getNumber(Map)". Thanks to Michael Akerman. + + + COLLECTIONS-335 + Fixed cache assignment for "TreeBidiMap#entrySet". Thanks to sebb. + + + COLLECTIONS-334 + Synchronized access to lock in "StaticBucketMap#size()". Thanks to sebb. + + + COLLECTIONS-307 + "SetUniqueList#subList()#contains(Object)" will now correctly check the subList + rather than the parent list. Thanks to Christian Semrau. + + + COLLECTIONS-304 + "SetUniqueList#set(int, Object)" will now correctly enforce the uniqueness constraint. + Thanks to Rafa? Figas,Bjorn Townsend. + + + COLLECTIONS-294 + "CaseInsensitiveMap" will now convert input strings to lower-case in a + locale-independent manner. Thanks to Benjamin Bentmann. + + + COLLECTIONS-266 + "MultiKey" will now be correctly serialized/de-serialized. Thanks to Joerg Schaible. + + + COLLECTIONS-261 + "Flat3Map#remove(Object)" will now return the correct value mapped to the removed key + if the size of the map i
svn commit: r11173 - /dev/commons/collections/ /dev/commons/collections/binaries/ /dev/commons/collections/source/ /release/commons/collections/ /release/commons/collections/binaries/ /release/commons
Author: tn Date: Sat Nov 14 13:10:41 2015 New Revision: 11173 Log: Publish commons-collections 3.2.2 Release Added: release/commons/collections/RELEASE-NOTES.txt - copied unchanged from r11172, dev/commons/collections/RELEASE-NOTES.txt release/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz - copied unchanged from r11172, dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz release/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.asc - copied unchanged from r11172, dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.asc release/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.md5 - copied unchanged from r11172, dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.md5 release/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.sha1 - copied unchanged from r11172, dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.sha1 release/commons/collections/binaries/commons-collections-3.2.2-bin.zip - copied unchanged from r11172, dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip release/commons/collections/binaries/commons-collections-3.2.2-bin.zip.asc - copied unchanged from r11172, dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.asc release/commons/collections/binaries/commons-collections-3.2.2-bin.zip.md5 - copied unchanged from r11172, dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.md5 release/commons/collections/binaries/commons-collections-3.2.2-bin.zip.sha1 - copied unchanged from r11172, dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.sha1 release/commons/collections/source/commons-collections-3.2.2-src.tar.gz - copied unchanged from r11172, dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz release/commons/collections/source/commons-collections-3.2.2-src.tar.gz.asc - copied unchanged from r11172, dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz.asc release/commons/collections/source/commons-collections-3.2.2-src.tar.gz.md5 - copied unchanged from r11172, dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz.md5 release/commons/collections/source/commons-collections-3.2.2-src.tar.gz.sha1 - copied unchanged from r11172, dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz.sha1 release/commons/collections/source/commons-collections-3.2.2-src.zip - copied unchanged from r11172, dev/commons/collections/source/commons-collections-3.2.2-src.zip release/commons/collections/source/commons-collections-3.2.2-src.zip.asc - copied unchanged from r11172, dev/commons/collections/source/commons-collections-3.2.2-src.zip.asc release/commons/collections/source/commons-collections-3.2.2-src.zip.md5 - copied unchanged from r11172, dev/commons/collections/source/commons-collections-3.2.2-src.zip.md5 release/commons/collections/source/commons-collections-3.2.2-src.zip.sha1 - copied unchanged from r11172, dev/commons/collections/source/commons-collections-3.2.2-src.zip.sha1 Removed: dev/commons/collections/RELEASE-NOTES.txt dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.asc dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.md5 dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.sha1 dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.asc dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.md5 dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.sha1 dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz.asc dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz.md5 dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz.sha1 dev/commons/collections/source/commons-collections-3.2.2-src.zip dev/commons/collections/source/commons-collections-3.2.2-src.zip.asc dev/commons/collections/source/commons-collections-3.2.2-src.zip.md5 dev/commons/collections/source/commons-collections-3.2.2-src.zip.sha1
svn commit: r1714324 - /commons/proper/collections/branches/COLLECTIONS_3_2_X/pom.xml
Author: tn Date: Sat Nov 14 13:44:07 2015 New Revision: 1714324 URL: http://svn.apache.org/viewvc?rev=1714324=rev Log: Update pom after release in 3_2_X branch. Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/pom.xml Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/pom.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/pom.xml?rev=1714324=1714323=1714324=diff == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/pom.xml (original) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/pom.xml Sat Nov 14 13:44:07 2015 @@ -27,7 +27,7 @@ 4.0.0 commons-collections commons-collections - 3.2.2-SNAPSHOT + 3.2.3-SNAPSHOT Apache Commons Collections 2001
svn commit: r1714360 - in /commons/proper/collections/trunk/src: changes/changes.xml main/java/org/apache/commons/collections4/map/MultiValueMap.java test/java/org/apache/commons/collections4/map/Mult
Author: tn Date: Sat Nov 14 20:24:42 2015 New Revision: 1714360 URL: http://svn.apache.org/viewvc?rev=1714360=rev Log: [COLLECTIONS-580] Add validation to MultiValueMap#ReflectionFactory: only Collection classes are support. Modified: commons/proper/collections/trunk/src/changes/changes.xml commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/MultiValueMap.java commons/proper/collections/trunk/src/test/java/org/apache/commons/collections4/map/MultiValueMapTest.java Modified: commons/proper/collections/trunk/src/changes/changes.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/changes/changes.xml?rev=1714360=1714359=1714360=diff == --- commons/proper/collections/trunk/src/changes/changes.xml (original) +++ commons/proper/collections/trunk/src/changes/changes.xml Sat Nov 14 20:24:42 2015 @@ -29,6 +29,11 @@ ForClosure, InstantiateFactory, InstantiateTransformer, InvokerTransformer, PrototypeCloneFactory, PrototypeSerializationFactory, WhileClosure. + + Added validation when de-serializing a "MultiValueMap#ReflectionFactory": + only Collection classes are allowed, otherwise an UnsupportedOperationException + will be thrown during de-serialization. + Subclasses of MultiKey did not re-calculate their hashcode after de-serialization. Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/MultiValueMap.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/MultiValueMap.java?rev=1714360=1714359=1714360=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/MultiValueMap.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/map/MultiValueMap.java Sat Nov 14 20:24:42 2015 @@ -20,7 +20,6 @@ import java.io.IOException; import java.io.ObjectInputStream; import java.io.ObjectOutputStream; import java.io.Serializable; - import java.util.AbstractCollection; import java.util.ArrayList; import java.util.Collection; @@ -209,6 +208,7 @@ public class MultiValueMap<K, V> extends * @param value the value to remove * @return {@code true} if the mapping was removed, {@code false} otherwise */ +@Override public boolean removeMapping(final Object key, final Object value) { final Collection valuesForKey = getCollection(key); if (valuesForKey == null) { @@ -434,14 +434,18 @@ public class MultiValueMap<K, V> extends } final K key = keyIterator.next(); final Transformer<V, Entry<K, V>> transformer = new Transformer<V, Entry<K, V>>() { +@Override public Entry<K, V> transform(final V input) { return new Entry<K, V>() { +@Override public K getKey() { return key; } +@Override public V getValue() { return input; } +@Override public V setValue(V value) { throw new UnsupportedOperationException(); } @@ -519,6 +523,7 @@ public class MultiValueMap<K, V> extends this.iterator = values.iterator(); } +@Override public void remove() { iterator.remove(); if (values.isEmpty()) { @@ -526,10 +531,12 @@ public class MultiValueMap<K, V> extends } } +@Override public boolean hasNext() { return iterator.hasNext(); } +@Override public V next() { return iterator.next(); } @@ -549,6 +556,7 @@ public class MultiValueMap<K, V> extends this.clazz = clazz; } +@Override public T create() { try { return clazz.newInstance(); @@ -556,6 +564,14 @@ public class MultiValueMap<K, V> extends throw new FunctorException("Cannot instantiate class: " + clazz, ex); } } + +private void readObject(ObjectInputStream is) throws IOException, ClassNotFoundException { +is.defaultReadObject(); +// ensure that the de-serialized class is a Collection, COLLECTIONS-580 +if (clazz != null && !Collection.class.isAssignableFrom(clazz)) { +throw new Unsupport
svn commit: r1714362 - in /commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4: ClosureUtils.java FactoryUtils.java TransformerUtils.java
Author: tn Date: Sat Nov 14 20:38:02 2015 New Revision: 1714362 URL: http://svn.apache.org/viewvc?rev=1714362=rev Log: [COLLECTIONS-580] Clarify class javadoc of utils that only unsafe classes are serializable anymore. Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ClosureUtils.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/FactoryUtils.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/TransformerUtils.java Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ClosureUtils.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ClosureUtils.java?rev=1714362=1714361=1714362=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ClosureUtils.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/ClosureUtils.java Sat Nov 14 20:38:02 2015 @@ -37,7 +37,6 @@ import org.apache.commons.collections4.f * Invoker - invokes a method on the input object * For - repeatedly calls a closure for a fixed number of times * While - repeatedly calls a closure while a predicate is true - * DoWhile - repeatedly calls a closure while a predicate is true * Chained - chains two or more closures together * If - calls one closure or another based on a predicate * Switch - calls one closure based on one or more predicates @@ -46,7 +45,14 @@ import org.apache.commons.collections4.f * NOP - does nothing * Exception - always throws an exception * - * All the supplied closures are Serializable. + * + * Since v4.1 only closures which are considered to be unsafe are + * Serializable. Closures considered to be unsafe for serialization are: + * + * Invoker + * For + * While + * * * @since 3.0 * @version $Id$ Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/FactoryUtils.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/FactoryUtils.java?rev=1714362=1714361=1714362=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/FactoryUtils.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/FactoryUtils.java Sat Nov 14 20:38:02 2015 @@ -26,12 +26,18 @@ import org.apache.commons.collections4.f * for the Factory functor interface. The supplied factories are: * * Prototype - clones a specified object - * Reflection - creates objects using reflection + * Instantiate - creates objects using reflection * Constant - always returns the same object * Null - always returns null * Exception - always throws an exception * - * All the supplied factories are Serializable. + * + * Since v4.1 only factories which are considered to be unsafe are + * Serializable. Factories considered to be unsafe for serialization are: + * + * Prototype + * Instantiate + * * * @since 3.0 * @version $Id$ Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/TransformerUtils.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/TransformerUtils.java?rev=1714362=1714361=1714362=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/TransformerUtils.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/TransformerUtils.java Sat Nov 14 20:38:02 2015 @@ -56,7 +56,14 @@ import org.apache.commons.collections4.f * Exception - always throws an exception * StringValue - returns a java.lang.String representation of the input object * - * All the supplied transformers are Serializable. + * + * Since v4.1 only transformers which are considered to be unsafe are + * Serializable. Transformers considered to be unsafe for serialization are: + * + * Invoker + * Clone + * Instantiate + * * * @since 3.0 * @version $Id$
svn commit: r1714262 - in /commons/proper/collections/trunk/src: changes/ main/java/org/apache/commons/collections4/functors/
Author: tn Date: Fri Nov 13 20:08:45 2015 New Revision: 1714262 URL: http://svn.apache.org/viewvc?rev=1714262=rev Log: [COLLECTIONS-580] Removed serialization support for the identified unsafe classes in the collections4 branch. Modified: commons/proper/collections/trunk/src/changes/changes.xml commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/functors/CloneTransformer.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/functors/ForClosure.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/functors/InstantiateFactory.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/functors/InstantiateTransformer.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/functors/InvokerTransformer.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/functors/PrototypeFactory.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/functors/WhileClosure.java commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/functors/package-info.java Modified: commons/proper/collections/trunk/src/changes/changes.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/changes/changes.xml?rev=1714262=1714261=1714262=diff == --- commons/proper/collections/trunk/src/changes/changes.xml (original) +++ commons/proper/collections/trunk/src/changes/changes.xml Fri Nov 13 20:08:45 2015 @@ -22,6 +22,13 @@ + + Serialization support for unsafe classes in the functor package + has been removed as this can be exploited for remote code execution + attacks. Classes considered to be unsafe are: CloneTransformer, + ForClosure, InstantiateFactory, InstantiateTransformer, InvokerTransformer, + PrototypeCloneFactory, PrototypeSerializationFactory, WhileClosure. + Subclasses of MultiKey did not re-calculate their hashcode after de-serialization. Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/functors/CloneTransformer.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/functors/CloneTransformer.java?rev=1714262=1714261=1714262=diff == --- commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/functors/CloneTransformer.java (original) +++ commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/functors/CloneTransformer.java Fri Nov 13 20:08:45 2015 @@ -16,22 +16,22 @@ */ package org.apache.commons.collections4.functors; -import java.io.Serializable; - import org.apache.commons.collections4.Transformer; /** * Transformer implementation that returns a clone of the input object. * * Clone is performed using PrototypeFactory.prototypeFactory(input).create(). + * + * WARNING: from v4.1 onwards this class will not be serializable anymore + * in order to prevent potential remote code execution exploits. Please refer to + * https://issues.apache.org/jira/browse/COLLECTIONS-580;>COLLECTIONS-580 + * for more details. * * @since 3.0 * @version $Id$ */ -public class CloneTransformer implements Transformer<T, T>, Serializable { - -/** Serial version UID */ -private static final long serialVersionUID = -8188742709499652567L; +public class CloneTransformer implements Transformer<T, T> { /** Singleton predicate instance */ @SuppressWarnings("rawtypes") // the singleton instance works for all types @@ -46,7 +46,7 @@ public class CloneTransformer impleme */ @SuppressWarnings("unchecked") // the singleton instance works for all types public static Transformer<T, T> cloneTransformer() { -return (Transformer<T, T>) INSTANCE; +return INSTANCE; } /** @@ -62,6 +62,7 @@ public class CloneTransformer impleme * @param input the input object to transform * @return the transformed result */ +@Override public T transform(final T input) { if (input == null) { return null; @@ -69,8 +70,4 @@ public class CloneTransformer impleme return PrototypeFactory.prototypeFactory(input).create(); } -private Object readResolve() { -return INSTANCE; -} - } Modified: commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/functors/ForClosure.java URL: http://svn.apache.org/viewvc/commons/proper/collections/trunk/src/main/java/org/apache/commons/collections4/functors/ForClosure.java?rev=1714262=1714261=1714262=diff =
svn commit: r1714131 - in /commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3: ./ build.xml pom.xml xdocs/download_collections.xml xdocs/index.xml
Author: tn Date: Thu Nov 12 22:25:00 2015 New Revision: 1714131 URL: http://svn.apache.org/viewvc?rev=1714131=rev Log: Creating Apache Commons Collections v3.2.2 RC3 tag. Added: commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/ - copied from r1714130, commons/proper/collections/branches/COLLECTIONS_3_2_X/ Modified: commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/build.xml commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/pom.xml commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/xdocs/download_collections.xml commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/xdocs/index.xml Modified: commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/build.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/build.xml?rev=1714131=1714130=1714131=diff == --- commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/build.xml (original) +++ commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/build.xml Thu Nov 12 22:25:00 2015 @@ -36,7 +36,7 @@ - + Modified: commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/pom.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/pom.xml?rev=1714131=1714130=1714131=diff == --- commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/pom.xml (original) +++ commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/pom.xml Thu Nov 12 22:25:00 2015 @@ -27,7 +27,7 @@ 4.0.0 commons-collections commons-collections - 3.2.2-SNAPSHOT + 3.2.2 Apache Commons Collections 2001 @@ -381,8 +381,8 @@ 1.2 1.2 collections -3.2.1 -RC1 +3.2.2 +RC3 -bin COLLECTIONS 12310465 Modified: commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/xdocs/download_collections.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/xdocs/download_collections.xml?rev=1714131=1714130=1714131=diff == --- commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/xdocs/download_collections.xml (original) +++ commons/proper/collections/tags/COLLECTIONS_3_2_2_RC3/xdocs/download_collections.xml Thu Nov 12 22:25:00 2015 @@ -45,15 +45,16 @@ limitations under the License. --> -Download Commons Collections +Download Apache Commons Collections Commons Documentation Team - + + We recommend you use a mirror to download our release builds, but you must verify the integrity of -the downloaded files using signatures downloaded from our main +the downloaded files using signatures downloaded from our main distribution directories. Recent releases (48 hours) may not yet be available from the mirrors. @@ -70,7 +71,7 @@ limitations under the License. - Other mirrors: + Other mirrors: [if-any http] [for http][http][end] @@ -87,59 +88,51 @@ limitations under the License. -The KEYS link links to the code signing keys used to sign the product. -The PGP link downloads the OpenPGP compatible signature from our main site. +The http://www.apache.org/dist/commons/KEYS;>KEYS +link links to the code signing keys used to sign the product. +The PGP link downloads the OpenPGP compatible signature from our main site. The MD5 link downloads the checksum from the main site. - - -For more information concerning Commons Collections, see the -Commons Collections web site. - - - -http://www.apache.org/dist/commons/KEYS;>KEYS - - Binary - - 3.2.1.tar.gz - - [http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.1-bin.tar.gz.md5;>md5] - [http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.1-bin.tar.gz.asc;>pgp] - - - - 3.2.1.zip - - [http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.1-bin.zip.md5;>md5] - [http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.1-bin.zip.asc;>pgp] - - - - - - Source - - 3.2.1.tar.gz - - [http://www.apache.org/dist/commons/collections/source/commons-collections-3.2.1-src.tar.gz.md5;>md5] - [http://www.apache.org/dist/commons/collections/source/commons-collections-3
svn commit: r11167 - in /dev/commons/collections: binaries/ source/
Author: tn Date: Thu Nov 12 23:22:22 2015 New Revision: 11167 Log: Creating distribution files for Commons Collections 3.2.2 RC3 Modified: dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.asc dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.md5 dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.sha1 dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.asc dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.md5 dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.sha1 dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz.asc dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz.md5 dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz.sha1 dev/commons/collections/source/commons-collections-3.2.2-src.zip dev/commons/collections/source/commons-collections-3.2.2-src.zip.asc dev/commons/collections/source/commons-collections-3.2.2-src.zip.md5 dev/commons/collections/source/commons-collections-3.2.2-src.zip.sha1 Modified: dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz == Binary files - no diff available. Modified: dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.asc == --- dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.asc (original) +++ dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.asc Thu Nov 12 23:22:22 2015 @@ -1,17 +1,17 @@ -BEGIN PGP SIGNATURE- Version: GnuPG v1 -iQIcBAABAgAGBQJWQ2NDAAoJEKQfE8mZlFKTQ4AQAI79ewAXeH7vwfKUJMTnXXD2 -TVlGyM8lEjwx4b2QQEO72SVHCQf0YWhVKVDK7rF+quKVGSwAm8zGYccpESgkR/Q3 -IZJMk10MSUzI3v+ndTazC2ocTa5Q7vulBCB/6fztsUDIUbRqiWaEi8CD6eIIbkEI -X6sp+wJj6ZGo2YB5ZM2t4VH6e3uqlLZBXhnhD/h80nG3D6LAXyDj9xWnZfZs6LAG -IPSIn9ZZUHkC8V1HMm+MZivrxenFEGB2CpP8KAOQFmRGpOAELO3cyoPkLDhMFSQH -31eGiQCULnUq038QpE9UWDBe8ldOinilIZi26xw3aUE5hFfaB60L5iYW8/5vReSm -YxgW4u6lPVfP7C+BfCCgN8BQIiznDW+ySs12I8wUhSWay1j72zU6p6CrgGhbKcuT -AfDSXROHkUeiv6pQMR9wFrvK4D60xvjgqXUnisvfh81xjG/U24gJzbtIyZH2ZGv1 -3wZhNeOBOvxPSfoEYihDvrC/PcbAA4ItxAka002LRe2eMgbRMzpyv1ihbqnWS63Q -hLh6XYnmpxLXN0LO7IyrVmBA9chS1TBDWtK0//+dZGf9F03gFO9wwTjxdOZAswG+ -MwFuaU8W1fil8+UWhgJMNyhEWIWkubJXofWi5xaCVN8+O568wwO5GqlYkrAATmZ0 -+zpIv6xPBbqrkgsyYNqb -=91g6 +iQIcBAABAgAGBQJWRRyMAAoJEKQfE8mZlFKTVAYP/imPwO1aaypomIx/HMRCPFHb +vIWtraYSpXRq0Dc0IP8Vcta8gtu9g+/Ojb1zFnZ1boUYld7StvDS8kPE5R7d/hjO +14pQundSAN4bpbB40AyJvRuRunxwFUnjA7Qbc0oDcXCFS3PQg/Ke2QvLAgioTJAW +e3dzELnPx3UZ70b4FKc+Nzv+du1NLjHAEPn9HYbbxxo2mheLIKVzRk8O8rOgOk06 +Lp+B9Uqb/hUQm1MSq387gZmir1Y9rqSJ89Cl4RwLW5YLNdssdVgyZq5a3FXgRY9F +jKCUTHaPyJW9DRbyIJwi+ELuUywDBasrnZVWnSa3JQsb+Y3k6jCnQIrj5YQkalHq +nZqCUubGKLGqNo0+KY5KKJ7IGEVrabb+pyMuec7i3OYCpkR0x0ZvRjkw+GMl073R +bg7ue/srOg76FwaRZof4JITwf1Nj1+SaZUvTveZc0cH29L+QgboT02Z436JrI2wk +NJ1TmHTveWj8/wB7rTGoJRQ/vfD8IUDqxJn9wVtMTgj+ClunFb8EjY5RcYwsHF4O +vJORx+41sImuOAh/LKExSJgx/WDQ72SSermsk/dPoZoaI+clOPMom7SyB2YrZCtd +fRKYsFg6AR3Q9a8w+XbgyWKw9SZ+NbEYho+UPCwbkde8gqU4rLIR+YoNz7MEiIl9 +1IkLDGEdDc2Y/CeU17eU +=X2df -END PGP SIGNATURE- Modified: dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.md5 == --- dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.md5 (original) +++ dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.md5 Thu Nov 12 23:22:22 2015 @@ -1 +1 @@ -da619f64854e44b650d94ed30a144894 \ No newline at end of file +eb44d6f7a7eab30c026f9a6ed7921596 \ No newline at end of file Modified: dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.sha1 == --- dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.sha1 (original) +++ dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.sha1 Thu Nov 12 23:22:22 2015 @@ -1 +1 @@ -4ed4321768e04e83981bef02d0abee0fb4d8355f \ No newline at end of file +c2ac1d9a25563af3b2c221c11d1700ec316f031a \ No newline at end of file Modified: dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip == Binary files - no diff available. Modified: dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.asc == --- dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.asc (original) +++ dev/commons/collections/binaries/commons
svn commit: r1714107 - in /commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections: TestExtendedProperties.java functors/AbstractTestSerialization.java functors/T
Author: tn Date: Thu Nov 12 19:35:51 2015 New Revision: 1714107 URL: http://svn.apache.org/viewvc?rev=1714107=rev Log: Fix test compilation and execution errors. Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/TestExtendedProperties.java commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/AbstractTestSerialization.java commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestPrototypeFactory.java commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/map/TestFlat3Map.java Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/TestExtendedProperties.java URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/TestExtendedProperties.java?rev=1714107=1714106=1714107=diff == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/TestExtendedProperties.java (original) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/TestExtendedProperties.java Thu Nov 12 19:35:51 2015 @@ -319,7 +319,9 @@ public class TestExtendedProperties exte SecurityManager manager = new SecurityManager() { public void checkPropertyAccess(String key) { -throw new SecurityException(); +if ("file.separator".equals(key)) { +throw new SecurityException(); +} } public void checkPermission(Permission perm) { @@ -333,7 +335,6 @@ public class TestExtendedProperties exte ExtendedProperties properties = new ExtendedProperties(); assertNotNull(properties); } catch (Exception ex) { -ex.printStackTrace(); fail("failed to instantiate ExtendedProperties"); } finally { System.setSecurityManager(null); Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/AbstractTestSerialization.java URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/AbstractTestSerialization.java?rev=1714107=1714106=1714107=diff == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/AbstractTestSerialization.java (original) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/AbstractTestSerialization.java Thu Nov 12 19:35:51 2015 @@ -60,7 +60,7 @@ public abstract class AbstractTestSerial //--- public void testSerializationDisabled() throws Exception { - Assert.assertNull(System.getProperty(FunctorUtils.UNSAFE_SERIALIZABLE_PROPERTY)); + Assert.assertFalse("true".equalsIgnoreCase(System.getProperty(FunctorUtils.UNSAFE_SERIALIZABLE_PROPERTY))); Object object = makeObject(); try { serialize(object); @@ -82,7 +82,7 @@ public abstract class AbstractTestSerial } public void testSerializationEnabled() throws Exception { - Assert.assertNull(System.getProperty(FunctorUtils.UNSAFE_SERIALIZABLE_PROPERTY)); + Assert.assertFalse("true".equalsIgnoreCase(System.getProperty(FunctorUtils.UNSAFE_SERIALIZABLE_PROPERTY))); System.setProperty(FunctorUtils.UNSAFE_SERIALIZABLE_PROPERTY, "true"); try { @@ -96,7 +96,7 @@ public abstract class AbstractTestSerial fail("de-serialization of " + getTestClass().getName() + " should be enabled"); } } finally { -System.clearProperty(FunctorUtils.UNSAFE_SERIALIZABLE_PROPERTY); +System.setProperty(FunctorUtils.UNSAFE_SERIALIZABLE_PROPERTY, "false"); } } Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestPrototypeFactory.java URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestPrototypeFactory.java?rev=1714107=1714106=1714107=diff == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestPrototypeFactory.java (original) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collect
svn commit: r1713796 - /commons/proper/collections/branches/COLLECTIONS_3_2_X/xdocs/style/
Author: tn Date: Wed Nov 11 10:06:26 2015 New Revision: 1713796 URL: http://svn.apache.org/viewvc?rev=1713796=rev Log: Remove obsolete style. Removed: commons/proper/collections/branches/COLLECTIONS_3_2_X/xdocs/style/
svn commit: r1713798 - /commons/proper/collections/branches/COLLECTIONS_3_2_X/pom.xml
Author: tn Date: Wed Nov 11 10:16:39 2015 New Revision: 1713798 URL: http://svn.apache.org/viewvc?rev=1713798=rev Log: Add rat plugin ignores for test data. Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/pom.xml Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/pom.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/pom.xml?rev=1713798=1713797=1713798=diff == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/pom.xml (original) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/pom.xml Wed Nov 11 10:16:39 2015 @@ -382,6 +382,7 @@ 1.2 collections 3.2.1 +RC1 -bin COLLECTIONS 12310465 @@ -390,49 +391,64 @@ src/java src/test - - - org.apache.maven.plugins - maven-surefire-plugin - - - org/apache/commons/collections/TestAllPackages.java - - - - - maven-antrun-plugin - - - package - - - - - - - - - - - - -run - - - - - - maven-assembly-plugin + + +org.apache.maven.plugins +maven-surefire-plugin - - src/assembly/bin.xml - src/assembly/src.xml - -gnu - - - - + + org/apache/commons/collections/TestAllPackages.java + + + + +maven-antrun-plugin + + +package + + + + + + + + + + + + + run + + + + + +maven-assembly-plugin + + +src/assembly/bin.xml +src/assembly/src.xml + + gnu + + + + + + + + +org.apache.rat +apache-rat-plugin + + +src/test/resources/data/test/* +maven-eclipse.xml + + + + +
svn commit: r1713850 - in /commons/proper/collections/branches/COLLECTIONS_3_2_X: RELEASE-NOTES.txt src/changes/changes.xml
Author: tn Date: Wed Nov 11 14:29:18 2015 New Revision: 1713850 URL: http://svn.apache.org/viewvc?rev=1713850=rev Log: Update Release Notes with details about improved fix for COLLECTIONS-580. Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/RELEASE-NOTES.txt commons/proper/collections/branches/COLLECTIONS_3_2_X/src/changes/changes.xml Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/RELEASE-NOTES.txt URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/RELEASE-NOTES.txt?rev=1713850=1713849=1713850=diff == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/RELEASE-NOTES.txt (original) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/RELEASE-NOTES.txt Wed Nov 11 14:29:18 2015 @@ -12,8 +12,9 @@ This release is JDK1.3 compatible, and d This v3.2.2 release is a bugfix release, fixing several bugs present in the previous releases of the 3.2 branch. Additionally, this release provides a mitigation for a known remote code exploitation via the standard java object serialization mechanism. -By default, de-serialization of "InvokerTransformer" instances is prohibited and -will result in an exception. For more details, please refer to COLLECTIONS-580. +By default, serialization support for unsafe classes in the functor package is +disabled and will result in an exception when either trying to serialize or de-serialize +an instance of these classes. For more details, please refer to COLLECTIONS-580. All users are strongly encouraged to updated to this release. @@ -23,11 +24,14 @@ Changes in this version include: CHANGES === -o COLLECTIONS-580: De-serialization of "InvokerTransformer" is disabled by default as this -can be exploited for remote code execution attacks. To re-enable the -feature the system property - "org.apache.commons.collections.invokertransformer.enableDeserialization" -needs to be set to "true". +o COLLECTIONS-580: Serialization support for unsafe classes in the functor package is +disabled by default as this can be exploited for remote code execution +attacks. To re-enable the feature the system property +"org.apache.commons.collections.enableUnsafeSerialization" needs to be +set to "true". +Classes considered to be unsafe are: CloneTransformer, ForClosure, +InstantiateFactory, InstantiateTransformer, InvokerTransformer, +PrototypeCloneFactory, PrototypeSerializationFactory, WhileClosure. BUGFIXES Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/changes/changes.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/src/changes/changes.xml?rev=1713850=1713849=1713850=diff == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/src/changes/changes.xml (original) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/src/changes/changes.xml Wed Nov 11 14:29:18 2015 @@ -21,12 +21,15 @@ - + - De-serialization of "InvokerTransformer" is disabled by default as this - can be exploited for remote code execution attacks. To re-enable the - feature the system property "org.apache.commons.collections.invokertransformer.enableDeserialization" + Serialization support for unsafe classes in the functor package is disabled + by default as this can be exploited for remote code execution attacks. + To re-enable the feature the system property "org.apache.commons.collections.enableUnsafeSerialization" needs to be set to "true". + Classes considered to be unsafe are: CloneTransformer, ForClosure, InstantiateFactory, + InstantiateTransformer, InvokerTransformer, PrototypeCloneFactory, + PrototypeSerializationFactory, WhileClosure. "ExtendedProperties" will now use a privileged action to access the
svn commit: r1713879 - in /commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2: ./ build.xml pom.xml xdocs/download_collections.xml xdocs/index.xml
Author: tn Date: Wed Nov 11 15:46:25 2015 New Revision: 1713879 URL: http://svn.apache.org/viewvc?rev=1713879=rev Log: Creating Apache Commons Collections v3.2.2 RC2 tag. Added: commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/ - copied from r1713878, commons/proper/collections/branches/COLLECTIONS_3_2_X/ Modified: commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/build.xml commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/pom.xml commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/xdocs/download_collections.xml commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/xdocs/index.xml Modified: commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/build.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/build.xml?rev=1713879=1713878=1713879=diff == --- commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/build.xml (original) +++ commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/build.xml Wed Nov 11 15:46:25 2015 @@ -36,7 +36,7 @@ - + Modified: commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/pom.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/pom.xml?rev=1713879=1713878=1713879=diff == --- commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/pom.xml (original) +++ commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/pom.xml Wed Nov 11 15:46:25 2015 @@ -27,7 +27,7 @@ 4.0.0 commons-collections commons-collections - 3.2.2-SNAPSHOT + 3.2.2 Apache Commons Collections 2001 @@ -381,8 +381,8 @@ 1.2 1.2 collections -3.2.1 -RC1 +3.2.2 +RC2 -bin COLLECTIONS 12310465 Modified: commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/xdocs/download_collections.xml URL: http://svn.apache.org/viewvc/commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/xdocs/download_collections.xml?rev=1713879=1713878=1713879=diff == --- commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/xdocs/download_collections.xml (original) +++ commons/proper/collections/tags/COLLECTIONS_3_2_2_RC2/xdocs/download_collections.xml Wed Nov 11 15:46:25 2015 @@ -45,15 +45,16 @@ limitations under the License. --> -Download Commons Collections +Download Apache Commons Collections Commons Documentation Team - + + We recommend you use a mirror to download our release builds, but you must verify the integrity of -the downloaded files using signatures downloaded from our main +the downloaded files using signatures downloaded from our main distribution directories. Recent releases (48 hours) may not yet be available from the mirrors. @@ -70,7 +71,7 @@ limitations under the License. - Other mirrors: + Other mirrors: [if-any http] [for http][http][end] @@ -87,59 +88,51 @@ limitations under the License. -The KEYS link links to the code signing keys used to sign the product. -The PGP link downloads the OpenPGP compatible signature from our main site. +The http://www.apache.org/dist/commons/KEYS;>KEYS +link links to the code signing keys used to sign the product. +The PGP link downloads the OpenPGP compatible signature from our main site. The MD5 link downloads the checksum from the main site. - - -For more information concerning Commons Collections, see the -Commons Collections web site. - - - -http://www.apache.org/dist/commons/KEYS;>KEYS - - Binary - - 3.2.1.tar.gz - - [http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.1-bin.tar.gz.md5;>md5] - [http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.1-bin.tar.gz.asc;>pgp] - - - - 3.2.1.zip - - [http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.1-bin.zip.md5;>md5] - [http://www.apache.org/dist/commons/collections/binaries/commons-collections-3.2.1-bin.zip.asc;>pgp] - - - - - - Source - - 3.2.1.tar.gz - - [http://www.apache.org/dist/commons/collections/source/commons-collections-3.2.1-src.tar.gz.md5;>md5] - [http://www.apache.org/dist/commons/collections/source/commons-collections-3
svn commit: r1713854 - in /commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections: TestFactoryUtils.java functors/TestPrototypeFactory.java
Author: tn Date: Wed Nov 11 14:40:21 2015 New Revision: 1713854 URL: http://svn.apache.org/viewvc?rev=1713854=rev Log: Move PrototypeFactory tests to new TestPrototypeFactory test. Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/TestFactoryUtils.java commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestPrototypeFactory.java Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/TestFactoryUtils.java URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/TestFactoryUtils.java?rev=1713854=1713853=1713854=diff == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/TestFactoryUtils.java (original) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/TestFactoryUtils.java Wed Nov 11 14:40:21 2015 @@ -129,68 +129,6 @@ public class TestFactoryUtils extends ju assertSame(ConstantFactory.NULL_INSTANCE, FactoryUtils.prototypeFactory(null)); } -public void testPrototypeFactoryPublicCloneMethod() throws Exception { -Date proto = new Date(); -Factory factory = FactoryUtils.prototypeFactory(proto); -assertNotNull(factory); -Object created = factory.create(); -assertTrue(proto != created); -assertEquals(proto, created); - -// check serialisation works -ByteArrayOutputStream buffer = new ByteArrayOutputStream(); -ObjectOutputStream out = new ObjectOutputStream(buffer); -out.writeObject(factory); -out.close(); -ObjectInputStream in = new ObjectInputStream(new ByteArrayInputStream(buffer.toByteArray())); -Object dest = in.readObject(); -in.close(); -} - -public void testPrototypeFactoryPublicCopyConstructor() throws Exception { -Mock1 proto = new Mock1(6); -Factory factory = FactoryUtils.prototypeFactory(proto); -assertNotNull(factory); -Object created = factory.create(); -assertTrue(proto != created); -assertEquals(proto, created); - -// check serialisation works -ByteArrayOutputStream buffer = new ByteArrayOutputStream(); -ObjectOutputStream out = new ObjectOutputStream(buffer); -try { -out.writeObject(factory); -} catch (NotSerializableException ex) { -out.close(); -} -factory = FactoryUtils.prototypeFactory(new Mock2("S")); -buffer = new ByteArrayOutputStream(); -out = new ObjectOutputStream(buffer); -out.writeObject(factory); -out.close(); -ObjectInputStream in = new ObjectInputStream(new ByteArrayInputStream(buffer.toByteArray())); -Object dest = in.readObject(); -in.close(); -} - -public void testPrototypeFactoryPublicSerialization() throws Exception { -Integer proto = new Integer(9); -Factory factory = FactoryUtils.prototypeFactory(proto); -assertNotNull(factory); -Object created = factory.create(); -assertTrue(proto != created); -assertEquals(proto, created); - -// check serialisation works -ByteArrayOutputStream buffer = new ByteArrayOutputStream(); -ObjectOutputStream out = new ObjectOutputStream(buffer); -out.writeObject(factory); -out.close(); -ObjectInputStream in = new ObjectInputStream(new ByteArrayInputStream(buffer.toByteArray())); -Object dest = in.readObject(); -in.close(); -} - public void testPrototypeFactoryPublicSerializationError() { Mock2 proto = new Mock2(new Object()); Factory factory = FactoryUtils.prototypeFactory(proto); Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestPrototypeFactory.java URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestPrototypeFactory.java?rev=1713854=1713853=1713854=diff == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestPrototypeFactory.java (original) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestPrototypeFactory.java Wed Nov 11 14:40:21 2015 @@ -16,9 +16,17 @@ */ package org.apache.commons.collections.functors; +import java.io.ByteArrayInputStream; +import java.io.ByteArrayOutputStream; +import java.io.NotSerializableException; +import java.io.ObjectInputStream; +import java.io.ObjectOu
svn commit: r11147 - in /dev/commons/collections: ./ binaries/ source/
Author: tn Date: Wed Nov 11 16:06:45 2015 New Revision: 11147 Log: Creating distribution files for Commons Collections 3.2.2 based on RC2. Modified: dev/commons/collections/RELEASE-NOTES.txt dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.asc dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.md5 dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.sha1 dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.asc dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.md5 dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.sha1 dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz.asc dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz.md5 dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz.sha1 dev/commons/collections/source/commons-collections-3.2.2-src.zip dev/commons/collections/source/commons-collections-3.2.2-src.zip.asc dev/commons/collections/source/commons-collections-3.2.2-src.zip.md5 dev/commons/collections/source/commons-collections-3.2.2-src.zip.sha1 Modified: dev/commons/collections/RELEASE-NOTES.txt == --- dev/commons/collections/RELEASE-NOTES.txt (original) +++ dev/commons/collections/RELEASE-NOTES.txt Wed Nov 11 16:06:45 2015 @@ -12,8 +12,9 @@ This release is JDK1.3 compatible, and d This v3.2.2 release is a bugfix release, fixing several bugs present in the previous releases of the 3.2 branch. Additionally, this release provides a mitigation for a known remote code exploitation via the standard java object serialization mechanism. -By default, de-serialization of "InvokerTransformer" instances is prohibited and -will result in an exception. For more details, please refer to COLLECTIONS-580. +By default, serialization support for unsafe classes in the functor package is +disabled and will result in an exception when either trying to serialize or de-serialize +an instance of these classes. For more details, please refer to COLLECTIONS-580. All users are strongly encouraged to updated to this release. @@ -23,11 +24,14 @@ Changes in this version include: CHANGES === -o COLLECTIONS-580: De-serialization of "InvokerTransformer" is disabled by default as this -can be exploited for remote code execution attacks. To re-enable the -feature the system property - "org.apache.commons.collections.invokertransformer.enableDeserialization" -needs to be set to "true". +o COLLECTIONS-580: Serialization support for unsafe classes in the functor package is +disabled by default as this can be exploited for remote code execution +attacks. To re-enable the feature the system property +"org.apache.commons.collections.enableUnsafeSerialization" needs to be +set to "true". +Classes considered to be unsafe are: CloneTransformer, ForClosure, +InstantiateFactory, InstantiateTransformer, InvokerTransformer, +PrototypeCloneFactory, PrototypeSerializationFactory, WhileClosure. BUGFIXES Modified: dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz == Binary files - no diff available. Modified: dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.asc == --- dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.asc (original) +++ dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.asc Wed Nov 11 16:06:45 2015 @@ -1,17 +1,17 @@ -BEGIN PGP SIGNATURE- Version: GnuPG v1 -iQIcBAABAgAGBQJWQRizAAoJEKQfE8mZlFKTGaIP/jl6U0JmcBV/z2/ZVq7/UYOz -/b+KRvy+b7T1fp9slQrj/dFMA9bM6l3EnbpYisvjyXBZBgOiHKjlz2HR7uefSAae -cpV//Gy09UrYGoPuvkDnbwl5FOzXPeTozoLq6F0CCASg7mbUYPNjjw69zxwb7qsD -nKq+iLV0/WOTaNdBGcsyu5/0DhLBI3f2aW4DgMZjWWgQs6elr+Xy1e5r6xh3SNzy -i9FEgBsxFfWZ6JJ637xOMbIK3Erk5FkGe2F0yvjznZ7i3Y3HfQ/EeXaY4h8VUIUK -Fjqpj26xXdEtGLUCQ6BM+yzyfNay1pAbOZAaFnRtdZ7NEZpOPutPdIIxb/su9H9f -Mzqaa+yMx+65dfSJEfciSD7ZXEGTxMV31kFbIa56HgN7jzKj4fklXXaTLjVOgZYz -nLuaSRgCbFXZAHU5+gDNHNnwZBCDuoalYXxYd4NdKITtpzLusHMvOCD1RC2vd7QK -jETP6unofLe+1444SD7Ww+1vi4qahqwqoxlvJ2GGBmCEvFq1Z9adYM+MlGjrH1yq -Z/eePR/SMWZOOAQGFnx0SZ/rWtDvVn4TZldLkNJkTFcn3KyaOU/3eV4Ls0dB7K1Y -aa0/BV7cganBp8dBbpTcX3qnh9MeH3ANg
svn commit: r1713878 - /commons/proper/collections/branches/COLLECTIONS_3_2_X/NOTICE.txt
Author: tn Date: Wed Nov 11 15:45:09 2015 New Revision: 1713878 URL: http://svn.apache.org/viewvc?rev=1713878=rev Log: Update NOTICE.txt with currenty year. Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/NOTICE.txt Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/NOTICE.txt URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/NOTICE.txt?rev=1713878=1713877=1713878=diff == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/NOTICE.txt (original) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/NOTICE.txt Wed Nov 11 15:45:09 2015 @@ -1,5 +1,5 @@ Apache Commons Collections -Copyright 2001-2008 The Apache Software Foundation +Copyright 2001-2015 The Apache Software Foundation This product includes software developed by The Apache Software Foundation (http://www.apache.org/).
svn commit: r1713845 - in /commons/proper/collections/branches/COLLECTIONS_3_2_X/src: java/org/apache/commons/collections/functors/ test/org/apache/commons/collections/ test/org/apache/commons/collect
Author: tn Date: Wed Nov 11 14:02:16 2015 New Revision: 1713845 URL: http://svn.apache.org/viewvc?rev=1713845=rev Log: [COLLECTIONS-580] Improve fix applied to InvokerTransformer and also apply it for other classes which are considered to be unsafe, improve tests. Added: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/AbstractTestSerialization.java (with props) commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestAll.java (with props) commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestCloneTransformer.java (with props) commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestForClosure.java (with props) commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestInstantiateFactory.java (with props) commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestInstantiateTransformer.java (with props) commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestWhileClosure.java (with props) Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/CloneTransformer.java commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/ForClosure.java commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/FunctorUtils.java commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/InstantiateFactory.java commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/InstantiateTransformer.java commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/InvokerTransformer.java commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/WhileClosure.java commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/package.html commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/TestAllPackages.java commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestInvokerTransformer.java Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/CloneTransformer.java URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/CloneTransformer.java?rev=1713845=1713844=1713845=diff == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/CloneTransformer.java (original) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/CloneTransformer.java Wed Nov 11 14:02:16 2015 @@ -16,6 +16,9 @@ */ package org.apache.commons.collections.functors; +import java.io.IOException; +import java.io.ObjectInputStream; +import java.io.ObjectOutputStream; import java.io.Serializable; import org.apache.commons.collections.Transformer; @@ -24,7 +27,17 @@ import org.apache.commons.collections.Tr * Transformer implementation that returns a clone of the input object. * * Clone is performed using PrototypeFactory.getInstance(input).create(). - * + * + * WARNING: from v3.2.2 onwards this class will throw an + * {@link UnsupportedOperationException} when trying to serialize or + * de-serialize an instance to prevent potential remote code execution exploits. + * + * In order to re-enable serialization support for {@code CloneTransformer} + * the following system property can be used (via -Dproperty=true): + * + * org.apache.commons.collections.enableUnsafeSerialization + * + * * @since Commons Collections 3.0 * @version $Revision$ $Date$ * @@ -68,4 +81,21 @@ public class CloneTransformer implements return PrototypeFactory.getInstance(input).create(); } +/** + * Overrides the default writeObject implementation to prevent + * serialization (see COLLECTIONS-580). + */ +private void writeObject(ObjectOutputStream os) throws IOException { +FunctorUtils.checkUnsafeSerialization(CloneTransformer.class); +os.defaultWriteObject(); +} + +/** + * Overrides the default readObject implementation to prevent + * de-serialization (see COLLECTIONS-580). + */ +private void readObject(ObjectInputStream is) throws ClassNotFoundException, IOException
svn commit: r1713849 - in /commons/proper/collections/branches/COLLECTIONS_3_2_X/src: java/org/apache/commons/collections/functors/ test/org/apache/commons/collections/functors/
Author: tn Date: Wed Nov 11 14:21:37 2015 New Revision: 1713849 URL: http://svn.apache.org/viewvc?rev=1713849=rev Log: [COLLECTIONS-580] Add fix for PrototypeFactory as well. Added: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestPrototypeFactory.java (with props) Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/PrototypeFactory.java commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/package.html commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestAll.java Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/PrototypeFactory.java URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/PrototypeFactory.java?rev=1713849=1713848=1713849=diff == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/PrototypeFactory.java (original) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/PrototypeFactory.java Wed Nov 11 14:21:37 2015 @@ -49,6 +49,16 @@ public class PrototypeFactory { * public copy constructor * serialization clone * + * + * WARNING: from v3.2.2 onwards this method will return a {@code Factory} + * that will throw an {@link UnsupportedOperationException} when trying to serialize + * or de-serialize it to prevent potential remote code execution exploits. + * + * In order to re-enable serialization support the following system property + * can be used (via -Dproperty=true): + * + * org.apache.commons.collections.enableUnsafeSerialization + * * * @param prototype the object to clone each time in the factory * @return the prototype factory @@ -144,6 +154,24 @@ public class PrototypeFactory { throw new FunctorException("PrototypeCloneFactory: Clone method threw an exception", ex); } } + +/** + * Overrides the default writeObject implementation to prevent + * serialization (see COLLECTIONS-580). + */ +private void writeObject(ObjectOutputStream os) throws IOException { +FunctorUtils.checkUnsafeSerialization(PrototypeCloneFactory.class); +os.defaultWriteObject(); +} + +/** + * Overrides the default readObject implementation to prevent + * de-serialization (see COLLECTIONS-580). + */ +private void readObject(ObjectInputStream is) throws ClassNotFoundException, IOException { +FunctorUtils.checkUnsafeSerialization(PrototypeCloneFactory.class); +is.defaultReadObject(); +} } // PrototypeSerializationFactory @@ -204,6 +232,24 @@ public class PrototypeFactory { } } } + +/** + * Overrides the default writeObject implementation to prevent + * serialization (see COLLECTIONS-580). + */ +private void writeObject(ObjectOutputStream os) throws IOException { + FunctorUtils.checkUnsafeSerialization(PrototypeSerializationFactory.class); +os.defaultWriteObject(); +} + +/** + * Overrides the default readObject implementation to prevent + * de-serialization (see COLLECTIONS-580). + */ +private void readObject(ObjectInputStream is) throws ClassNotFoundException, IOException { + FunctorUtils.checkUnsafeSerialization(PrototypeSerializationFactory.class); +is.defaultReadObject(); +} } } Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/package.html URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/package.html?rev=1713849=1713848=1713849=diff == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/package.html (original) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/src/java/org/apache/commons/collections/functors/package.html Wed Nov 11 14:21:37 2015 @@ -38,6 +38,8 @@ Classes considered to be unsafe are: InstantiateFactory InstantiateTransformer InvokerTransformer + PrototypeFactory$PrototypeCloneFactory + PrototypeFactory$PrototypeSerializationFactory WhileClosure Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apac
svn commit: r1713553 - /commons/proper/collections/branches/COLLECTIONS_3_2_X/src/changes/release-notes.vm
Author: tn Date: Mon Nov 9 21:49:12 2015 New Revision: 1713553 URL: http://svn.apache.org/viewvc?rev=1713553=rev Log: Add release-notes template. Added: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/changes/release-notes.vm Added: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/changes/release-notes.vm URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/src/changes/release-notes.vm?rev=1713553=auto == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/src/changes/release-notes.vm (added) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/src/changes/release-notes.vm Mon Nov 9 21:49:12 2015 @@ -0,0 +1,138 @@ +## Licensed to the Apache Software Foundation (ASF) under one +## or more contributor license agreements. See the NOTICE file +## distributed with this work for additional information +## regarding copyright ownership. The ASF licenses this file +## to you under the Apache License, Version 2.0 (the +## "License"); you may not use this file except in compliance +## with the License. You may obtain a copy of the License at +## +## http://www.apache.org/licenses/LICENSE-2.0 +## +## Unless required by applicable law or agreed to in writing, +## software distributed under the License is distributed on an +## "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY +## KIND, either express or implied. See the License for the +## specific language governing permissions and limitations +## under the License. + Apache ${project.name} ${version} RELEASE NOTES + +$introduction.replaceAll("(?http://maven.apache.org/plugins/maven-changes-plugin/examples/using-a-custom-announcement-template.html +## Hack to improve layout: replace all pairs of spaces with a single new-line +$release.description.replaceAll(" ", " +") + +## Fix up indentation for multi-line action descriptions +#macro ( indent ) +#set($action=$action.replaceAll("(?m)^ +"," ")) +#end +#if ($release.getActions().size() == 0) +No changes defined in this version. +#else +Changes in this version include: + +#if ($release.getActions('add').size() !=0) +New features: +#foreach($actionItem in $release.getActions('add')) +## Use replaceAll to fix up LF-only line ends on Windows. +#set($action=$actionItem.getAction().replaceAll("\n"," +")) +#indent() +#if ($actionItem.getIssue()) +#set($issue=$actionItem.getIssue()) +#else +#set($issue="") +#end +#if ($actionItem.getDueTo()) +#set($dueto=$actionItem.getDueTo()) +#else +#set($dueto="") +#end +o#if($!issue != "") $issue: #end ${action} #if($!dueto != "")Thanks to $dueto. #end + +#set($issue="") +#set($dueto="") +#end +#end + +#if ($release.getActions('fix').size() !=0) +Fixed Bugs: +#foreach($actionItem in $release.getActions('fix')) +## Use replaceAll to fix up LF-only line ends on Windows. +#set($action=$actionItem.getAction().replaceAll("\n"," +")) +#indent() +#if ($actionItem.getIssue()) +#set($issue=$actionItem.getIssue()) +#else +#set($issue="") +#end +#if ($actionItem.getDueTo()) +#set($dueto=$actionItem.getDueTo()) +#else +#set($dueto="") +#end +o#if($!issue != "") $issue: #end ${action} #if($!dueto != "")Thanks to $dueto. #end + +#set($issue="") +#set($dueto="") +#end +#end + +#if ($release.getActions('update').size() !=0) +Changes: +#foreach($actionItem in $release.getActions('update')) +## Use replaceAll to fix up LF-only line ends on Windows. +#set($action=$actionItem.getAction().replaceAll("\n"," +")) +#indent() +#if ($actionItem.getIssue()) +#set($issue=$actionItem.getIssue()) +#else +#set($issue="") +#end +#if ($actionItem.getDueTo()) +#set($dueto=$actionItem.getDueTo()) +#else +#set($dueto="") +#end +o#if($!issue != "") $issue: #end ${action} #if($!dueto != "")Thanks to $dueto. #end + +#set($issue="") +#set($dueto="") +#end +#end + +#if ($release.getActions('remove').size() !=0) +Removed: +#foreach($actionItem in $release.getActions('remove')) +## Use replaceAll to fix up LF-only line ends on Windows. +#set($action=$actionItem.getAction().replaceAll("\n"," +")) +#indent() +#if ($actionItem.getIssue()) +#set($issue=$actionItem.getIssue()) +#else +#set($issue="") +#end +#if ($actionItem.getDueTo()) +#set($dueto=$actionItem.getDueTo()) +#else +#set($dueto="") +#end +o#if($!issue != "") $issue. #end ${action} #if($!dueto != "")Thanks to $dueto. #end + +#set($issue="") +#set($dueto="") +#end +#end +## End of main loop +#end + +For complete information on ${project.name}, including instructions on how to submit bug reports, +patches, or suggestions for improvement, see the Apache ${project.name} website: + +${project.url}
svn commit: r1713554 - in /commons/proper/collections/branches/COLLECTIONS_3_2_X: RELEASE-NOTES.html RELEASE-NOTES.txt src/assembly/bin.xml src/assembly/src.xml
Author: tn Date: Mon Nov 9 22:02:29 2015 New Revision: 1713554 URL: http://svn.apache.org/viewvc?rev=1713554=rev Log: Create release notes for 3.2.2, changing from html to txt format. Added: commons/proper/collections/branches/COLLECTIONS_3_2_X/RELEASE-NOTES.txt (with props) Removed: commons/proper/collections/branches/COLLECTIONS_3_2_X/RELEASE-NOTES.html Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/assembly/bin.xml commons/proper/collections/branches/COLLECTIONS_3_2_X/src/assembly/src.xml Added: commons/proper/collections/branches/COLLECTIONS_3_2_X/RELEASE-NOTES.txt URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/RELEASE-NOTES.txt?rev=1713554=auto == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/RELEASE-NOTES.txt (added) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/RELEASE-NOTES.txt Mon Nov 9 22:02:29 2015 @@ -0,0 +1,67 @@ + Apache Commons Collections +Version 3.2.2 +RELEASE NOTES + + +INTRODUCTION: + +Commons collections is a project to develop and maintain collection classes +based on and inspired by the JDK collection framework. +This release is JDK1.3 compatible, and does not use JDK1.5 generics. + +This v3.2.2 release is a bugfix release, fixing several bugs present in the previous +releases of the 3.2 branch. Additionally, this release provides a mitigation for a +known remote code exploitation via the standard java object serialization mechanism. +By default, de-serialization of "InvokerTransformer" instances is prohibited and +will result in an exception. For more details, please refer to COLLECTIONS-580. + +All users are strongly encouraged to updated to this release. + + +Changes in this version include: + +CHANGES +=== + +o COLLECTIONS-580: De-serialization of "InvokerTransformer" is disabled by default as this +can be exploited for remote code execution attacks. To re-enable the +feature the system property + "org.apache.commons.collections.invokertransformer.enableDeserialization" +needs to be set to "true". + +BUGFIXES + + +o COLLECTIONS-538: "ExtendedProperties" will now use a privileged action to access the +"file.separator" system property. In case the class does not have +permission to read system properties, the "File#separator" field will +be used instead. Thanks to Trejkaz. +o COLLECTIONS-447: Tree traversal with a TreeListIterator will not be affected anymore by +the removal of an element directly after a call to previous(). Thanks to Jeffrey Barnes. +o COLLECTIONS-444: SetUniqueList.set(int, Object) now works correctly if the object to be inserted +is already placed at the given position. Thanks to Thomas Vahrst, John Vasileff. +o COLLECTIONS-350: Removed debug output in "MapUtils#getNumber(Map)". Thanks to Michael Akerman. +o COLLECTIONS-335: Fixed cache assignment for "TreeBidiMap#entrySet". Thanks to sebb. +o COLLECTIONS-334: Synchronized access to lock in "StaticBucketMap#size()". Thanks to sebb. +o COLLECTIONS-307: "SetUniqueList#subList()#contains(Object)" will now correctly check the subList +rather than the parent list. Thanks to Christian Semrau. +o COLLECTIONS-304: "SetUniqueList#set(int, Object)" will now correctly enforce the uniqueness constraint. +Thanks to Rafa? Figas,Bjorn Townsend. +o COLLECTIONS-294: "CaseInsensitiveMap" will now convert input strings to lower-case in a +locale-independent manner. Thanks to Benjamin Bentmann. +o COLLECTIONS-266: "MultiKey" will now be correctly serialized/de-serialized. Thanks to Joerg Schaible. +o COLLECTIONS-261: "Flat3Map#remove(Object)" will now return the correct value mapped to the removed key +if the size of the map is less or equal 3. Thanks to ori. +o COLLECTIONS-249: "SetUniqueList.addAll(int, Collection)" now correctly add the collection at the +provided index. Thanks to Joe Kelly. +o COLLECTIONS-228: "MultiValueMap#put(Object, Object)" and "MultiValueMap#putAll(Object, Collection)" +now correctly return if the map has changed by this operation. +o COLLECTIONS-219: "CollectionUtils#removeAll" wrongly called "ListUtils#retainAll". Thanks to Tom Leccese. +o COLLECTIONS-217: Calling "setValue(Object)" on any Entry returned by a "Flat3Map" will now +correctly set the value for the
svn commit: r11092 - in /dev/commons/collections: ./ binaries/ source/
Author: tn Date: Mon Nov 9 22:22:07 2015 New Revision: 11092 Log: Uploaded distribution files for Commons Collections 3.2.2. Added: dev/commons/collections/RELEASE-NOTES.txt (with props) dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz (with props) dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.asc dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.md5 dev/commons/collections/binaries/commons-collections-3.2.2-bin.tar.gz.sha1 dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip (with props) dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.asc dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.md5 dev/commons/collections/binaries/commons-collections-3.2.2-bin.zip.sha1 dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz (with props) dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz.asc dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz.md5 dev/commons/collections/source/commons-collections-3.2.2-src.tar.gz.sha1 dev/commons/collections/source/commons-collections-3.2.2-src.zip (with props) dev/commons/collections/source/commons-collections-3.2.2-src.zip.asc dev/commons/collections/source/commons-collections-3.2.2-src.zip.md5 dev/commons/collections/source/commons-collections-3.2.2-src.zip.sha1 Added: dev/commons/collections/RELEASE-NOTES.txt == --- dev/commons/collections/RELEASE-NOTES.txt (added) +++ dev/commons/collections/RELEASE-NOTES.txt Mon Nov 9 22:22:07 2015 @@ -0,0 +1,67 @@ + Apache Commons Collections +Version 3.2.2 +RELEASE NOTES + + +INTRODUCTION: + +Commons collections is a project to develop and maintain collection classes +based on and inspired by the JDK collection framework. +This release is JDK1.3 compatible, and does not use JDK1.5 generics. + +This v3.2.2 release is a bugfix release, fixing several bugs present in the previous +releases of the 3.2 branch. Additionally, this release provides a mitigation for a +known remote code exploitation via the standard java object serialization mechanism. +By default, de-serialization of "InvokerTransformer" instances is prohibited and +will result in an exception. For more details, please refer to COLLECTIONS-580. + +All users are strongly encouraged to updated to this release. + + +Changes in this version include: + +CHANGES +=== + +o COLLECTIONS-580: De-serialization of "InvokerTransformer" is disabled by default as this +can be exploited for remote code execution attacks. To re-enable the +feature the system property + "org.apache.commons.collections.invokertransformer.enableDeserialization" +needs to be set to "true". + +BUGFIXES + + +o COLLECTIONS-538: "ExtendedProperties" will now use a privileged action to access the +"file.separator" system property. In case the class does not have +permission to read system properties, the "File#separator" field will +be used instead. Thanks to Trejkaz. +o COLLECTIONS-447: Tree traversal with a TreeListIterator will not be affected anymore by +the removal of an element directly after a call to previous(). Thanks to Jeffrey Barnes. +o COLLECTIONS-444: SetUniqueList.set(int, Object) now works correctly if the object to be inserted +is already placed at the given position. Thanks to Thomas Vahrst, John Vasileff. +o COLLECTIONS-350: Removed debug output in "MapUtils#getNumber(Map)". Thanks to Michael Akerman. +o COLLECTIONS-335: Fixed cache assignment for "TreeBidiMap#entrySet". Thanks to sebb. +o COLLECTIONS-334: Synchronized access to lock in "StaticBucketMap#size()". Thanks to sebb. +o COLLECTIONS-307: "SetUniqueList#subList()#contains(Object)" will now correctly check the subList +rather than the parent list. Thanks to Christian Semrau. +o COLLECTIONS-304: "SetUniqueList#set(int, Object)" will now correctly enforce the uniqueness constraint. +Thanks to Rafa? Figas,Bjorn Townsend. +o COLLECTIONS-294: "CaseInsensitiveMap" will now convert input strings to lower-case in a +locale-independent manner. Thanks to Benjamin Bentmann. +o COLLECTIONS-266: "MultiKey" will now be correctly serialized/de-serialized. Thanks to Joerg Schaible. +o COLLECTIONS-261: "Flat3Map#remove(Object)" will now return the correct value mapped to the removed key +if the size of the map is less or equal 3. Tha
svn commit: r1713540 - /commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestInvokerTransformer.java
Author: tn Date: Mon Nov 9 21:20:49 2015 New Revision: 1713540 URL: http://svn.apache.org/viewvc?rev=1713540=rev Log: Add missing AL header. Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestInvokerTransformer.java Modified: commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestInvokerTransformer.java URL: http://svn.apache.org/viewvc/commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestInvokerTransformer.java?rev=1713540=1713539=1713540=diff == --- commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestInvokerTransformer.java (original) +++ commons/proper/collections/branches/COLLECTIONS_3_2_X/src/test/org/apache/commons/collections/functors/TestInvokerTransformer.java Mon Nov 9 21:20:49 2015 @@ -1,3 +1,19 @@ +/* + * Licensed to the Apache Software Foundation (ASF) under one or more + * contributor license agreements. See the NOTICE file distributed with + * this work for additional information regarding copyright ownership. + * The ASF licenses this file to You under the Apache License, Version 2.0 + * (the "License"); you may not use this file except in compliance with + * the License. You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + */ package org.apache.commons.collections.functors; import java.io.ByteArrayInputStream;