I followed these instructions to host a NuGet Server (version 2.2.2) on our Intranet. It works great as far as listing the packages and retrieving them in VS 2012. But when I create a package using the Nuget Package Explorer and try to publish it I am prompted with a Windows Security dialog prompting for credentials. No matter what credentials I enter it keeps re-prompting me for a user name and password and returns a 401 authentication error. Why is the NuGet server prompting me for Windows credentials and how can I get rid of it? It only does this for publishing and nothing else.
-
1Same problem... I changed the perms to the "Packages" directory to "All" and "IIS_USR", and they can write in... Still it showing a credential prompt. Help? – Taber Feb 08 '13 at 09:10
4 Answers
There are one more thing apart from permissions configuration for Packages folder. In my case I have to use URL like
http://<server>/<nuget_virtual_dir>/api/v2/package/
for pushing. It was the only solution in my case.

- 939
- 11
- 20
When you use NuGet push you need to put /api/v2/package after the NuGet server URL (example http://myhost/myNuGetServer/api/v2/package)
If you use the NuGet user interface (NuGet Package Explorer) you need to put just the server url than URL (example http://myhost/myNuGetServer/)
Take care also of apikey configuration in Web.config and use it in NuGet push!

- 6,414
- 3
- 28
- 45
I think a found a solution (at least to my problems):
I gave up to the Nuget problem, and I focused in the ISS 401 error. Then I gave permissions to the user "IIS AppPool\DefaultAppPool" to the app's root (or your AppPool that use the app, in my case "ASP.NET v4.0"). Then it work like charm!.
More info (and good explanation about the problem): ApplicationPoolIdentity in IIS7 401 errors
You may find this SO answer helpful, as it covers how to configure credentials on a publishing workstation (or build server, but in either case it's accurate info.)

- 1
- 1

- 8,727
- 3
- 50
- 48