CAST HIGHLIGHT - Results - SCA - The ratio of “Your Code” and “Third Party” code is calculated using "number of files" instead of "Lines of Code"

In Highlight the ratio of “Your Code” and “Third Party” code is calculated using "number of files" instead of "Lines of Code". This is when Highlight calculates LoC of third-party component files if they have readable source code along with In-house code.

 

Details

Third party ratio cannot be calculated based on lines of code. because in some cases 3rd party components consist of binaries (JARs, DLLs) or dependencies for which Highlight cannot calculate the LOCs. 

So each third-party file or dependency that has been  detected  and scanned  in SCA accounts for a count of 1 for ratio calculation. 

For more details about how lines of code are counted in CAST Highlight please refer :  What is a line of code and how Highlight counts them

 
User could still build a custom extension (to calculate 3rd party ratio based on LOC) using Highlight's APIs/data for specific cases but it will likely be an approximation.  Please refer CAST Highlight API: https://rpa.casthighlight.com/api-doc/index.html. Please contact your CAST Professional Services representative for support related to this. 

 

 

Related Documentation

What is a line of code and how Highlight counts them?

CAST HIGHLIGHT - API - How to get the LOC count even when LOC count is low and is displayed only as a percentage?

CAST HIGHLIGHT - Analysis - Though Highlight uses Physical LOC counts, LOC count is lesser than expected

 

Additional Resources

CAST Highlight Troubleshooting Guides

CAST Highlight Product Documentation

 

 

Ticket

40642


 



 

 

 

Have more questions? Submit a request

Comments

Powered by Zendesk