Current Behaviour
While validating a buildDropPath where one of the files has been intentionally tampered with, passing a directory to the outputPath parameter of the SbomValidator.ValidateSbomAsync method, the returned SBOMValidationResult has the IsSuccessful property set to true.
Expected Behaviour
While validating a buildDropPath where one of the files has been intentionally tampered with, passing a directory to the outputPath parameter of the SbomValidator.ValidateSbomAsync method, the returned SBOMValidationResult has the IsSuccessful property set to false.
Alternatively, an exception should be thrown if the output file cannot be written to.
Steps to Reproduce
- Created an artifact and generate an SBOM
- Tamper with one of the files so that hash changes
- Call
ISBOMValidator.ValidateSbomAsync with the outputPath parameter as an existing directory path
- Inspect returned result
Additonal Context
Library version used: 3.1.0