jenkinsci/fortify-on-demand-uploader-plugin

Not all applications appear in application dropdown

Closed this issue · 5 comments

When attempting to upload to FOD, not all applications appear in dropdown. I used POSTMAN to duplicate the API call from the source, and it does appear in it. Also of note, the application has not had any assessments run against it. Please contact reginald.brown@hpe.com for more information.

If it is related to the type of application maybe this could help.
There is a filter somewhere that discards mobile applications (https://github.com/jenkinsci/fortify-on-demand-uploader-plugin/blob/master/src/main/java/org/jenkinsci/plugins/fod/FoDAPI.java#L395). Also the current version doesn't support pagination, so if you have a large number of applications, only the first ones will show.
The PR #10 tries to solve that, and also some people are also working on an update that should fix those issues (c.f. the comments on the PR).

It's not mobile, and when I perform the GET via Postman, the app that immediately precedes it, and the one right after both show up in the plugin dropdown. I think it might be related to the fact that there has never been an assessment run against it.

Upon further investigation, I think this is related to the getReleaseList() method. That method makes the following call: "/api/v2/Releases?fields=applicationId,applicationName,releaseId,releaseName";

The application has no releases returned in that call, those that appear in the application dropdown do.

On a second look, I think that it's because of pagination that the release isn't returned, the client has 246 releases, and the API returns 50 at a time in v3, I imagine v2 was the same.

Resolved in PR #10, merged.