3

I'm trying to restore packages with the nuget restore command using the nuget.exe command line utility.

I'm on Ubuntu 14.04, and have just performed apt-get update.

Calling mono --version returns: Mono JIT compiler version 3.2.8 (Debian 3.2.8+dfsg-4ubuntu1)

Here is my exact call and response:

$ mono nuget.exe restore
WARNING: The initialization function tries to access Value on this instance
WARNING: The initialization function tries to access Value on this instance
WARNING: The initialization function tries to access Value on this instance
WARNING: Error getting response stream (Write: The authentication or decryption has failed.): SendFailure
Unable to find version '2.0.14' of package 'FSharp.Data'.
Unable to find version '1.3.0.1' of package 'FsUnit'.
Unable to find version '1.3.0.1' of package 'FsUnit.Sample'.
Unable to find version '2.6.3' of package 'NUnit'.

I have tried with and without a nuget.config file in the same folder.

What's going wrong and what can I do to solve?

Scott Weldon
  • 9,673
  • 6
  • 48
  • 67
Nick
  • 6,366
  • 5
  • 43
  • 62
  • 2
    found the answer here http://stackoverflow.com/questions/15181888/nuget-on-linux-error-getting-response-stream – Nick Sep 20 '14 at 15:40

1 Answers1

3

The problem you describe has to do with root security certificates.

Enter the following command in your terminal:

mozroots --import --sync

As per @ahri below, here is a more up-to-date answer:

mozroots --import --sync --url https://hg.mozilla.org/mozilla-central/raw-file/tip/security‌​/nss/lib/ckfw/builti‌​ns/certdata.txt

Source

seyisulu
  • 406
  • 6
  • 13
  • A more recent update, as this didn't work for me: `mozroots --import --sync --url https://hg.mozilla.org/mozilla-central/raw-file/tip/security/nss/lib/ckfw/builtins/certdata.txt` – ahri Sep 17 '16 at 13:54
  • @ScottWeldon It appears to have moved to https://hg.mozilla.org/mozilla-central/raw-file/tip/security/nss/lib/ckfw/builtins/certdata.txt now. Perhaps the easiest thing is to simply search google for "mozilla certdata.txt" as that's how I'm hunting it down. – ahri Nov 15 '16 at 21:11