Security: don't download files we don't have checksums for. #324

This commit is contained in:
Andrey Smirnov
2015-12-22 13:52:53 +03:00
parent ca319c804e
commit 631fe44c6b
6 changed files with 4 additions and 9 deletions
+4
View File
@@ -327,6 +327,10 @@ func DownloadTryCompression(downloader aptly.Downloader, url string, expectedChe
}
if !foundChecksum {
if !ignoreMismatch {
continue
}
file, err = DownloadTemp(downloader, tryURL)
}