diff options
| author | Jaime Marquínez Ferrándiz | 2014-02-26 21:51:46 +0100 |
|---|---|---|
| committer | Adam Vandenberg | 2014-03-02 09:16:53 -0800 |
| commit | 8a014b32212b22bab2725612262733f0485fc50c (patch) | |
| tree | 075e0d3f6fc46d4a983fd79490d8751fbf1e3475 /Library | |
| parent | c534b1907d10f57220d7f13a791c38c35854b32c (diff) | |
| download | brew-8a014b32212b22bab2725612262733f0485fc50c.tar.bz2 | |
audit: Raise a problem if the SourceForge download url uses http instead of https
Signed-off-by: Adam Vandenberg <flangy@gmail.com>
Diffstat (limited to 'Library')
| -rw-r--r-- | Library/Homebrew/cmd/audit.rb | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/Library/Homebrew/cmd/audit.rb b/Library/Homebrew/cmd/audit.rb index 47b673c5f..c3db8a08a 100644 --- a/Library/Homebrew/cmd/audit.rb +++ b/Library/Homebrew/cmd/audit.rb @@ -223,7 +223,7 @@ class FormulaAuditor next if p =~ %r[svn\.sourceforge] # Is it a sourceforge http(s) URL? - next unless p =~ %r[^https?://.*\bsourceforge\.com] + next unless p =~ %r[^https?://.*\b(sourceforge|sf)\.(com|net)] if p =~ /(\?|&)use_mirror=/ problem "Don't use #{$1}use_mirror in SourceForge urls (url is #{p})." @@ -245,6 +245,10 @@ class FormulaAuditor if p =~ %r[^http://\w+\.dl\.] problem "Don't use specific dl mirrors in SourceForge urls (url is #{p})." end + + if p.start_with? "http://downloads" + problem "Use https:// URLs for downloads from SourceForge (url is #{p})." + end end # Check for git:// GitHub repo urls, https:// is preferred. |
