1
0
Fork 0
mirror of https://github.com/gocsaf/csaf.git synced 2025-12-22 11:55:40 +01:00

implement rolieServiceReporter

This commit is contained in:
JanHoefelmeyer 2023-06-14 15:27:59 +02:00
parent 380ccfdf5a
commit 051de5194d

View file

@ -339,8 +339,18 @@ func (r *rolieFeedReporter) report(p *processor, domain *Domain) {
// whether it is a [RFC8322] conform JSON file that lists the
// ROLIE feed documents and sets the "message" field value
// of the "Requirement" struct as a result of that.
func (r *rolieServiceReporter) report(_ *processor, _ *Domain) {
// TODO
func (r *rolieServiceReporter) report(p *processor, domain *Domain) {
req := r.requirement(domain)
if !p.badROLIEservice.used() {
req.message(InfoType, "ROLIE service document was not checked.")
return
}
if len(p.badROLIEservice) == 0 {
req.message(InfoType, "ROLIE service document validated fine.")
return
}
req.Messages = p.badROLIEservice
}
// report tests whether a ROLIE category document is used and if so,