Merge pull request #8412 from bayandin/add-allow-list-for-certificates

audit: add CERT_ERROR_ALLOWLIST
This commit is contained in:
Alexander Bayandin 2020-08-20 20:23:25 +01:00 committed by GitHub
commit 43fa35bdf0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -545,6 +545,10 @@ module Homebrew
problem "Versioned formulae in homebrew/core should use `keg_only :versioned_formula`"
end
CERT_ERROR_ALLOWLIST = {
"monero" => "https://www.getmonero.org/",
}.freeze
def audit_homepage
homepage = formula.homepage
@ -552,6 +556,8 @@ module Homebrew
return unless @online
return if CERT_ERROR_ALLOWLIST[formula.name] == homepage
return unless DevelopmentTools.curl_handles_most_https_certificates?
if http_content_problem = curl_check_http_content(homepage,