1
0
Fork 0
mirror of https://github.com/gocsaf/csaf.git synced 2025-12-22 18:15:42 +01:00

Allow http redirects (#400)

* Fix HTTP Header redirects causing the checker to fail a domain

* Slightly clarify comment

* Formatting

---------

Co-authored-by: JanHoefelmeyer <hoefelmeyer.jan@gmail.com>
This commit is contained in:
JanHoefelmeyer 2023-07-07 14:02:58 +02:00 committed by GitHub
parent b423eed4e9
commit aeeb169111
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -166,8 +166,11 @@ func (p *processor) eval(requirement int) bool {
case 5:
return !p.badAmberRedPermissions.hasErrors()
// Currently, only domains using HTTP-Header redirects are checked.
// A domain reaching evaluation will only have HTTP-Header redirects if any,
// and thus requirement 6 will always be fullfilled.
case 6:
return len(p.redirects) == 0
return true
case 7:
return !p.badProviderMetadata.hasErrors()
case 8: