My organization started to scan all our application for vulnerabilities and the scanner show up with lots of findings.
Some CVE are easy to fix, but some require extra steps, and I wonder how to properly fix CVE in transitive dependencies, expecially Spring Boot transitive dependencies, since in my application we use spring-boot-starter dependency to pull all other Spring-related dependencies.
For example one of my application still use Spring Boot version 2.6.2 and some of the CVE findings include CVE-2022-22978 so I need to upgrade the spring-security-core dependency to, at least, version 5.6.9. Is it better to upgrade the Spring Boot version to the latest 2.6.14 or just upgrade the spring-security-core dependency? My concern on upgrading the Spring Boot version to the latest will somehow break my application and will cause a major change to the application.
- How do we properly fix CVE issue on the transitive dependency while the direct dependency has not release their fix yet?
- Is it safe just to upgrade specific transitive dependency? How do we know if the upgraded transitive dependency compatible with its direct dependency?