[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
122/376: Warn about untrusted binary caches in extra-binary-caches
From: |
Ludovic Courtès |
Subject: |
122/376: Warn about untrusted binary caches in extra-binary-caches |
Date: |
Wed, 28 Jan 2015 22:04:28 +0000 |
civodul pushed a commit to tag 1.8
in repository guix.
commit 57695d8f7630581c53ab37fe4123f92a3b1f426e
Author: Eelco Dolstra <address@hidden>
Date: Thu Aug 7 22:46:35 2014 +0200
Warn about untrusted binary caches in extra-binary-caches
---
scripts/download-from-binary-cache.pl.in | 7 +++++--
1 files changed, 5 insertions(+), 2 deletions(-)
diff --git a/scripts/download-from-binary-cache.pl.in
b/scripts/download-from-binary-cache.pl.in
index a3af75f..49f829b 100644
--- a/scripts/download-from-binary-cache.pl.in
+++ b/scripts/download-from-binary-cache.pl.in
@@ -237,7 +237,7 @@ sub getAvailableCaches {
my @untrustedUrls = strToList
$Nix::Config::config{"untrusted-binary-caches"};
@urls = ();
foreach my $url (@untrustedUrls) {
- die "binary cache ‘$url’ is not trusted (please add it to
‘trusted-binary-caches’ address@hidden in $Nix::Config::confDir/nix.conf)\n"
+ die "binary cache ‘$url’ is not trusted (please add it to
‘trusted-binary-caches’ in $Nix::Config::confDir/nix.conf)\n"
unless scalar(grep { $url eq $_ } @trustedUrls) > 0;
push @urls, $url;
}
@@ -245,7 +245,10 @@ sub getAvailableCaches {
my @untrustedUrls = strToList
$Nix::Config::config{"untrusted-extra-binary-caches"} // "";
foreach my $url (@untrustedUrls) {
- next unless scalar(grep { $url eq $_ } @trustedUrls) > 0;
+ unless (scalar(grep { $url eq $_ } @trustedUrls) > 0) {
+ warn "binary cache ‘$url’ is not trusted (please add it to
‘trusted-binary-caches’ in $Nix::Config::confDir/nix.conf)\n";
+ next;
+ }
push @urls, $url;
}
- 121/376: nix-install-package: Use extra-binary-caches, (continued)
- 121/376: nix-install-package: Use extra-binary-caches, Ludovic Courtès, 2015/01/28
- 119/376: Add support for order-only dependencies, Ludovic Courtès, 2015/01/28
- 118/376: install-nix-from-closure.sh: Use https channel if possible, Ludovic Courtès, 2015/01/28
- 114/376: Refactor, Ludovic Courtès, 2015/01/28
- 117/376: Remove unnecessary call to addTempRoot(), Ludovic Courtès, 2015/01/28
- 115/376: Move some options out of globals, Ludovic Courtès, 2015/01/28
- 116/376: Doh, Ludovic Courtès, 2015/01/28
- 112/376: Add option ‘build-extra-chroot-dirs’, Ludovic Courtès, 2015/01/28
- 111/376: Get rid of "killing <pid>" message for unused build hooks, Ludovic Courtès, 2015/01/28
- 129/376: Remove log2html.xsl and friends, Ludovic Courtès, 2015/01/28
- 122/376: Warn about untrusted binary caches in extra-binary-caches,
Ludovic Courtès <=
- 113/376: Update manual, Ludovic Courtès, 2015/01/28
- 126/376: Handle compound single dash options properly, Ludovic Courtès, 2015/01/28
- 124/376: Fix warning about non-existant -I directories, Ludovic Courtès, 2015/01/28
- 127/376: Use regular file GC roots if possible, Ludovic Courtès, 2015/01/28
- 128/376: nix-log2xml: Handle UTF-8 characters, Ludovic Courtès, 2015/01/28
- 132/376: nix-shell: Use $XDG_RUNTIME_DIR, Ludovic Courtès, 2015/01/28
- 120/376: download-from-binary-cache.pl: Respect $SSL_CERT_FILE, Ludovic Courtès, 2015/01/28
- 123/376: Remove pointless NIX_LOG_TYPE environment variable, Ludovic Courtès, 2015/01/28
- 136/376: Propagate remote timeouts properly, Ludovic Courtès, 2015/01/28
- 131/376: Use $XDG_RUNTIME_DIR for temporary files, Ludovic Courtès, 2015/01/28