Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Veracode security scan finds Medium flaw in SoftServiceLoader.java #1506

Open
cmiyachi opened this issue Aug 2, 2021 · 0 comments
Open

Veracode security scan finds Medium flaw in SoftServiceLoader.java #1506

cmiyachi opened this issue Aug 2, 2021 · 0 comments

Comments

@cmiyachi
Copy link

cmiyachi commented Aug 2, 2021

Task List

Veracode scan finds a medium security flaw in this file for the function ServiceDefinition on line / around 261.

There is little verification of the strings passed.

This is a static scan which just looks at the code itself.

Environment Information

  • Operating System: TOD
  • GORM Version: TODO
  • Grails Version (if using Grails): TODO
  • JDK Version: TODO

Example Application

Information from the Veracode scan:

A call uses reflection in an unsafe manner. An attacker can specify the class name to be instantiated, which may create unexpected control flow paths through the application. Depending on how reflection is being used, the attack vector may allow the attacker to bypass security checks or otherwise cause the application to behave in an unexpected manner. Even if the object does not implement the specified interface and a ClassCastException is thrown, the constructor of the untrusted class name will have already executed.

Veracode recommends: Validate the class name against a combination of white and black lists to ensure that only expected behavior is produced.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant