Skip to content

Commit

Permalink
Upgraded jackson dependency to 2.8.8 - CVE-2016-7051. Issue #1264. Re…
Browse files Browse the repository at this point in the history
…ported by Philippe Perrault.
  • Loading branch information
thboileau committed May 27, 2017
1 parent c9f6dff commit 7340432
Show file tree
Hide file tree
Showing 27 changed files with 20 additions and 9 deletions.
3 changes: 3 additions & 0 deletions build/tmpl/text/changes.txt
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,9 @@ Changes log


@version-full@ (@release-date@)
- Vulnerabilities fixed
- Upgraded jackson dependency to 2.8.8 - CVE-2016-7051. Issue #1264.
Reported by Philippe Perrault.
- Bugs fixed
- Invalid max-age value for cookie settings replaced by Integer.MAX_VALUE constant. Issue #1251.
Reported by Chad Gatesman.
Expand Down
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Binary file not shown.
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<library id="jackson" symbolicName="com.fasterxml.jackson">
<name>High-performance JSON processor</name>
<description>High-performance JSON processor</description>
<version>2.4</version>
<release>4</release>
<version>2.8</version>
<release>8</release>
<homeUri>http://jackson.codehaus.org/</homeUri>
<downloadUri>http://wiki.fasterxml.com/JacksonDownload</downloadUri>
<provider>The Codehaus foundation</provider>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,9 @@
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyDescription;
import com.fasterxml.jackson.annotation.JsonRootName;
import com.fasterxml.jackson.databind.JavaType;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.databind.SerializationConfig;
import com.fasterxml.jackson.databind.introspect.AnnotatedClass;
import com.fasterxml.jackson.databind.introspect.JacksonAnnotationIntrospector;

Expand Down Expand Up @@ -118,10 +121,12 @@ public static void addRepresentation(CollectInfo collectInfo,
if (typeInfo.isPojo()) {
// add properties definition

BeanInfo beanInfo = BeanInfoUtils.getBeanInfo(typeInfo
.getRepresentationClazz());
BeanInfo beanInfo = BeanInfoUtils.getBeanInfo(typeInfo.getRepresentationClazz());

JsonIgnoreProperties jsonIgnorePropertiesAnnotation = AnnotatedClass.construct(typeInfo.getRepresentationClazz(), new JacksonAnnotationIntrospector(), null).getAnnotation(JsonIgnoreProperties.class);
ObjectMapper mapper = new ObjectMapper();
JsonIgnoreProperties jsonIgnorePropertiesAnnotation = AnnotatedClass
.construct(mapper.constructType(typeInfo.getRepresentationClazz()), mapper.getSerializationConfig())
.getAnnotation(JsonIgnoreProperties.class);
List<String> jsonIgnoreProperties = jsonIgnorePropertiesAnnotation == null ? null : Arrays.asList(jsonIgnorePropertiesAnnotation.value());

for (PropertyDescriptor pd : beanInfo.getPropertyDescriptors()) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -91,6 +91,9 @@
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonPropertyDescription;
import com.fasterxml.jackson.annotation.JsonRootName;
import com.fasterxml.jackson.databind.JavaType;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.fasterxml.jackson.databind.SerializationConfig;
import com.fasterxml.jackson.databind.introspect.AnnotatedClass;
import com.fasterxml.jackson.databind.introspect.JacksonAnnotationIntrospector;

Expand Down Expand Up @@ -334,12 +337,12 @@ private static void addRepresentation(CollectInfo collectInfo,

if (typeInfo.isPojo()) {
// add properties definition
BeanInfo beanInfo = BeanInfoUtils.getBeanInfo(typeInfo
.getRepresentationClazz());
BeanInfo beanInfo = BeanInfoUtils.getBeanInfo(typeInfo.getRepresentationClazz());


ObjectMapper mapper = new ObjectMapper();
JsonIgnoreProperties jsonIgnorePropertiesAnnotation = AnnotatedClass
.construct(typeInfo.getRepresentationClazz(),
new JacksonAnnotationIntrospector(), null)
.construct(mapper.constructType(typeInfo.getRepresentationClazz()), mapper.getSerializationConfig())
.getAnnotation(JsonIgnoreProperties.class);
List<String> jsonIgnoreProperties = jsonIgnorePropertiesAnnotation == null ? null
: Arrays.asList(jsonIgnorePropertiesAnnotation.value());
Expand Down

0 comments on commit 7340432

Please sign in to comment.