HCheong147352 (Community Member) asked a question.

getting CWE ID 73 for this line of code File file = new File(fileLocation);

for our application, this function is to let user to upload their documents (picture and pdf file) so we cannot hard code the file name in logic. May i know there have any suggestion on how to fix this finding?

 

We had also implement the fix file path and extension checking but get the same finding also.


Topics (1)

No articles found
Loading

Ask the Community

Get answers, share a use case, discuss your favorite features, or get input from the community.