swagger-api / swagger-api/swagger-codegen

Support for newer versions of okhttpclient and logging-interceptor over security vulnerable current versions.

Open
#9,484 2 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Mustache
Stars
17.8k
Forks
6k
PR merge metrics
No merged PRs in 30d

Description

Description

Current codegen cli is using okhttp-2.7.5.jar which has become outdated and also has security vulnerabilities. Is there any way we can upgrade to the newer version of okhttp-3.12.1 jar.

Same is the case with logging-interceptor-2.7.5 jars with logging-interceptor- 3.11.0.

Normally direct version upgrade is not a problem but for these major changes have happened and the package name has also changed.

Swagger-codegen version

swagger-codegen-cli-3.0.8.jar

Swagger declaration file content or url

(for JSON code), so it becomes more readable. If it is longer than about ten lines,
please create a Gist (https://gist.github.com) or upload it somewhere else and
link it here.
-->

Command line used for generation

java -jar swagger-codegen-cli-3.0.8.jar generate -i ./test_swagger.yaml --artifact-version Version1-SNAPSHOT --invoker-package com.sample.java.client --api-package com.sample.java.client.api --model-package com.sample.java.client.datamodels -l java -o SampleJava

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at the codegen CLI dependency declarations and search for references to okhttp-2.7.5 and logging-interceptor-2.7.5. Check the package-name changes while updating them to okhttp 3.12.1 and logging-interceptor 3.11.0, then run the shown Java generation command; done means generation succeeds without the vulnerable versions.

Written by the indexing model from the issue text.

Assessment

Tech stack
java
Domain
cli, security, tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.