gocsaf / csaf

Tools to download or provide CSAF (Common Security Advisory Framework) documents.
https://csaf.io
42 stars 25 forks source link

Be more verbose in case of signature check failures #361

Closed s-l-teichmann closed 1 year ago

s-l-teichmann commented 1 year ago

Also simplify handling of signature keys.

For #358

s-l-teichmann commented 1 year ago

I came a cross a weird output:

{
          "num": 20,
          "description": "Public OpenPGP Key",
          "messages": [
            {
              "type": 0,
              "text": "No OpenPGP keys loaded."
            },
            {
              "type": 0,
              "text": "1 public OpenPGP key(s) loaded."
            }
          ]
        }
      ]
    }
  ],
  "version": "2.1.1-21-g7eadf00",

This wasn't the case before:

{
          "num": 20,
          "description": "Public OpenPGP Key",
          "messages": [
            {
              "type": 0,
              "text": "2 public OpenPGP key(s) loaded."
            }
          ]
        }
      ]
    }
  ],
  "version": "2.1.1-20-g3590cf1",

Good catch! Commit 87ab2ed97dbb45e6575862091de90fba7b9a70c7 should solve this.