mirror of
https://github.com/gocsaf/csaf.git
synced 2025-12-22 11:55:40 +01:00
Add check for should-be-access-protected advisories for not-authorized client.
This commit is contained in:
parent
55f6a48db1
commit
a02d9c36a7
1 changed files with 5 additions and 0 deletions
|
|
@ -715,6 +715,11 @@ func (p *processor) integrity(
|
|||
"Extracting 'tlp level' from %s failed: %v", u, err)
|
||||
} else {
|
||||
tlpe := extractTLP(tlpa)
|
||||
// If the client has no authorization it shouldn't be able to access TLP:AMBER or TLP:RED advisories
|
||||
if !p.opts.protectedAccess() && (tlpe == "AMBER" || tlpe == "RED") {
|
||||
p.badAmberRedPermissions.use()
|
||||
p.badAmberRedPermissions.error("Advisory %s of TLP level %v is not access protected.", u, tlpe)
|
||||
}
|
||||
// check if current feed has correct or all of their tlp levels entries.
|
||||
if p.labelChecker != nil {
|
||||
p.labelChecker.check(p, tlpe, u)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue