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

Improve https get diagnostics, add verbose option

* Implement a logging client and activate it using verbose parameter or option
   in checker and aggregator.

Co-authored-by: Sascha L. Teichmann <sascha.teichmann@intevation.de>
This commit is contained in:
Bernhard E. Reiter 2022-06-02 15:07:55 +02:00 committed by GitHub
parent e4011ea4cc
commit a849ac0d5f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 70 additions and 14 deletions

View file

@ -136,7 +136,6 @@ func LoadProviderMetadataForDomain(
// First try well-know path
wellknownURL := "https://" + domain + "/.well-known/csaf/provider-metadata.json"
log.Printf("Trying: %s\n", wellknownURL)
wellknownResult := LoadProviderMetadataFromURL(client, wellknownURL)
if wellknownResult == nil {
@ -153,7 +152,6 @@ func LoadProviderMetadataForDomain(
// Next load the PMDs from security.txt
secURL := "https://" + domain + "/.well-known/security.txt"
log.Printf("Trying: %s\n", secURL)
secResults := LoadProviderMetadatasFromSecurity(client, secURL)
if secResults == nil {
@ -212,7 +210,6 @@ func LoadProviderMetadataForDomain(
// Last resort fall back to DNS.
dnsURL := "https://csaf.data.security." + domain
log.Printf("Trying: %s\n", dnsURL)
dnsResult := LoadProviderMetadataFromURL(client, dnsURL)
if dnsResult == nil {