use of org.gradle.api.internal.artifacts.verification.verifier.VerificationFailure in project gradle by gradle.
the class HtmlDependencyVerificationReportRenderer method formatError.
private void formatError(RepositoryAwareVerificationFailure failure) {
VerificationFailure vf = failure.getFailure();
reportSignatureProblems(vf);
reportChecksumProblems(vf);
reportOtherProblems(vf);
}
use of org.gradle.api.internal.artifacts.verification.verifier.VerificationFailure in project gradle by gradle.
the class DependencyVerificationReportWriter method explainSingleFailure.
private void explainSingleFailure(DependencyVerificationReportRenderer renderer, ReportState state, RepositoryAwareVerificationFailure wrapper) {
VerificationFailure failure = wrapper.getFailure();
if (failure instanceof MissingChecksums) {
state.hasMissing();
} else {
if (failure instanceof SignatureVerificationFailure) {
state.failedSignatures();
if (((SignatureVerificationFailure) failure).getErrors().values().stream().map(SignatureVerificationFailure.SignatureError::getKind).noneMatch(kind -> kind == SignatureVerificationFailure.FailureKind.PASSED_NOT_TRUSTED)) {
state.maybeCompromised();
} else {
state.hasUntrustedKeys();
}
} else {
state.maybeCompromised();
}
}
renderer.reportFailure(wrapper);
}
Aggregations