svn commit: r48093 - in /dev/johnzon: apache-johnzon-1.2.13-src.zip apache-johnzon-1.2.13-src.zip.asc apache-johnzon-1.2.13-src.zip.sha512
Author: rmannibucau Date: Wed Jun 2 15:49:50 2021 New Revision: 48093 Log: apache-johnzon-1.2.13 (dev) Added: dev/johnzon/apache-johnzon-1.2.13-src.zip (with props) dev/johnzon/apache-johnzon-1.2.13-src.zip.asc dev/johnzon/apache-johnzon-1.2.13-src.zip.sha512 Added: dev/johnzon/apache-johnzon-1.2.13-src.zip == Binary file - no diff available. Propchange: dev/johnzon/apache-johnzon-1.2.13-src.zip -- svn:mime-type = application/octet-stream Added: dev/johnzon/apache-johnzon-1.2.13-src.zip.asc == --- dev/johnzon/apache-johnzon-1.2.13-src.zip.asc (added) +++ dev/johnzon/apache-johnzon-1.2.13-src.zip.asc Wed Jun 2 15:49:50 2021 @@ -0,0 +1,11 @@ +-BEGIN PGP SIGNATURE- + +iQEzBAABCgAdFiEEz4CgVaKtKOnvv5QqcxKfWN5h7L0FAmC3p/QACgkQcxKfWN5h +7L2kBwgArrIQPYzAdXlbGR1urFasIsUcPm6utxwRZFjN0fJAxq2Fagj9DI/gQgSR +81b4hjULqMYzgsdxdTicD5a9tiPBGbrhp+9A3i+we/uOYwEvuNBvihUx0mp53Epd +6G/l2W5urDx8gomenEaIKupBBJ73boFUJ3DTh1lSDm7Usex09a0oufWnGF9xXakH +APEzIMEU+MDFe+IxhVSxP+ecEF0BWuWcfVD0FpuJBJN0OWIcIwCc4TpC930YSGDQ +D95D5BnDU5bnKkPAvJam33bZj3AYG9ob7QHd8QTAffov0D9X5kK8EsbAe3ndWcVC +A3j7YB/FhH1j66walRrO0ivn806IpQ== +=E0ms +-END PGP SIGNATURE- Added: dev/johnzon/apache-johnzon-1.2.13-src.zip.sha512 == --- dev/johnzon/apache-johnzon-1.2.13-src.zip.sha512 (added) +++ dev/johnzon/apache-johnzon-1.2.13-src.zip.sha512 Wed Jun 2 15:49:50 2021 @@ -0,0 +1 @@ +fcc28d44c02ab13ef2c0c05a4a4100196a8217d7e2aa11f263843356270b25ce019db8cc92b9b50320321fa821f2e7fe3486315122bfc675aedefd360d7248df apache-johnzon-1.2.13-src.zip
[johnzon] 01/02: [maven-release-plugin] prepare release v1.2.13
This is an automated email from the ASF dual-hosted git repository. rmannibucau pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/johnzon.git commit ea9841db857c8b77ad633b2df614205173794958 Author: Romain Manni-Bucau AuthorDate: Wed Jun 2 17:45:21 2021 +0200 [maven-release-plugin] prepare release v1.2.13 --- johnzon-core/pom.xml | 2 +- johnzon-distribution/pom.xml | 2 +- johnzon-jaxrs/pom.xml| 2 +- johnzon-json-extras/pom.xml | 2 +- johnzon-jsonb/pom.xml| 2 +- johnzon-jsonlogic/pom.xml| 2 +- johnzon-jsonp-strict/pom.xml | 2 +- johnzon-jsonschema/pom.xml | 2 +- johnzon-mapper/pom.xml | 2 +- johnzon-maven-plugin/pom.xml | 2 +- johnzon-osgi/pom.xml | 2 +- johnzon-websocket/pom.xml| 2 +- pom.xml | 4 ++-- 13 files changed, 14 insertions(+), 14 deletions(-) diff --git a/johnzon-core/pom.xml b/johnzon-core/pom.xml index e190010..a7d9877 100644 --- a/johnzon-core/pom.xml +++ b/johnzon-core/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13-SNAPSHOT +1.2.13 4.0.0 diff --git a/johnzon-distribution/pom.xml b/johnzon-distribution/pom.xml index 4966478..e07611b 100644 --- a/johnzon-distribution/pom.xml +++ b/johnzon-distribution/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13-SNAPSHOT +1.2.13 4.0.0 diff --git a/johnzon-jaxrs/pom.xml b/johnzon-jaxrs/pom.xml index 1246565..41f434b 100644 --- a/johnzon-jaxrs/pom.xml +++ b/johnzon-jaxrs/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13-SNAPSHOT +1.2.13 4.0.0 diff --git a/johnzon-json-extras/pom.xml b/johnzon-json-extras/pom.xml index 528cc29..7e2408a 100644 --- a/johnzon-json-extras/pom.xml +++ b/johnzon-json-extras/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13-SNAPSHOT +1.2.13 4.0.0 diff --git a/johnzon-jsonb/pom.xml b/johnzon-jsonb/pom.xml index 73ca292..f02ab59 100644 --- a/johnzon-jsonb/pom.xml +++ b/johnzon-jsonb/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13-SNAPSHOT +1.2.13 4.0.0 diff --git a/johnzon-jsonlogic/pom.xml b/johnzon-jsonlogic/pom.xml index b1169ac..a717310 100644 --- a/johnzon-jsonlogic/pom.xml +++ b/johnzon-jsonlogic/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13-SNAPSHOT +1.2.13 4.0.0 diff --git a/johnzon-jsonp-strict/pom.xml b/johnzon-jsonp-strict/pom.xml index b2c7e55..482102c 100644 --- a/johnzon-jsonp-strict/pom.xml +++ b/johnzon-jsonp-strict/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13-SNAPSHOT +1.2.13 4.0.0 diff --git a/johnzon-jsonschema/pom.xml b/johnzon-jsonschema/pom.xml index bd61f0d..f22ca60 100644 --- a/johnzon-jsonschema/pom.xml +++ b/johnzon-jsonschema/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13-SNAPSHOT +1.2.13 4.0.0 diff --git a/johnzon-mapper/pom.xml b/johnzon-mapper/pom.xml index f4eaf18..a023ee0 100644 --- a/johnzon-mapper/pom.xml +++ b/johnzon-mapper/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13-SNAPSHOT +1.2.13 4.0.0 diff --git a/johnzon-maven-plugin/pom.xml b/johnzon-maven-plugin/pom.xml index 4404c0c..b9aa351 100644 --- a/johnzon-maven-plugin/pom.xml +++ b/johnzon-maven-plugin/pom.xml @@ -23,7 +23,7 @@ johnzon org.apache.johnzon -1.2.13-SNAPSHOT +1.2.13 johnzon-maven-plugin diff --git a/johnzon-osgi/pom.xml b/johnzon-osgi/pom.xml index 9e736a7..2b6bb65 100644 --- a/johnzon-osgi/pom.xml +++ b/johnzon-osgi/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13-SNAPSHOT +1.2.13 4.0.0 diff --git a/johnzon-websocket/pom.xml b/johnzon-websocket/pom.xml index 6066c1e..5cbaf95 100644 --- a/johnzon-websocket/pom.xml +++ b/johnzon-websocket/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13-SNAPSHOT +1.2.13 4.0.0 diff --git a/pom.xml b/pom.xml index d8f13d3..cda2fb3 100644 --- a/pom.xml +++ b/pom.xml @@ -29,7 +29,7 @@ org.apache.johnzon johnzon pom - 1.2.13-SNAPSHOT + 1.2.13 Apache Johnzon Apache Johnzon is an implementation of JSR-353 (JavaTM API for JSON Processing). 2014 @@ -491,7 +491,7 @@ scm:git:https://git-wip-us.apache.org/repos/asf/johnzon.git scm:git:https://git-wip-us.apache.org/repos/asf/johnzon.git https://git-wip-us.apache.org/repos/asf?p=johnzon.git -HEAD +v1.2.13
[johnzon] branch master updated (48c34e6 -> 54ce79d)
This is an automated email from the ASF dual-hosted git repository. rmannibucau pushed a change to branch master in repository https://gitbox.apache.org/repos/asf/johnzon.git. from 48c34e6 [JOHNZON-346] avoid array out of bound exception when string gets an escaped character new ea9841d [maven-release-plugin] prepare release v1.2.13 new 54ce79d [maven-release-plugin] prepare for next development iteration The 2 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "add" were already present in the repository and have only been added to this reference. Summary of changes: johnzon-core/pom.xml | 2 +- johnzon-distribution/pom.xml | 2 +- johnzon-jaxrs/pom.xml| 2 +- johnzon-json-extras/pom.xml | 2 +- johnzon-jsonb/pom.xml| 2 +- johnzon-jsonlogic/pom.xml| 2 +- johnzon-jsonp-strict/pom.xml | 2 +- johnzon-jsonschema/pom.xml | 2 +- johnzon-mapper/pom.xml | 2 +- johnzon-maven-plugin/pom.xml | 2 +- johnzon-osgi/pom.xml | 2 +- johnzon-websocket/pom.xml| 2 +- pom.xml | 2 +- 13 files changed, 13 insertions(+), 13 deletions(-)
[johnzon] 02/02: [maven-release-plugin] prepare for next development iteration
This is an automated email from the ASF dual-hosted git repository. rmannibucau pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/johnzon.git commit 54ce79d1f492c37df36dbf253ff27a5e48a8b25c Author: Romain Manni-Bucau AuthorDate: Wed Jun 2 17:45:31 2021 +0200 [maven-release-plugin] prepare for next development iteration --- johnzon-core/pom.xml | 2 +- johnzon-distribution/pom.xml | 2 +- johnzon-jaxrs/pom.xml| 2 +- johnzon-json-extras/pom.xml | 2 +- johnzon-jsonb/pom.xml| 2 +- johnzon-jsonlogic/pom.xml| 2 +- johnzon-jsonp-strict/pom.xml | 2 +- johnzon-jsonschema/pom.xml | 2 +- johnzon-mapper/pom.xml | 2 +- johnzon-maven-plugin/pom.xml | 2 +- johnzon-osgi/pom.xml | 2 +- johnzon-websocket/pom.xml| 2 +- pom.xml | 4 ++-- 13 files changed, 14 insertions(+), 14 deletions(-) diff --git a/johnzon-core/pom.xml b/johnzon-core/pom.xml index a7d9877..861e314 100644 --- a/johnzon-core/pom.xml +++ b/johnzon-core/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13 +1.2.14-SNAPSHOT 4.0.0 diff --git a/johnzon-distribution/pom.xml b/johnzon-distribution/pom.xml index e07611b..efb6699 100644 --- a/johnzon-distribution/pom.xml +++ b/johnzon-distribution/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13 +1.2.14-SNAPSHOT 4.0.0 diff --git a/johnzon-jaxrs/pom.xml b/johnzon-jaxrs/pom.xml index 41f434b..b27f976 100644 --- a/johnzon-jaxrs/pom.xml +++ b/johnzon-jaxrs/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13 +1.2.14-SNAPSHOT 4.0.0 diff --git a/johnzon-json-extras/pom.xml b/johnzon-json-extras/pom.xml index 7e2408a..b216e4a 100644 --- a/johnzon-json-extras/pom.xml +++ b/johnzon-json-extras/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13 +1.2.14-SNAPSHOT 4.0.0 diff --git a/johnzon-jsonb/pom.xml b/johnzon-jsonb/pom.xml index f02ab59..6bb86de 100644 --- a/johnzon-jsonb/pom.xml +++ b/johnzon-jsonb/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13 +1.2.14-SNAPSHOT 4.0.0 diff --git a/johnzon-jsonlogic/pom.xml b/johnzon-jsonlogic/pom.xml index a717310..0f6a913 100644 --- a/johnzon-jsonlogic/pom.xml +++ b/johnzon-jsonlogic/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13 +1.2.14-SNAPSHOT 4.0.0 diff --git a/johnzon-jsonp-strict/pom.xml b/johnzon-jsonp-strict/pom.xml index 482102c..8e5dbf6 100644 --- a/johnzon-jsonp-strict/pom.xml +++ b/johnzon-jsonp-strict/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13 +1.2.14-SNAPSHOT 4.0.0 diff --git a/johnzon-jsonschema/pom.xml b/johnzon-jsonschema/pom.xml index f22ca60..9d57732 100644 --- a/johnzon-jsonschema/pom.xml +++ b/johnzon-jsonschema/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13 +1.2.14-SNAPSHOT 4.0.0 diff --git a/johnzon-mapper/pom.xml b/johnzon-mapper/pom.xml index a023ee0..c175839 100644 --- a/johnzon-mapper/pom.xml +++ b/johnzon-mapper/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13 +1.2.14-SNAPSHOT 4.0.0 diff --git a/johnzon-maven-plugin/pom.xml b/johnzon-maven-plugin/pom.xml index b9aa351..914bf3b 100644 --- a/johnzon-maven-plugin/pom.xml +++ b/johnzon-maven-plugin/pom.xml @@ -23,7 +23,7 @@ johnzon org.apache.johnzon -1.2.13 +1.2.14-SNAPSHOT johnzon-maven-plugin diff --git a/johnzon-osgi/pom.xml b/johnzon-osgi/pom.xml index 2b6bb65..d37c9b1 100644 --- a/johnzon-osgi/pom.xml +++ b/johnzon-osgi/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13 +1.2.14-SNAPSHOT 4.0.0 diff --git a/johnzon-websocket/pom.xml b/johnzon-websocket/pom.xml index 5cbaf95..cce3460 100644 --- a/johnzon-websocket/pom.xml +++ b/johnzon-websocket/pom.xml @@ -21,7 +21,7 @@ johnzon org.apache.johnzon -1.2.13 +1.2.14-SNAPSHOT 4.0.0 diff --git a/pom.xml b/pom.xml index cda2fb3..b5f776f 100644 --- a/pom.xml +++ b/pom.xml @@ -29,7 +29,7 @@ org.apache.johnzon johnzon pom - 1.2.13 + 1.2.14-SNAPSHOT Apache Johnzon Apache Johnzon is an implementation of JSR-353 (JavaTM API for JSON Processing). 2014 @@ -491,7 +491,7 @@ scm:git:https://git-wip-us.apache.org/repos/asf/johnzon.git scm:git:https://git-wip-us.apache.org/repos/asf/johnzon.git https://git-wip-us.apache.org/repos/asf?p=johnzon.git -v1.2.13 +HEAD
[johnzon] annotated tag v1.2.13 created (now c0e9504)
This is an automated email from the ASF dual-hosted git repository. rmannibucau pushed a change to annotated tag v1.2.13 in repository https://gitbox.apache.org/repos/asf/johnzon.git. at c0e9504 (tag) tagging ea9841db857c8b77ad633b2df614205173794958 (commit) replaces v1.2.12 by Romain Manni-Bucau on Wed Jun 2 17:45:31 2021 +0200 - Log - [maven-release-plugin] copy for tag v1.2.13 --- This annotated tag includes the following new commits: new ea9841d [maven-release-plugin] prepare release v1.2.13 The 1 revisions listed above as "new" are entirely new to this repository and will be described in separate emails. The revisions listed as "add" were already present in the repository and have only been added to this reference.
[johnzon] branch master updated: [JOHNZON-346] avoid array out of bound exception when string gets an escaped character
This is an automated email from the ASF dual-hosted git repository. rmannibucau pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/johnzon.git The following commit(s) were added to refs/heads/master by this push: new 48c34e6 [JOHNZON-346] avoid array out of bound exception when string gets an escaped character 48c34e6 is described below commit 48c34e68c51791b0aea15b94cb013ea8586e29da Author: Romain Manni-Bucau AuthorDate: Wed Jun 2 16:54:36 2021 +0200 [JOHNZON-346] avoid array out of bound exception when string gets an escaped character --- .../apache/johnzon/core/JsonStreamParserImpl.java | 4 +- .../johnzon/core/JsonStreamParserImplTest.java | 66 ++ 2 files changed, 69 insertions(+), 1 deletion(-) diff --git a/johnzon-core/src/main/java/org/apache/johnzon/core/JsonStreamParserImpl.java b/johnzon-core/src/main/java/org/apache/johnzon/core/JsonStreamParserImpl.java index 9d42c87..c511e0d 100644 --- a/johnzon-core/src/main/java/org/apache/johnzon/core/JsonStreamParserImpl.java +++ b/johnzon-core/src/main/java/org/apache/johnzon/core/JsonStreamParserImpl.java @@ -197,7 +197,9 @@ public class JsonStreamParserImpl extends JohnzonJsonParserImpl implements JsonC final char[] newArray = new char[fallBackCopyBuffer.length + Math.max(getBufferExtends(fallBackCopyBuffer.length), length)]; // TODO: log to adjust size once? System.arraycopy(fallBackCopyBuffer, 0, newArray, 0, fallBackCopyBufferLength); -System.arraycopy(buffer, startOfValueInBuffer, newArray, fallBackCopyBufferLength, length); +if (startOfValueInBuffer != -1) { +System.arraycopy(buffer, startOfValueInBuffer, newArray, fallBackCopyBufferLength, length); +} if (releaseFallBackCopyBufferLength) { bufferProvider.release(fallBackCopyBuffer); releaseFallBackCopyBufferLength = false; diff --git a/johnzon-core/src/test/java/org/apache/johnzon/core/JsonStreamParserImplTest.java b/johnzon-core/src/test/java/org/apache/johnzon/core/JsonStreamParserImplTest.java new file mode 100644 index 000..4537138 --- /dev/null +++ b/johnzon-core/src/test/java/org/apache/johnzon/core/JsonStreamParserImplTest.java @@ -0,0 +1,66 @@ +/* + * 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.johnzon.core; + +import org.junit.Test; + +import javax.json.stream.JsonParser; +import java.io.ByteArrayInputStream; +import java.io.IOException; +import java.nio.charset.StandardCharsets; +import java.util.ArrayList; +import java.util.List; + +import static java.util.Arrays.asList; +import static java.util.Collections.emptyMap; +import static org.junit.Assert.assertEquals; + +public class JsonStreamParserImplTest { +@Test +public void ensureNoArrayBoundErrorWhenOverflow() throws IOException { +final String json = new JsonObjectBuilderImpl( +emptyMap(), +BufferStrategyFactory.valueOf("QUEUE").newCharProvider(100), +RejectDuplicateKeysMode.TRUE) +.add("content", "{\"foo\":\"barbar\\barbarbar\"}") +.build() +.toString(); +final JsonParser parser = new JsonStreamParserImpl(new ByteArrayInputStream(json +.getBytes(StandardCharsets.UTF_8)), StandardCharsets.UTF_8, +10, +BufferStrategyFactory.valueOf("QUEUE").newCharProvider(10), +BufferStrategyFactory.valueOf("QUEUE").newCharProvider(10), +true); +final List events = new ArrayList<>(); +while (parser.hasNext()) { +final JsonParser.Event event = parser.next(); +events.add(event.name()); +switch (event) { +case VALUE_STRING: +events.add(parser.getString()); +break; +default: +} +} +parser.close(); +assertEquals( +asList("START_OBJECT", "KEY_NAME", "VALUE_STRING", "{\"foo\":\"barbar\\barbarbar\"}", "END_OBJECT"), +events); +} +}