NuGet Authentication on Artifactory from Visual Studio

We have a local Artifactory Pro server that serves nuget packets and uses LDAP to authenticate all users. Using Artifactory-NuGet from cmdline works fine, but when I try to use the package manager from Visual Studio, authentication fails.

I noticed that Visual Studio is trying to add a domain prefix after the first failed authentication attempt: the login attempt as a "user" fails, and then the login authorization window "DOMAIN \ user" is the username.

I am not sure if the source of the problem is in Visual Studio or in Artifactory. I noticed that web access to Artifactory does not accept user names in the form "DOMAIN \ user", although I believe that this is necessary.

So my question is: how do I authenticate to the NuGet-supported LDAP server provided by Artifactory from Visual Studio?

+4
source share
2 answers

Make sure you enter your username (LDAP username) and your encrypted password, the one you can get through artifactory webapp

+2
source

, NuGet.

, , VS . , cookie , VS.

Browser
Request = https://server/repo/artifact.pkg
Responce = 401 not authrised
{user prompted for username and password}
Request = http TUNNEL encryped basic login
Responce = 200 encrypted security token
Request = https://server/repo/artifact.pkg + security token
Responce = 200 the pkg file


Visual studio
Request = https://server/repo/$metadata
Responce = 401 not authrised
{user prompted for username and password}
Request = http TUNNEL encryped basic login
Responce = 200 encrypted security token
Request = https://server/repo/$metadata + security token
Responce = 200 <edmx> list of artifacts
Request = https://server/repo/artifact.pkg
Responce = 401 not authrised
{user prompted for username and password}
Request = http TUNNEL encryped basic login
Responce = 200 encrypted security token
Request = https://server/repo/artifact.pkg
Responce = 301 its moved to "https://server/repo/artifact.pkg"

VS , cookie . , Windows cookie . , MS.

+1

All Articles