io.codemodder.codemods.optimize-jackson-string-usage.yaml Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of core-codemods Show documentation
Show all versions of core-codemods Show documentation
Codemods for fixing common errors across many Java projects
rules:
- id: optimize-jackson-string-usage
mode: taint
pattern-sources:
- patterns:
- pattern: $STR = IOUtils.toString((InputStream $STREAM));
pattern-sinks:
- pattern: $INSTANCE = (ObjectMapper $MAPPER).readValue($STR, $TYPE);
message: wasteful jackson deserialization
languages:
- java
severity: WARNING